Getting Started

PassFast lets you generate Apple Wallet and Google Wallet passes via API. Design a template, call the API with dynamic data, and get a signed .pkpass file (Apple) or a save URL (Google) back.

How It Works

  1. Create a template — define pass style, colors, fields, and images in the Template Builder.
  2. Publish the template — lock it so passes can be generated from it.
  3. Call the API — send a POST request with the template ID and dynamic data. You get back an Apple .pkpass binary, a Google save URL, or both.
  4. Deliver to your users — serve the .pkpass file to iOS/macOS devices (Apple), redirect to the save URL (Google), or use a share link that handles both wallets automatically.

Authentication

PassFast uses two types of API keys. You can manage them on the API Keys page.

Key TypePrefixUse CaseScopes
Secretsk_live_Server-side only. Full API access.All
Publishablepk_live_Client-side (iOS, web). Can only generate and download passes.passes:create, passes:download

All requests use a Bearer token in the Authorization header:

Authorization Header
Authorization: Bearer sk_live_your_secret_key_here

Quick Start: Generate Your First Pass

Before you begin, make sure you have:

  • An API key from the API Keys page
  • A published template from the Templates page
  • Signing credentials — during app onboarding you choose between managed signing (PassFast signs for you, no certificates needed) or custom signing (your own Apple .p12 certificate and/or Google service account). You can change this anytime in Settings.

For custom signing setup (Apple certs, Google service account, APNs), see Setup & Configuration.

Generate passes for both wallets (recommended)

Using template: Your Template
curl -X POST https://api.passfa.st/functions/v1/generate-pass \
  -H "Authorization: Bearer sk_live_YOUR_SECRET_KEY" \
  -H "X-App-Id: YOUR_APP_ID" \
  -H "Content-Type: application/json" \
  -d '{
    "template_id": "YOUR_TEMPLATE_ID",
    "serial_number": "PASS-001",
    "wallet_type": "both",
    "data": {
      "memberName": "Jane Smith",
      "memberId": "MEM-12345"
    }
  }'
Response (JSON)
{
  "apple": {
    "id": "uuid",
    "serial_number": "PASS-001",
    "wallet_type": "apple",
    "status": "active",
    "download_url": "/manage-passes/<id>/download"
  },
  "google": {
    "id": "uuid",
    "serial_number": "PASS-001",
    "wallet_type": "google",
    "status": "active",
    "save_url": "https://pay.google.com/gp/v/save/...",
    "google_object_id": "issuerId.passId"
  },
  "warnings": []
}

Use wallet_type: "both" to generate Apple and Google passes in one call. For Apple-only, omit wallet_type (defaults to "apple") and pipe to --output pass.pkpass. For Google-only, set wallet_type: "google".

Or use an SDK

PassFast provides official SDKs for TypeScript and Swift:

TypeScript (npm install @passfast/sdk)
import { PassFast } from "@passfast/sdk";

const pf = new PassFast("sk_live_YOUR_SECRET_KEY");

const { passId, pkpassData } = await pf.passes.generate({
  template_id: "YOUR_TEMPLATE_ID",
  serial_number: "PASS-001",
  data: { memberName: "Jane Smith", memberId: "MEM-12345" },
});
Swift (SPM: github.com/aberkaneso/passfast-swift)
import PassFast

let client = PassFastClient(apiKey: "pk_live_YOUR_KEY")

let (pass, passId) = try await client.passes.generatePKPass(.init(
    templateId: "YOUR_TEMPLATE_ID",
    serialNumber: "PASS-001",
    data: ["memberName": "Jane Smith", "memberId": "MEM-12345"]
))

What's in the request body?

FieldTypeRequiredDescription
template_idstringYesID of a published template
serial_numberstringYesUnique serial number for this pass
dataobjectYesDynamic values matching the template's field schema
wallet_typestringNo"both" (recommended), "apple" (default), or "google"
external_idstringNoYour own identifier for cross-referencing
expires_atstringNoISO 8601 expiration date
get_or_createbooleanNoReturn existing active pass instead of 409 on duplicate serial (default: false)