Skip to content

List Templates API V2

POST https://secure-{REGION}.id123.io/api/v2/ action: list-templates

New to the API?

Start with the API V2 Introduction for authentication, terminology (IDMS, Card Template, API Key), and a full endpoint list.

Introduction

This API is used to retrieve all templates meta information (limited info) that exists within an institution’s account. The API request includes pagination options for card templates. A ‘limit’ and ‘offset’ can be passed along with the api-key to get a set of data. These fields are optional, if not passed in the request then the first 10 templates of the account will get returned in the response.

limit defaults to 10 and can be up to 500. To get the next page, add the limit to offset.

Request Format

POST /api/v2/ HTTP/1.1
Host: secure-{REGION}.id123.io
X-API-KEY: API_KEY
Content-Type: application/json

{
   "action": "list-templates",
   "limit": 100, // optional, default 10, max 500
   "offset": 0   // optional, default 0
}

Success Response

{
   "status": "success",
   "code": "S2007",
   "message": "Card Templates were retrieved successfully.",
   "data": [
       {
           "card-template-id": "CARD_TEMPLATE_ID",
           "institution": "INSTITUTE NAME",
           "issuance-type": "INSTITUTION_ISSUED",
           "title": "TEMPLATE_TITLE",
           "created-at": "yyyy-mm-ddThh:mm:ss+00:00", //UTC
           "last-updated": "yyyy-mm-ddThh:mm:ss+00:00" //UTC
       }
   ]
}

Failure Response

{
    "status": "failure",
    "code": "ERROR CODE",
    "message": "ERROR MESSAGE"
}

Errors

This action can return the errors below, as well as the Common API Errors. Placeholders such as {CUSTOM-VALUE-1} are explained in Status Codes.

Status Code Status Message
F203 Card template was not found.