Creates a new unavailability

Request Information

URI Parameters :

None.

Body Parameters :

user_unavailability
NameDescriptionTypeAdditional information
id

Primary Key

globally unique identifier
date_start

Date+Time of the beginning

date

Required

date_end

Date+Time of the end

date

Required

modified_dateutc

Date+Time of the modified

date

Required

description

Description of the unavailability

string

Max length: 255

is_approved

Indicate if this object has been approved using a User Week Approval

boolean
user_id

User owner of this unavailability

globally unique identifier

Optionally required : user_id, user_code or user must be provided

user_code

Embedded entity "user" using ERP PK when adding/updating user_unavailability

string

Optionally required : user_id, user_code or user must be provided

user

Embedded entity "user" using node when adding/updating user_unavailability

user

Optionally required : user_id, user_code or user must be provided

user_unavailability_type_id

Type of the unavailability, cf model user_unavailability_type

globally unique identifier

Required

Optionally required : user_unavailability_type_id, user_unavailability_type_code or user_unavailability_type must be provided

user_unavailability_type_code

Embedded entity "user_unavailability_type" using ERP PK when adding/updating user_unavailability

string

Optionally required : user_unavailability_type_id, user_unavailability_type_code or user_unavailability_type must be provided

user_unavailability_type

Embedded entity "user_unavailability_type" using node when adding/updating user_unavailability

user_unavailability_type

Optionally required : user_unavailability_type_id, user_unavailability_type_code or user_unavailability_type must be provided

Request Formats :

application/json, text/json

Sample:
{
  "id": "90ea6e35-57c1-49cd-9e21-53b59a091f10",
  "date_start": "2026-10-19T13:34:45.4600552+00:00",
  "date_end": "2026-10-19T13:34:45.4600552+00:00",
  "modified_dateutc": "2026-10-19T13:34:45.4600552+00:00",
  "description": "sample string 5",
  "is_approved": true,
  "user_id": "68043b72-6eaf-4176-9972-ef00b9c8b923",
  "user_code": "sample string 8",
  "user": {
    "id": "f8cdc203-2e96-4db5-b6cb-04206d92d660",
    "db_language_id": "461a9375-4a7e-48b7-9d39-2ed10cc52af4",
    "username": "sample string 3",
    "firstname": "sample string 4",
    "lastname": "sample string 5",
    "code": "sample string 6",
    "archived": true,
    "disabled": true,
    "emergency_contact": "sample string 9",
    "bankaccount": "sample string 10",
    "social_security": "sample string 11",
    "place_of_birth": "sample string 12",
    "nationality": "sample string 13",
    "functions": "sample string 14",
    "birthdate": "2026-10-19T13:34:45.4600552+00:00",
    "skype": "sample string 16",
    "notes": "sample string 17",
    "sales_organization_id": "3a9404d1-c674-44c8-8bde-f898e805eb0d",
    "sales_organization": {
      "id": "e67d0246-78e3-4676-aebc-8b8a707e7385",
      "code": "sample string 2",
      "name": "sample string 3",
      "description": "sample string 4",
      "db_country_id": "826e4535-447c-4335-8049-8557bf8e7ef7",
      "db_currency_id": "24837122-bbe4-4932-9b48-615c9d2476f5",
      "db_language_id": "93a8c5ff-b0a2-4ed2-a6bf-ead531b252b9",
      "accountancy_code": "sample string 8",
      "archived": true,
      "default_unit_of_measure_system_type": "sample string 10",
      "street": "sample string 11",
      "street2": "sample string 12",
      "street_number": "sample string 13",
      "zip": "sample string 14",
      "city": "sample string 15",
      "email": "sample string 16",
      "phone": "sample string 17",
      "fax": "sample string 18",
      "url": "sample string 19",
      "vat_reg_code": "sample string 20",
      "modified_dateutc": "2026-10-19T13:34:45.4600552+00:00"
    },
    "sales_organization_code": "sample string 19",
    "is_team_leader": true,
    "team_leader_user_id": "8f414cf4-4a3d-4365-9b63-2a3599b24ef0",
    "email": "sample string 22",
    "phone": "sample string 23",
    "fax": "sample string 24",
    "mobile": "sample string 25",
    "private_email": "sample string 26",
    "private_phone": "sample string 27",
    "private_fax": "sample string 28",
    "private_mobile": "sample string 29",
    "private_street": "sample string 30",
    "private_street_number": "sample string 31",
    "private_city": "sample string 32",
    "private_zip": "sample string 33",
    "private_db_country_id": "3c3d0399-cc1e-45a4-a2e8-90604e4ff824",
    "private_db_country_code": "sample string 35",
    "modified_dateutc": "2026-10-19T13:34:45.4600552+00:00",
    "allow_hero_app": true,
    "allow_sales_app": true,
    "allow_service_app": true,
    "user_group_id": "1e1fca33-5bb9-4aaf-b096-caa2980a2b41"
  },
  "user_unavailability_type_id": "d2fdfee2-9be8-41f5-8aa5-c9046256f4db",
  "user_unavailability_type_code": "sample string 10",
  "user_unavailability_type": {
    "id": "e86d4c9b-f5e5-4acf-aeb0-c3a56575a54a",
    "code": "sample string 2",
    "name": "sample string 3",
    "description": "sample string 4",
    "sales_organization_id": "de33cb8c-7203-46f4-9b48-18a8e2b9122c",
    "sales_organization_code": "sample string 6",
    "sales_organization": {
      "id": "e67d0246-78e3-4676-aebc-8b8a707e7385",
      "code": "sample string 2",
      "name": "sample string 3",
      "description": "sample string 4",
      "db_country_id": "826e4535-447c-4335-8049-8557bf8e7ef7",
      "db_currency_id": "24837122-bbe4-4932-9b48-615c9d2476f5",
      "db_language_id": "93a8c5ff-b0a2-4ed2-a6bf-ead531b252b9",
      "accountancy_code": "sample string 8",
      "archived": true,
      "default_unit_of_measure_system_type": "sample string 10",
      "street": "sample string 11",
      "street2": "sample string 12",
      "street_number": "sample string 13",
      "zip": "sample string 14",
      "city": "sample string 15",
      "email": "sample string 16",
      "phone": "sample string 17",
      "fax": "sample string 18",
      "url": "sample string 19",
      "vat_reg_code": "sample string 20",
      "modified_dateutc": "2026-10-19T13:34:45.4600552+00:00"
    },
    "modified_dateutc": "2026-10-19T13:34:45.4600552+00:00"
  }
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.