@zinn-digital/sdk 0.1.1435 → 0.1.1437
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 +302 -0
- package/package.json +1 -1
|
@@ -14055,6 +14055,52 @@ export interface paths {
|
|
|
14055
14055
|
patch?: never;
|
|
14056
14056
|
trace?: never;
|
|
14057
14057
|
};
|
|
14058
|
+
"/v1/admin/sites/{siteId}/origin-key": {
|
|
14059
|
+
parameters: {
|
|
14060
|
+
query?: never;
|
|
14061
|
+
header?: never;
|
|
14062
|
+
path: {
|
|
14063
|
+
/** @description Site ID (UUIDv7). */
|
|
14064
|
+
siteId: components["parameters"]["SiteId"];
|
|
14065
|
+
};
|
|
14066
|
+
cookie?: never;
|
|
14067
|
+
};
|
|
14068
|
+
/**
|
|
14069
|
+
* Staff view of a site's origin-lock key rotation.
|
|
14070
|
+
* @description **Staff only** (`sites.restart`), any tenant. The same shape as `getSiteOriginKey`, including `last_error` when the last rotation failed.
|
|
14071
|
+
*/
|
|
14072
|
+
get: operations["adminGetSiteOriginKey"];
|
|
14073
|
+
put?: never;
|
|
14074
|
+
post?: never;
|
|
14075
|
+
delete?: never;
|
|
14076
|
+
options?: never;
|
|
14077
|
+
head?: never;
|
|
14078
|
+
patch?: never;
|
|
14079
|
+
trace?: never;
|
|
14080
|
+
};
|
|
14081
|
+
"/v1/admin/sites/{siteId}/origin-key/rotate": {
|
|
14082
|
+
parameters: {
|
|
14083
|
+
query?: never;
|
|
14084
|
+
header?: never;
|
|
14085
|
+
path: {
|
|
14086
|
+
/** @description Site ID (UUIDv7). */
|
|
14087
|
+
siteId: components["parameters"]["SiteId"];
|
|
14088
|
+
};
|
|
14089
|
+
cookie?: never;
|
|
14090
|
+
};
|
|
14091
|
+
get?: never;
|
|
14092
|
+
put?: never;
|
|
14093
|
+
/**
|
|
14094
|
+
* Staff rotation of a site's origin-lock key, with a stated reason.
|
|
14095
|
+
* @description **Staff only** (`sites.restart`), audit-logged with the stated `reason`. Exactly the customer's `rotateSiteOriginKey` otherwise: one site, a grace overlap, no downtime. `409` while a rotation is already running.
|
|
14096
|
+
*/
|
|
14097
|
+
post: operations["adminRotateSiteOriginKey"];
|
|
14098
|
+
delete?: never;
|
|
14099
|
+
options?: never;
|
|
14100
|
+
head?: never;
|
|
14101
|
+
patch?: never;
|
|
14102
|
+
trace?: never;
|
|
14103
|
+
};
|
|
14058
14104
|
"/v1/admin/sites/{siteId}/performance": {
|
|
14059
14105
|
parameters: {
|
|
14060
14106
|
query?: never;
|
|
@@ -41232,6 +41278,28 @@ export interface paths {
|
|
|
41232
41278
|
patch?: never;
|
|
41233
41279
|
trace?: never;
|
|
41234
41280
|
};
|
|
41281
|
+
"/v1/public/ads-tag/{public_key}/signals": {
|
|
41282
|
+
parameters: {
|
|
41283
|
+
query?: never;
|
|
41284
|
+
header?: never;
|
|
41285
|
+
path: {
|
|
41286
|
+
public_key: string;
|
|
41287
|
+
};
|
|
41288
|
+
cookie?: never;
|
|
41289
|
+
};
|
|
41290
|
+
get?: never;
|
|
41291
|
+
put?: never;
|
|
41292
|
+
/**
|
|
41293
|
+
* The universal tag's click-shield beacon (public, rate-limited, per-site key).
|
|
41294
|
+
* @description Public (SHIELDTAG, docs/1006.d/features/za-316-shieldtag.md): the universal script sends it with `navigator.sendBeacon` as `text/plain` JSON (no CORS preflight), so the click-fraud shield works on ANY website, not only sites Zinn® hosts. `k` is `landing` (a paid-click visit; `q` holds ONLY the recognised click ids — gclid, msclkid, fbclid, ttclid, li_fat_id, twclid, epik), `engaged` (the visitor scrolled, tapped or typed), `page` (a later page view, only after ad consent) or `conversion` (`zinnAds.conversion` ran). The visitor address and user agent are the REQUEST's (our ingress's trusted client address), never the body's; the host is the tag's own site; the time is the engine's. The `Origin` must be the tag's site or a subdomain of it. A follow-up is kept only when the same address landed from a paid click inside the 10-minute dwell window. Landings are scored by the same shield as hosted sites every 5 minutes once the dwell window closed (same weights, verdicts, IP exclusions and claim packs), only while the organisation has the shield and is in good standing; a site already scored as a hosted site or by the Zinn® Ads WordPress plugin is not scored twice. Beacons are deleted after 3 days. Always `204` for a well-formed beacon, stored or not (no oracle).
|
|
41295
|
+
*/
|
|
41296
|
+
post: operations["sendAdsSiteTagSignal"];
|
|
41297
|
+
delete?: never;
|
|
41298
|
+
options?: never;
|
|
41299
|
+
head?: never;
|
|
41300
|
+
patch?: never;
|
|
41301
|
+
trace?: never;
|
|
41302
|
+
};
|
|
41235
41303
|
"/v1/public/ads-wordpress/claim": {
|
|
41236
41304
|
parameters: {
|
|
41237
41305
|
query?: never;
|
|
@@ -50294,6 +50362,56 @@ export interface paths {
|
|
|
50294
50362
|
patch?: never;
|
|
50295
50363
|
trace?: never;
|
|
50296
50364
|
};
|
|
50365
|
+
"/v1/sites/{siteId}/origin-key": {
|
|
50366
|
+
parameters: {
|
|
50367
|
+
query?: never;
|
|
50368
|
+
header?: never;
|
|
50369
|
+
path: {
|
|
50370
|
+
/** @description Site ID (UUIDv7). */
|
|
50371
|
+
siteId: components["parameters"]["SiteId"];
|
|
50372
|
+
};
|
|
50373
|
+
cookie?: never;
|
|
50374
|
+
};
|
|
50375
|
+
/**
|
|
50376
|
+
* Where a site's origin-lock key rotation is.
|
|
50377
|
+
* @description The key's `generation` (0 = the key the site was created with), whether a rotation is running (`state` `staged` or `overlap`), when the last one finished and, during the grace overlap, when the old key stops being accepted. Never the key itself.
|
|
50378
|
+
*
|
|
50379
|
+
* `404` for a site that is not the caller's or is not on one of our servers. Requires `sites.view`.
|
|
50380
|
+
*/
|
|
50381
|
+
get: operations["getSiteOriginKey"];
|
|
50382
|
+
put?: never;
|
|
50383
|
+
post?: never;
|
|
50384
|
+
delete?: never;
|
|
50385
|
+
options?: never;
|
|
50386
|
+
head?: never;
|
|
50387
|
+
patch?: never;
|
|
50388
|
+
trace?: never;
|
|
50389
|
+
};
|
|
50390
|
+
"/v1/sites/{siteId}/origin-key/rotate": {
|
|
50391
|
+
parameters: {
|
|
50392
|
+
query?: never;
|
|
50393
|
+
header?: never;
|
|
50394
|
+
path: {
|
|
50395
|
+
/** @description Site ID (UUIDv7). */
|
|
50396
|
+
siteId: components["parameters"]["SiteId"];
|
|
50397
|
+
};
|
|
50398
|
+
cookie?: never;
|
|
50399
|
+
};
|
|
50400
|
+
get?: never;
|
|
50401
|
+
put?: never;
|
|
50402
|
+
/**
|
|
50403
|
+
* Rotate a site's origin-lock key, with no downtime.
|
|
50404
|
+
* @description Replaces this ONE site's origin-lock key; no other site's key changes. Runs as a background job: the server is taught the new key alongside the old one and proven to accept it, the platform switches to the new key, and after a 15-minute grace window the old key is removed and proven refused. The site keeps serving throughout. Audit-logged.
|
|
50405
|
+
*
|
|
50406
|
+
* Answers `202` with `state: staged`. `409` while a rotation is already running. `404` for a site that is not the caller's or is not on one of our servers. Requires `sites.view` and `sites.panel_access`.
|
|
50407
|
+
*/
|
|
50408
|
+
post: operations["rotateSiteOriginKey"];
|
|
50409
|
+
delete?: never;
|
|
50410
|
+
options?: never;
|
|
50411
|
+
head?: never;
|
|
50412
|
+
patch?: never;
|
|
50413
|
+
trace?: never;
|
|
50414
|
+
};
|
|
50297
50415
|
"/v1/sites/{siteId}/origin-load": {
|
|
50298
50416
|
parameters: {
|
|
50299
50417
|
query?: never;
|
|
@@ -67028,6 +67146,13 @@ export interface components {
|
|
|
67028
67146
|
meta_pixel_id?: string;
|
|
67029
67147
|
microsoft_uet_id?: string;
|
|
67030
67148
|
};
|
|
67149
|
+
/** @description What the click shield has seen through this tag (SHIELDTAG, docs/1006.d/features/za-316-shieldtag.md): when the last paid-click landing beacon arrived and the clicks scored from it in 30 days. Set on the list and the single read; the tag protects a site we do not host as soon as it is installed and the organisation has the shield. */
|
|
67150
|
+
shield?: {
|
|
67151
|
+
clicks_30d: number;
|
|
67152
|
+
/** Format: date-time */
|
|
67153
|
+
last_landing_at: string | null;
|
|
67154
|
+
suspected_30d: number;
|
|
67155
|
+
};
|
|
67031
67156
|
site_host: string;
|
|
67032
67157
|
/** Format: date-time */
|
|
67033
67158
|
updated_at: string | null;
|
|
@@ -101901,6 +102026,32 @@ export interface components {
|
|
|
101901
102026
|
*/
|
|
101902
102027
|
verified_at: string | null;
|
|
101903
102028
|
};
|
|
102029
|
+
/** @description Where one site's origin-lock key rotation is (docs/1211). Never carries the key. */
|
|
102030
|
+
SiteOriginKey: {
|
|
102031
|
+
/** @description How many rotations have finished. 0 is the key the site was created with. */
|
|
102032
|
+
generation: number;
|
|
102033
|
+
/** @description Why the last rotation failed, or empty. */
|
|
102034
|
+
last_error: string;
|
|
102035
|
+
/**
|
|
102036
|
+
* Format: date-time
|
|
102037
|
+
* @description During `overlap`, when the old key stops being accepted.
|
|
102038
|
+
*/
|
|
102039
|
+
previous_valid_until: string | null;
|
|
102040
|
+
/**
|
|
102041
|
+
* Format: date-time
|
|
102042
|
+
* @description When the platform last switched to a new key.
|
|
102043
|
+
*/
|
|
102044
|
+
rotated_at: string | null;
|
|
102045
|
+
/** @description True while `state` is `staged` or `overlap`. */
|
|
102046
|
+
rotating: boolean;
|
|
102047
|
+
/** Format: uuid */
|
|
102048
|
+
site_id: string;
|
|
102049
|
+
/**
|
|
102050
|
+
* @description `staged` - the server is learning the new key; `overlap` - the platform sends the new key and the old one is still accepted until `previous_valid_until`; `failed` - the last rotation stopped (see `last_error`) and the site is on its current key.
|
|
102051
|
+
* @enum {string}
|
|
102052
|
+
*/
|
|
102053
|
+
state: "idle" | "staged" | "overlap" | "failed";
|
|
102054
|
+
};
|
|
101904
102055
|
SiteOriginLoad: components["schemas"]["OriginLoadState"] & {
|
|
101905
102056
|
blind: boolean;
|
|
101906
102057
|
/** Format: date-time */
|
|
@@ -133882,6 +134033,66 @@ export interface operations {
|
|
|
133882
134033
|
503: components["responses"]["ServiceUnavailable"];
|
|
133883
134034
|
};
|
|
133884
134035
|
};
|
|
134036
|
+
adminGetSiteOriginKey: {
|
|
134037
|
+
parameters: {
|
|
134038
|
+
query?: never;
|
|
134039
|
+
header?: never;
|
|
134040
|
+
path: {
|
|
134041
|
+
/** @description Site ID (UUIDv7). */
|
|
134042
|
+
siteId: components["parameters"]["SiteId"];
|
|
134043
|
+
};
|
|
134044
|
+
cookie?: never;
|
|
134045
|
+
};
|
|
134046
|
+
requestBody?: never;
|
|
134047
|
+
responses: {
|
|
134048
|
+
/** @description The site's origin-lock key state. */
|
|
134049
|
+
200: {
|
|
134050
|
+
headers: {
|
|
134051
|
+
[name: string]: unknown;
|
|
134052
|
+
};
|
|
134053
|
+
content: {
|
|
134054
|
+
"application/json": components["schemas"]["SiteOriginKey"];
|
|
134055
|
+
};
|
|
134056
|
+
};
|
|
134057
|
+
401: components["responses"]["Unauthorized"];
|
|
134058
|
+
403: components["responses"]["Forbidden"];
|
|
134059
|
+
404: components["responses"]["NotFound"];
|
|
134060
|
+
429: components["responses"]["TooManyRequests"];
|
|
134061
|
+
};
|
|
134062
|
+
};
|
|
134063
|
+
adminRotateSiteOriginKey: {
|
|
134064
|
+
parameters: {
|
|
134065
|
+
query?: never;
|
|
134066
|
+
header?: never;
|
|
134067
|
+
path: {
|
|
134068
|
+
/** @description Site ID (UUIDv7). */
|
|
134069
|
+
siteId: components["parameters"]["SiteId"];
|
|
134070
|
+
};
|
|
134071
|
+
cookie?: never;
|
|
134072
|
+
};
|
|
134073
|
+
requestBody: {
|
|
134074
|
+
content: {
|
|
134075
|
+
"application/json": components["schemas"]["StaffRecoveryReason"];
|
|
134076
|
+
};
|
|
134077
|
+
};
|
|
134078
|
+
responses: {
|
|
134079
|
+
/** @description Rotation started. */
|
|
134080
|
+
202: {
|
|
134081
|
+
headers: {
|
|
134082
|
+
[name: string]: unknown;
|
|
134083
|
+
};
|
|
134084
|
+
content: {
|
|
134085
|
+
"application/json": components["schemas"]["SiteOriginKey"];
|
|
134086
|
+
};
|
|
134087
|
+
};
|
|
134088
|
+
401: components["responses"]["Unauthorized"];
|
|
134089
|
+
403: components["responses"]["Forbidden"];
|
|
134090
|
+
404: components["responses"]["NotFound"];
|
|
134091
|
+
409: components["responses"]["Conflict"];
|
|
134092
|
+
422: components["responses"]["UnprocessableEntity"];
|
|
134093
|
+
429: components["responses"]["TooManyRequests"];
|
|
134094
|
+
};
|
|
134095
|
+
};
|
|
133885
134096
|
getAdminSitePerformance: {
|
|
133886
134097
|
parameters: {
|
|
133887
134098
|
query?: never;
|
|
@@ -179682,6 +179893,40 @@ export interface operations {
|
|
|
179682
179893
|
};
|
|
179683
179894
|
};
|
|
179684
179895
|
};
|
|
179896
|
+
sendAdsSiteTagSignal: {
|
|
179897
|
+
parameters: {
|
|
179898
|
+
query?: never;
|
|
179899
|
+
header?: never;
|
|
179900
|
+
path: {
|
|
179901
|
+
public_key: string;
|
|
179902
|
+
};
|
|
179903
|
+
cookie?: never;
|
|
179904
|
+
};
|
|
179905
|
+
requestBody: {
|
|
179906
|
+
content: {
|
|
179907
|
+
"text/plain": string;
|
|
179908
|
+
};
|
|
179909
|
+
};
|
|
179910
|
+
responses: {
|
|
179911
|
+
/** @description Received (stored, or ignored on purpose). */
|
|
179912
|
+
204: {
|
|
179913
|
+
headers: {
|
|
179914
|
+
/** @description * */
|
|
179915
|
+
"Access-Control-Allow-Origin"?: string;
|
|
179916
|
+
[name: string]: unknown;
|
|
179917
|
+
};
|
|
179918
|
+
content?: never;
|
|
179919
|
+
};
|
|
179920
|
+
/** @description Not a beacon (bad JSON, unknown kind, a landing without a click id, too large). */
|
|
179921
|
+
400: {
|
|
179922
|
+
headers: {
|
|
179923
|
+
[name: string]: unknown;
|
|
179924
|
+
};
|
|
179925
|
+
content?: never;
|
|
179926
|
+
};
|
|
179927
|
+
429: components["responses"]["TooManyRequests"];
|
|
179928
|
+
};
|
|
179929
|
+
};
|
|
179685
179930
|
claimAdsWordPressSite: {
|
|
179686
179931
|
parameters: {
|
|
179687
179932
|
query?: never;
|
|
@@ -194121,6 +194366,63 @@ export interface operations {
|
|
|
194121
194366
|
503: components["responses"]["ServiceUnavailable"];
|
|
194122
194367
|
};
|
|
194123
194368
|
};
|
|
194369
|
+
getSiteOriginKey: {
|
|
194370
|
+
parameters: {
|
|
194371
|
+
query?: never;
|
|
194372
|
+
header?: never;
|
|
194373
|
+
path: {
|
|
194374
|
+
/** @description Site ID (UUIDv7). */
|
|
194375
|
+
siteId: components["parameters"]["SiteId"];
|
|
194376
|
+
};
|
|
194377
|
+
cookie?: never;
|
|
194378
|
+
};
|
|
194379
|
+
requestBody?: never;
|
|
194380
|
+
responses: {
|
|
194381
|
+
/** @description The site's origin-lock key state. */
|
|
194382
|
+
200: {
|
|
194383
|
+
headers: {
|
|
194384
|
+
"RateLimit-Remaining": components["headers"]["RateLimitRemaining"];
|
|
194385
|
+
[name: string]: unknown;
|
|
194386
|
+
};
|
|
194387
|
+
content: {
|
|
194388
|
+
"application/json": components["schemas"]["SiteOriginKey"];
|
|
194389
|
+
};
|
|
194390
|
+
};
|
|
194391
|
+
401: components["responses"]["Unauthorized"];
|
|
194392
|
+
403: components["responses"]["Forbidden"];
|
|
194393
|
+
404: components["responses"]["NotFound"];
|
|
194394
|
+
429: components["responses"]["TooManyRequests"];
|
|
194395
|
+
};
|
|
194396
|
+
};
|
|
194397
|
+
rotateSiteOriginKey: {
|
|
194398
|
+
parameters: {
|
|
194399
|
+
query?: never;
|
|
194400
|
+
header?: never;
|
|
194401
|
+
path: {
|
|
194402
|
+
/** @description Site ID (UUIDv7). */
|
|
194403
|
+
siteId: components["parameters"]["SiteId"];
|
|
194404
|
+
};
|
|
194405
|
+
cookie?: never;
|
|
194406
|
+
};
|
|
194407
|
+
requestBody?: never;
|
|
194408
|
+
responses: {
|
|
194409
|
+
/** @description Rotation started. */
|
|
194410
|
+
202: {
|
|
194411
|
+
headers: {
|
|
194412
|
+
"RateLimit-Remaining": components["headers"]["RateLimitRemaining"];
|
|
194413
|
+
[name: string]: unknown;
|
|
194414
|
+
};
|
|
194415
|
+
content: {
|
|
194416
|
+
"application/json": components["schemas"]["SiteOriginKey"];
|
|
194417
|
+
};
|
|
194418
|
+
};
|
|
194419
|
+
401: components["responses"]["Unauthorized"];
|
|
194420
|
+
403: components["responses"]["Forbidden"];
|
|
194421
|
+
404: components["responses"]["NotFound"];
|
|
194422
|
+
409: components["responses"]["Conflict"];
|
|
194423
|
+
429: components["responses"]["TooManyRequests"];
|
|
194424
|
+
};
|
|
194425
|
+
};
|
|
194124
194426
|
getSiteOriginLoad: {
|
|
194125
194427
|
parameters: {
|
|
194126
194428
|
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.1437",
|
|
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>",
|