---
llm-context: api-documentation
purpose: Assist LLMs and developers with integrating the DoorFlow API API
service: doorflow
version: 3.0
endpoint: PUT /api/3/card_template_types/{code}
summary: Update card template type
auth: oauth2
format: markdown
updated: 2026-06-14
---

# PUT /api/3/card_template_types/{code}

Update card template type

Updates an existing card template type. Submitting non_printable_zones replaces the entire zones array.

## Authentication

This endpoint requires authentication using one of the following methods:

### OAuth 2.0 (Recommended)

Use an OAuth 2.0 access token in the Authorization header. This is the recommended authentication method for all integrations. OAuth provides automatic token expiration, granular permission scopes, detailed usage tracking, and per-integration revocation.

**Required Scopes:** private.card_template_type

**Example:**
```
Authorization: Bearer YOUR_ACCESS_TOKEN
```

## Parameters

### Path Parameters

**`code`** (Required)
- **Type:** string
- **Description:** Card template type code



## Request Body

### Fields

**`card_template_type`** *object*

### Example

```json
{
  "card_template_type": {
    "code": "string",
    "name": "string",
    "page_size": "string",
    "width_mm": "value",
    "height_mm": "value",
    "orientation_default": "string",
    "non_printable_zones": [
      {
        "label": null,
        "x_mm": null,
        "y_mm": null,
        "width_mm": null,
        "height_mm": null
      }
    ]
  }
}
```

## Responses

### 200 - Card template type updated successfully

#### Response Fields

**`code`** *string* - **Required**
Unique identifier for this type
*Example:* `ISO_CARD`

**`name`** *string* - **Required**
Display name
*Example:* `Standard ISO Card`

**`page_size`** *string*
Physical page size category
*Example:* `ISO_CARD`

**`width_mm`** *number*
Physical width in millimetres
*Example:* `85.6`

**`height_mm`** *number*
Physical height in millimetres
*Example:* `54.0`

**`orientation_default`** *string*
Default orientation: P = Portrait, L = Landscape
*Example:* `L`

**`preview_image_url`** *string | null*
URL to a preview image, or null if not set

**`non_printable_zones`** *array&lt;object&gt;*
Non-printable zone definitions

**`created_at`** *string*
When the record was created

**`updated_at`** *string*
When the record was last updated

#### Example Response

```json
{
  "code": "ISO_CARD",
  "name": "Standard ISO Card",
  "page_size": "ISO_CARD",
  "width_mm": 85.6,
  "height_mm": 54.0,
  "orientation_default": "L",
  "preview_image_url": "string",
  "non_printable_zones": [
    {
      "label": "signature_stripe",
      "x_mm": "value",
      "y_mm": "value",
      "width_mm": "value",
      "height_mm": "value"
    }
  ],
  "created_at": "string",
  "updated_at": "string"
}
```

### 401 - Unauthorized - Invalid or missing authentication

#### Response Fields

**`error`** *string*
*Example:* `unauthorized`

**`error_description`** *string*
*Example:* `The access token is invalid`

#### Example Response

```json
{
  "error": "unauthorized",
  "error_description": "The access token is invalid"
}
```

### 403 - Forbidden - User does not have permission

#### Response Fields

**`error`** *string*
*Example:* `forbidden`

**`error_description`** *string*
*Example:* `You are not authorized to access this resource`

#### Example Response

```json
{
  "error": "forbidden",
  "error_description": "You are not authorized to access this resource"
}
```

### 404 - Not Found - Resource does not exist or is not an admission request event

#### Response Fields

**`error`** *string*
*Example:* `not_found`

**`error_description`** *string*
*Example:* `The requested resource was not found`

#### Example Response

```json
{
  "error": "not_found",
  "error_description": "The requested resource was not found"
}
```

### 422 - Unprocessable Entity - Validation failed

#### Response Fields

**`error`** *string*
Error message

**`errors`** *object*
Field-specific validation errors

#### Example Response

```json
{
  "error": "string",
  "errors": {
    "value": [
      "string"
    ],
    "credential_type_id": [
      "string"
    ],
    "limit_reached": "You have reached your HID Mobile licence limit. Please contact DoorFlow Support."
  }
}
```

### 500 - Internal Server Error

#### Response Fields

**`error`** *string*
*Example:* `internal_server_error`

**`error_description`** *string*
*Example:* `An unexpected error occurred`

#### Example Response

```json
{
  "error": "internal_server_error",
  "error_description": "An unexpected error occurred"
}
```
