{
  "slug": "stripe-test-clock-creation-accepts-a-customer-parameter-298e8b06edda",
  "title": "Stripe test clock creation accepts a customer parameter",
  "tools": [
    "stripe"
  ],
  "tags": [
    "agent"
  ],
  "introduced_at": "2026-05-27T00:00:00.000Z",
  "announced_at": "2026-05-27T00:00:00.000Z",
  "effective_at": null,
  "date_basis": "source-publication",
  "status": "unknown",
  "how": {
    "incantation": "When creating a test clock for API-based testing with an existing customer, pass the customer ID in `customer`; Stripe says an attached customer cannot be removed.",
    "examples": [
      "curl https://api.stripe.com/v1/test_helpers/test_clocks \\\n  -u \"<YOUR_SECRET_KEY>\" \\\n  -H \"Stripe-Version: 2026-05-27.dahlia\" \\\n  -d frozen_time=<UNIX_TIMESTAMP> \\\n  -d customer=<CUSTOMER_ID>"
    ],
    "gotchas": [
      "frozen_time (required): Timestamp for the test clock’s initial frozen time.",
      "customer: Existing customer to attach to the test clock; attached customers cannot be removed.",
      "Stripe-Version (required): Set to `2026-05-27.dahlia` to use the documented API version.",
      "Prerequisite: Use a Stripe secret key for authentication.",
      "Prerequisite: Send API requests with `Stripe-Version: 2026-05-27.dahlia` for this version.",
      "The `customer` parameter accepts an existing customer ID.",
      "After a customer is attached to a test clock, it cannot be removed."
    ]
  },
  "why_it_matters": "When automating test clock setup for API-based testing, create the test clock with an existing customer attached.",
  "before": "Use the Dashboard to attach a customer to a test clock.",
  "sources": [
    "https://docs.stripe.com/changelog/dahlia/2026-05-27/test-clock-creation-customer-parameter",
    "https://docs.stripe.com/api/test_clocks/create?api-version=2026-05-27.dahlia"
  ],
  "rank": 0.97019,
  "judge": {
    "publish": true,
    "judge_model": "codex-cli/gpt-6-luna+typesafe/jev-1.13.0",
    "prompt_version": "extract-v7+enrich-v2+judge-v2x3+jev-publish-v1"
  },
  "review_state": "approved",
  "provenance": {
    "run_id": "wave1b-tools-20261017",
    "verdict_id": "wave1b-tools-20261017:wave1b-tools-20261017-eb0883be7e2959d1-0:gate",
    "evidence_hash": "3923a1ab7c1ae50dbf7148a94e78fad319bb689280ac86110b6ed9f4389e30a1"
  },
  "review": {
    "draft_hash": "ded26ab80d417692f2afe57a1e585927adc7bd8a3d02d054fbaadd0df132bafa",
    "reviewer": "publication-gate",
    "reviewed_at": "2026-10-07T00:00:00.000Z",
    "decision": "wave1b-tools-20261017:gate",
    "reason": "3 of 3 judge runs approved with p_yes >= 0.9 (mean 0.97 >= 0.9; 2 needed) and Jev gave 0.70 (>= 0.6 needed)."
  }
}
