v1

latestOpenAPI 3.1.02026-08-061,5107704.5 MB
Custom Entity

CustomEntities.update

Modifies CustomEntity or {custom_entity_api_name} with given id(s)

patch/entities/{custom_entity_api_name}/{id}

Path parameters

custom_entity_api_namestring required

Custom entity api name

idstring uuid required

ID of CustomEntity to update

Query parameters

validation-levelinteger

Specify validation level of CustomEntity on update. Use them as bit mask: 0 - validate each field on entity, 2 - validate only changed fields, 4 - validate only system fields, 8 - allows to override readonly fields, 16 - allows to set entity on deleted relationship.

Request body

currency_exchange_rates_list_idstring uuid

Id of the currency exchange rate list applied to this record.

namestring

Name of the entity and its default text representation.

owner_idstring uuid

Id of the record owner.

share_mode0 | 1 | 2 | 3

Sharing model applied on top of the owner/unit visibility (e.g. shared with selected sales units or selected users).

Integer enum value: 0 - Standard, 1 - Private, 2 - AllView, 3 - AllEdit

type_idstring uuid

Id of the custom entity type.

unit_idstring uuid

Id of the sales unit.

revisioninteger

Revision when entity was lastly changed.

Example request

{
  "currency_exchange_rates_list_id": "01234567-abcd-dcba-ffff-000000000000",
  "name": "string",
  "owner_id": "01234567-abcd-dcba-ffff-000000000000",
  "type_id": "01234567-abcd-dcba-ffff-000000000000",
  "unit_id": "01234567-abcd-dcba-ffff-000000000000",
  "revision": 1
}

Response

Modification confirmation. Returns resulting CustomEntity

successboolean

True when response succeeded, false on error.

Example response

{
  "success": true,
  "data": {
    "id": "01234567-abcd-dcba-ffff-000000000000",
    "modified": "2019-01-01T00:00:00",
    "created": "2019-01-01T00:00:00",
    "currency_exchange_rates_list_id": "01234567-abcd-dcba-ffff-000000000000",
    "name": "string",
    "owner_id": "01234567-abcd-dcba-ffff-000000000000",
    "table_name": "string",
    "type_id": "01234567-abcd-dcba-ffff-000000000000",
    "unit_id": "01234567-abcd-dcba-ffff-000000000000",
    "revision": 1
  }
}