@zinn-digital/sdk 0.1.1827 → 0.1.1830

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.
@@ -11819,7 +11819,7 @@ export interface paths {
11819
11819
  query?: never;
11820
11820
  header?: never;
11821
11821
  path: {
11822
- action: "repair" | "dismiss" | "undo";
11822
+ action: "repair" | "dismiss" | "undo" | "restore_backup";
11823
11823
  findingId: string;
11824
11824
  };
11825
11825
  cookie?: never;
@@ -11827,8 +11827,8 @@ export interface paths {
11827
11827
  get?: never;
11828
11828
  put?: never;
11829
11829
  /**
11830
- * Repair a site integrity finding now (202), dismiss it, or undo its deep clean (202; staff, audit-logged).
11831
- * @description `undo` puts back the files and database backup the finding's deep clean took (`detail.deep_clean.backup_dir`); a finding without one answers 409.
11830
+ * Repair a site integrity finding now (202), dismiss it, undo its deep clean or restore its pre-repair backup (202; staff, audit-logged).
11831
+ * @description `undo` puts back the files and database backup the finding's deep clean took (`detail.deep_clean.backup_dir`); a finding without one answers 409. `restore_backup` puts back the backup taken before the finding's automatic repair (`detail.pre_repair_backup.backup_dir`: the core files, or the database); the live copy it replaces is kept beside the backup, and the outcome is recorded as `detail.pre_repair_restore`. A finding without one answers 409 (`refusal.pluginGuard.noPreRepairBackup`).
11832
11832
  */
11833
11833
  post: operations["actOnSiteIntegrityFinding"];
11834
11834
  delete?: never;
@@ -18400,6 +18400,122 @@ export interface paths {
18400
18400
  patch?: never;
18401
18401
  trace?: never;
18402
18402
  };
18403
+ "/v1/ads/connections/{connection_id}/amazon/campaigns": {
18404
+ parameters: {
18405
+ query?: never;
18406
+ header?: never;
18407
+ path: {
18408
+ connection_id: string;
18409
+ };
18410
+ cookie?: never;
18411
+ };
18412
+ /**
18413
+ * An Amazon Ads profile's Sponsored Products campaigns with their daily budgets (AMZBIDS).
18414
+ * @description Gated on `ads.view`. Read from Amazon now (`POST /sp/campaigns/list`, every page): each enabled or paused Sponsored Products campaign with its state and its daily budget (micros of the profile currency; `null` when the campaign's budget is not a daily one). `step_pct` is the most one change may move a budget or a bid. Refusals (`422`): `amazonOnly`, `amazonReadFailed` (carries `error.failure`, §2.57: `provider_outage` with Amazon Ads' status board, `our_fault` for our own 4xx), `needsReconnect`.
18415
+ */
18416
+ get: operations["listAdsAmazonCampaigns"];
18417
+ put?: never;
18418
+ post?: never;
18419
+ delete?: never;
18420
+ options?: never;
18421
+ head?: never;
18422
+ patch?: never;
18423
+ trace?: never;
18424
+ };
18425
+ "/v1/ads/connections/{connection_id}/amazon/campaigns/{campaign_id}/ad-groups": {
18426
+ parameters: {
18427
+ query?: never;
18428
+ header?: never;
18429
+ path: {
18430
+ campaign_id: string;
18431
+ connection_id: string;
18432
+ };
18433
+ cookie?: never;
18434
+ };
18435
+ /**
18436
+ * One Amazon Ads campaign's ad groups with their default bids and keyword bids (AMZBIDS).
18437
+ * @description Gated on `ads.view`. Read from Amazon now (`/sp/adGroups/list` and `/sp/keywords/list`, every page): each enabled or paused ad group with its default bid, and each keyword in it with its own bid (`null`: the keyword bids its ad group's default). Refusals (`422`): `amazonOnly`, `amazonNoSuchCampaign`, `amazonReadFailed`, `needsReconnect`.
18438
+ */
18439
+ get: operations["listAdsAmazonAdGroups"];
18440
+ put?: never;
18441
+ post?: never;
18442
+ delete?: never;
18443
+ options?: never;
18444
+ head?: never;
18445
+ patch?: never;
18446
+ trace?: never;
18447
+ };
18448
+ "/v1/ads/connections/{connection_id}/amazon/campaigns/{campaign_id}/ad-groups/{ad_group_id}/bid": {
18449
+ parameters: {
18450
+ query?: never;
18451
+ header?: never;
18452
+ path: {
18453
+ ad_group_id: string;
18454
+ campaign_id: string;
18455
+ connection_id: string;
18456
+ };
18457
+ cookie?: never;
18458
+ };
18459
+ get?: never;
18460
+ put?: never;
18461
+ /**
18462
+ * Change an Amazon Ads ad group's default bid — the click is the approval (AMZBIDS).
18463
+ * @description Gated on `ads.manage`; audit action `ads.amazon_bid_set`. Read from Amazon first, proposed as a `bids` change and approved in one step, sent once through the gate with a 30-day Undo that puts the default bid Amazon held back. Refusals (`422`): `amazonOnly`, `amazonBadBid`, `amazonNoSuchCampaign`, `amazonNoSuchAdGroup`, `amazonBidUnchanged`, `amazonStepTooBig`, `amazonBidOverBudget` (a bid above the campaign's daily budget), `amazonWritesOff`, `notInGoodStanding`, `amazonReadFailed`, `needsReconnect`.
18464
+ */
18465
+ post: operations["setAdsAmazonAdGroupBid"];
18466
+ delete?: never;
18467
+ options?: never;
18468
+ head?: never;
18469
+ patch?: never;
18470
+ trace?: never;
18471
+ };
18472
+ "/v1/ads/connections/{connection_id}/amazon/campaigns/{campaign_id}/budget": {
18473
+ parameters: {
18474
+ query?: never;
18475
+ header?: never;
18476
+ path: {
18477
+ campaign_id: string;
18478
+ connection_id: string;
18479
+ };
18480
+ cookie?: never;
18481
+ };
18482
+ get?: never;
18483
+ put?: never;
18484
+ /**
18485
+ * Change an Amazon Ads campaign's daily budget — the click is the approval (AMZBIDS).
18486
+ * @description Gated on `ads.manage`; audit action `ads.amazon_budget_set`. The campaign is read from Amazon first; the change is proposed as a `budgets` change and approved in one step, then sent ONCE by the apply workflow through the same gate as every write (kill switches, good standing, the connection's spend ceilings weighed against the profile's enabled daily budgets — a raise past a ceiling is refused, a cut never is; `ZINN_ADS_AMAZON_WRITES=off` and any house connection refuse `amazonWritesOff`). An unconfirmed send is never re-sent. The 30-day Undo puts the daily budget Amazon held back. Refusals (`422`): `amazonOnly`, `amazonBadBudget` (zero, past the cap, or finer than the currency's smallest unit), `amazonNoSuchCampaign`, `amazonNoDailyBudget`, `amazonBudgetUnchanged`, `amazonStepTooBig` (more than `step_pct` of the current budget either way), `amazonWritesOff`, `notInGoodStanding`, `amazonReadFailed`, `needsReconnect`.
18487
+ */
18488
+ post: operations["setAdsAmazonCampaignBudget"];
18489
+ delete?: never;
18490
+ options?: never;
18491
+ head?: never;
18492
+ patch?: never;
18493
+ trace?: never;
18494
+ };
18495
+ "/v1/ads/connections/{connection_id}/amazon/campaigns/{campaign_id}/keywords/{keyword_id}/bid": {
18496
+ parameters: {
18497
+ query?: never;
18498
+ header?: never;
18499
+ path: {
18500
+ campaign_id: string;
18501
+ connection_id: string;
18502
+ keyword_id: string;
18503
+ };
18504
+ cookie?: never;
18505
+ };
18506
+ get?: never;
18507
+ put?: never;
18508
+ /**
18509
+ * Change an Amazon Ads keyword's bid — the click is the approval (AMZBIDS).
18510
+ * @description Gated on `ads.manage`; audit action `ads.amazon_bid_set`. As `setAdsAmazonAdGroupBid`, for one keyword that has its own bid; a keyword bidding its ad group's default is refused `amazonKeywordNoBid` (the Undo could not take a set bid away again). Also `amazonNoSuchKeyword`.
18511
+ */
18512
+ post: operations["setAdsAmazonKeywordBid"];
18513
+ delete?: never;
18514
+ options?: never;
18515
+ head?: never;
18516
+ patch?: never;
18517
+ trace?: never;
18518
+ };
18403
18519
  "/v1/ads/connections/{connection_id}/audiences": {
18404
18520
  parameters: {
18405
18521
  query?: never;
@@ -68334,6 +68450,40 @@ export interface components {
68334
68450
  connection_id: string;
68335
68451
  data: components["schemas"]["AdsAllowedTerm"][];
68336
68452
  };
68453
+ /** @description One Amazon Ads ad group, its default bid and its keywords (AMZBIDS). */
68454
+ AdsAmazonAdGroup: {
68455
+ /** Format: int64 */
68456
+ default_bid_micros: number;
68457
+ id: string;
68458
+ keywords: components["schemas"]["AdsAmazonKeyword"][];
68459
+ name: string;
68460
+ state: string;
68461
+ };
68462
+ AdsAmazonBidRequest: {
68463
+ /**
68464
+ * Format: int64
68465
+ * @description The new bid in micros of the profile currency (1 unit = 1,000,000).
68466
+ */
68467
+ bid_micros: number;
68468
+ };
68469
+ /** @description One Amazon Ads Sponsored Products campaign and its daily budget (AMZBIDS). Money is micros of the profile currency (§2.8). */
68470
+ AdsAmazonCampaign: {
68471
+ /** Format: int64 */
68472
+ daily_budget_micros: number | null;
68473
+ id: string;
68474
+ name: string;
68475
+ /** @description Amazon's state (ENABLED, PAUSED). */
68476
+ state: string;
68477
+ };
68478
+ /** @description One Amazon Ads keyword and its bid (AMZBIDS); `bid_micros` null = the ad group's default bid. */
68479
+ AdsAmazonKeyword: {
68480
+ /** Format: int64 */
68481
+ bid_micros: number | null;
68482
+ id: string;
68483
+ match_type: string;
68484
+ state: string;
68485
+ text: string;
68486
+ };
68337
68487
  AdsAnalyticsAnomaly: {
68338
68488
  change_pct: number;
68339
68489
  /** Format: date */
@@ -110384,6 +110534,22 @@ export interface components {
110384
110534
  last_seen_at: string;
110385
110535
  /** @description Staff only. */
110386
110536
  org_id?: string;
110537
+ /** @description Staff only. The backup taken on the box BEFORE this finding's automatic repair (`core`: wp-admin, wp-includes and the root PHP files; `db`: the database), and staff's restore of it (`POST .../restore_backup`). Null when no repair took one. */
110538
+ pre_repair_backup?: {
110539
+ /** Format: date-time */
110540
+ at?: string;
110541
+ backup_dir?: string;
110542
+ restore?: {
110543
+ /** Format: date-time */
110544
+ at?: string;
110545
+ error?: string;
110546
+ ok?: boolean;
110547
+ /** @description Where the live copy it replaced was kept. */
110548
+ replaced_kept_at?: string;
110549
+ } | null;
110550
+ /** @enum {string} */
110551
+ scope?: "core" | "db";
110552
+ } | null;
110387
110553
  /** @description Staff's free-text note in English; customer surfaces show repair_reason instead. */
110388
110554
  repair_note?: string;
110389
110555
  /**
@@ -140617,7 +140783,7 @@ export interface operations {
140617
140783
  query?: never;
140618
140784
  header?: never;
140619
140785
  path: {
140620
- action: "repair" | "dismiss" | "undo";
140786
+ action: "repair" | "dismiss" | "undo" | "restore_backup";
140621
140787
  findingId: string;
140622
140788
  };
140623
140789
  cookie?: never;
@@ -151740,6 +151906,178 @@ export interface operations {
151740
151906
  429: components["responses"]["TooManyRequests"];
151741
151907
  };
151742
151908
  };
151909
+ listAdsAmazonCampaigns: {
151910
+ parameters: {
151911
+ query?: never;
151912
+ header?: never;
151913
+ path: {
151914
+ connection_id: string;
151915
+ };
151916
+ cookie?: never;
151917
+ };
151918
+ requestBody?: never;
151919
+ responses: {
151920
+ /** @description The profile's campaigns. */
151921
+ 200: {
151922
+ headers: {
151923
+ [name: string]: unknown;
151924
+ };
151925
+ content: {
151926
+ "application/json": {
151927
+ campaigns: components["schemas"]["AdsAmazonCampaign"][];
151928
+ /** Format: uuid */
151929
+ connection_id: string;
151930
+ /** @description ISO 4217 code of the profile. */
151931
+ currency: string;
151932
+ step_pct: number;
151933
+ };
151934
+ };
151935
+ };
151936
+ 401: components["responses"]["Unauthorized"];
151937
+ 403: components["responses"]["Forbidden"];
151938
+ 404: components["responses"]["NotFound"];
151939
+ 422: components["responses"]["UnprocessableEntity"];
151940
+ 429: components["responses"]["TooManyRequests"];
151941
+ };
151942
+ };
151943
+ listAdsAmazonAdGroups: {
151944
+ parameters: {
151945
+ query?: never;
151946
+ header?: never;
151947
+ path: {
151948
+ campaign_id: string;
151949
+ connection_id: string;
151950
+ };
151951
+ cookie?: never;
151952
+ };
151953
+ requestBody?: never;
151954
+ responses: {
151955
+ /** @description The campaign's ad groups. */
151956
+ 200: {
151957
+ headers: {
151958
+ [name: string]: unknown;
151959
+ };
151960
+ content: {
151961
+ "application/json": {
151962
+ ad_groups: components["schemas"]["AdsAmazonAdGroup"][];
151963
+ campaign_id: string;
151964
+ /** Format: uuid */
151965
+ connection_id: string;
151966
+ step_pct: number;
151967
+ };
151968
+ };
151969
+ };
151970
+ 401: components["responses"]["Unauthorized"];
151971
+ 403: components["responses"]["Forbidden"];
151972
+ 404: components["responses"]["NotFound"];
151973
+ 422: components["responses"]["UnprocessableEntity"];
151974
+ 429: components["responses"]["TooManyRequests"];
151975
+ };
151976
+ };
151977
+ setAdsAmazonAdGroupBid: {
151978
+ parameters: {
151979
+ query?: never;
151980
+ header?: never;
151981
+ path: {
151982
+ ad_group_id: string;
151983
+ campaign_id: string;
151984
+ connection_id: string;
151985
+ };
151986
+ cookie?: never;
151987
+ };
151988
+ requestBody: {
151989
+ content: {
151990
+ "application/json": components["schemas"]["AdsAmazonBidRequest"];
151991
+ };
151992
+ };
151993
+ responses: {
151994
+ /** @description Approved; the apply workflow sends it. */
151995
+ 202: {
151996
+ headers: {
151997
+ [name: string]: unknown;
151998
+ };
151999
+ content: {
152000
+ "application/json": components["schemas"]["AdsChange"];
152001
+ };
152002
+ };
152003
+ 401: components["responses"]["Unauthorized"];
152004
+ 403: components["responses"]["Forbidden"];
152005
+ 404: components["responses"]["NotFound"];
152006
+ 422: components["responses"]["UnprocessableEntity"];
152007
+ 429: components["responses"]["TooManyRequests"];
152008
+ };
152009
+ };
152010
+ setAdsAmazonCampaignBudget: {
152011
+ parameters: {
152012
+ query?: never;
152013
+ header?: never;
152014
+ path: {
152015
+ campaign_id: string;
152016
+ connection_id: string;
152017
+ };
152018
+ cookie?: never;
152019
+ };
152020
+ requestBody: {
152021
+ content: {
152022
+ "application/json": {
152023
+ /**
152024
+ * Format: int64
152025
+ * @description The new daily budget in micros of the profile currency (1 unit = 1,000,000).
152026
+ */
152027
+ daily_budget_micros: number;
152028
+ };
152029
+ };
152030
+ };
152031
+ responses: {
152032
+ /** @description Approved; the apply workflow sends it. */
152033
+ 202: {
152034
+ headers: {
152035
+ [name: string]: unknown;
152036
+ };
152037
+ content: {
152038
+ "application/json": components["schemas"]["AdsChange"];
152039
+ };
152040
+ };
152041
+ 401: components["responses"]["Unauthorized"];
152042
+ 403: components["responses"]["Forbidden"];
152043
+ 404: components["responses"]["NotFound"];
152044
+ 422: components["responses"]["UnprocessableEntity"];
152045
+ 429: components["responses"]["TooManyRequests"];
152046
+ };
152047
+ };
152048
+ setAdsAmazonKeywordBid: {
152049
+ parameters: {
152050
+ query?: never;
152051
+ header?: never;
152052
+ path: {
152053
+ campaign_id: string;
152054
+ connection_id: string;
152055
+ keyword_id: string;
152056
+ };
152057
+ cookie?: never;
152058
+ };
152059
+ requestBody: {
152060
+ content: {
152061
+ "application/json": components["schemas"]["AdsAmazonBidRequest"];
152062
+ };
152063
+ };
152064
+ responses: {
152065
+ /** @description Approved; the apply workflow sends it. */
152066
+ 202: {
152067
+ headers: {
152068
+ [name: string]: unknown;
152069
+ };
152070
+ content: {
152071
+ "application/json": components["schemas"]["AdsChange"];
152072
+ };
152073
+ };
152074
+ 401: components["responses"]["Unauthorized"];
152075
+ 403: components["responses"]["Forbidden"];
152076
+ 404: components["responses"]["NotFound"];
152077
+ 422: components["responses"]["UnprocessableEntity"];
152078
+ 429: components["responses"]["TooManyRequests"];
152079
+ };
152080
+ };
151743
152081
  listAdsAudiences: {
151744
152082
  parameters: {
151745
152083
  query?: never;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zinn-digital/sdk",
3
- "version": "0.1.1827",
3
+ "version": "0.1.1830",
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>",