@zinn-digital/sdk 0.1.2047 → 0.1.2051
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/dist/generated/schema.d.ts +100 -0
- package/package.json +1 -1
|
@@ -43142,6 +43142,29 @@ export interface paths {
|
|
|
43142
43142
|
patch?: never;
|
|
43143
43143
|
trace?: never;
|
|
43144
43144
|
};
|
|
43145
|
+
"/v1/orders/{orderId}/paypal-subscription": {
|
|
43146
|
+
parameters: {
|
|
43147
|
+
query?: never;
|
|
43148
|
+
header?: never;
|
|
43149
|
+
path: {
|
|
43150
|
+
/** @description The order's id. */
|
|
43151
|
+
orderId: components["parameters"]["OrderId"];
|
|
43152
|
+
};
|
|
43153
|
+
cookie?: never;
|
|
43154
|
+
};
|
|
43155
|
+
get?: never;
|
|
43156
|
+
put?: never;
|
|
43157
|
+
/**
|
|
43158
|
+
* Pay an order with ONE PayPal approval that also renews its subscriptions.
|
|
43159
|
+
* @description The one-approval checkout (V1 parity). Opens one PayPal subscription agreement for an order with exactly one recurring line: the one-off part of the order is the agreement's setup fee and the recurring part is cycle 1, so the buyer approves once and PayPal collects the whole order at activation and renews the recurring part after. The order is settled by the `BILLING.SUBSCRIPTION.ACTIVATED` webhook (once, however often PayPal redelivers it) and its subscriptions are created on the PayPal rail, so the engine never bills them a second time. Idempotent per order: a reload returns the same approval link. Account credit is not applied on this path, and nothing is charged by this call.
|
|
43160
|
+
*/
|
|
43161
|
+
post: operations["openPayPalOrderSubscription"];
|
|
43162
|
+
delete?: never;
|
|
43163
|
+
options?: never;
|
|
43164
|
+
head?: never;
|
|
43165
|
+
patch?: never;
|
|
43166
|
+
trace?: never;
|
|
43167
|
+
};
|
|
43145
43168
|
"/v1/orders/{orderId}/paypal/capture": {
|
|
43146
43169
|
parameters: {
|
|
43147
43170
|
query?: never;
|
|
@@ -83814,6 +83837,8 @@ export interface components {
|
|
|
83814
83837
|
registry_data?: {
|
|
83815
83838
|
[key: string]: components["schemas"]["RegistryData"];
|
|
83816
83839
|
};
|
|
83840
|
+
/** @description Crypto's "renew automatically" choice (D4b, as V1). On the `nowpayments` rail, `true` or omitted (the checkbox starts ticked) is stored on the crypto payment and turns crypto auto-renew on for each subscription the order creates once it is paid; `false` leaves it off. Ignored on every other rail. ⛔ No schema `default` (a defaulted property becomes REQUIRED in the generated TypeScript). */
|
|
83841
|
+
renew_automatically?: boolean;
|
|
83817
83842
|
/** @description Whether the organisation's **account credit pays first** (row 1106#49). Omitted or `true`: credit is debited before the chosen rail and the rail is charged only the remainder (card and crypto through the charge itself; PayPal opens its order for the remainder and the credit is debited just before capture, given back if the capture fails or the approval is abandoned). Credit that covers the whole total settles the order with no gateway. `false`: the balance is left untouched and the rail is charged the whole total. Either way the order is `paid` only when the whole total is settled, and the payment records the credit part in `wallet_applied_minor`. */
|
|
83818
83843
|
use_credit?: boolean;
|
|
83819
83844
|
};
|
|
@@ -110169,13 +110194,28 @@ export interface components {
|
|
|
110169
110194
|
accepts_deploys: boolean | null;
|
|
110170
110195
|
/** @description False for groups that carry no V2 agent by design (customer_compute, launch, v1). */
|
|
110171
110196
|
agent_expected: boolean;
|
|
110197
|
+
/**
|
|
110198
|
+
* @description The resource that runs out first.
|
|
110199
|
+
* @enum {string|null}
|
|
110200
|
+
*/
|
|
110201
|
+
binding: "disk" | "ram" | "cpu" | null;
|
|
110172
110202
|
/** @description The server's hostname. */
|
|
110173
110203
|
box: string;
|
|
110174
110204
|
cores: number;
|
|
110175
110205
|
cpu_busy_fraction: number | null;
|
|
110206
|
+
/** @description Busy share of all cores at the 7-day 95th percentile; null when it could not be read. */
|
|
110207
|
+
cpu_busy_p95_fraction: number | null;
|
|
110176
110208
|
days_to_full: number | null;
|
|
110177
110209
|
disk_used_fraction: number;
|
|
110178
110210
|
filesystems: components["schemas"]["ServerFilesystem"][];
|
|
110211
|
+
/** @description Sites that fit on CPU alone. */
|
|
110212
|
+
fit_cpu: number | null;
|
|
110213
|
+
/** @description Sites that fit on disk alone. */
|
|
110214
|
+
fit_disk: number | null;
|
|
110215
|
+
/** @description True when the per-site cost was measured on this box; false when the fleet median was used. */
|
|
110216
|
+
fit_measured: boolean;
|
|
110217
|
+
/** @description Sites that fit in RAM alone. */
|
|
110218
|
+
fit_ram: number | null;
|
|
110179
110219
|
/** @enum {string} */
|
|
110180
110220
|
group: "hosting" | "magento" | "mail" | "cluster" | "ci" | "network" | "launch" | "customer_compute" | "v1" | "other";
|
|
110181
110221
|
inode_used_fraction: number;
|
|
@@ -110199,6 +110239,8 @@ export interface components {
|
|
|
110199
110239
|
seconds_since_report: number | null;
|
|
110200
110240
|
site_capacity: number | null;
|
|
110201
110241
|
sites: number | null;
|
|
110242
|
+
/** @description How many more sites fit on real resources: the smallest of disk, RAM and CPU. Null on a box that hosts no sites or has no measurement. */
|
|
110243
|
+
sites_fit: number | null;
|
|
110202
110244
|
/** @description Plan or product from the supplier (`cpx32`, `AX102-3-LTD`); empty when unknown. */
|
|
110203
110245
|
size: string;
|
|
110204
110246
|
/**
|
|
@@ -198031,6 +198073,11 @@ export interface operations {
|
|
|
198031
198073
|
* @example 3f6c1a52-8e0b-4d1e-9b7a-2c5d4e6f7a81
|
|
198032
198074
|
*/
|
|
198033
198075
|
payment_method_id?: string;
|
|
198076
|
+
/**
|
|
198077
|
+
* @description Crypto's "renew automatically" choice (D4b, as V1). When `gateway` is `nowpayments`, `true` or omitted (the checkbox starts ticked) is stored on the crypto payment and, once it settles and fulfilment creates the subscription, crypto auto-renew is turned on for it (a NOWPayments link is e-mailed to the billing address before each renewal; see `setSubscriptionCryptoAutoRenew`). `false` leaves it off. Ignored on every other rail. Anything that is not a JSON boolean counts as omitted.
|
|
198078
|
+
* @example true
|
|
198079
|
+
*/
|
|
198080
|
+
renew_automatically?: boolean;
|
|
198034
198081
|
/**
|
|
198035
198082
|
* @description Whether account credit pays first (BILLPARITY F1, owner 2026-11-22). Omit, or send `true`, for the default: the balance pays first and only the rest reaches `gateway`. Send `false` when the customer's balance covers the order but they chose to pay by card, PayPal or crypto instead: the balance is not drawn and the chosen rail is charged for the whole order. Anything that is not a JSON boolean is `422` with `details[0].field = use_balance`; `false` together with `credit_only: true` is a contradiction and also `422` on `use_balance`. Nothing is drawn or charged on either refusal.
|
|
198036
198083
|
* @example false
|
|
@@ -198211,6 +198258,59 @@ export interface operations {
|
|
|
198211
198258
|
};
|
|
198212
198259
|
};
|
|
198213
198260
|
};
|
|
198261
|
+
openPayPalOrderSubscription: {
|
|
198262
|
+
parameters: {
|
|
198263
|
+
query?: never;
|
|
198264
|
+
header?: never;
|
|
198265
|
+
path: {
|
|
198266
|
+
/** @description The order's id. */
|
|
198267
|
+
orderId: components["parameters"]["OrderId"];
|
|
198268
|
+
};
|
|
198269
|
+
cookie?: never;
|
|
198270
|
+
};
|
|
198271
|
+
requestBody?: never;
|
|
198272
|
+
responses: {
|
|
198273
|
+
/** @description Where to send the buyer to approve. */
|
|
198274
|
+
200: {
|
|
198275
|
+
headers: {
|
|
198276
|
+
[name: string]: unknown;
|
|
198277
|
+
};
|
|
198278
|
+
content: {
|
|
198279
|
+
"application/json": {
|
|
198280
|
+
/**
|
|
198281
|
+
* Format: uri
|
|
198282
|
+
* @description PayPal's approval page for this agreement.
|
|
198283
|
+
*/
|
|
198284
|
+
approve_url: string;
|
|
198285
|
+
/** @description PayPal's agreement id (`I-…`). */
|
|
198286
|
+
paypal_subscription_id: string;
|
|
198287
|
+
};
|
|
198288
|
+
};
|
|
198289
|
+
};
|
|
198290
|
+
401: components["responses"]["Unauthorized"];
|
|
198291
|
+
403: components["responses"]["Forbidden"];
|
|
198292
|
+
404: components["responses"]["NotFound"];
|
|
198293
|
+
/** @description The order is already paid, cannot be paid, has no recurring line, its recurring lines do not share one interval and currency, a recurring line is discounted or a prepaid multi-period term, or it is already bound to another agreement (pay it with `openPayPalOrder`). */
|
|
198294
|
+
422: {
|
|
198295
|
+
headers: {
|
|
198296
|
+
[name: string]: unknown;
|
|
198297
|
+
};
|
|
198298
|
+
content: {
|
|
198299
|
+
"application/json": components["schemas"]["Error"];
|
|
198300
|
+
};
|
|
198301
|
+
};
|
|
198302
|
+
429: components["responses"]["TooManyRequests"];
|
|
198303
|
+
/** @description PayPal is not configured, or an operator has disabled it. */
|
|
198304
|
+
503: {
|
|
198305
|
+
headers: {
|
|
198306
|
+
[name: string]: unknown;
|
|
198307
|
+
};
|
|
198308
|
+
content: {
|
|
198309
|
+
"application/json": components["schemas"]["Error"];
|
|
198310
|
+
};
|
|
198311
|
+
};
|
|
198312
|
+
};
|
|
198313
|
+
};
|
|
198214
198314
|
capturePayPalOrder: {
|
|
198215
198315
|
parameters: {
|
|
198216
198316
|
query?: never;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zinn-digital/sdk",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2051",
|
|
4
4
|
"description": "Typed TypeScript client for the Zinn Digital Platform API, generated from its OpenAPI spec.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Neil Lock \u2014 CEO, Zinn Digital\u00ae Ltd <office@zinndigital.com>",
|