@zinn-digital/sdk 0.1.1404 → 0.1.1406

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.
@@ -15972,6 +15972,54 @@ export interface paths {
15972
15972
  patch: operations["updateAdsAutopilotDecisions"];
15973
15973
  trace?: never;
15974
15974
  };
15975
+ "/v1/ads/brief": {
15976
+ parameters: {
15977
+ query?: never;
15978
+ header?: never;
15979
+ path?: never;
15980
+ cookie?: never;
15981
+ };
15982
+ /**
15983
+ * The one brief across every ad network, and the split it drives.
15984
+ * @description Gated on `ads.view`. Read from our own rows (no network call): the objective (`leads` or `revenue`), the monthly budget, the optional target and the test share, and per network its current and proposed monthly ceiling and `why` (`bestReturn`, `offTarget`, `testShare`, `held`, `unreadable`, `otherCurrency`, `noReturn`), plus the versions saved in the last 30 days. The split is the cross-network budget's proposal (docs/1006 §113, §67), measured daily by a Temporal workflow and applied with `applyAdsCrossBudget`.
15985
+ */
15986
+ get: operations["getAdsBrief"];
15987
+ /**
15988
+ * State the objective and the budget once, for every network.
15989
+ * @description Gated on `ads.manage`; audit action `ads.brief_set`. Sets the cross-network monthly ceiling to `budget_minor` and ranks the split by `objective`; the brief it replaces is kept 30 days for `undoAdsBrief`. Measured again now by a Temporal workflow, never in the request; nothing is applied (approve-first unless `mode: auto`). Refusals `refusal.adsconnect.briefBadObjective`, `briefBadBudget`, `briefBadCurrency`, `briefBadTarget`, `briefBadTestShare`, `briefBadMode`.
15990
+ */
15991
+ put: operations["setAdsBrief"];
15992
+ post?: never;
15993
+ /**
15994
+ * Remove the brief (the budget stays, split by conversions per spend).
15995
+ * @description Gated on `ads.manage`; audit action `ads.brief_clear`. Kept as a version, so it can be undone within 30 days.
15996
+ */
15997
+ delete: operations["clearAdsBrief"];
15998
+ options?: never;
15999
+ head?: never;
16000
+ patch?: never;
16001
+ trace?: never;
16002
+ };
16003
+ "/v1/ads/brief/undo": {
16004
+ parameters: {
16005
+ query?: never;
16006
+ header?: never;
16007
+ path?: never;
16008
+ cookie?: never;
16009
+ };
16010
+ get?: never;
16011
+ put?: never;
16012
+ /**
16013
+ * Put back the brief the last save replaced.
16014
+ * @description Gated on `ads.manage`; audit action `ads.brief_undo`. Refused with `refusal.adsconnect.briefNothingToUndo` when no version from the last 30 days is left.
16015
+ */
16016
+ post: operations["undoAdsBrief"];
16017
+ delete?: never;
16018
+ options?: never;
16019
+ head?: never;
16020
+ patch?: never;
16021
+ trace?: never;
16022
+ };
15975
16023
  "/v1/ads/builds": {
15976
16024
  parameters: {
15977
16025
  query?: never;
@@ -62270,6 +62318,64 @@ export interface components {
62270
62318
  /** @description Our absolute-top share on the brand keywords below this (with rank loss) means someone is placed above us. */
62271
62319
  top_floor_pct: number;
62272
62320
  };
62321
+ AdsBrief: {
62322
+ /** @enum {string} */
62323
+ blocked: "" | "noReturnYet";
62324
+ brief: {
62325
+ /** @description Integer minor units (§2.8). */
62326
+ budget_minor: number | null;
62327
+ currency: string;
62328
+ /** @enum {string} */
62329
+ mode: "suggest" | "auto";
62330
+ /** @enum {string} */
62331
+ objective: "leads" | "revenue";
62332
+ target: number | null;
62333
+ test_share_pct: number;
62334
+ } | null;
62335
+ can_undo_brief: boolean;
62336
+ keep_days: number;
62337
+ last_apply: {
62338
+ at: string | null;
62339
+ by: string | null;
62340
+ can_undo: boolean;
62341
+ moves: components["schemas"]["AdsCrossBudgetMove"][];
62342
+ undone_at: string | null;
62343
+ } | null;
62344
+ /** Format: date-time */
62345
+ measured_at: string | null;
62346
+ moves: components["schemas"]["AdsCrossBudgetMove"][];
62347
+ /** Format: uuid */
62348
+ org_id: string;
62349
+ split: {
62350
+ /** Format: uuid */
62351
+ connection_id: string;
62352
+ conversions_milli: number;
62353
+ cost_minor: number;
62354
+ current_minor: number | null;
62355
+ label: string;
62356
+ platform: string;
62357
+ proposed_minor: number | null;
62358
+ value_minor: number;
62359
+ why: components["schemas"]["AdsBriefWhy"];
62360
+ }[];
62361
+ test_share_max: number;
62362
+ test_share_min: number;
62363
+ test_share_recommended: number;
62364
+ versions: {
62365
+ /** Format: date-time */
62366
+ at: string;
62367
+ brief: {
62368
+ [key: string]: unknown;
62369
+ };
62370
+ by: string;
62371
+ /** Format: uuid */
62372
+ id: string;
62373
+ /** Format: date-time */
62374
+ undone_at: string | null;
62375
+ }[];
62376
+ };
62377
+ /** @enum {string} */
62378
+ AdsBriefWhy: "bestReturn" | "offTarget" | "testShare" | "held" | "unreadable" | "otherCurrency" | "noReturn";
62273
62379
  /** @description The customer's own budget for one campaign (za-84, docs/1006 §84). */
62274
62380
  AdsBudgetDecision: {
62275
62381
  /** Format: int64 */
@@ -63181,6 +63287,10 @@ export interface components {
63181
63287
  targets: {
63182
63288
  [key: string]: number;
63183
63289
  };
63290
+ /** @description za-208 — per connection id, why it gets what it gets (absent on a proposal made before the brief existed). */
63291
+ why?: {
63292
+ [key: string]: components["schemas"]["AdsBriefWhy"];
63293
+ };
63184
63294
  };
63185
63295
  };
63186
63296
  AdsCrossBudgetMove: {
@@ -106599,6 +106709,14 @@ export interface components {
106599
106709
  prune_namespace?: components["schemas"]["TranslationNamespacePrune"];
106600
106710
  };
106601
106711
  TranslationSourceBatchResult: {
106712
+ /** @description What became of the items' `repo_translations`, counted like `recordRepoTranslations`. All zero when none were sent. */
106713
+ repo_translations?: {
106714
+ missing: number;
106715
+ recorded: number;
106716
+ refused: number;
106717
+ stale: number;
106718
+ unchanged: number;
106719
+ };
106602
106720
  /** @description One result per submitted item, in the order submitted. */
106603
106721
  results: components["schemas"]["TranslationSourceResult"][];
106604
106722
  /** @description Field names deleted by `prune`, sorted. Empty when `prune` was absent or nothing was stale. Reported rather than assumed: a destructive operation that returns no number is indistinguishable from one that did nothing. */
@@ -106614,6 +106732,10 @@ export interface components {
106614
106732
  */
106615
106733
  is_html: boolean;
106616
106734
  object_ref: components["schemas"]["ObjectRef"];
106735
+ /** @description The repository's committed translations OF THIS `source_text`, locale -> text. Written repo-owned in the same transaction as the registration (the same rules as `recordRepoTranslations`: a text that breaks a pinned term rendering is refused), so no machine translation is bought for those locales; only the locales absent here are machine-translated. Counted in the batch result's `repo_translations`. */
106736
+ repo_translations?: {
106737
+ [key: string]: string;
106738
+ };
106617
106739
  /** @description The locale `source_text` is written in. Defaults to `en`. */
106618
106740
  source_locale?: components["schemas"]["LocaleCode"];
106619
106741
  /** @description The source-locale text to translate. May be empty to clear a field. */
@@ -134995,6 +135117,136 @@ export interface operations {
134995
135117
  429: components["responses"]["TooManyRequests"];
134996
135118
  };
134997
135119
  };
135120
+ getAdsBrief: {
135121
+ parameters: {
135122
+ query?: {
135123
+ org_id?: string;
135124
+ };
135125
+ header?: never;
135126
+ path?: never;
135127
+ cookie?: never;
135128
+ };
135129
+ requestBody?: never;
135130
+ responses: {
135131
+ /** @description The brief and the split it drives. */
135132
+ 200: {
135133
+ headers: {
135134
+ [name: string]: unknown;
135135
+ };
135136
+ content: {
135137
+ "application/json": components["schemas"]["AdsBrief"];
135138
+ };
135139
+ };
135140
+ 401: components["responses"]["Unauthorized"];
135141
+ 403: components["responses"]["Forbidden"];
135142
+ 404: components["responses"]["NotFound"];
135143
+ 422: components["responses"]["UnprocessableEntity"];
135144
+ 429: components["responses"]["TooManyRequests"];
135145
+ };
135146
+ };
135147
+ setAdsBrief: {
135148
+ parameters: {
135149
+ query?: never;
135150
+ header?: never;
135151
+ path?: never;
135152
+ cookie?: never;
135153
+ };
135154
+ requestBody: {
135155
+ content: {
135156
+ "application/json": {
135157
+ /** @description The monthly budget, integer minor units of `currency` (§2.8). */
135158
+ budget_minor: number;
135159
+ /** @description ISO 4217 */
135160
+ currency: string;
135161
+ /** @enum {string} */
135162
+ mode?: "suggest" | "auto";
135163
+ /** @enum {string} */
135164
+ objective: "leads" | "revenue";
135165
+ /** Format: uuid */
135166
+ org_id?: string;
135167
+ /** @description `leads` — a cost per conversion in minor units; `revenue` — a ROAS in %. */
135168
+ target?: number | null;
135169
+ /** @description The share the networks with no measured return test with (recommended 10). */
135170
+ test_share_pct?: number;
135171
+ };
135172
+ };
135173
+ };
135174
+ responses: {
135175
+ /** @description The brief and the split it drives. */
135176
+ 200: {
135177
+ headers: {
135178
+ [name: string]: unknown;
135179
+ };
135180
+ content: {
135181
+ "application/json": components["schemas"]["AdsBrief"];
135182
+ };
135183
+ };
135184
+ 401: components["responses"]["Unauthorized"];
135185
+ 403: components["responses"]["Forbidden"];
135186
+ 404: components["responses"]["NotFound"];
135187
+ 422: components["responses"]["UnprocessableEntity"];
135188
+ 429: components["responses"]["TooManyRequests"];
135189
+ };
135190
+ };
135191
+ clearAdsBrief: {
135192
+ parameters: {
135193
+ query?: {
135194
+ org_id?: string;
135195
+ };
135196
+ header?: never;
135197
+ path?: never;
135198
+ cookie?: never;
135199
+ };
135200
+ requestBody?: never;
135201
+ responses: {
135202
+ /** @description The brief and the split it drives. */
135203
+ 200: {
135204
+ headers: {
135205
+ [name: string]: unknown;
135206
+ };
135207
+ content: {
135208
+ "application/json": components["schemas"]["AdsBrief"];
135209
+ };
135210
+ };
135211
+ 401: components["responses"]["Unauthorized"];
135212
+ 403: components["responses"]["Forbidden"];
135213
+ 404: components["responses"]["NotFound"];
135214
+ 422: components["responses"]["UnprocessableEntity"];
135215
+ 429: components["responses"]["TooManyRequests"];
135216
+ };
135217
+ };
135218
+ undoAdsBrief: {
135219
+ parameters: {
135220
+ query?: never;
135221
+ header?: never;
135222
+ path?: never;
135223
+ cookie?: never;
135224
+ };
135225
+ requestBody?: {
135226
+ content: {
135227
+ "application/json": {
135228
+ /** Format: uuid */
135229
+ org_id?: string;
135230
+ };
135231
+ };
135232
+ };
135233
+ responses: {
135234
+ /** @description The brief and the split it drives. */
135235
+ 200: {
135236
+ headers: {
135237
+ [name: string]: unknown;
135238
+ };
135239
+ content: {
135240
+ "application/json": components["schemas"]["AdsBrief"];
135241
+ };
135242
+ };
135243
+ 401: components["responses"]["Unauthorized"];
135244
+ 403: components["responses"]["Forbidden"];
135245
+ 404: components["responses"]["NotFound"];
135246
+ 422: components["responses"]["UnprocessableEntity"];
135247
+ 429: components["responses"]["TooManyRequests"];
135248
+ };
135249
+ };
134998
135250
  listAdsBuilds: {
134999
135251
  parameters: {
135000
135252
  query?: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zinn-digital/sdk",
3
- "version": "0.1.1404",
3
+ "version": "0.1.1406",
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>",