{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://ucp.dev/2026-04-08/schemas/shopping/types/token_credential.json",
  "title": "Token Credential",
  "description": "Base token credential schema. Concrete payment handlers may extend this schema with additional fields and define their own constraints.",
  "allOf": [
    {
      "$ref": "https://ucp.dev/2026-04-08/schemas/shopping/types/payment_credential.json"
    },
    {
      "type": "object",
      "required": [
        "type",
        "token"
      ],
      "properties": {
        "type": {
          "type": "string",
          "description": "The specific type of token produced by the handler (e.g., 'stripe_token')."
        },
        "token": {
          "type": "string",
          "description": "The token value.",
          "ucp_response": "omit"
        }
      }
    }
  ]
}