image-skill 0.1.59 → 0.1.60

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -4,6 +4,15 @@ This changelog tracks the public `image-skill` CLI package and public skill
4
4
  mirror. The npm package metadata remains the authority for tarball integrity and
5
5
  provenance; this file is the human- and agent-readable release map.
6
6
 
7
+ ## 0.1.60 - 2026-06-17
8
+
9
+ - Release (activation/self-fund): add `credits quote --json`
10
+ `data.next_actions.recommended_buy`, carrying the returned `quote_id`, a
11
+ stable purchase idempotency key, copy-runnable buy/status commands, and
12
+ explicit live-money payment-attempt safety fields. Quote remains no-credit
13
+ and no-media; buy still requires delegated spend and verified
14
+ settlement/webhook fulfillment before credits are granted.
15
+
7
16
  ## 0.1.59 - 2026-06-17
8
17
 
9
18
  - Release (activation/self-fund): add
package/SKILL.md CHANGED
@@ -178,6 +178,13 @@ that action's `command` as the next authenticated quote step. It is the ranked
178
178
  handoff to the best currently usable rail. The quote command creates a
179
179
  live-money payment object but does not move money, grant credits, debit
180
180
  credits, call a provider, or write media.
181
+ After the quote succeeds, prefer
182
+ `data.next_actions.recommended_buy.command`: it includes the returned
183
+ `quote_id` and a stable non-secret purchase idempotency key. For x402 this
184
+ creates the browserless deposit attempt whose response contains pay-to
185
+ instructions; for Checkout this creates the human handoff URL. Use the quote
186
+ response's `status_command` to inspect by `quote_id`, and after buy returns a
187
+ `payment_attempt_id`, prefer `status_command_after_payment`.
181
188
 
182
189
  Credits are not granted until verified settlement or webhook fulfillment succeeds in either rail. Operator-provided promotion codes are entered on Stripe-hosted Checkout, not in the CLI. For exact bounded budgets, keep the same rail choice: use `credits quote --credits CREDITS --payment-method stripe_x402.exact.usdc` when the method is agent-settleable, and use `--payment-method stripe_checkout` only for a human Checkout fallback.
183
190
 
@@ -15,7 +15,7 @@ import { Readable } from "node:stream";
15
15
  import { pipeline } from "node:stream/promises";
16
16
  import os from "node:os";
17
17
 
18
- const VERSION = "0.1.59";
18
+ const VERSION = "0.1.60";
19
19
  const PACKAGE_NAME = "image-skill";
20
20
  const DEFAULT_API_BASE_URL = "https://api.image-skill.com";
21
21
  const DEFAULT_DOCS_BASE_URL = "https://image-skill.com";
@@ -1241,7 +1241,10 @@ async function credits(argv) {
1241
1241
  `generated idempotency key ${idempotency.value}; pass --idempotency-key for stable retries`,
1242
1242
  );
1243
1243
  }
1244
- return result;
1244
+ return withCopyRunnableCreditQuoteCommands(
1245
+ result,
1246
+ createGuideCommandPrefix(),
1247
+ );
1245
1248
  }
1246
1249
  if (subcommand === "buy") {
1247
1250
  const args = parseArgs(rest);
@@ -2759,6 +2762,73 @@ function paymentMethodCatalogWithCopyRunnableCommands(catalog, commandPrefix) {
2759
2762
  };
2760
2763
  }
2761
2764
 
2765
+ function withCopyRunnableCreditQuoteCommands(result, commandPrefix) {
2766
+ const data = result.envelope.data;
2767
+ if (
2768
+ data === null ||
2769
+ typeof data !== "object" ||
2770
+ data.next_actions === null ||
2771
+ typeof data.next_actions !== "object"
2772
+ ) {
2773
+ return result;
2774
+ }
2775
+ return {
2776
+ ...result,
2777
+ envelope: {
2778
+ ...result.envelope,
2779
+ data: creditQuoteWithCopyRunnableCommands(data, commandPrefix),
2780
+ },
2781
+ };
2782
+ }
2783
+
2784
+ function creditQuoteWithCopyRunnableCommands(quote, commandPrefix) {
2785
+ const recommendedBuy =
2786
+ quote.next_actions?.recommended_buy !== null &&
2787
+ typeof quote.next_actions?.recommended_buy === "object"
2788
+ ? quote.next_actions.recommended_buy
2789
+ : null;
2790
+ if (recommendedBuy === null) {
2791
+ return quote;
2792
+ }
2793
+ return {
2794
+ ...quote,
2795
+ next_actions: {
2796
+ ...quote.next_actions,
2797
+ recommended_buy: {
2798
+ ...recommendedBuy,
2799
+ command:
2800
+ typeof recommendedBuy.command === "string"
2801
+ ? renderCopyRunnablePaymentCommand(
2802
+ commandPrefix,
2803
+ recommendedBuy.command,
2804
+ )
2805
+ : recommendedBuy.command,
2806
+ buy_command:
2807
+ typeof recommendedBuy.buy_command === "string"
2808
+ ? renderCopyRunnablePaymentCommand(
2809
+ commandPrefix,
2810
+ recommendedBuy.buy_command,
2811
+ )
2812
+ : recommendedBuy.buy_command,
2813
+ status_command:
2814
+ typeof recommendedBuy.status_command === "string"
2815
+ ? renderCopyRunnablePaymentCommand(
2816
+ commandPrefix,
2817
+ recommendedBuy.status_command,
2818
+ )
2819
+ : recommendedBuy.status_command,
2820
+ status_command_after_payment:
2821
+ typeof recommendedBuy.status_command_after_payment === "string"
2822
+ ? renderCopyRunnablePaymentCommand(
2823
+ commandPrefix,
2824
+ recommendedBuy.status_command_after_payment,
2825
+ )
2826
+ : recommendedBuy.status_command_after_payment,
2827
+ },
2828
+ },
2829
+ };
2830
+ }
2831
+
2762
2832
  function renderCopyRunnablePaymentCommand(commandPrefix, command) {
2763
2833
  if (/\bnpx\s+(?:-y|--yes)\s+image-skill@latest\b/.test(command)) {
2764
2834
  return command;
package/cli.md CHANGED
@@ -623,14 +623,47 @@ Minimum success data:
623
623
  "idempotency_key": "quote-run-001",
624
624
  "pack_id": null,
625
625
  "pack": null,
626
- "live_money": true
626
+ "live_money": true,
627
+ "next_actions": {
628
+ "recommended_buy": {
629
+ "purpose": "complete_credit_top_up",
630
+ "recommendation_reason": "human_checkout_handoff",
631
+ "quote_id": "quote_...",
632
+ "method_id": "stripe_checkout",
633
+ "provider": "stripe",
634
+ "command": "image-skill credits buy --provider stripe --quote-id quote_... --idempotency-key purchase:quote_... --json",
635
+ "buy_command_copy_runnable": true,
636
+ "purchase_idempotency_key": "purchase:quote_...",
637
+ "status_command": "image-skill credits status --quote-id quote_... --json",
638
+ "status_command_copy_runnable": true,
639
+ "status_command_after_payment": "image-skill credits status --payment-attempt-id PAYMENT_ATTEMPT_ID --json",
640
+ "status_command_after_payment_copy_runnable": false,
641
+ "requires_auth": true,
642
+ "live_money": true,
643
+ "requires_browser": true,
644
+ "agent_settleable": false,
645
+ "human_handoff_required": true,
646
+ "command_effect": {
647
+ "label": "live_money_payment_attempt_requires_completion",
648
+ "no_spend": false,
649
+ "payment_attempt": true,
650
+ "credit_debit": false,
651
+ "media_write": false,
652
+ "wallet_settlement": false
653
+ }
654
+ }
655
+ }
627
656
  }
628
657
  ```
629
658
 
630
659
  For x402 quotes, `accepted_payment_method` is
631
660
  `"stripe_x402.exact.usdc"`. The quote does not grant credits or include pay-to
632
- instructions; `credits buy --provider stripe_x402` creates the action-required
633
- deposit challenge.
661
+ instructions; `data.next_actions.recommended_buy.command` carries the returned
662
+ `quote_id` and a stable non-secret purchase idempotency key for the
663
+ action-required deposit attempt. Run it only when delegated spend is allowed.
664
+ Use `data.next_actions.recommended_buy.status_command` to inspect the quote or
665
+ payment state by `quote_id`; after buy returns a `payment_attempt_id`, prefer
666
+ `status_command_after_payment`.
634
667
 
635
668
  Hosted API equivalent:
636
669
 
package/llms.txt CHANGED
@@ -118,7 +118,7 @@ Hosted API endpoints:
118
118
  - GET https://api.image-skill.com/v1/quota returns durable hosted quota for Authorization: Bearer TOKEN.
119
119
  - GET https://api.image-skill.com/v1/payment-methods returns the no-auth action-only payment rail catalog. It tells agents which currently usable rails are available, whether live money can move, buyer modes (agent_only, hybrid, human_only), browser requirements, agent_initiated, agent_settleable, settlement_blocker, limits, endpoint paths, recovery commands, and data.next_actions.recommended_quote when a currently usable live rail can be quoted next. Planned, watch-only, fake, and private harness rails are intentionally omitted.
120
120
  - GET https://api.image-skill.com/v1/credit-packs returns the public pack catalog. Recommended live-money packs include starter-500, builder-2000, and studio-5000. Packs are the default top-up UX; exact quotes remain supported for agents that already know the required credit budget.
121
- - POST https://api.image-skill.com/v1/credit-quotes returns a credit quote for Authorization: Bearer TOKEN. Request JSON: either credits or pack_id, optional payment_method, idempotency_key. Use stripe_checkout for the human Checkout path. Use payment_method stripe_x402.exact.usdc only when credits methods returns it available/quoteable/purchasable/requires_browser:false; treat it as autonomous self-settlement only when agent_settleable:true is also returned. Response includes quote_id, credits, price_amount_cents, currency, accepted_payment_method, pack_id, pack, and live_money. One credit equals $0.01, so price_amount_cents equals credits. This does not grant credits.
121
+ - POST https://api.image-skill.com/v1/credit-quotes returns a credit quote for Authorization: Bearer TOKEN. Request JSON: either credits or pack_id, optional payment_method, idempotency_key. Use stripe_checkout for the human Checkout path. Use payment_method stripe_x402.exact.usdc only when credits methods returns it available/quoteable/purchasable/requires_browser:false; treat it as autonomous self-settlement only when agent_settleable:true is also returned. Response includes quote_id, credits, price_amount_cents, currency, accepted_payment_method, pack_id, pack, live_money, and data.next_actions.recommended_buy for live public rails. The recommended buy action includes the real quote_id, a stable non-secret purchase_idempotency_key, a copy-runnable buy command, a quote-id status command, and a payment-attempt status template. One credit equals $0.01, so price_amount_cents equals credits. This does not grant credits.
122
122
  - POST https://api.image-skill.com/v1/credit-purchases/stripe-x402-deposits creates a browserless action-required USDC deposit attempt for a stripe_x402.exact.usdc quote. Request JSON: quote_id, idempotency_key. Response includes state: action_required, payment_attempt_id, accepted_payment_method: stripe_x402.exact.usdc, live_money, amount_cents, stripe_x402 challenge metadata, stripe_x402.payable_instructions when Stripe returns a Base deposit address, and next.agent_action: pay_stripe_crypto_deposit. A wallet-equipped agent can pay the exact USDC token_amount_atomic to payable_instructions.deposit_address on Base. This does not grant credits; verified settlement/webhook fulfillment grants paid credits exactly once.
123
123
  - POST https://api.image-skill.com/v1/credit-purchases/stripe-checkout-sessions creates a Stripe Checkout Session for a stripe_checkout quote. Request JSON: quote_id, idempotency_key. Response includes state: action_required, payment_attempt_id, checkout_session_id, checkout_handoff_url, checkout_compact_url, checkout_url, accepted_payment_method: stripe_checkout, and next.human_action: open_checkout_url. Present checkout_handoff_url to humans because it is short and redirects to Stripe; checkout_compact_url is also copy-safe when present. If no handoff URL is available, present the full checkout_url in a code block. Do not remove the Stripe # fragment; Checkout needs it in the browser. Stripe-hosted Checkout may accept operator-provided promotion codes; humans enter them on Stripe, not in the Image Skill CLI. This does not grant credits; verified Stripe webhook fulfillment grants paid credits exactly once.
124
124
  - GET https://api.image-skill.com/v1/credit-purchases/status returns durable payment state for Authorization: Bearer TOKEN. Query with exactly one of quote_id, payment_attempt_id, checkout_session_id, or receipt_id. Response includes state, quote, payment_attempt, receipt, credit_event, provider_event, limits, and next.
@@ -196,7 +196,7 @@ Unclaimed agents may not:
196
196
  - send card data, wallet secrets, wallet private keys, seed phrases, raw x402 payment headers, provider receipts, Stripe secrets, MPP tokens, SPTs, bearer tokens, or any payment credential to Image Skill; Stripe payment details must be entered only on Stripe-hosted checkout pages
197
197
 
198
198
  Credits:
199
- One Image Skill credit is $0.01. Use image-skill credits methods --json to inspect payment rail availability, browser/human requirements, agent_initiated, agent_settleable, and settlement_blocker. If data.next_actions.recommended_quote is present, prefer its command as the next authenticated quote step; it is a no-spend live-money quote object handoff and does not move money, grant credits, debit credits, call a provider, or write media. Always pass the returned payment method when quoting. When stripe_x402.exact.usdc is returned with available:true, quoteable:true, purchasable:true, requires_browser:false, and agent_settleable:true, image-skill credits quote --pack PACK_ID --payment-method stripe_x402.exact.usdc --json followed by image-skill credits buy --provider stripe_x402 --quote-id QUOTE_ID --idempotency-key KEY --json creates a browserless live deposit attempt with stripe_x402.payable_instructions. Treat live_money:true as real spend, stay inside the delegated cap, and pay exactly token_amount_atomic USDC units to payable_instructions.deposit_address on Base only from a wallet substrate you control. Use image-skill credits quote --pack PACK_ID --payment-method stripe_checkout --json and image-skill credits buy --provider stripe --quote-id QUOTE_ID --idempotency-key KEY --json only for the Stripe Checkout human path; this returns checkout_handoff_url, copy-safe checkout_compact_url, and full Stripe checkout_url fallback and does not grant credits. Present checkout_handoff_url or checkout_compact_url to humans, especially in mobile terminals, SSH, or chat. If checkout_handoff_url is absent, present the full checkout_url in a code block and preserve the Stripe # fragment. Use image-skill credits status --payment-attempt-id PAYMENT_ATTEMPT_ID --json after buy and after settlement/checkout completion to read state, receipt, credit_event, limits, and retry guidance. Create/edit debit model-priced credits after provider success; inspect models show and operation cost.credit_pricing for credits_required and pricing_confidence. Do not silently downgrade to the cheapest model to avoid payment when the user asked for quality or is willing to pay; quote the needed credits and use an agent_settleable:true x402 rail or Stripe Checkout fallback. Credits buy requires explicit --idempotency-key. Quote idempotency keys are scoped to the hosted agent identity and exact quote terms; the public CLI generates one when omitted and returns it in the quote response, while explicit keys remain available for retry-stable automation. Inspect error.recovery.suggested_command on CREDIT_QUOTE_CONFLICT. Never send payment credentials to Image Skill: no wallet private keys, seed phrases, x402 payment headers, deposit client secrets, provider receipts, card data, or Stripe secrets. Public request fields are credits, pack_id, payment_method, quote_id, status reference IDs, and idempotency_key.
199
+ One Image Skill credit is $0.01. Use image-skill credits methods --json to inspect payment rail availability, browser/human requirements, agent_initiated, agent_settleable, and settlement_blocker. If data.next_actions.recommended_quote is present, prefer its command as the next authenticated quote step; it is a no-spend live-money quote object handoff and does not move money, grant credits, debit credits, call a provider, or write media. Always pass the returned payment method when quoting. After a successful public live-rail quote, prefer data.next_actions.recommended_buy.command: it includes the returned quote_id and a stable non-secret purchase idempotency key, and creates or replays the matching payment attempt. When stripe_x402.exact.usdc is returned with available:true, quoteable:true, purchasable:true, requires_browser:false, and agent_settleable:true, image-skill credits quote --pack PACK_ID --payment-method stripe_x402.exact.usdc --json followed by the quote response's recommended_buy.command creates a browserless live deposit attempt with stripe_x402.payable_instructions. Treat live_money:true as real spend, stay inside the delegated cap, and pay exactly token_amount_atomic USDC units to payable_instructions.deposit_address on Base only from a wallet substrate you control. Use image-skill credits quote --pack PACK_ID --payment-method stripe_checkout --json and the quote response's recommended_buy.command only for the Stripe Checkout human path; this returns checkout_handoff_url, copy-safe checkout_compact_url, and full Stripe checkout_url fallback and does not grant credits. Present checkout_handoff_url or checkout_compact_url to humans, especially in mobile terminals, SSH, or chat. If checkout_handoff_url is absent, present the full checkout_url in a code block and preserve the Stripe # fragment. Use image-skill credits status --quote-id QUOTE_ID --json before or after buy, and image-skill credits status --payment-attempt-id PAYMENT_ATTEMPT_ID --json after buy and after settlement/checkout completion to read state, receipt, credit_event, limits, and retry guidance. Create/edit debit model-priced credits after provider success; inspect models show and operation cost.credit_pricing for credits_required and pricing_confidence. Do not silently downgrade to the cheapest model to avoid payment when the user asked for quality or is willing to pay; quote the needed credits and use an agent_settleable:true x402 rail or Stripe Checkout fallback. Credits buy requires explicit --idempotency-key; recommended_buy.command supplies one generated from the quote id. Quote idempotency keys are scoped to the hosted agent identity and exact quote terms; the public CLI generates one when omitted and returns it in the quote response, while explicit keys remain available for retry-stable automation. Inspect error.recovery.suggested_command on CREDIT_QUOTE_CONFLICT. Never send payment credentials to Image Skill: no wallet private keys, seed phrases, x402 payment headers, deposit client secrets, provider receipts, card data, or Stripe secrets. Public request fields are credits, pack_id, payment_method, quote_id, status reference IDs, and idempotency_key.
200
200
 
201
201
  Telemetry:
202
202
  - command or endpoint name
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "image-skill",
3
- "version": "0.1.59",
3
+ "version": "0.1.60",
4
4
  "description": "Zero-setup durable creative-media CLI for agents (image + video + audio + 3D): guide-first creation, model and cost inspection, owned URLs, JSON recovery, payments, reusable assets, and feedback.",
5
5
  "type": "module",
6
6
  "private": false,
package/skill.md CHANGED
@@ -178,6 +178,13 @@ that action's `command` as the next authenticated quote step. It is the ranked
178
178
  handoff to the best currently usable rail. The quote command creates a
179
179
  live-money payment object but does not move money, grant credits, debit
180
180
  credits, call a provider, or write media.
181
+ After the quote succeeds, prefer
182
+ `data.next_actions.recommended_buy.command`: it includes the returned
183
+ `quote_id` and a stable non-secret purchase idempotency key. For x402 this
184
+ creates the browserless deposit attempt whose response contains pay-to
185
+ instructions; for Checkout this creates the human handoff URL. Use the quote
186
+ response's `status_command` to inspect by `quote_id`, and after buy returns a
187
+ `payment_attempt_id`, prefer `status_command_after_payment`.
181
188
 
182
189
  Credits are not granted until verified settlement or webhook fulfillment succeeds in either rail. Operator-provided promotion codes are entered on Stripe-hosted Checkout, not in the CLI. For exact bounded budgets, keep the same rail choice: use `credits quote --credits CREDITS --payment-method stripe_x402.exact.usdc` when the method is agent-settleable, and use `--payment-method stripe_checkout` only for a human Checkout fallback.
183
190
 
@@ -178,6 +178,13 @@ that action's `command` as the next authenticated quote step. It is the ranked
178
178
  handoff to the best currently usable rail. The quote command creates a
179
179
  live-money payment object but does not move money, grant credits, debit
180
180
  credits, call a provider, or write media.
181
+ After the quote succeeds, prefer
182
+ `data.next_actions.recommended_buy.command`: it includes the returned
183
+ `quote_id` and a stable non-secret purchase idempotency key. For x402 this
184
+ creates the browserless deposit attempt whose response contains pay-to
185
+ instructions; for Checkout this creates the human handoff URL. Use the quote
186
+ response's `status_command` to inspect by `quote_id`, and after buy returns a
187
+ `payment_attempt_id`, prefer `status_command_after_payment`.
181
188
 
182
189
  Credits are not granted until verified settlement or webhook fulfillment succeeds in either rail. Operator-provided promotion codes are entered on Stripe-hosted Checkout, not in the CLI. For exact bounded budgets, keep the same rail choice: use `credits quote --credits CREDITS --payment-method stripe_x402.exact.usdc` when the method is agent-settleable, and use `--payment-method stripe_checkout` only for a human Checkout fallback.
183
190
 
@@ -623,14 +623,47 @@ Minimum success data:
623
623
  "idempotency_key": "quote-run-001",
624
624
  "pack_id": null,
625
625
  "pack": null,
626
- "live_money": true
626
+ "live_money": true,
627
+ "next_actions": {
628
+ "recommended_buy": {
629
+ "purpose": "complete_credit_top_up",
630
+ "recommendation_reason": "human_checkout_handoff",
631
+ "quote_id": "quote_...",
632
+ "method_id": "stripe_checkout",
633
+ "provider": "stripe",
634
+ "command": "image-skill credits buy --provider stripe --quote-id quote_... --idempotency-key purchase:quote_... --json",
635
+ "buy_command_copy_runnable": true,
636
+ "purchase_idempotency_key": "purchase:quote_...",
637
+ "status_command": "image-skill credits status --quote-id quote_... --json",
638
+ "status_command_copy_runnable": true,
639
+ "status_command_after_payment": "image-skill credits status --payment-attempt-id PAYMENT_ATTEMPT_ID --json",
640
+ "status_command_after_payment_copy_runnable": false,
641
+ "requires_auth": true,
642
+ "live_money": true,
643
+ "requires_browser": true,
644
+ "agent_settleable": false,
645
+ "human_handoff_required": true,
646
+ "command_effect": {
647
+ "label": "live_money_payment_attempt_requires_completion",
648
+ "no_spend": false,
649
+ "payment_attempt": true,
650
+ "credit_debit": false,
651
+ "media_write": false,
652
+ "wallet_settlement": false
653
+ }
654
+ }
655
+ }
627
656
  }
628
657
  ```
629
658
 
630
659
  For x402 quotes, `accepted_payment_method` is
631
660
  `"stripe_x402.exact.usdc"`. The quote does not grant credits or include pay-to
632
- instructions; `credits buy --provider stripe_x402` creates the action-required
633
- deposit challenge.
661
+ instructions; `data.next_actions.recommended_buy.command` carries the returned
662
+ `quote_id` and a stable non-secret purchase idempotency key for the
663
+ action-required deposit attempt. Run it only when delegated spend is allowed.
664
+ Use `data.next_actions.recommended_buy.status_command` to inspect the quote or
665
+ payment state by `quote_id`; after buy returns a `payment_attempt_id`, prefer
666
+ `status_command_after_payment`.
634
667
 
635
668
  Hosted API equivalent:
636
669
 
@@ -118,7 +118,7 @@ Hosted API endpoints:
118
118
  - GET https://api.image-skill.com/v1/quota returns durable hosted quota for Authorization: Bearer TOKEN.
119
119
  - GET https://api.image-skill.com/v1/payment-methods returns the no-auth action-only payment rail catalog. It tells agents which currently usable rails are available, whether live money can move, buyer modes (agent_only, hybrid, human_only), browser requirements, agent_initiated, agent_settleable, settlement_blocker, limits, endpoint paths, recovery commands, and data.next_actions.recommended_quote when a currently usable live rail can be quoted next. Planned, watch-only, fake, and private harness rails are intentionally omitted.
120
120
  - GET https://api.image-skill.com/v1/credit-packs returns the public pack catalog. Recommended live-money packs include starter-500, builder-2000, and studio-5000. Packs are the default top-up UX; exact quotes remain supported for agents that already know the required credit budget.
121
- - POST https://api.image-skill.com/v1/credit-quotes returns a credit quote for Authorization: Bearer TOKEN. Request JSON: either credits or pack_id, optional payment_method, idempotency_key. Use stripe_checkout for the human Checkout path. Use payment_method stripe_x402.exact.usdc only when credits methods returns it available/quoteable/purchasable/requires_browser:false; treat it as autonomous self-settlement only when agent_settleable:true is also returned. Response includes quote_id, credits, price_amount_cents, currency, accepted_payment_method, pack_id, pack, and live_money. One credit equals $0.01, so price_amount_cents equals credits. This does not grant credits.
121
+ - POST https://api.image-skill.com/v1/credit-quotes returns a credit quote for Authorization: Bearer TOKEN. Request JSON: either credits or pack_id, optional payment_method, idempotency_key. Use stripe_checkout for the human Checkout path. Use payment_method stripe_x402.exact.usdc only when credits methods returns it available/quoteable/purchasable/requires_browser:false; treat it as autonomous self-settlement only when agent_settleable:true is also returned. Response includes quote_id, credits, price_amount_cents, currency, accepted_payment_method, pack_id, pack, live_money, and data.next_actions.recommended_buy for live public rails. The recommended buy action includes the real quote_id, a stable non-secret purchase_idempotency_key, a copy-runnable buy command, a quote-id status command, and a payment-attempt status template. One credit equals $0.01, so price_amount_cents equals credits. This does not grant credits.
122
122
  - POST https://api.image-skill.com/v1/credit-purchases/stripe-x402-deposits creates a browserless action-required USDC deposit attempt for a stripe_x402.exact.usdc quote. Request JSON: quote_id, idempotency_key. Response includes state: action_required, payment_attempt_id, accepted_payment_method: stripe_x402.exact.usdc, live_money, amount_cents, stripe_x402 challenge metadata, stripe_x402.payable_instructions when Stripe returns a Base deposit address, and next.agent_action: pay_stripe_crypto_deposit. A wallet-equipped agent can pay the exact USDC token_amount_atomic to payable_instructions.deposit_address on Base. This does not grant credits; verified settlement/webhook fulfillment grants paid credits exactly once.
123
123
  - POST https://api.image-skill.com/v1/credit-purchases/stripe-checkout-sessions creates a Stripe Checkout Session for a stripe_checkout quote. Request JSON: quote_id, idempotency_key. Response includes state: action_required, payment_attempt_id, checkout_session_id, checkout_handoff_url, checkout_compact_url, checkout_url, accepted_payment_method: stripe_checkout, and next.human_action: open_checkout_url. Present checkout_handoff_url to humans because it is short and redirects to Stripe; checkout_compact_url is also copy-safe when present. If no handoff URL is available, present the full checkout_url in a code block. Do not remove the Stripe # fragment; Checkout needs it in the browser. Stripe-hosted Checkout may accept operator-provided promotion codes; humans enter them on Stripe, not in the Image Skill CLI. This does not grant credits; verified Stripe webhook fulfillment grants paid credits exactly once.
124
124
  - GET https://api.image-skill.com/v1/credit-purchases/status returns durable payment state for Authorization: Bearer TOKEN. Query with exactly one of quote_id, payment_attempt_id, checkout_session_id, or receipt_id. Response includes state, quote, payment_attempt, receipt, credit_event, provider_event, limits, and next.
@@ -196,7 +196,7 @@ Unclaimed agents may not:
196
196
  - send card data, wallet secrets, wallet private keys, seed phrases, raw x402 payment headers, provider receipts, Stripe secrets, MPP tokens, SPTs, bearer tokens, or any payment credential to Image Skill; Stripe payment details must be entered only on Stripe-hosted checkout pages
197
197
 
198
198
  Credits:
199
- One Image Skill credit is $0.01. Use image-skill credits methods --json to inspect payment rail availability, browser/human requirements, agent_initiated, agent_settleable, and settlement_blocker. If data.next_actions.recommended_quote is present, prefer its command as the next authenticated quote step; it is a no-spend live-money quote object handoff and does not move money, grant credits, debit credits, call a provider, or write media. Always pass the returned payment method when quoting. When stripe_x402.exact.usdc is returned with available:true, quoteable:true, purchasable:true, requires_browser:false, and agent_settleable:true, image-skill credits quote --pack PACK_ID --payment-method stripe_x402.exact.usdc --json followed by image-skill credits buy --provider stripe_x402 --quote-id QUOTE_ID --idempotency-key KEY --json creates a browserless live deposit attempt with stripe_x402.payable_instructions. Treat live_money:true as real spend, stay inside the delegated cap, and pay exactly token_amount_atomic USDC units to payable_instructions.deposit_address on Base only from a wallet substrate you control. Use image-skill credits quote --pack PACK_ID --payment-method stripe_checkout --json and image-skill credits buy --provider stripe --quote-id QUOTE_ID --idempotency-key KEY --json only for the Stripe Checkout human path; this returns checkout_handoff_url, copy-safe checkout_compact_url, and full Stripe checkout_url fallback and does not grant credits. Present checkout_handoff_url or checkout_compact_url to humans, especially in mobile terminals, SSH, or chat. If checkout_handoff_url is absent, present the full checkout_url in a code block and preserve the Stripe # fragment. Use image-skill credits status --payment-attempt-id PAYMENT_ATTEMPT_ID --json after buy and after settlement/checkout completion to read state, receipt, credit_event, limits, and retry guidance. Create/edit debit model-priced credits after provider success; inspect models show and operation cost.credit_pricing for credits_required and pricing_confidence. Do not silently downgrade to the cheapest model to avoid payment when the user asked for quality or is willing to pay; quote the needed credits and use an agent_settleable:true x402 rail or Stripe Checkout fallback. Credits buy requires explicit --idempotency-key. Quote idempotency keys are scoped to the hosted agent identity and exact quote terms; the public CLI generates one when omitted and returns it in the quote response, while explicit keys remain available for retry-stable automation. Inspect error.recovery.suggested_command on CREDIT_QUOTE_CONFLICT. Never send payment credentials to Image Skill: no wallet private keys, seed phrases, x402 payment headers, deposit client secrets, provider receipts, card data, or Stripe secrets. Public request fields are credits, pack_id, payment_method, quote_id, status reference IDs, and idempotency_key.
199
+ One Image Skill credit is $0.01. Use image-skill credits methods --json to inspect payment rail availability, browser/human requirements, agent_initiated, agent_settleable, and settlement_blocker. If data.next_actions.recommended_quote is present, prefer its command as the next authenticated quote step; it is a no-spend live-money quote object handoff and does not move money, grant credits, debit credits, call a provider, or write media. Always pass the returned payment method when quoting. After a successful public live-rail quote, prefer data.next_actions.recommended_buy.command: it includes the returned quote_id and a stable non-secret purchase idempotency key, and creates or replays the matching payment attempt. When stripe_x402.exact.usdc is returned with available:true, quoteable:true, purchasable:true, requires_browser:false, and agent_settleable:true, image-skill credits quote --pack PACK_ID --payment-method stripe_x402.exact.usdc --json followed by the quote response's recommended_buy.command creates a browserless live deposit attempt with stripe_x402.payable_instructions. Treat live_money:true as real spend, stay inside the delegated cap, and pay exactly token_amount_atomic USDC units to payable_instructions.deposit_address on Base only from a wallet substrate you control. Use image-skill credits quote --pack PACK_ID --payment-method stripe_checkout --json and the quote response's recommended_buy.command only for the Stripe Checkout human path; this returns checkout_handoff_url, copy-safe checkout_compact_url, and full Stripe checkout_url fallback and does not grant credits. Present checkout_handoff_url or checkout_compact_url to humans, especially in mobile terminals, SSH, or chat. If checkout_handoff_url is absent, present the full checkout_url in a code block and preserve the Stripe # fragment. Use image-skill credits status --quote-id QUOTE_ID --json before or after buy, and image-skill credits status --payment-attempt-id PAYMENT_ATTEMPT_ID --json after buy and after settlement/checkout completion to read state, receipt, credit_event, limits, and retry guidance. Create/edit debit model-priced credits after provider success; inspect models show and operation cost.credit_pricing for credits_required and pricing_confidence. Do not silently downgrade to the cheapest model to avoid payment when the user asked for quality or is willing to pay; quote the needed credits and use an agent_settleable:true x402 rail or Stripe Checkout fallback. Credits buy requires explicit --idempotency-key; recommended_buy.command supplies one generated from the quote id. Quote idempotency keys are scoped to the hosted agent identity and exact quote terms; the public CLI generates one when omitted and returns it in the quote response, while explicit keys remain available for retry-stable automation. Inspect error.recovery.suggested_command on CREDIT_QUOTE_CONFLICT. Never send payment credentials to Image Skill: no wallet private keys, seed phrases, x402 payment headers, deposit client secrets, provider receipts, card data, or Stripe secrets. Public request fields are credits, pack_id, payment_method, quote_id, status reference IDs, and idempotency_key.
200
200
 
201
201
  Telemetry:
202
202
  - command or endpoint name