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": "cb1c7df1-1bff-4889-9591-ed5d4a802d73",
  "date_start": "2026-10-26T16:59:43.6099465+00:00",
  "date_end": "2026-10-26T16:59:43.6099465+00:00",
  "modified_dateutc": "2026-10-26T16:59:43.6099465+00:00",
  "description": "sample string 5",
  "is_approved": true,
  "user_id": "6c921630-aadb-430d-9f86-81f77319831c",
  "user_code": "sample string 8",
  "user": {
    "id": "32e5ac40-c710-43d5-880d-e54ced28b1a8",
    "db_language_id": "ec6f3486-d477-43f3-9eaf-089fcfd51d16",
    "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-26T16:59:43.6231935+00:00",
    "skype": "sample string 16",
    "notes": "sample string 17",
    "sales_organization_id": "a5540723-14fa-4597-a755-0b3055b2fce3",
    "sales_organization": {
      "id": "1ef1ac0e-8996-421e-b198-821c07bb7e4f",
      "code": "sample string 2",
      "name": "sample string 3",
      "description": "sample string 4",
      "db_country_id": "4a6a2379-96a4-4edc-89ae-1329843b65b7",
      "db_currency_id": "de2aec07-611e-4ff8-b0d1-33e987fe9a45",
      "db_language_id": "81ab87fb-b68f-4e54-b649-b6a84f597753",
      "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-26T16:59:43.6231935+00:00"
    },
    "sales_organization_code": "sample string 19",
    "is_team_leader": true,
    "team_leader_user_id": "19d93e00-2552-4e5f-a440-8eceb21d827f",
    "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": "77c27702-9973-4c6b-88de-dfcf8e5de9b2",
    "private_db_country_code": "sample string 35",
    "modified_dateutc": "2026-10-26T16:59:43.6231935+00:00",
    "allow_hero_app": true,
    "allow_sales_app": true,
    "allow_service_app": true,
    "user_group_id": "2b58f7f5-ab6e-4394-b9f7-eae1f22d0f78"
  },
  "user_unavailability_type_id": "69b5a58f-dfd0-4f06-aaab-9be018852479",
  "user_unavailability_type_code": "sample string 10",
  "user_unavailability_type": {
    "id": "1e6a3ab0-d344-4a25-a476-7906f439008f",
    "code": "sample string 2",
    "name": "sample string 3",
    "description": "sample string 4",
    "sales_organization_id": "62dfa7f7-5dbc-4f4a-8d00-27b36b066819",
    "sales_organization_code": "sample string 6",
    "sales_organization": {
      "id": "1ef1ac0e-8996-421e-b198-821c07bb7e4f",
      "code": "sample string 2",
      "name": "sample string 3",
      "description": "sample string 4",
      "db_country_id": "4a6a2379-96a4-4edc-89ae-1329843b65b7",
      "db_currency_id": "de2aec07-611e-4ff8-b0d1-33e987fe9a45",
      "db_language_id": "81ab87fb-b68f-4e54-b649-b6a84f597753",
      "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-26T16:59:43.6231935+00:00"
    },
    "modified_dateutc": "2026-10-26T16:59:43.6231935+00:00"
  }
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.