Create card template type
Creates a new card template type. The code field must be unique.
/api/3/card_template_types
Authentication
This endpoint requires authentication:
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. Learn how to obtain an access token.
Header Format:
Authorization: Bearer YOUR_ACCESS_TOKEN
Required Scopes:
private.card_template_type
Request Body
card_template_type
object
Show child attributes
code
string
Unique code (required for creation)
name
string
page_size
string
width_mm
number
height_mm
number
orientation_default
string
non_printable_zones
array
Non-printable zones. Replaces the entire array on update
Example
{
"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
Card template type created successfully
Response Fields
code
string
required
Unique identifier for this type
eg. ISO_CARD
name
string
required
Display name
eg. Standard ISO Card
page_size
string
Physical page size category
eg. ISO_CARD
width_mm
number
Physical width in millimetres
eg. 85.6
height_mm
number
Physical height in millimetres
eg. 54.0
orientation_default
string
Default orientation: P = Portrait, L = Landscape
eg. L
preview_image_url
string | null
URL to a preview image, or null if not set
non_printable_zones
array<object>
Non-printable zone definitions
created_at
string
When the record was created
updated_at
string
When the record was last updated
Unauthorized - Invalid or missing authentication
Response Fields
error
string
eg. unauthorized
error_description
string
eg. The access token is invalid
Forbidden - User does not have permission
Response Fields
error
string
eg. forbidden
error_description
string
eg. You are not authorized to access this resource
Unprocessable Entity - Validation failed
Response Fields
error
string
Error message
errors
object
Field-specific validation errors
Show child attributes
value
array
eg. ["value is already in use on your account", "must be between 4 and 7 digits in length"]
Validation errors for the credential value
credential_type_id
array
eg. ["Not found for this account"]
Validation errors for the credential type
limit_reached
string
eg. You have reached your HID Mobile licence limit. Please contact DoorFlow Support.
License limit error message
Internal Server Error
Response Fields
error
string
eg. internal_server_error
error_description
string
eg. An unexpected error occurred