---
search:
  tags:
    - Attribute Templates V2
    - PATCH
seo:
  description: >-
    Bulk-patches attribute templates by id.… Reference for the PATCH
    /api/v2/{team_slug}/{app_slug}/attribute-templates endpoint in the
    Management API v2.
sidebar:
  label: Update attribute templates
  badge: PATCH
title: Update attribute templates
type: openapi-operation
---
Bulk-patches attribute templates by id. Successful entities are returned in data including their fields. Sending fields upserts those fields by key. Attributes are listed from the attributes endpoint.

`PATCH /api/v2/{team_slug}/{app_slug}/attribute-templates`

**Request body** (`application/json`, required)

- `attribute_templates` (PatchAttributeTemplateItem[], required)

Request body example:

```json
{
  "attribute_templates": [
    {
      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
      "key": "string",
      "name": "string",
      "type": "string",
      "filterable": true,
      "translatable": true,
      "resources": [
        "string"
      ],
      "fields": [
        {
          "key": "string",
          "name": "string",
          "type": "string",
          "translatable": true
        }
      ]
    }
  ]
}
```

**Responses**

- `200` — Patched (partial success possible)
- `400` — Request-level failure
- `401` — Request-level failure
- `403` — Request-level failure
- `500` — Request-level failure

Response example, 200:

```json
{
  "data": [
    {
      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
      "name": "string",
      "key": "string",
      "type": "string",
      "filterable": true,
      "translatable": true,
      "resources": [
        "string"
      ],
      "fields": [
        {
          "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
          "name": "string",
          "key": "string",
          "type": "string",
          "updated_at": "2019-08-24T14:15:22Z",
          "created_at": "2019-08-24T14:15:22Z"
        }
      ],
      "updated_at": "2019-08-24T14:15:22Z",
      "created_at": "2019-08-24T14:15:22Z"
    }
  ],
  "errors": [
    {
      "key": "string",
      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
      "message": "string"
    }
  ]
}
```
