@zinn-digital/sdk 0.1.1520 → 0.1.1522
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 +221 -2
- package/package.json +1 -1
|
@@ -53306,7 +53306,7 @@ export interface paths {
|
|
|
53306
53306
|
get: operations["getSiteLoginCheck"];
|
|
53307
53307
|
/**
|
|
53308
53308
|
* Switch the Turnstile login check on or off for a site.
|
|
53309
|
-
* @description Answers `202`: the request is saved and the change runs as a background job (it creates or deletes the site's widget and writes the site, which takes seconds). Poll the `GET` while `busy`. `409` while an earlier change is still running, or when the site cannot carry the check. Audit-logged. Requires `sites.view` and `sites.panel_access`.
|
|
53309
|
+
* @description Answers `202`: the request is saved and the change runs as a background job (it creates or deletes the site's widget and writes the site, which takes seconds). Poll the `GET` while `busy`. `places` chooses the forms the check protects (V1's `forms`; `all_places` on the `GET` lists them). `409` while an earlier change is still running, or when the site cannot carry the check. Audit-logged. Requires `sites.view` and `sites.panel_access`.
|
|
53310
53310
|
*/
|
|
53311
53311
|
put: operations["updateSiteLoginCheck"];
|
|
53312
53312
|
post?: never;
|
|
@@ -53316,6 +53316,56 @@ export interface paths {
|
|
|
53316
53316
|
patch?: never;
|
|
53317
53317
|
trace?: never;
|
|
53318
53318
|
};
|
|
53319
|
+
"/v1/sites/{siteId}/turnstile/keys": {
|
|
53320
|
+
parameters: {
|
|
53321
|
+
query?: never;
|
|
53322
|
+
header?: never;
|
|
53323
|
+
path: {
|
|
53324
|
+
/** @description Site ID (UUIDv7). */
|
|
53325
|
+
siteId: components["parameters"]["SiteId"];
|
|
53326
|
+
};
|
|
53327
|
+
cookie?: never;
|
|
53328
|
+
};
|
|
53329
|
+
get?: never;
|
|
53330
|
+
/**
|
|
53331
|
+
* Use your own Cloudflare Turnstile keys for a site's login check.
|
|
53332
|
+
* @description Owner 1105#26. Paste the sitekey and secret of a Turnstile widget in YOUR Cloudflare account (its hostnames must include the site's domain). The secret is checked with one Cloudflare siteverify call, kept in Vault and never returned. `422` for keys that are malformed, Cloudflare's test keys, or a secret Cloudflare rejects. When the check is on, the site is switched to your keys by the background job (`202`; poll the `GET`) and the platform widget is deleted; when it is off, the keys are saved for when it is switched on (`200`). `409` while a change is running or for a site that cannot carry the check. Audit-logged. Requires `sites.view` and `sites.panel_access`.
|
|
53333
|
+
*/
|
|
53334
|
+
put: operations["setSiteLoginCheckOwnKeys"];
|
|
53335
|
+
post?: never;
|
|
53336
|
+
/**
|
|
53337
|
+
* Stop using your own Turnstile keys; go back to the platform widget.
|
|
53338
|
+
* @description Forgets your keys. When the check is on, the background job creates a platform widget and writes it to the site (`202`), and your secret is deleted from Vault once it is replaced; otherwise `200`. `409` while a change is running. Audit-logged. Requires `sites.view` and `sites.panel_access`.
|
|
53339
|
+
*/
|
|
53340
|
+
delete: operations["removeSiteLoginCheckOwnKeys"];
|
|
53341
|
+
options?: never;
|
|
53342
|
+
head?: never;
|
|
53343
|
+
patch?: never;
|
|
53344
|
+
trace?: never;
|
|
53345
|
+
};
|
|
53346
|
+
"/v1/sites/{siteId}/turnstile/rotate": {
|
|
53347
|
+
parameters: {
|
|
53348
|
+
query?: never;
|
|
53349
|
+
header?: never;
|
|
53350
|
+
path: {
|
|
53351
|
+
/** @description Site ID (UUIDv7). */
|
|
53352
|
+
siteId: components["parameters"]["SiteId"];
|
|
53353
|
+
};
|
|
53354
|
+
cookie?: never;
|
|
53355
|
+
};
|
|
53356
|
+
get?: never;
|
|
53357
|
+
put?: never;
|
|
53358
|
+
/**
|
|
53359
|
+
* Give a site's platform Turnstile widget a new secret key.
|
|
53360
|
+
* @description V1's `turnstile_rotate`. The background job asks Cloudflare for a new secret (the old one stays valid for two hours, so a visitor mid-login is not refused), writes it to the site and reads it back (`202`; poll the `GET`). `409` for a site on your own keys (rotate those in your Cloudflare account), with no widget yet, or while a change is running. Audit-logged. Requires `sites.view` and `sites.panel_access`.
|
|
53361
|
+
*/
|
|
53362
|
+
post: operations["rotateSiteLoginCheckSecret"];
|
|
53363
|
+
delete?: never;
|
|
53364
|
+
options?: never;
|
|
53365
|
+
head?: never;
|
|
53366
|
+
patch?: never;
|
|
53367
|
+
trace?: never;
|
|
53368
|
+
};
|
|
53319
53369
|
"/v1/sites/{siteId}/upgrade-to-php": {
|
|
53320
53370
|
parameters: {
|
|
53321
53371
|
query?: never;
|
|
@@ -90142,6 +90192,28 @@ export interface components {
|
|
|
90142
90192
|
/** @description Where to pull from, and how to sign in. ⛔⛔ **These are live credentials for a third party's production server.** They are written straight to the platform's secret store, referenced from the job by a Vault path, deleted when the job ends, and are never returned by any endpoint, never written to an audit record and never quoted in an error. The job row keeps the **hostname only**. */
|
|
90143
90193
|
MigrationCredentials: {
|
|
90144
90194
|
api_token?: string;
|
|
90195
|
+
/**
|
|
90196
|
+
* @description Optional. The source database server as the site itself reaches it (usually `localhost`). Used with the other `database_*` fields.
|
|
90197
|
+
* @default
|
|
90198
|
+
*/
|
|
90199
|
+
database_host: string;
|
|
90200
|
+
/**
|
|
90201
|
+
* @description Optional. The site's database. With several sites under one `ssh` login it also tells the driver which folder is this site's.
|
|
90202
|
+
* @default
|
|
90203
|
+
*/
|
|
90204
|
+
database_name: string;
|
|
90205
|
+
/** @default */
|
|
90206
|
+
database_password: string;
|
|
90207
|
+
/**
|
|
90208
|
+
* @description Optional. `0` means the database server's default port.
|
|
90209
|
+
* @default 0
|
|
90210
|
+
*/
|
|
90211
|
+
database_port: number;
|
|
90212
|
+
/**
|
|
90213
|
+
* @description Optional. The source site's own database login. An `ssh` source otherwise uses the account's `~/.my.cnf` or the site's `wp-config.php`; a login sent here wins over both. Stored in the secret store with the rest, never returned.
|
|
90214
|
+
* @default
|
|
90215
|
+
*/
|
|
90216
|
+
database_username: string;
|
|
90145
90217
|
/** @description The server's public hostname, e.g. `server123.yourhost.com`. Must resolve to a public address — a private or link-local target is refused with `source_host_not_public` at the door as well as in the adapter. */
|
|
90146
90218
|
host: string;
|
|
90147
90219
|
/**
|
|
@@ -103694,14 +103766,31 @@ export interface components {
|
|
|
103694
103766
|
site: string;
|
|
103695
103767
|
};
|
|
103696
103768
|
SiteLoginCheck: {
|
|
103769
|
+
/** @description Every form the check can protect (the picker's choices). */
|
|
103770
|
+
all_places: string[];
|
|
103697
103771
|
available: boolean;
|
|
103698
103772
|
busy: boolean;
|
|
103773
|
+
/** @description `true` for a platform widget that exists (POST /rotate). */
|
|
103774
|
+
can_rotate: boolean;
|
|
103699
103775
|
/** @description What was last asked for. */
|
|
103700
103776
|
enabled: boolean;
|
|
103701
103777
|
/** @enum {string} */
|
|
103702
|
-
error_code: "" | "readonly" | "no_widget" | "not_supported" | "failed";
|
|
103778
|
+
error_code: "" | "readonly" | "no_widget" | "not_supported" | "own_keys_missing" | "failed";
|
|
103779
|
+
/**
|
|
103780
|
+
* @description `platform`: a widget we create. `own`: the customer's own keys (PUT /keys).
|
|
103781
|
+
* @enum {string}
|
|
103782
|
+
*/
|
|
103783
|
+
key_source: "platform" | "own";
|
|
103784
|
+
/** @description The customer's own PUBLIC sitekey, when set. The secret is never returned. */
|
|
103785
|
+
own_sitekey: string | null;
|
|
103786
|
+
/** @description The forms the check protects. */
|
|
103787
|
+
places: ("login" | "register" | "lostpassword" | "comments" | "cf7" | "wpforms" | "elementor" | "everest" | "fluent" | "formidable" | "forminator" | "happyforms" | "kadence" | "mc4wp" | "metform" | "ninja" | "otter" | "spectra")[];
|
|
103703
103788
|
/** Format: date-time */
|
|
103704
103789
|
requested_at: string | null;
|
|
103790
|
+
/** Format: date-time */
|
|
103791
|
+
rotated_at: string | null;
|
|
103792
|
+
/** @description The PUBLIC sitekey the site uses now. Never the secret. */
|
|
103793
|
+
sitekey: string | null;
|
|
103705
103794
|
stale: boolean;
|
|
103706
103795
|
/** @enum {string} */
|
|
103707
103796
|
status: "off" | "pending" | "active" | "failed";
|
|
@@ -103710,8 +103799,16 @@ export interface components {
|
|
|
103710
103799
|
/** Format: date-time */
|
|
103711
103800
|
verified_at: string | null;
|
|
103712
103801
|
};
|
|
103802
|
+
SiteLoginCheckKeys: {
|
|
103803
|
+
/** @description Your widget's secret key. Checked with Cloudflare, kept in Vault, never returned. */
|
|
103804
|
+
secret: string;
|
|
103805
|
+
/** @description Your widget's sitekey (0x…). */
|
|
103806
|
+
sitekey: string;
|
|
103807
|
+
};
|
|
103713
103808
|
SiteLoginCheckUpdate: {
|
|
103714
103809
|
enabled: boolean;
|
|
103810
|
+
/** @description Which forms to protect (V1's `forms`). Omitted keeps the current choice. */
|
|
103811
|
+
places?: ("login" | "register" | "lostpassword" | "comments" | "cf7" | "wpforms" | "elementor" | "everest" | "fluent" | "formidable" | "forminator" | "happyforms" | "kadence" | "mc4wp" | "metform" | "ninja" | "otter" | "spectra")[];
|
|
103715
103812
|
};
|
|
103716
103813
|
/** @description The site's CloudLinux LVE resource tier — `docs/204` §7b. ⭐ `ep` is the limit that emits `508 Resource Limit Is Reached`, which is why this is on a customer screen at all: it converts "your server is broken" into "you hit your plan's limit, here is the upgrade". */
|
|
103717
103814
|
SiteLveState: {
|
|
@@ -107016,6 +107113,11 @@ export interface components {
|
|
|
107016
107113
|
changed_by?: string;
|
|
107017
107114
|
/** @description What was last asked for. */
|
|
107018
107115
|
enabled?: boolean;
|
|
107116
|
+
/**
|
|
107117
|
+
* @description `own`: the customer's own Turnstile widget keys (1105#26); `sitekey` is theirs and `cf_account_id` empty.
|
|
107118
|
+
* @enum {string}
|
|
107119
|
+
*/
|
|
107120
|
+
key_source?: "platform" | "own";
|
|
107019
107121
|
last_error: string;
|
|
107020
107122
|
places: string[];
|
|
107021
107123
|
/** @description `check` only: what the site answered. */
|
|
@@ -107025,6 +107127,11 @@ export interface components {
|
|
|
107025
107127
|
};
|
|
107026
107128
|
/** Format: date-time */
|
|
107027
107129
|
requested_at?: string | null;
|
|
107130
|
+
/**
|
|
107131
|
+
* Format: date-time
|
|
107132
|
+
* @description When the platform widget's secret was last rotated.
|
|
107133
|
+
*/
|
|
107134
|
+
rotated_at?: string | null;
|
|
107028
107135
|
/** @description PUBLIC (it is in the page HTML). */
|
|
107029
107136
|
sitekey: string;
|
|
107030
107137
|
stale?: boolean;
|
|
@@ -201879,6 +201986,118 @@ export interface operations {
|
|
|
201879
201986
|
429: components["responses"]["TooManyRequests"];
|
|
201880
201987
|
};
|
|
201881
201988
|
};
|
|
201989
|
+
setSiteLoginCheckOwnKeys: {
|
|
201990
|
+
parameters: {
|
|
201991
|
+
query?: never;
|
|
201992
|
+
header?: never;
|
|
201993
|
+
path: {
|
|
201994
|
+
/** @description Site ID (UUIDv7). */
|
|
201995
|
+
siteId: components["parameters"]["SiteId"];
|
|
201996
|
+
};
|
|
201997
|
+
cookie?: never;
|
|
201998
|
+
};
|
|
201999
|
+
requestBody: {
|
|
202000
|
+
content: {
|
|
202001
|
+
"application/json": components["schemas"]["SiteLoginCheckKeys"];
|
|
202002
|
+
};
|
|
202003
|
+
};
|
|
202004
|
+
responses: {
|
|
202005
|
+
/** @description Saved; the check is off, so nothing ran. */
|
|
202006
|
+
200: {
|
|
202007
|
+
headers: {
|
|
202008
|
+
"RateLimit-Remaining": components["headers"]["RateLimitRemaining"];
|
|
202009
|
+
[name: string]: unknown;
|
|
202010
|
+
};
|
|
202011
|
+
content: {
|
|
202012
|
+
"application/json": components["schemas"]["SiteLoginCheck"];
|
|
202013
|
+
};
|
|
202014
|
+
};
|
|
202015
|
+
/** @description Saved; the site is being switched to your keys. */
|
|
202016
|
+
202: {
|
|
202017
|
+
headers: {
|
|
202018
|
+
"RateLimit-Remaining": components["headers"]["RateLimitRemaining"];
|
|
202019
|
+
[name: string]: unknown;
|
|
202020
|
+
};
|
|
202021
|
+
content: {
|
|
202022
|
+
"application/json": components["schemas"]["SiteLoginCheck"];
|
|
202023
|
+
};
|
|
202024
|
+
};
|
|
202025
|
+
401: components["responses"]["Unauthorized"];
|
|
202026
|
+
403: components["responses"]["Forbidden"];
|
|
202027
|
+
404: components["responses"]["NotFound"];
|
|
202028
|
+
409: components["responses"]["Conflict"];
|
|
202029
|
+
422: components["responses"]["UnprocessableEntity"];
|
|
202030
|
+
429: components["responses"]["TooManyRequests"];
|
|
202031
|
+
};
|
|
202032
|
+
};
|
|
202033
|
+
removeSiteLoginCheckOwnKeys: {
|
|
202034
|
+
parameters: {
|
|
202035
|
+
query?: never;
|
|
202036
|
+
header?: never;
|
|
202037
|
+
path: {
|
|
202038
|
+
/** @description Site ID (UUIDv7). */
|
|
202039
|
+
siteId: components["parameters"]["SiteId"];
|
|
202040
|
+
};
|
|
202041
|
+
cookie?: never;
|
|
202042
|
+
};
|
|
202043
|
+
requestBody?: never;
|
|
202044
|
+
responses: {
|
|
202045
|
+
/** @description Done; the check is off. */
|
|
202046
|
+
200: {
|
|
202047
|
+
headers: {
|
|
202048
|
+
"RateLimit-Remaining": components["headers"]["RateLimitRemaining"];
|
|
202049
|
+
[name: string]: unknown;
|
|
202050
|
+
};
|
|
202051
|
+
content: {
|
|
202052
|
+
"application/json": components["schemas"]["SiteLoginCheck"];
|
|
202053
|
+
};
|
|
202054
|
+
};
|
|
202055
|
+
/** @description The site is being switched to the platform widget. */
|
|
202056
|
+
202: {
|
|
202057
|
+
headers: {
|
|
202058
|
+
"RateLimit-Remaining": components["headers"]["RateLimitRemaining"];
|
|
202059
|
+
[name: string]: unknown;
|
|
202060
|
+
};
|
|
202061
|
+
content: {
|
|
202062
|
+
"application/json": components["schemas"]["SiteLoginCheck"];
|
|
202063
|
+
};
|
|
202064
|
+
};
|
|
202065
|
+
401: components["responses"]["Unauthorized"];
|
|
202066
|
+
403: components["responses"]["Forbidden"];
|
|
202067
|
+
404: components["responses"]["NotFound"];
|
|
202068
|
+
409: components["responses"]["Conflict"];
|
|
202069
|
+
429: components["responses"]["TooManyRequests"];
|
|
202070
|
+
};
|
|
202071
|
+
};
|
|
202072
|
+
rotateSiteLoginCheckSecret: {
|
|
202073
|
+
parameters: {
|
|
202074
|
+
query?: never;
|
|
202075
|
+
header?: never;
|
|
202076
|
+
path: {
|
|
202077
|
+
/** @description Site ID (UUIDv7). */
|
|
202078
|
+
siteId: components["parameters"]["SiteId"];
|
|
202079
|
+
};
|
|
202080
|
+
cookie?: never;
|
|
202081
|
+
};
|
|
202082
|
+
requestBody?: never;
|
|
202083
|
+
responses: {
|
|
202084
|
+
/** @description The secret is being replaced. */
|
|
202085
|
+
202: {
|
|
202086
|
+
headers: {
|
|
202087
|
+
"RateLimit-Remaining": components["headers"]["RateLimitRemaining"];
|
|
202088
|
+
[name: string]: unknown;
|
|
202089
|
+
};
|
|
202090
|
+
content: {
|
|
202091
|
+
"application/json": components["schemas"]["SiteLoginCheck"];
|
|
202092
|
+
};
|
|
202093
|
+
};
|
|
202094
|
+
401: components["responses"]["Unauthorized"];
|
|
202095
|
+
403: components["responses"]["Forbidden"];
|
|
202096
|
+
404: components["responses"]["NotFound"];
|
|
202097
|
+
409: components["responses"]["Conflict"];
|
|
202098
|
+
429: components["responses"]["TooManyRequests"];
|
|
202099
|
+
};
|
|
202100
|
+
};
|
|
201882
202101
|
upgradeSiteToPhp: {
|
|
201883
202102
|
parameters: {
|
|
201884
202103
|
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.1522",
|
|
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>",
|