@fleetless/contracts 6.4.0 → 7.0.0-next.1
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 +42 -0
- package/artifacts/openapi.json +5805 -1805
- package/artifacts/routes.json +104 -17
- package/artifacts/schema/addon-catalogue-entry.schema.json +1 -15
- package/artifacts/schema/billing-address.schema.json +7 -1
- package/artifacts/schema/billing-change-request.schema.json +9 -0
- package/artifacts/schema/billing-change-response.schema.json +2219 -625
- package/artifacts/schema/billing-details-update.schema.json +70 -0
- package/artifacts/schema/billing-details.schema.json +27 -3
- package/artifacts/schema/billing-view.schema.json +56 -24
- package/artifacts/schema/checkout-request.schema.json +90 -154
- package/artifacts/schema/checkout-response.schema.json +531 -17
- package/artifacts/schema/invoice-pay-request.schema.json +16 -0
- package/artifacts/schema/payment-method-change-request.schema.json +7 -0
- package/artifacts/schema/plan-catalogue-entry.schema.json +1 -15
- package/artifacts/schema/plan-prices.schema.json +1 -15
- package/artifacts/schema/purchase-billing-details.schema.json +111 -0
- package/artifacts/schema/purchase-conflict-details.schema.json +582 -0
- package/artifacts/schema/purchase-hold-reason.schema.json +9 -0
- package/artifacts/schema/purchase-intent-confirm-request.schema.json +40 -0
- package/artifacts/schema/purchase-intent-lookup-query.schema.json +56 -0
- package/artifacts/schema/purchase-intent-response.schema.json +1554 -0
- package/artifacts/schema/purchase-operation-key.schema.json +7 -0
- package/artifacts/schema/purchase-operation.schema.json +11 -0
- package/artifacts/schema/purchase-quote.schema.json +43 -0
- package/artifacts/schema/purchase-refusal-rule.schema.json +13 -0
- package/artifacts/schema/vat-decision.schema.json +77 -0
- package/artifacts/schema/vat-id-check-response.schema.json +111 -25
- package/artifacts/schema/vies-pending-reason.schema.json +9 -0
- package/dist/billing.d.ts +1128 -75
- package/dist/billing.js +174 -66
- package/dist/index.d.ts +2 -0
- package/dist/index.js +1 -0
- package/dist/plans.d.ts +4 -9
- package/dist/plans.js +4 -7
- package/dist/routes.js +62 -64
- package/package.json +2 -2
package/artifacts/routes.json
CHANGED
|
@@ -3186,6 +3186,31 @@
|
|
|
3186
3186
|
"transport": "http",
|
|
3187
3187
|
"notes": "`I saved my recovery codes` gates the button on the page; the step itself only checks that a second factor now exists. A browser gets a `303` to the console callback with the authorization code; a JSON caller that URL as `redirect_to`."
|
|
3188
3188
|
},
|
|
3189
|
+
{
|
|
3190
|
+
"method": "GET",
|
|
3191
|
+
"path": "/waitlist-invite/:token",
|
|
3192
|
+
"section": "developer-auth",
|
|
3193
|
+
"summary": "Starts invite-bound console sign-up for a new Basic organization.",
|
|
3194
|
+
"audience": "internal",
|
|
3195
|
+
"auth": "none",
|
|
3196
|
+
"rateLimited": true,
|
|
3197
|
+
"ownerTier": false,
|
|
3198
|
+
"status": 303,
|
|
3199
|
+
"params": [
|
|
3200
|
+
{
|
|
3201
|
+
"name": "token",
|
|
3202
|
+
"description": "The opaque waiting-list invitation token from the mailed link; never a query parameter."
|
|
3203
|
+
}
|
|
3204
|
+
],
|
|
3205
|
+
"query": null,
|
|
3206
|
+
"request": null,
|
|
3207
|
+
"response": null,
|
|
3208
|
+
"errors": [
|
|
3209
|
+
"rate_limited"
|
|
3210
|
+
],
|
|
3211
|
+
"transport": "http",
|
|
3212
|
+
"notes": "Exchanges a valid seven-day invitation for a short-lived browser-proof cookie, then redirects with `303` into console sign-up. The response uses `Cache-Control: no-store` and `Referrer-Policy: no-referrer`; no caller-supplied redirect is accepted. Invalid, expired, used, declined or replaced links render the same `410` page; the per-IP backstop answers `429 rate_limited`. Only the invited normalized email address may register a new Basic organization under `SIGNUP_MODE=closed`, and the signup code still proves control of that address. Every step rechecks the unspent generation, expiry and address; re-inviting immediately invalidates the old link and any signup it started. The GET does not consume the invitation: final organization/Owner creation, waiting-list transition and single-use consumption share one transaction. The interaction binds the invitation id/generation, never the raw token. Tokens, proof values and recipient links stay out of the directory, logs and operator responses. Team invitations through `/accept-invite/:token` still join an existing organization."
|
|
3213
|
+
},
|
|
3189
3214
|
{
|
|
3190
3215
|
"method": "GET",
|
|
3191
3216
|
"path": "/console/oauth/signup/:id",
|
|
@@ -3207,7 +3232,7 @@
|
|
|
3207
3232
|
"response": null,
|
|
3208
3233
|
"errors": [],
|
|
3209
3234
|
"transport": "http",
|
|
3210
|
-
"notes": "HTML: the email field and `Email me a code`, the first of three steps — email, code, organization. While the deployment runs in closed beta this renders the \"sign-up is closed\" card at `403` instead, keeping the interaction alive and pointing back at sign-in and the waiting list — the person may well already have an account."
|
|
3235
|
+
"notes": "HTML: the email field and `Email me a code`, the first of three steps — email, code, organization. While the deployment runs in closed beta this renders the \"sign-up is closed\" card at `403` instead, keeping the interaction alive and pointing back at sign-in and the waiting list — the person may well already have an account. Under `SIGNUP_MODE=closed`, only a valid invite-bound interaction may continue for the invited normalized email address and a new Basic organization. Each step rechecks its unspent invitation generation, expiry and address; ordinary public sign-up remains refused."
|
|
3211
3236
|
},
|
|
3212
3237
|
{
|
|
3213
3238
|
"method": "POST",
|
|
@@ -3231,7 +3256,7 @@
|
|
|
3231
3256
|
"email_taken"
|
|
3232
3257
|
],
|
|
3233
3258
|
"transport": "http",
|
|
3234
|
-
"notes": "A browser form post gets the code card; a JSON caller gets `{ \"next\", \"email\" }`, which has no schema. **No password**: the code mailed here, six digits valid ten minutes, proves the address. A per-interaction proof cookie is set here — it is what stops a third party from finishing a sign-up somebody else started. Sign-up is the one surface whose job is to say an address is taken, so `409 email_taken` is not a leak here."
|
|
3259
|
+
"notes": "A browser form post gets the code card; a JSON caller gets `{ \"next\", \"email\" }`, which has no schema. **No password**: the code mailed here, six digits valid ten minutes, proves the address. A per-interaction proof cookie is set here — it is what stops a third party from finishing a sign-up somebody else started. Sign-up is the one surface whose job is to say an address is taken, so `409 email_taken` is not a leak here. Under `SIGNUP_MODE=closed`, only a valid invite-bound interaction may request the code for the invited normalized email address; the unspent invitation generation, expiry and address are rechecked. Ordinary public sign-up still answers `403 signup_closed`."
|
|
3235
3260
|
},
|
|
3236
3261
|
{
|
|
3237
3262
|
"method": "POST",
|
|
@@ -3256,7 +3281,7 @@
|
|
|
3256
3281
|
"invalid_code"
|
|
3257
3282
|
],
|
|
3258
3283
|
"transport": "http",
|
|
3259
|
-
"notes": "A wrong code renders the code card again with the attempts left (`400 invalid_code`); a spent, expired or exhausted one is `410 token_spent`. The step before must have run in **this** browser (`401 wrong_browser`). A browser form post gets the organization card, the address shown `confirmed`; a JSON caller gets `{ \"next\" }`, which has no schema."
|
|
3284
|
+
"notes": "A wrong code renders the code card again with the attempts left (`400 invalid_code`); a spent, expired or exhausted one is `410 token_spent`. The step before must have run in **this** browser (`401 wrong_browser`). A browser form post gets the organization card, the address shown `confirmed`; a JSON caller gets `{ \"next\" }`, which has no schema. Under `SIGNUP_MODE=closed`, only a valid invite-bound interaction may continue after rechecking its unspent invitation generation, expiry and invited normalized email address. Ordinary public sign-up still answers `403 signup_closed`."
|
|
3260
3285
|
},
|
|
3261
3286
|
{
|
|
3262
3287
|
"method": "POST",
|
|
@@ -3281,7 +3306,7 @@
|
|
|
3281
3306
|
"email_taken"
|
|
3282
3307
|
],
|
|
3283
3308
|
"transport": "http",
|
|
3284
|
-
"notes": "The form carries `org_name` only. The org and its founding Owner are created in one transaction, and only after the code step confirmed the address. Both steps before must have run in **this** browser: a missing or mismatched proof cookie is `401 wrong_browser` and the person is sent back to step one. `409 email_taken` when the address was taken meanwhile. A browser form post gets a `303` to the console callback; a JSON caller gets `redirect_to` at `200`. This is the only way an organisation is created: `POST /api/auth/signup` is gone, because without a password it would hand a session to anybody who names an address."
|
|
3309
|
+
"notes": "The form carries `org_name` only. The org and its founding Owner are created in one transaction, and only after the code step confirmed the address. Both steps before must have run in **this** browser: a missing or mismatched proof cookie is `401 wrong_browser` and the person is sent back to step one. `409 email_taken` when the address was taken meanwhile. A browser form post gets a `303` to the console callback; a JSON caller gets `redirect_to` at `200`. This is the only way an organisation is created: `POST /api/auth/signup` is gone, because without a password it would hand a session to anybody who names an address. Under `SIGNUP_MODE=closed`, only a valid invite-bound interaction may create a new Basic organization for the invited normalized email address. Rechecking the unspent invitation generation, expiry and address, creating the org/Owner, transitioning the waiting-list entry and consuming the invitation happen in that same transaction. Ordinary public sign-up still answers `403 signup_closed`."
|
|
3285
3310
|
},
|
|
3286
3311
|
{
|
|
3287
3312
|
"method": "POST",
|
|
@@ -6502,7 +6527,7 @@
|
|
|
6502
6527
|
"method": "POST",
|
|
6503
6528
|
"path": "/api/billing/checkout",
|
|
6504
6529
|
"section": "billing",
|
|
6505
|
-
"summary": "
|
|
6530
|
+
"summary": "Records a company purchase intent for the first paid plan.",
|
|
6506
6531
|
"audience": "developer",
|
|
6507
6532
|
"auth": "developer",
|
|
6508
6533
|
"rateLimited": true,
|
|
@@ -6525,7 +6550,67 @@
|
|
|
6525
6550
|
"payment_provider_unavailable"
|
|
6526
6551
|
],
|
|
6527
6552
|
"transport": "http",
|
|
6528
|
-
"notes": "
|
|
6553
|
+
"notes": "Basic stays free for every payer. New paid checkout requires a company, terms, current buyer eligibility and an EUR quote. Other EU countries require direct VIES valid with an identifier; unavailable/unverified or missing identifier returns awaiting_vies without payment or redirect. Cloud checks the non-EU Tax ID and versioned public-email policy, and US state. Persist operation_key before POST; the same org/key/input returns the same intent, different input is 409 target_state_conflict with purchaseConflictDetails rule operation_key_reused. Owner lookup recovers a lost response. Only explicit confirmation of the current quote may create a payment; a worker cannot start it. payment_started.payment.checkout_url exists only for a hosted payment, where the buyer chooses card, PayPal or Apple Pay. Its return is <console>/settings/billing?checkout=<checkout_id>; GET /api/billing/checkout/:id reconciles the recorded payment. An active/past_due account uses billing/change; already_billed and plan_limit retain their existing meanings."
|
|
6554
|
+
},
|
|
6555
|
+
{
|
|
6556
|
+
"method": "GET",
|
|
6557
|
+
"path": "/api/billing/intents",
|
|
6558
|
+
"section": "billing",
|
|
6559
|
+
"summary": "Recovers a purchase intent by operation key or intent ID.",
|
|
6560
|
+
"audience": "developer",
|
|
6561
|
+
"auth": "developer",
|
|
6562
|
+
"rateLimited": false,
|
|
6563
|
+
"ownerTier": true,
|
|
6564
|
+
"status": 200,
|
|
6565
|
+
"params": [],
|
|
6566
|
+
"query": "purchase-intent-lookup-query",
|
|
6567
|
+
"request": null,
|
|
6568
|
+
"response": "purchase-intent-response",
|
|
6569
|
+
"errors": [
|
|
6570
|
+
"unauthorized",
|
|
6571
|
+
"token_expired",
|
|
6572
|
+
"token_revoked",
|
|
6573
|
+
"tier_required",
|
|
6574
|
+
"validation_error",
|
|
6575
|
+
"not_found"
|
|
6576
|
+
],
|
|
6577
|
+
"transport": "http",
|
|
6578
|
+
"notes": "Supply exactly one of operation_key or intent_id and the expected operation. Scope lookup to the authenticated owner and org; unknown, foreign-org or mismatched-operation intents return 404 without disclosure. Repeating a lookup after restart or lost response returns the same intent/payment identity and, for a paid change, its billing result. Awaiting VIES and eligible states never start payment; Console polls at a bounded interval and asks for fresh confirmation of the displayed quote."
|
|
6579
|
+
},
|
|
6580
|
+
{
|
|
6581
|
+
"method": "POST",
|
|
6582
|
+
"path": "/api/billing/intents/:id/confirm",
|
|
6583
|
+
"section": "billing",
|
|
6584
|
+
"summary": "Confirms the current purchase quote exactly once.",
|
|
6585
|
+
"audience": "developer",
|
|
6586
|
+
"auth": "developer",
|
|
6587
|
+
"rateLimited": true,
|
|
6588
|
+
"ownerTier": true,
|
|
6589
|
+
"status": 200,
|
|
6590
|
+
"params": [
|
|
6591
|
+
{
|
|
6592
|
+
"name": "id",
|
|
6593
|
+
"description": "The intent ID returned by the start or lookup response."
|
|
6594
|
+
}
|
|
6595
|
+
],
|
|
6596
|
+
"query": null,
|
|
6597
|
+
"request": "purchase-intent-confirm-request",
|
|
6598
|
+
"response": "purchase-intent-response",
|
|
6599
|
+
"errors": [
|
|
6600
|
+
"unauthorized",
|
|
6601
|
+
"token_expired",
|
|
6602
|
+
"token_revoked",
|
|
6603
|
+
"tier_required",
|
|
6604
|
+
"validation_error",
|
|
6605
|
+
"not_found",
|
|
6606
|
+
"target_state_conflict",
|
|
6607
|
+
"plan_limit",
|
|
6608
|
+
"rate_limited",
|
|
6609
|
+
"billing_unavailable",
|
|
6610
|
+
"payment_provider_unavailable"
|
|
6611
|
+
],
|
|
6612
|
+
"transport": "http",
|
|
6613
|
+
"notes": "Require the same operation_key and operation plus the displayed quote_revision and buyer_fingerprint. Under the org lock compare current buyer, country, VAT ID, Tax ID, invoice email/policy version, US state, EUR quote, invoice status/amount/currency and integration holds. A stale revision is 409 target_state_conflict with purchaseConflictDetails/current_intent; the owner must confirm again. Foreign or mismatched operation is 404 without disclosure. Pending or held cannot charge. Persist one payment row before the provider call and use its ID as the provider idempotency key. Repeated confirmations and lost responses recover that payment/result; never create another. Look up/adopt a possibly-created payment before resending after a timeout; ambiguity is not permission to charge again."
|
|
6529
6614
|
},
|
|
6530
6615
|
{
|
|
6531
6616
|
"method": "GET",
|
|
@@ -6560,7 +6645,7 @@
|
|
|
6560
6645
|
"method": "POST",
|
|
6561
6646
|
"path": "/api/billing/vat-id/check",
|
|
6562
6647
|
"section": "billing",
|
|
6563
|
-
"summary": "Checks a VAT ID
|
|
6648
|
+
"summary": "Checks a VAT ID using requester-aware direct VIES.",
|
|
6564
6649
|
"audience": "developer",
|
|
6565
6650
|
"auth": "developer",
|
|
6566
6651
|
"rateLimited": true,
|
|
@@ -6579,13 +6664,13 @@
|
|
|
6579
6664
|
"rate_limited"
|
|
6580
6665
|
],
|
|
6581
6666
|
"transport": "http",
|
|
6582
|
-
"notes": "
|
|
6667
|
+
"notes": "Reports status and optional display name only; full evidence stays in protected Finance storage. valid with a missing identifier remains pending/vies_identifier_missing. unverified or unavailable remains pending without zero rating or payment. A form check never authorizes a later charge; Cloud binds current evidence to the buyer and quote at confirmation. Rate limited on billing.vat_check."
|
|
6583
6668
|
},
|
|
6584
6669
|
{
|
|
6585
6670
|
"method": "PATCH",
|
|
6586
6671
|
"path": "/api/billing/details",
|
|
6587
6672
|
"section": "billing",
|
|
6588
|
-
"summary": "Edits
|
|
6673
|
+
"summary": "Edits company billing details for revalidation before the next charge.",
|
|
6589
6674
|
"audience": "developer",
|
|
6590
6675
|
"auth": "developer",
|
|
6591
6676
|
"rateLimited": false,
|
|
@@ -6604,13 +6689,13 @@
|
|
|
6604
6689
|
"not_found"
|
|
6605
6690
|
],
|
|
6606
6691
|
"transport": "http",
|
|
6607
|
-
"notes": "
|
|
6692
|
+
"notes": "404 not_found when no billing account exists. Edits may change company name, full address/state, Tax ID, VAT ID and invoice email. Validate the merged buyer before a later charge; edits invalidate old evidence and quote revisions. Revalidate the email policy and country requirements. An edit does not create a payment, activate a plan, pay an invoice, clear dunning or lift a lock."
|
|
6608
6693
|
},
|
|
6609
6694
|
{
|
|
6610
6695
|
"method": "POST",
|
|
6611
6696
|
"path": "/api/billing/change",
|
|
6612
6697
|
"section": "billing",
|
|
6613
|
-
"summary": "
|
|
6698
|
+
"summary": "Records a paid-change intent or schedules a decrease.",
|
|
6614
6699
|
"audience": "developer",
|
|
6615
6700
|
"auth": "developer",
|
|
6616
6701
|
"rateLimited": false,
|
|
@@ -6632,13 +6717,13 @@
|
|
|
6632
6717
|
"payment_provider_unavailable"
|
|
6633
6718
|
],
|
|
6634
6719
|
"transport": "http",
|
|
6635
|
-
"notes": "The
|
|
6720
|
+
"notes": "The request names an absolute plan/cycle/add-on target and a stable operation_key. Increases need a current company/EUR decision and explicit owner confirmation even after a worker resolves VIES. billingChangeResponse carries intent while awaiting_vies, eligible, refused or held; the old plan stays in effect. Confirm under the org lock, comparing buyer/policy fingerprint and quote revision; use one persisted payment row for provider idempotency. A started paid change returns billing, charged and intent with payment_started. An immediate accepted decrease retains the billing/charged branch (charged null); decreases are scheduled for period end. Existing no_account, past_due, no_valid_mandate and plan_limit conflicts remain. Do not advance periods, cancel existing choices or begin dunning merely because an intent is pending."
|
|
6636
6721
|
},
|
|
6637
6722
|
{
|
|
6638
6723
|
"method": "POST",
|
|
6639
6724
|
"path": "/api/billing/payment-method",
|
|
6640
6725
|
"section": "billing",
|
|
6641
|
-
"summary": "
|
|
6726
|
+
"summary": "Records an invoice-paying method intent or a held mandate setup.",
|
|
6642
6727
|
"audience": "developer",
|
|
6643
6728
|
"auth": "developer",
|
|
6644
6729
|
"rateLimited": true,
|
|
@@ -6649,6 +6734,7 @@
|
|
|
6649
6734
|
"request": "payment-method-change-request",
|
|
6650
6735
|
"response": "checkout-response",
|
|
6651
6736
|
"errors": [
|
|
6737
|
+
"target_state_conflict",
|
|
6652
6738
|
"unauthorized",
|
|
6653
6739
|
"token_expired",
|
|
6654
6740
|
"token_revoked",
|
|
@@ -6660,7 +6746,7 @@
|
|
|
6660
6746
|
"payment_provider_unavailable"
|
|
6661
6747
|
],
|
|
6662
6748
|
"transport": "http",
|
|
6663
|
-
"notes": "
|
|
6749
|
+
"notes": "Use a stable operation_key and owner intent lookup after reload/timeout. Offer payment_method_options. Apple Pay with zero-amount changes disabled pays an open invoice through operation payment_method_invoice; without one, 400 validation_error has field method and rule applepay_needs_open_invoice. Apply the same buyer/VIES gate, current-amount reconfirmation and USD legacy hold as invoices/:id/pay. Pending, eligible and held contain no checkout URL; redirect only on payment_started.payment.kind hosted. A 0.00 mandate-only setup uses operation mandate_setup and held/mandate_policy_unresolved until the integration decision settles eligibility and currency. It pays no invoice and clears no dunning or lock. An invoice charged back is never retried automatically. 404 not_found when no account exists. Same key with changed input is a typed operation_key_reused conflict."
|
|
6664
6750
|
},
|
|
6665
6751
|
{
|
|
6666
6752
|
"method": "POST",
|
|
@@ -6747,7 +6833,7 @@
|
|
|
6747
6833
|
"method": "POST",
|
|
6748
6834
|
"path": "/api/billing/invoices/:id/pay",
|
|
6749
6835
|
"section": "billing",
|
|
6750
|
-
"summary": "
|
|
6836
|
+
"summary": "Records an owner-confirmed payment intent for an open invoice or due charge.",
|
|
6751
6837
|
"audience": "developer",
|
|
6752
6838
|
"auth": "developer",
|
|
6753
6839
|
"rateLimited": true,
|
|
@@ -6760,9 +6846,10 @@
|
|
|
6760
6846
|
}
|
|
6761
6847
|
],
|
|
6762
6848
|
"query": null,
|
|
6763
|
-
"request":
|
|
6849
|
+
"request": "invoice-pay-request",
|
|
6764
6850
|
"response": "checkout-response",
|
|
6765
6851
|
"errors": [
|
|
6852
|
+
"validation_error",
|
|
6766
6853
|
"unauthorized",
|
|
6767
6854
|
"token_expired",
|
|
6768
6855
|
"token_revoked",
|
|
@@ -6774,7 +6861,7 @@
|
|
|
6774
6861
|
"payment_provider_unavailable"
|
|
6775
6862
|
],
|
|
6776
6863
|
"transport": "http",
|
|
6777
|
-
"notes": "
|
|
6864
|
+
"notes": "The required operation_key binds the org, invoice and request; reuse with changed input is 409 target_state_conflict (purchaseConflictDetails). :id may be an issued invoice or a due charge with no number. Recheck current buyer eligibility, VIES, invoice status, owed amount and original currency before every new provider call. Invalid VAT is state invalid_vat_id with rule vat_id_invalid, without a payment. Pending/eligible/held has no redirect; after VIES recovers, the owner must confirm the current quote. An issued USD invoice remains held/legacy_usd_invoice: never convert it or call the provider anew until the integration decision resolves the conflict. Already-created payments retain recorded currency/amount and are looked up/reconciled, never replaced. Under the org lock, confirmation checks the current owed amount and returns the same payment identity on retries. invoice_not_open is a typed conflict; 404 not_found for unknown/foreign invoice. Pending itself never pays an invoice, lifts a lock or resets dunning."
|
|
6778
6865
|
},
|
|
6779
6866
|
{
|
|
6780
6867
|
"method": "POST",
|
|
@@ -42,30 +42,16 @@
|
|
|
42
42
|
"maximum": 9007199254740991,
|
|
43
43
|
"description": "Per month in euro cents, excluding VAT."
|
|
44
44
|
},
|
|
45
|
-
"usd_month": {
|
|
46
|
-
"type": "integer",
|
|
47
|
-
"minimum": 0,
|
|
48
|
-
"maximum": 9007199254740991,
|
|
49
|
-
"description": "Per month in US dollar cents, excluding VAT: the euro price × 1.15, rounded up to a whole dollar."
|
|
50
|
-
},
|
|
51
45
|
"eur_year": {
|
|
52
46
|
"type": "integer",
|
|
53
47
|
"minimum": 0,
|
|
54
48
|
"maximum": 9007199254740991,
|
|
55
49
|
"description": "Per year in euro cents, excluding VAT: twelve months less 15 %."
|
|
56
|
-
},
|
|
57
|
-
"usd_year": {
|
|
58
|
-
"type": "integer",
|
|
59
|
-
"minimum": 0,
|
|
60
|
-
"maximum": 9007199254740991,
|
|
61
|
-
"description": "Per year in US dollar cents, excluding VAT: the yearly euro price × 1.15, rounded up to a whole dollar."
|
|
62
50
|
}
|
|
63
51
|
},
|
|
64
52
|
"required": [
|
|
65
53
|
"eur_month",
|
|
66
|
-
"
|
|
67
|
-
"eur_year",
|
|
68
|
-
"usd_year"
|
|
54
|
+
"eur_year"
|
|
69
55
|
],
|
|
70
56
|
"additionalProperties": false,
|
|
71
57
|
"description": "The price of one unit."
|
|
@@ -35,7 +35,13 @@
|
|
|
35
35
|
"country": {
|
|
36
36
|
"type": "string",
|
|
37
37
|
"pattern": "^[A-Z]{2}$",
|
|
38
|
-
"description": "The billing country
|
|
38
|
+
"description": "The billing country, used for purchase eligibility and VAT."
|
|
39
|
+
},
|
|
40
|
+
"state": {
|
|
41
|
+
"description": "State or region. A new US purchase requires a two-letter state code; historical addresses may omit it.",
|
|
42
|
+
"type": "string",
|
|
43
|
+
"minLength": 1,
|
|
44
|
+
"maxLength": 100
|
|
39
45
|
}
|
|
40
46
|
},
|
|
41
47
|
"required": [
|
|
@@ -2,6 +2,12 @@
|
|
|
2
2
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
3
|
"type": "object",
|
|
4
4
|
"properties": {
|
|
5
|
+
"operation_key": {
|
|
6
|
+
"type": "string",
|
|
7
|
+
"format": "uuid",
|
|
8
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
|
|
9
|
+
"description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
|
|
10
|
+
},
|
|
5
11
|
"plan": {
|
|
6
12
|
"description": "The target plan. Omitted leaves the plan as it is.",
|
|
7
13
|
"type": "string",
|
|
@@ -56,5 +62,8 @@
|
|
|
56
62
|
"additionalProperties": false
|
|
57
63
|
}
|
|
58
64
|
},
|
|
65
|
+
"required": [
|
|
66
|
+
"operation_key"
|
|
67
|
+
],
|
|
59
68
|
"additionalProperties": false
|
|
60
69
|
}
|