[{"data":1,"prerenderedAt":13},["ShallowReactive",2],{"docs-entities\u002Fdelivery-services":3,"docs-tabs-entities\u002Fdelivery-services":6},{"content":4,"lastmod":5},"# Delivery services\n\nSelect a delivery service for a shipment. Create your own records using a registered REST handler.\n\nBitrix24 API: `sale.delivery.*`\nScope: `delivery`\n\nBuilt-in services are readable. Bitrix24 permits updates and deletion only for REST-handler records; OAuth applications are also checked against handler ownership. The `sale` scope alone is insufficient.\n\n## Operations\n\n- [List](.\u002Fdelivery-services\u002Flist.md) — `GET \u002Fv1\u002Fdelivery-services`\n- [Get](.\u002Fdelivery-services\u002Fget.md) — `GET \u002Fv1\u002Fdelivery-services\u002F:id`\n- [Create](.\u002Fdelivery-services\u002Fcreate.md) — `POST \u002Fv1\u002Fdelivery-services`\n- [Update](.\u002Fdelivery-services\u002Fupdate.md) — `PATCH \u002Fv1\u002Fdelivery-services\u002F:id`\n- [Delete](.\u002Fdelivery-services\u002Fdelete.md) — `DELETE \u002Fv1\u002Fdelivery-services\u002F:id`\n- [Handlers](.\u002Fdelivery-services\u002Fhandlers.md) — `GET \u002Fv1\u002Fdelivery-services\u002Fhandlers`\n\n## Key fields\n\nPass `id` from the [delivery service list](.\u002Fdelivery-services\u002Flist.md) as the shipment `deliveryId`. `parentId` links a profile to its parent service. `logotype` is a file ID, not a URL.\n\n[All fields](.\u002Fdelivery-services\u002Ffields.md).\n\n## Before you start\n\nHandlers are registered separately: these routes only read their definitions. `active` uses `Y` and `N` strings, not `boolean` values.\n\nCreation returns `parent` and `profiles`. A profile can also be used in a shipment.\n\n## Typical workflow\n\nRead the [handler list](.\u002Fdelivery-services\u002Fhandlers.md), select a `code`, create an inactive service, get it, update `name`, then delete only your own record. Creation may have completed even if the response failed. Check the [service list](.\u002Fdelivery-services\u002Flist.md) before retrying.\n\n## Limits\n\nLists are complete, without `limit` or `offset`. `meta.total` equals the length of `data`. The entity does not support `search`, `aggregate`, or batch operations. Logo: `logo` is a `[filename, base64]` array, up to 2 MiB decoded. The JSON body can be up to 3 MiB. Set `restCode` and `config` only when creating a service.\n\n## Write restrictions\n\n| Record | GET | PATCH \u002F DELETE |\n|---|---|---|\n| Built-in | Yes | 403 |\n| REST | Yes | Subject to Bitrix24 rights and OAuth ownership |\n\n## See also\n\n- [Shipments](\u002Fdocs\u002Fentities\u002Fshipments)\n- [CRM deliveries](\u002Fdocs\u002Fentities\u002Fcrm-deliveries)\n","2026-10-14",{"delivery-services\u002Flist.md":7,"delivery-services\u002Fget.md":8,"delivery-services\u002Fcreate.md":9,"delivery-services\u002Fupdate.md":10,"delivery-services\u002Fdelete.md":11,"delivery-services\u002Fhandlers.md":12},"## List delivery services\n\n`GET \u002Fv1\u002Fdelivery-services`\n\nFind delivery services in the online store by specified conditions and choose records for further operations.\n\n## Parameters\n\n| Parameter | Type | Required | Description |\n|-----------|------|:--------:|-------------|\n| `filter` (query) | object \\| string | no | Filter by [delivery service fields](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Ffields). Accepts a JSON object or bracket notation. [Filtering syntax](\u002Fdocs\u002Ffiltering). Example: `?filter[id]=85`. Operators: `$eq`, `$ne`, `$gt`, `$gte`, `$lt`, `$lte`, `$in`, `$nin`, `$like`, `$nlike` |\n| `sort` (query) | string | no | Comma-separated field names. A leading minus sorts in descending order. Example: `sort=-id` |\n| `select` (query) | string | no | Comma-separated fields to return, or `*` for all fields. Example: `select=id,name,active,currency` |\n\nThe result contains all matching records, with no pagination. Only the parameters in the table are supported.\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -g \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services?filter[id]=85&select=id,name,active,currency&sort=-id\" \\\n  -H \"X-Api-Key: YOUR_API_KEY\"\n```\n\n### curl — OAuth app\n\n```bash\ncurl -g \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services?filter[id]=85&select=id,name,active,currency&sort=-id\" \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\"\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services?filter[id]=85&select=id,name,active,currency&sort=-id', {\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n  },\n})\n\nconst { success, data, meta } = await res.json()\nconsole.log(data)\n```\n\n### JavaScript — OAuth app\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services?filter[id]=85&select=id,name,active,currency&sort=-id', {\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n  },\n})\n\nconst { success, data, meta } = await res.json()\nconsole.log(data)\n```\n\n## Response fields\n\n| Field | Type | Description |\n|-------|------|-------------|\n| `success` | boolean | Always `true` on success |\n| `data` | array | Delivery service records |\n| `data[].id` | integer | Delivery service ID |\n| `data[].parentId` | integer \\| null | Parent service ID from the [delivery service list](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Flist). May be `null` |\n| `data[].name` | string \\| null | Delivery service name |\n| `data[].active` | string \\| null | Activity flag: `Y` or `N` |\n| `data[].description` | string \\| null | Delivery service description |\n| `data[].currency` | string \\| null | Currency code from the [currency list](\u002Fdocs\u002Fentities\u002Fcurrencies\u002Flist) |\n| `data[].sort` | integer \\| null | Sort order |\n| `data[].logotype` | integer \\| null | Logo file ID, not a URL. May be `null` |\n| `meta.total` | integer | Number of records in `data` |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": [\n    {\n      \"id\": 85,\n      \"name\": \"Courier delivery to an address\",\n      \"active\": \"N\",\n      \"currency\": \"USD\"\n    }\n  ],\n  \"meta\": {\n    \"total\": 1\n  }\n}\n```\n\n## Error response example\n\n400 — unsupported query parameter:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"INVALID_PARAMS\",\n    \"message\": \"Only filter, sort and select are supported; the full list has no pagination\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|------|-------------|\n| 400 | `INVALID_PARAMS` | Unsupported query parameter, repeated `sort` or `select`, invalid parameter type, or duplicate sort field |\n| 400 | `INVALID_FILTER` | The request combines JSON and bracket filter notation, or repeats a filter condition |\n| 400 | `INVALID_FILTER_SHAPE` | The filter has an invalid structure, empty conditions, nested values, or mixed array and operator forms |\n| 400 | `INVALID_FILTER_OPERATOR` | Unsupported filter operator |\n| 400 | `INVALID_DUPLICATE_FILTER_FIELD` | Multiple conditions produce the same filter field and operator |\n| 400 | `UNKNOWN_FILTER_FIELD` | Unknown filter field |\n| 400 | `UNKNOWN_SELECT_FIELD` | Unknown field in `select` |\n| 400 | `UNKNOWN_SORT_FIELD` | Unknown field in `sort` |\n| 502 | `BITRIX_RESPONSE_INVALID` | The response does not match the delivery service format |\n| 422 | `BITRIX_ERROR` | Bitrix24 rejected the operation. The original error message is preserved |\n| 403 | `BITRIX_ACCESS_DENIED` | Bitrix24 denied access |\n| 403 | `SCOPE_DENIED` | The API key lacks the `delivery` scope |\n| 401 | `TOKEN_MISSING` | No Bitrix24 credentials are configured for the key |\n\nFor common API errors, see [Errors](\u002Fdocs\u002Ferrors).\n\n## See also\n\n- [Get a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fget)\n- [Create a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fcreate)\n- [Update a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fupdate)\n- [Delivery service fields](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Ffields)\n- [Filtering syntax](\u002Fdocs\u002Ffiltering)\n- [Delivery services](\u002Fdocs\u002Fentities\u002Fdelivery-services)\n","## Get a delivery service\n\n`GET \u002Fv1\u002Fdelivery-services\u002F:id`\n\nLook up a delivery service by its ID to check its settings before updating the service or using it in an integration.\n\n## Parameters\n\n| Parameter | Type | Required | Description |\n|-----------|------|:--------:|-------------|\n| `id` (path) | integer | yes | Positive integer no greater than `9007199254740991`. Obtain it from the [delivery service list](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Flist) |\n\nQuery parameters are not supported.\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -g \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85\" \\\n  -H \"X-Api-Key: YOUR_API_KEY\"\n```\n\n### curl — OAuth app\n\n```bash\ncurl -g \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85\" \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\"\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85', {\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n  },\n})\n\nconst { success, data } = await res.json()\nconsole.log(data)\n```\n\n### JavaScript — OAuth app\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85', {\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n  },\n})\n\nconst { success, data } = await res.json()\nconsole.log(data)\n```\n\n## Response fields\n\n| Field | Type | Description |\n|-------|------|-------------|\n| `success` | boolean | Always `true` on success |\n| `data` | object | Delivery service record |\n| `data.id` | integer | Delivery service ID |\n| `data.parentId` | integer \\| null | Parent service ID from the [delivery service list](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Flist). May be `null` |\n| `data.name` | string \\| null | Delivery service name |\n| `data.active` | string \\| null | Activity flag: `Y` or `N` |\n| `data.description` | string \\| null | Delivery service description |\n| `data.currency` | string \\| null | Currency code from the [currency list](\u002Fdocs\u002Fentities\u002Fcurrencies\u002Flist) |\n| `data.sort` | integer \\| null | Sort order |\n| `data.logotype` | integer \\| null | Logo file ID, not a URL. May be `null` |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"id\": 85,\n    \"parentId\": null,\n    \"name\": \"Courier delivery\",\n    \"active\": \"N\",\n    \"description\": \"\",\n    \"currency\": \"USD\",\n    \"sort\": 100,\n    \"logotype\": null\n  }\n}\n```\n\n## Error response example\n\n404 — delivery service not found:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"ENTITY_NOT_FOUND\",\n    \"message\": \"Entity not found\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|------|-------------|\n| 400 | `INVALID_PARAMS` | The path ID is not a positive safe integer, or the request contains query parameters |\n| 404 | `ENTITY_NOT_FOUND` | No delivery service with this ID was found |\n| 502 | `BITRIX_RESPONSE_INVALID` | The response does not match the delivery service format |\n| 422 | `BITRIX_ERROR` | Bitrix24 rejected the operation. The original error message is preserved |\n| 403 | `BITRIX_ACCESS_DENIED` | Bitrix24 denied access |\n| 403 | `SCOPE_DENIED` | The API key lacks the `delivery` scope |\n| 401 | `TOKEN_MISSING` | No Bitrix24 credentials are configured for the key |\n\nFor common API errors, see [Errors](\u002Fdocs\u002Ferrors).\n\n## See also\n\n- [List delivery services](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Flist)\n- [Create a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fcreate)\n- [Update a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fupdate)\n- [Delivery service fields](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Ffields)\n- [Delivery services](\u002Fdocs\u002Fentities\u002Fdelivery-services)\n","## Create a delivery service\n\n`POST \u002Fv1\u002Fdelivery-services`\n\nCreates a delivery service and its profiles using a handler already registered in the Bitrix24 account.\n\nPass fields at the JSON root without a `fields` wrapper.\n\n## Request fields (body)\n\n| Field | Type | Required | Description |\n|---|---|---|---|\n| `name` | string | yes | Service name. Empty strings and `\"0\"` are not accepted |\n| `currency` | string | yes | Nonempty currency code, for example `USD`. [List currencies](\u002Fdocs\u002Fentities\u002Fcurrencies\u002Flist) |\n| `restCode` | string | yes | Nonempty `code` value from the [handler list](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fhandlers) |\n| `description` | string | no | Service description |\n| `sort` | integer | no | Sort index |\n| `active` | string | no | Service activity: `Y` or `N`. Defaults to `Y` when omitted |\n| `logo` | string[] | no | Two nonempty elements: the file name and its base64 content. The decoded file must be at most 2 MiB |\n| `config` | object \\| array | no | Settings for the selected handler in Bitrix24 format. Nested keys and their case are preserved |\n\nThe body must contain at least one field. The JSON body must be at most 3 MiB.\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X POST \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\" \\\n  -H \"X-Api-Key: YOUR_API_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n  \"name\": \"Courier delivery\",\n  \"restCode\": \"my_delivery_handler\",\n  \"currency\": \"USD\",\n  \"active\": \"N\"\n}'\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X POST \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\" \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n  \"name\": \"Courier delivery\",\n  \"restCode\": \"my_delivery_handler\",\n  \"currency\": \"USD\",\n  \"active\": \"N\"\n}'\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({\n    name: 'Courier delivery',\n    restCode: 'my_delivery_handler',\n    currency: 'USD',\n    active: 'N',\n  }),\n})\n\nconst { success, data } = await res.json()\nconsole.log(data.parent.id)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({\n    name: 'Courier delivery',\n    restCode: 'my_delivery_handler',\n    currency: 'USD',\n    active: 'N',\n  }),\n})\n\nconst { success, data } = await res.json()\nconsole.log(data.parent.id)\n```\n\n## Response fields\n\nHTTP status: `201 Created`. `data` contains the required `parent` object and `profiles` array.\n\n`RO` marks read-only fields.\n\n| Field | Type | Description |\n|---|---|---|\n| `success` | boolean | `true` on success |\n| `data` | object | Created service and its profiles |\n| `data.parent` | object | Parent delivery service |\n| `data.profiles` | object[] | Created delivery profiles |\n| `data.parent.id` | integer | Service ID. RO |\n| `data.parent.parentId` | integer \\| null | Parent service ID or `null`. RO |\n| `data.parent.name` | string \\| null | Service name |\n| `data.parent.active` | string \\| null | Service activity |\n| `data.parent.description` | string \\| null | Service description |\n| `data.parent.currency` | string \\| null | Currency code |\n| `data.parent.sort` | integer \\| null | Sort index |\n| `data.parent.logotype` | integer \\| null | Logo file ID, not a URL, or `null`. RO. Use `logo` to write the file |\n| `data.profiles[].id` | integer | Service ID. RO |\n| `data.profiles[].parentId` | integer \\| null | Parent service ID or `null`. RO |\n| `data.profiles[].name` | string \\| null | Service name |\n| `data.profiles[].active` | string \\| null | Service activity |\n| `data.profiles[].description` | string \\| null | Service description |\n| `data.profiles[].currency` | string \\| null | Currency code |\n| `data.profiles[].sort` | integer \\| null | Sort index |\n| `data.profiles[].logotype` | integer \\| null | Logo file ID, not a URL, or `null`. RO. Use `logo` to write the file |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"parent\": {\n      \"id\": 85,\n      \"parentId\": null,\n      \"name\": \"Courier delivery\",\n      \"active\": \"N\",\n      \"description\": \"\",\n      \"currency\": \"USD\",\n      \"sort\": 100,\n      \"logotype\": null\n    },\n    \"profiles\": [\n      {\n        \"id\": 87,\n        \"parentId\": 85,\n        \"name\": \"Delivery profile 1\",\n        \"active\": \"N\",\n        \"description\": \"Taxi Delivery\",\n        \"currency\": \"USD\",\n        \"sort\": 100,\n        \"logotype\": null\n      },\n      {\n        \"id\": 89,\n        \"parentId\": 85,\n        \"name\": \"Delivery profile 2\",\n        \"active\": \"N\",\n        \"description\": \"Cargo Delivery\",\n        \"currency\": \"USD\",\n        \"sort\": 100,\n        \"logotype\": null\n      }\n    ]\n  }\n}\n```\n\n## Error response example\n\n400 — the body is an empty JSON object:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"MISSING_REQUIRED_FIELDS\",\n    \"message\": \"A nonempty JSON object is required\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | `error.code` | Description |\n|---|---|---|\n| 400 | `MISSING_REQUIRED_FIELDS` | The body is not a nonempty JSON object, a required field is missing, or the name is empty |\n| 400 | `INVALID_PARAMS` | A field has an invalid type, or `logo` contains an invalid file |\n| 400 | `READONLY_FIELD` | The body contains a field absent from the request field table, including `logotype` |\n| 413 | `PAYLOAD_TOO_LARGE` | The logo file exceeds 2 MiB, or the JSON body exceeds 3 MiB |\n| 422 | `BITRIX_ERROR` | Bitrix24 rejected creation. See `error.message` for the reason |\n| 502 | `BITRIX_RESPONSE_INVALID` | The creation response does not contain valid service and profile objects |\n| 403 | `BITRIX_ACCESS_DENIED` | The user lacks permission to create the service |\n| 401 | `TOKEN_MISSING` | The API key has no configured Bitrix24 credentials |\n| 403 | `SCOPE_DENIED` | The API key lacks the `delivery` scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The API key is in read-only mode |\n\nFor the full list of common API errors, see [Errors](\u002Fdocs\u002Ferrors).\n\n## See also\n\n- [Delivery services](\u002Fdocs\u002Fentities\u002Fdelivery-services)\n- [List delivery services](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Flist)\n- [Get a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fget)\n- [Update a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fupdate)\n- [Delete a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fdelete)\n- [List delivery handlers](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fhandlers)\n- [Batch](\u002Fdocs\u002Fbatch)\n- [Limits and optimization](\u002Fdocs\u002Foptimization)\n","## Update a delivery service\n\n`PATCH \u002Fv1\u002Fdelivery-services\u002F:id`\n\nPartially updates a delivery service by ID, preserving the values of fields omitted from the request.\n\nPass fields at the JSON root without a `fields` wrapper.\n\n## Parameters\n\n| Parameter | Type | Required | Description |\n|---|---|---|---|\n| `id` (path) | integer | yes | Positive safe integer ID from the [delivery service list](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Flist) |\n\n## Request fields (body)\n\n| Field | Type | Required | Description |\n|---|---|---|---|\n| `name` | string | no | Service name. Empty strings and `\"0\"` are not accepted |\n| `currency` | string | no | Currency code, for example `USD`. [List currencies](\u002Fdocs\u002Fentities\u002Fcurrencies\u002Flist) |\n| `description` | string | no | Service description |\n| `sort` | integer | no | Sort index |\n| `active` | string | no | Service activity, for example `Y` or `N` |\n| `logo` | string[] | no | Two nonempty elements: the file name and its base64 content. The decoded file must be at most 2 MiB |\n\nThe body must contain at least one field. The JSON body must be at most 3 MiB.\n\nSet `restCode` and `config` only when [creating a service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fcreate).\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X PATCH \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85\" \\\n  -H \"X-Api-Key: YOUR_API_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n  \"name\": \"Courier delivery to an address\"\n}'\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X PATCH \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85\" \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n  \"name\": \"Courier delivery to an address\"\n}'\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85', {\n  method: 'PATCH',\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({\n    name: 'Courier delivery to an address',\n  }),\n})\n\nconst { success, data } = await res.json()\nconsole.log(data.id)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85', {\n  method: 'PATCH',\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({\n    name: 'Courier delivery to an address',\n  }),\n})\n\nconst { success, data } = await res.json()\nconsole.log(data.id)\n```\n\n## Response fields\n\nHTTP status: `200 OK`. Returns the updated record.\n\n`RO` marks read-only fields.\n\n| Field | Type | Description |\n|---|---|---|\n| `success` | boolean | `true` on success |\n| `data` | object | Updated delivery service |\n| `data.id` | integer | Service ID. RO |\n| `data.parentId` | integer \\| null | Parent service ID or `null`. RO |\n| `data.name` | string \\| null | Service name |\n| `data.active` | string \\| null | Service activity |\n| `data.description` | string \\| null | Service description |\n| `data.currency` | string \\| null | Currency code |\n| `data.sort` | integer \\| null | Sort index |\n| `data.logotype` | integer \\| null | Logo file ID, not a URL, or `null`. RO. Use `logo` to write the file |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"id\": 85,\n    \"parentId\": null,\n    \"name\": \"Courier delivery to an address\",\n    \"active\": \"N\",\n    \"description\": \"\",\n    \"currency\": \"USD\",\n    \"sort\": 100,\n    \"logotype\": null\n  }\n}\n```\n\n## Error response example\n\n400 — the body contains `logotype` instead of `logo`:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"READONLY_FIELD\",\n    \"message\": \"Field 'logotype' is not writable for this operation\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | `error.code` | Description |\n|---|---|---|\n| 400 | `INVALID_PARAMS` | `id` is not a positive safe integer, a field has an invalid type, or `logo` contains an invalid file |\n| 400 | `MISSING_REQUIRED_FIELDS` | The body is not a nonempty JSON object, or `name` is an empty string or `\"0\"` |\n| 400 | `READONLY_FIELD` | The body contains a field absent from the request field table, including `logotype`, `restCode`, or `config` |\n| 404 | `ENTITY_NOT_FOUND` | The service with the specified `id` was not found during the update |\n| 404 | `ENTITY_NOT_FOUND` | After a successful write, the updated service was not found when reading the result |\n| 413 | `PAYLOAD_TOO_LARGE` | The logo file exceeds 2 MiB, or the JSON body exceeds 3 MiB |\n| 422 | `BITRIX_ERROR` | Bitrix24 rejected or did not confirm the update. See `error.message` for the reason |\n| 502 | `BITRIX_RESPONSE_INVALID` | The Bitrix24 update response has an invalid structure |\n| 502 | `BITRIX_RESPONSE_INVALID` | A valid record could not be read after the update |\n| 403 | `BITRIX_ACCESS_DENIED` | The user lacks permission to modify the service, the service was created without a REST handler, or it belongs to another OAuth application |\n| 401 | `TOKEN_MISSING` | The API key has no configured Bitrix24 credentials |\n| 403 | `SCOPE_DENIED` | The API key lacks the `delivery` scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The API key is in read-only mode |\n\nFor the full list of common API errors, see [Errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\nAn error while reading the result does not mean the change was not saved. Before retrying, check the service with [get by ID](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fget).\n\n## See also\n\n- [Delivery services](\u002Fdocs\u002Fentities\u002Fdelivery-services)\n- [List delivery services](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Flist)\n- [Get a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fget)\n- [Create a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fcreate)\n- [Delete a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fdelete)\n- [Batch](\u002Fdocs\u002Fbatch)\n- [Limits and optimization](\u002Fdocs\u002Foptimization)\n","## Delete a delivery service\n\n`DELETE \u002Fv1\u002Fdelivery-services\u002F:id`\n\nDeletes a delivery service by ID from the service list if the user has permission to delete it. Deleted records cannot be restored through the API.\n\n## Parameters\n\n| Parameter | Type | Required | Description |\n|---|---|---|---|\n| `id` (path) | integer | yes | Positive safe integer ID from the [delivery service list](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Flist) |\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X DELETE \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85\" \\\n  -H \"X-Api-Key: YOUR_API_KEY\"\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X DELETE \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85\" \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\"\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85', {\n  method: 'DELETE',\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n  },\n})\n\nconst { success, data } = await res.json()\nconsole.log(success && data === true)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002F85', {\n  method: 'DELETE',\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n  },\n})\n\nconst { success, data } = await res.json()\nconsole.log(success && data === true)\n```\n\n## Response fields\n\nHTTP status: `200 OK`.\n\n| Field | Type | Description |\n|---|---|---|\n| `success` | boolean | `true` on success |\n| `data` | boolean | `true` confirms deletion |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": true\n}\n```\n\n## Error response example\n\n404 — the service with the specified ID was not found:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"ENTITY_NOT_FOUND\",\n    \"message\": \"Entity not found\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | `error.code` | Description |\n|---|---|---|\n| 400 | `INVALID_PARAMS` | `id` is not a positive safe integer |\n| 404 | `ENTITY_NOT_FOUND` | The service with the specified `id` was not found |\n| 422 | `BITRIX_ERROR` | Bitrix24 rejected or did not confirm deletion. See `error.message` for the reason |\n| 502 | `BITRIX_RESPONSE_INVALID` | The deletion response has an invalid structure |\n| 403 | `BITRIX_ACCESS_DENIED` | The user lacks permission to delete the service, the service was created without a REST handler, or it belongs to another OAuth application |\n| 401 | `TOKEN_MISSING` | The API key has no configured Bitrix24 credentials |\n| 403 | `SCOPE_DENIED` | The API key lacks the `delivery` scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The API key is in read-only mode |\n\nFor the full list of common API errors, see [Errors](\u002Fdocs\u002Ferrors).\n\n## See also\n\n- [Delivery services](\u002Fdocs\u002Fentities\u002Fdelivery-services)\n- [List delivery services](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Flist)\n- [Get a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fget)\n- [Create a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fcreate)\n- [Update a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fupdate)\n- [Batch](\u002Fdocs\u002Fbatch)\n- [Limits and optimization](\u002Fdocs\u002Foptimization)\n","## List delivery handlers\n\n`GET \u002Fv1\u002Fdelivery-services\u002Fhandlers`\n\nLists registered REST delivery handlers so you can choose a handler before creating a delivery service.\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002Fhandlers\" \\\n  -H \"X-Api-Key: YOUR_API_KEY\"\n```\n\n### curl — OAuth application\n\n```bash\ncurl \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002Fhandlers\" \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\"\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002Fhandlers', {\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n  },\n})\n\nconst { success, data, meta } = await res.json()\nconsole.log(data, meta.total)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fdelivery-services\u002Fhandlers', {\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n  },\n})\n\nconst { success, data, meta } = await res.json()\nconsole.log(data, meta.total)\n```\n\n## Response fields\n\n| Field | Type | Required | Description |\n|-------|------|:--------:|-------------|\n| `success` | boolean | yes | `true` on a successful request |\n| `data` | array | yes | Array of registered handlers. Empty if no handlers are registered |\n| `data[].id` | integer | no | Handler ID |\n| `data[].name` | string | no | Handler name |\n| `data[].code` | string | no | Handler code. Pass it as `restCode` when [creating a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fcreate) |\n| `data[].sort` | integer | no | Handler sort order |\n| `data[].description` | string | no | Handler description |\n| `data[].settings` | object \\| array | no | Handler settings. Nested keys retain their Bitrix24 names |\n| `data[].profiles` | array | no | Handler profile definitions. Nested keys retain their Bitrix24 names |\n| `meta` | object | yes | Handler count metadata |\n| `meta.total` | integer | yes | Number of items in `data` |\n\n## Response example\n\nThe example shows the main handler fields. The full structure is listed in the Response fields table above.\n\n```json\n{\n  \"success\": true,\n  \"data\": [\n    {\n      \"id\": 1,\n      \"name\": \"Delivery handler\",\n      \"code\": \"my_delivery_handler\",\n      \"sort\": 250\n    }\n  ],\n  \"meta\": {\n    \"total\": 1\n  }\n}\n```\n\n## Error response example\n\n400 — query parameters are present in the URL:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"INVALID_PARAMS\",\n    \"message\": \"Handlers have no query parameters\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|------|-------------|\n| 400 | `INVALID_PARAMS` | Any query parameter is present in the URL. Call this method without query parameters |\n| 502 | `BITRIX_RESPONSE_INVALID` | The response structure or a numeric field value is invalid |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |\n| 401 | `TOKEN_MISSING` | The key has no available Bitrix24 tokens |\n| 403 | `SCOPE_DENIED` | The key lacks the `delivery` scope |\n| 403 | `BITRIX_ACCESS_DENIED` | Bitrix24 denied access |\n| 422 | `BITRIX_ERROR` | Bitrix24 rejected the request. The reason is in `error.message` |\n\nFor all common API errors, see [Errors](\u002Fdocs\u002Ferrors).\n\n## See also\n\n- [Create a delivery service](\u002Fdocs\u002Fentities\u002Fdelivery-services\u002Fcreate)\n- [Delivery services](\u002Fdocs\u002Fentities\u002Fdelivery-services)\n",1795000329320]