> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tapace.lk/llms.txt
> Use this file to discover all available pages before exploring further.

# Issue a pass

> Creates a pass from a template for one holder.

The pass is created in the environment of your API key. Send the holder its `distributionUrl` so they can add it. See [Deliver passes](/guides/deliver-passes).

<ParamField header="Idempotency-Key" type="string" required>
  A unique value, such as a UUID, so a retry never issues a second pass. See [Idempotency](/idempotency).
</ParamField>

<ParamField body="templateId" type="string" required>
  The template to issue from, for example `tmpl_Q4vN8xT2mLr7KpZs3Wd1`. Archived templates can't issue passes.
</ParamField>

<ParamField body="fieldValues" type="object">
  Values for the template's per-pass fields, keyed by field key. Each value is a string or a number. Every key in the template's `requiredFields` must be included.
</ParamField>

<ParamField body="holderName" type="string">
  The holder's name. Used to find the pass in the dashboard.
</ParamField>

<ParamField body="holderEmail" type="string">
  The holder's email address. Used to find the pass in the dashboard.
</ParamField>

<ParamField body="barcodeValue" type="string">
  The value encoded in the barcode. Required when the template takes a barcode value for each pass.
</ParamField>

<ParamField body="platforms" type="object">
  Which wallets to issue for. Both default to `true` when the template supports them.

  <Expandable title="properties">
    <ParamField body="apple" type="boolean">
      Issue for Apple Wallet.
    </ParamField>

    <ParamField body="google" type="boolean">
      Issue for Google Wallet.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField body="revision" type="integer">
  A specific template revision to issue from. Defaults to the latest.
</ParamField>

<ParamField body="certificateId" type="string">
  The Apple certificate to sign with. Defaults to the one chosen in the template's settings.
</ParamField>

<ParamField body="googleIssuerId" type="string">
  The Google Wallet issuer to use. Defaults to the one chosen in the template's settings.
</ParamField>

### Response

Returns the new [pass](/api-reference/passes/get) with status `201`.

### Errors

| Status | When |
| - | - |
| `400` | A field key is unknown, a required field is missing, a value isn't a string or number, or the template is archived. |
| `404` | The template doesn't exist. |
| `422` | A live pass has no live Apple certificate or Google issuer to sign with. See [Test and live](/environments). |

<RequestExample>
  ```bash cURL theme={null}
  curl https://api.tapace.lk/v1/passes \
    -H "Authorization: Bearer $TAPACE_API_KEY" \
    -H "Idempotency-Key: 6f1c2b7e-3b1a-4c9e-9d8a-3f8c5b1d9e2a" \
    -H "Content-Type: application/json" \
    -d '{
      "templateId": "tmpl_Q4vN8xT2mLr7KpZs3Wd1",
      "holderName": "Nimal Perera",
      "holderEmail": "nimal@example.com",
      "fieldValues": {
        "memberName": "Nimal Perera",
        "points": 120
      }
    }'
  ```
</RequestExample>

<ResponseExample>
  ```json 201 theme={null}
  {
    "object": "pass",
    "id": "pass_7hGk2LmQ9xVt4RnB8cYe",
    "shortId": "6BkJLsso1xyB",
    "templateId": "tmpl_Q4vN8xT2mLr7KpZs3Wd1",
    "templateName": "Gold membership",
    "templateRevision": 3,
    "environment": "test",
    "status": "active",
    "source": "api",
    "holderName": "Nimal Perera",
    "holderEmail": "nimal@example.com",
    "platforms": { "apple": true, "google": true },
    "signing": {
      "appleCertificateId": "demo",
      "applePassTypeIdentifier": null,
      "googleIssuerId": "demo"
    },
    "fieldValues": { "memberName": "Nimal Perera", "points": 120 },
    "distributionUrl": "https://pass.tapace.lk/6BkJLsso1xyB",
    "createdAt": "2026-10-13T10:00:00.000Z",
    "updatedAt": "2026-10-13T10:00:00.000Z",
    "voidedAt": null
  }
  ```

  ```json 400 theme={null}
  {
    "error": {
      "type": "invalid_request_error",
      "message": "Field \"Member name\" is required."
    },
    "requestId": "req_8f3a2c1d9e7b6a54"
  }
  ```
</ResponseExample>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.