Bulk Create Attribute Templates
# Bulk Create Attribute Templates
Creates multiple attribute templates in a single atomic operation. Each template can have custom fields defined. Returns lists of successful and failed creations with detailed error reasons.
POST
/api/v1/{team_slug}/{app_slug}/attributes/bulk
PurposeCreates multiple attribute templates in a single atomic operation.
Required inputsteam_slug path app_slug path
Primary response200 ยท Templates processed successfully
Operation keymanagement-api:POST:/api/v1/{team_slug}/{app_slug}/attributes/bulk
## API ownership
- API family: Management API
- Best for: Trusted back-office workflows that create, update, organize, or delete merchant-owned data.
- Do not use from: Browser-only storefront code or public clients.
- Guide route: [/apis/management/latest](/apis/management/latest)
The OpenAPI contract defines the method, path, parameters, request body, and responses for this operation.
## Operation
- Method: `POST`
- Path: `/api/v1/{team_slug}/{app_slug}/attributes/bulk`
- Summary: Bulk Create Attribute Templates
- Description: Creates multiple attribute templates in a single atomic operation. Each template can have custom fields defined. Returns lists of successful and failed creations with detailed error reasons.
- OpenAPI contract:
management-api
- Operation ID: Not documented in the OpenAPI contract.
- Stable operation key: `management-api:POST:/api/v1/{team_slug}/{app_slug}/attributes/bulk`
Operation key uses API family, method, and path because this OpenAPI contract does not publish an operation ID.
## Parameters
| Name | In | Required | Type | Description |
| --- | --- | --- | --- | --- |
| team_slug | path | Yes | string | Team slug |
| app_slug | path | Yes | string | App slug |
## Request body
- Required: Yes
- Description: Attribute templates to create (max 50)
- Content: application/json (object)
### Bulk Create Attribute Templates Payload
| Property | Type | Required | Details |
| --- | --- | --- | --- |
| `items` | object[] | Yes | maxItems: 50 |
#### Input Attribute Template
| Property | Type | Required | Details |
| --- | --- | --- | --- |
| `fields` | object[] | No | - |
| `filterable` | boolean | No | - |
| `key` | string | Yes | Key of the attribute |
| `name` | string | Yes | Name of the attribute |
| `resources` | string[] | No | - |
| `translatable` | boolean | No | - |
| `type` | string | Yes | Name of the attribute |
#### Input Attribute Field
| Property | Type | Required | Details |
| --- | --- | --- | --- |
| `key` | string | Yes | Key of the attribute template field |
| `name` | string | Yes | Name for the attribute template field |
| `type` | enum("boolean", "text", "number", "image", "color", "image_object") | Yes | The type of the attribute template field. This field defines how we should treat the field when you create, update or list attributes |
**Generated example (synthetic):**
```json
{
"items": [
{
"fields": [
{
"key": null,
"name": null,
"type": null
}
],
"filterable": false,
"key": "string",
"name": "string",
"resources": [
"string"
],
"translatable": false,
"type": "string"
}
]
}
```
## Responses
| Status | Description | Content |
| --- | --- | --- |
| 200 | Templates processed successfully | application/json (object) |
| 400 | Invalid request payload | application/json (object) |
| 401 | Unauthorized access | application/json (object) |
| 500 | Internal server error | application/json (object) |
### 200 - object
#### Bulk Create Attribute Templates Response
| Property | Type | Required | Details |
| --- | --- | --- | --- |
| `data` | object | No | - |
| `details` | string[] | No | Additional contextual information about the response. Used to provide supplementary details beyond the main data payload, such as validation warnings or processing notes |
| `success` | boolean | No | - |
##### Bulk Create Attribute Templates
| Property | Type | Required | Details |
| --- | --- | --- | --- |
| `failed_creations` | object[] | No | - |
| `successful_creations` | object[] | No | - |
##### Bulk Create Attribute Template Failed
| Property | Type | Required | Details |
| --- | --- | --- | --- |
| `input` | object | No | - |
| `reason` | string | No | - |
##### Attribute Template
| Property | Type | Required | Details |
| --- | --- | --- | --- |
| `attributes` | object[] | No | - |
| `created_at` | string | No | - |
| `fields` | object[] | No | - |
| `filterable` | boolean | No | - |
| `id` | string | No | - |
| `key` | string | No | - |
| `name` | string | No | - |
| `resources` | string[] | No | - |
| `source_app_id` | string | No | - |
| `source_id` | string | No | - |
| `translatable` | boolean | No | - |
| `type` | string | No | - |
| `updated_at` | string | No | - |
**Generated example (synthetic):**
```json
{
"data": {
"failed_creations": [
{
"input": {
"fields": null,
"filterable": null,
"key": null,
"name": null,
"resources": null,
"translatable": null,
"type": null
},
"reason": "string"
}
],
"successful_creations": [
{
"attributes": [],
"created_at": "string",
"fields": [],
"filterable": false,
"id": "string",
"key": "string",
"name": "string",
"resources": [],
"source_app_id": "string",
"source_id": "string",
"translatable": false,
"type": "string",
"updated_at": "string"
}
]
},
"details": [
"string"
],
"success": false
}
```
### 400 - object
#### Error Message
| Property | Type | Required | Details |
| --- | --- | --- | --- |
| `details` | string[] | No | - |
| `message` | string | No | - |
| `success` | boolean | No | - |
**Generated example (synthetic):**
```json
{
"details": [
"string"
],
"message": "string",
"success": false
}
```
### 401 - object
#### Error Message
| Property | Type | Required | Details |
| --- | --- | --- | --- |
| `details` | string[] | No | - |
| `message` | string | No | - |
| `success` | boolean | No | - |
**Generated example (synthetic):**
```json
{
"details": [
"string"
],
"message": "string",
"success": false
}
```
### 500 - object
#### Error Message
| Property | Type | Required | Details |
| --- | --- | --- | --- |
| `details` | string[] | No | - |
| `message` | string | No | - |
| `success` | boolean | No | - |
**Generated example (synthetic):**
```json
{
"details": [
"string"
],
"message": "string",
"success": false
}
```
## Contract identity
Use these fields to confirm you are implementing the intended endpoint contract.
- API family: Management API
- Method: `POST`
- Path: `/api/v1/{team_slug}/{app_slug}/attributes/bulk`
- Operation ID: Not documented in the OpenAPI contract.
- Stable operation key: `management-api:POST:/api/v1/{team_slug}/{app_slug}/attributes/bulk`
- OpenAPI tag: Attribute Templates, Bulk
- OpenAPI summary: Bulk Create Attribute Templates