[{"data":1,"prerenderedAt":7},["ShallowReactive",2],{"docs-entities\u002Fcatalog-services\u002Fcreate":3,"docs-tabs-entities\u002Fcatalog-services\u002Fcreate":6},{"content":4,"lastmod":5},"## Create a service\n\n`POST \u002Fv1\u002Fcatalog-services`\n\nCreates a service in the product catalog. Fields are passed flat at the root of the JSON.\n\n## Request fields (body)\n\n| Field | Type | Required | Description |\n|------|-----|:-----:|---------|\n| `name` | string | yes | Service name |\n| `iblockId` | number | yes | Product catalog ID — a catalog whose `productIblockId` is not filled in. List: [`GET \u002Fv1\u002Fcatalogs`](\u002Fdocs\u002Fentities\u002Fcatalogs\u002Flist) |\n| `iblockSectionId` | number | no | Catalog section ID. List: [`GET \u002Fv1\u002Fcatalog-sections`](\u002Fdocs\u002Fentities\u002Fcatalog-sections\u002Flist) |\n| `iblockSection` | array | no | Array of catalog section IDs, if the service belongs to several sections. The first ID of the array becomes the main section `iblockSectionId`. List: [`GET \u002Fv1\u002Fcatalog-sections`](\u002Fdocs\u002Fentities\u002Fcatalog-sections\u002Flist) |\n| `active` | boolean | no | Whether the service is active. Defaults to `true` |\n| `available` | boolean | no | Whether the service is available for purchase. Defaults to `false` |\n| `measure` | number | no | Unit of measure ID. List: [`GET \u002Fv1\u002Fcatalog-measures`](\u002Fdocs\u002Fentities\u002Fcatalog-measures\u002Flist) |\n| `vatIncluded` | boolean | no | VAT is included in the price |\n| `vatId` | number | no | VAT rate ID. List: [`GET \u002Fv1\u002Fcatalog-vat-rates`](\u002Fdocs\u002Fentities\u002Fcatalog-vat-rates\u002Flist) |\n| `code` | string | no | Symbolic code |\n| `xmlId` | string | no | External code. If omitted, the response returns the service `id` as a string in this field |\n| `sort` | number | no | Sort order. Defaults to `500` |\n| `previewText` | string | no | Preview text |\n| `previewTextType` | string | no | Preview text format: `text` or `html`. Defaults to `text` |\n| `detailText` | string | no | Detailed description |\n| `detailTextType` | string | no | Detailed description format: `text` or `html`. Defaults to `text` |\n| `previewPicture` | object | no | Preview picture |\n| `detailPicture` | object | no | Detail picture |\n| `propertyNNN` | string | no | Catalog property value, where `NNN` is the property `id` from [`GET \u002Fv1\u002Fcatalog-product-properties`](\u002Fdocs\u002Fentities\u002Fcatalog-product-properties\u002Flist). A string property accepts a string: `\"property301\": \"A-100\"` |\n\nFields marked `readonly: true` in [Service fields](.\u002Ffields.md) are filled in by the system — for example, `type` and `createdBy`. Such a field in the body is rejected with `400 READONLY_FIELD`. The sale price is set separately via [`POST \u002Fv1\u002Fcatalog-prices`](\u002Fdocs\u002Fentities\u002Fcatalog-prices\u002Fcreate) with the service `id` in `productId`.\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X POST \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fcatalog-services\" \\\n  -H \"X-Api-Key: YOUR_API_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n    \"name\": \"Air conditioner installation\",\n    \"iblockId\": 25,\n    \"iblockSectionId\": 281,\n    \"measure\": 9,\n    \"vatIncluded\": true\n  }'\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X POST \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fcatalog-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\": \"Air conditioner installation\",\n    \"iblockId\": 25,\n    \"iblockSectionId\": 281,\n    \"measure\": 9,\n    \"vatIncluded\": true\n  }'\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fcatalog-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: 'Air conditioner installation',\n    iblockId: 25,\n    iblockSectionId: 281,\n    measure: 9,\n    vatIncluded: true,\n  }),\n})\n\nconst { success, data } = await res.json()\nconsole.log('Service ID:', data.id)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fcatalog-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: 'Air conditioner installation',\n    iblockId: 25,\n    iblockSectionId: 281,\n    measure: 9,\n    vatIncluded: true,\n  }),\n})\n\nconst { success, data } = await res.json()\n```\n\n## Response fields\n\n| Field | Type | Description |\n|------|-----|---------|\n| `success` | boolean | Always `true` on success |\n| `data` | object | Full object of the created service. The field set is the same as in [`GET \u002Fv1\u002Fcatalog-services\u002F:id`](.\u002Fget.md) |\n\n## Response example\n\nThe main fields are shown.\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"id\": 7231,\n    \"iblockId\": 25,\n    \"iblockSectionId\": 281,\n    \"iblockSection\": [281],\n    \"name\": \"Air conditioner installation\",\n    \"type\": 7,\n    \"active\": true,\n    \"available\": false,\n    \"code\": null,\n    \"xmlId\": \"7231\",\n    \"sort\": 500,\n    \"measure\": 9,\n    \"vatId\": null,\n    \"vatIncluded\": true,\n    \"previewText\": null,\n    \"previewTextType\": \"text\",\n    \"createdBy\": 1295,\n    \"modifiedBy\": 1295,\n    \"dateCreate\": \"2026-10-08T20:50:59.000Z\",\n    \"timestampX\": \"2026-10-08T20:50:59.000Z\"\n  }\n}\n```\n\n## Error response example\n\n422 — the name was not passed:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"BITRIX_ERROR\",\n    \"message\": \"Required fields: name\",\n    \"b24Code\": \"0\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|-----|----------|\n| 422 | `BITRIX_ERROR` | `name` was not passed (`Required fields: name`) |\n| 422 | `BITRIX_ERROR` | `iblockId` was not passed, or no catalog with this `iblockId` exists (`iblock is not catalog`) |\n| 422 | `BITRIX_ERROR` | `iblockId` contains the ID of an offers catalog rather than a product catalog (`productType is not allowed for this catalog`) |\n| 400 | `EMPTY_CREATE_BODY` | The request body is empty |\n| 400 | `NESTED_FIELDS_ENVELOPE` | The body contains an object under `fields` instead of root-level fields; the service is not created |\n| 400 | `READONLY_FIELD` | The body contains a field filled in by the system, for example `type` or `createdBy` |\n| 403 | `SCOPE_DENIED` | The key lacks the `catalog` scope |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header was not passed |\n\nFull list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\n**A new service is not available for purchase.** If `available` is not passed, the service is created with `available: false`. To make the service sellable right away, pass `\"available\": true` on creation or later in [`PATCH \u002Fv1\u002Fcatalog-services\u002F:id`](.\u002Fupdate.md).\n\n**Unknown scalar fields are not rejected.** A name that is not among the service fields is skipped in the create body: the service is created without it, and the response is `201`. An object under `fields` is rejected with `400 NESTED_FIELDS_ENVELOPE` before creation — send fields at the JSON root. Check names against [Service fields](.\u002Ffields.md).\n\n## See also\n\n- [List services](\u002Fdocs\u002Fentities\u002Fcatalog-services\u002Flist)\n- [Get a service](\u002Fdocs\u002Fentities\u002Fcatalog-services\u002Fget)\n- [Update a service](\u002Fdocs\u002Fentities\u002Fcatalog-services\u002Fupdate)\n- [Delete a service](\u002Fdocs\u002Fentities\u002Fcatalog-services\u002Fdelete)\n- [Catalog prices](\u002Fdocs\u002Fentities\u002Fcatalog-prices)\n- [Catalog sections](\u002Fdocs\u002Fentities\u002Fcatalog-sections)\n- [Batch](\u002Fdocs\u002Fbatch)\n- [Limits and optimization](\u002Fdocs\u002Foptimization)\n","2026-10-15",{},1795415202349]