跳到正文
cccskills
免费在 GitHub 公开

stripe-test-clock-constraints

Reference for Stripe test clock constraints and pitfalls. Use when planning or debugging test-clock workflows, when an advance or customer-attach step fails, or to check rules before building a time-simulation scenario with create_stripe_test_clock, advance_stripe_test_clock, and create_stripe_test_customers.

中文简介正在准备中。当前显示原文说明。

集成工具Stripe
查看安装方法

包含的文件(1)

  • SKILL.md2.7 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

Stripe Test Clock Constraints

Quick reference for the rules and gotchas of Stripe test clocks as exposed by this MCP. Consult this before designing a time-simulation scenario.

Hard constraints

  • Max 3 customers per clock. create_stripe_test_customers with a test_clock set rejects number > 3. To exceed 3 customers in one scenario, use additional clocks.
  • Clock attachment is creation-time only. A customer can be linked to a test clock only when it is created (create_stripe_test_customers with test_clock). There is no way to attach or move an existing customer to a clock afterward, so create the clock first.
  • Advance is forward-only. advance_stripe_test_clock can only move frozen_time to a time after the current frozen time. You cannot rewind a clock; to test an earlier point, create a new clock.
  • Advance is asynchronous. After advance_stripe_test_clock, the clock enters an advancing state and processes billing events in the background. The tool returns the status once in its response, but this MCP server does not expose a tool to retrieve or re-poll the clock, so you cannot programmatically watch it reach ready. If the response shows advancing, wait a few seconds before follow-up operations, or have the user confirm the clock has settled in the Stripe Dashboard.

Time format

  • frozen_time is a Unix timestamp in seconds (epoch seconds), not milliseconds and not an ISO string.
  • Convert carefully:
    • Many languages give milliseconds (Date.now() in JS) — divide by 1000 and floor.
    • From an ISO date: compute epoch seconds (for example, in shell date -d '2024-02-01T00:00:00Z' +%s).
    • When reading a value back, multiply by 1000 to build a JS Date.
  • A common bug is passing milliseconds, which lands the clock far in the future; double-check the magnitude (a 2024-2026 timestamp is ~1.7e9, a millisecond value is ~1.7e12).

Practical guidance

  • Plan all the time points you need up front; since you cannot rewind, build a fresh clock per backward scenario.
  • Keep the test_clock_id returned at creation; it is required for every advance.
  • To cross a billing boundary, advance to just past the subscription's current_period_end.
  • For an end-to-end billing procedure, see stripe-billing-cycle-test.
  • For setup/cleanup of the data around clocks, see stripe-test-data-lifecycle.

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

Verify Stripe subscription billing cycles using a test clock. Use when you need to simulate time passing to trigger subscription renewals, recurring invoices, or to confirm that the next billing date generates the expected charge in Stripe test mode.

中文简介正在准备中。当前显示原文说明。

hideokamoto/stripe-testing-mcp-tools92026年7月29日 更新

Stripe CLI の `stripe fixtures` コマンドで実行可能な fixture JSON を、対話的に整理しながら生成・検証する。test_clock を使った時間進行、サブスクのライフサイクル、失敗カードでの payment_intent 失敗、Connect 配下の Destination charge、bulk 件数のテスト顧客作成など、複数ステップの API リクエスト連鎖を扱う。「Stripe の fixture を書いて」「fixtures.json を作って」「このシナリオを fixture 化」「テストデータを大量に作りたい」「サブスクの月次失敗をテストしたい」「stripe trigger と fixture どっち使う」のような依頼で起動する。"fixture" という単語が無くても、複数ステップの Stripe テストデータ準備、 test clock を使った時間進行、 bulk なテスト顧客作成、 失敗パターンの再現といった意図が見えたら起動する。単発 API 呼び出しが目的なら起動せずに `stripe trigger` か API 1コールを案内する。

中文简介正在准备中。当前显示原文说明。

hideokamoto/stripe-testing-mcp-tools92026年7月29日 更新

Set up, verify, and clean up Stripe test data end to end. Use when creating test customers, products, or subscriptions and you want a repeatable setup-then-teardown workflow, or when you need to remove leftover test customers and products with delete_stripe_test_customers, archive_stripe_test_products, and delete_stripe_test_products.

中文简介正在准备中。当前显示原文说明。

hideokamoto/stripe-testing-mcp-tools92026年7月29日 更新

查看 hideokamoto 的全部技能

报告此技能的问题