@zinn-digital/sdk 0.1.1407 → 0.1.1410
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 +167 -0
- package/package.json +1 -1
|
@@ -17657,6 +17657,32 @@ export interface paths {
|
|
|
17657
17657
|
patch?: never;
|
|
17658
17658
|
trace?: never;
|
|
17659
17659
|
};
|
|
17660
|
+
"/v1/ads/connections/{connection_id}/copy-winners": {
|
|
17661
|
+
parameters: {
|
|
17662
|
+
query?: never;
|
|
17663
|
+
header?: never;
|
|
17664
|
+
path: {
|
|
17665
|
+
connection_id: string;
|
|
17666
|
+
};
|
|
17667
|
+
cookie?: never;
|
|
17668
|
+
};
|
|
17669
|
+
/**
|
|
17670
|
+
* Copy winners across your own accounts and countries - settings and the last run (za-N5).
|
|
17671
|
+
* @description Gated on `ads.view`. On the caller's own connection. The daily audit (Temporal) finds the responsive search ads that win in a campaign on FIRST-PARTY conversions only (a one-sided two-proportion test against the campaign's other ads at `confidence_pct`, with at least `min_clicks` clicks and `min_conversions` conversions over `lookback_days`) and offers each winner - its ad and keyword set - to the same org's other campaigns, countries and connected accounts on the same website, translated in one batched call where the language differs and checked by the ad-quality gate (docs/1006 §91). Copies are ordinary changes on the TARGET connection (`listAdsChanges`): approve-first in mode `suggest`; approved at once with Undo in mode `auto` when that account's `campaigns` class is Automatic. `pending` counts this account's copies waiting anywhere in the org. Read from stored rows, never a network call in the request.
|
|
17672
|
+
*/
|
|
17673
|
+
get: operations["getAdsCopyWinners"];
|
|
17674
|
+
put?: never;
|
|
17675
|
+
post?: never;
|
|
17676
|
+
delete?: never;
|
|
17677
|
+
options?: never;
|
|
17678
|
+
head?: never;
|
|
17679
|
+
/**
|
|
17680
|
+
* Edit copy winners - switch, mode, thresholds; null puts a threshold back on Recommended (audited).
|
|
17681
|
+
* @description Gated on `ads.manage`. Audit action `ads.copy_winners_update`. `on` is a boolean; `mode` is `suggest` or `auto`; each threshold is a whole number inside its bounds (see `settings.<field>.min/max` in the GET), or `null` for the Recommended value. Any unknown field or invalid value refuses the whole request with `copyWinnersInvalid` (nothing is half-applied).
|
|
17682
|
+
*/
|
|
17683
|
+
patch: operations["updateAdsCopyWinners"];
|
|
17684
|
+
trace?: never;
|
|
17685
|
+
};
|
|
17660
17686
|
"/v1/ads/connections/{connection_id}/crm-sources": {
|
|
17661
17687
|
parameters: {
|
|
17662
17688
|
query?: never;
|
|
@@ -23049,6 +23075,8 @@ export interface paths {
|
|
|
23049
23075
|
* `state.on_byo` is `true` only when a live customer key exists for **every** provider we route to, so credits genuinely cannot be spent. The banner must stay silent in that case: selling credit to somebody whose every call runs on their own key sells them something that will never be spent. It is **not** "this org has a key" — a customer holding one Anthropic key still pays us for Google, OpenAI and xAI.
|
|
23050
23076
|
*
|
|
23051
23077
|
* Amounts are USD **micros** (1 minor unit = 10,000 micros; 1 USD = 1,000,000), because one model call costs a fraction of a cent and rounding each one up to a penny over-bills by two orders of magnitude. `packs[].price_minor` is ordinary integer minor units, because that is what the customer is charged. Requires `sites.view`.
|
|
23078
|
+
*
|
|
23079
|
+
* The AI credits an active plan includes (`inference_credits_monthly`, Zinn® AI Hosting) are granted before the balance is read, once per monthly slot of the subscription's period: one credit is 1,000 micros (USD 0.001) of usage at the price charged, so 5,000 credits are USD 5. Only an `active` subscription of an org in good standing earns a grant. The grant appears in `history` as a `grant` row whose `note` is the token `plan_credit:<credits>`, which the dashboard renders as a translated sentence.
|
|
23052
23080
|
*/
|
|
23053
23081
|
get: operations["getAiCredits"];
|
|
23054
23082
|
put?: never;
|
|
@@ -63144,6 +63172,88 @@ export interface components {
|
|
|
63144
63172
|
uploaded: number;
|
|
63145
63173
|
};
|
|
63146
63174
|
};
|
|
63175
|
+
AdsCopyWinner: {
|
|
63176
|
+
ad_group: string;
|
|
63177
|
+
ad_id: string;
|
|
63178
|
+
/** @description The campaign's other ads, pooled. */
|
|
63179
|
+
baseline_rate: number;
|
|
63180
|
+
campaign?: string;
|
|
63181
|
+
campaign_id: string;
|
|
63182
|
+
clicks: number;
|
|
63183
|
+
/** @description First-party conversions only. */
|
|
63184
|
+
conversions: number;
|
|
63185
|
+
/** @description ISO country codes the source campaign targets. */
|
|
63186
|
+
countries: string[];
|
|
63187
|
+
/** @description The source market's language code. */
|
|
63188
|
+
language: string;
|
|
63189
|
+
p_value: number;
|
|
63190
|
+
rate: number;
|
|
63191
|
+
};
|
|
63192
|
+
AdsCopyWinnerCopy: {
|
|
63193
|
+
ad_group: string;
|
|
63194
|
+
campaign?: string;
|
|
63195
|
+
campaign_id: string;
|
|
63196
|
+
/** Format: uuid */
|
|
63197
|
+
change_id?: string;
|
|
63198
|
+
/**
|
|
63199
|
+
* Format: uuid
|
|
63200
|
+
* @description The target connection (same org).
|
|
63201
|
+
*/
|
|
63202
|
+
connection_id: string;
|
|
63203
|
+
countries?: string[];
|
|
63204
|
+
descriptions?: string[];
|
|
63205
|
+
detail?: string[];
|
|
63206
|
+
headlines?: string[];
|
|
63207
|
+
keywords?: string[];
|
|
63208
|
+
language: string;
|
|
63209
|
+
/** @description Why it waits - noTranslation, tooLong, gateRefused. */
|
|
63210
|
+
reason?: string;
|
|
63211
|
+
source_ad_id: string;
|
|
63212
|
+
/** @enum {string} */
|
|
63213
|
+
status: "proposed" | "approved" | "waiting";
|
|
63214
|
+
};
|
|
63215
|
+
AdsCopyWinnersEnvelope: {
|
|
63216
|
+
data: {
|
|
63217
|
+
last_run: components["schemas"]["AdsCopyWinnersRun"] | null;
|
|
63218
|
+
/** @enum {string} */
|
|
63219
|
+
mode: "suggest" | "auto";
|
|
63220
|
+
on: boolean;
|
|
63221
|
+
/** @description This account's copies waiting for approval, in any of the org's accounts. */
|
|
63222
|
+
pending: number;
|
|
63223
|
+
settings: {
|
|
63224
|
+
confidence_pct: components["schemas"]["AdsCompetitorGroupsThreshold"];
|
|
63225
|
+
lookback_days: components["schemas"]["AdsCompetitorGroupsThreshold"];
|
|
63226
|
+
min_clicks: components["schemas"]["AdsCompetitorGroupsThreshold"];
|
|
63227
|
+
min_conversions: components["schemas"]["AdsCompetitorGroupsThreshold"];
|
|
63228
|
+
};
|
|
63229
|
+
};
|
|
63230
|
+
};
|
|
63231
|
+
AdsCopyWinnersPatch: {
|
|
63232
|
+
confidence_pct?: number | null;
|
|
63233
|
+
lookback_days?: number | null;
|
|
63234
|
+
min_clicks?: number | null;
|
|
63235
|
+
min_conversions?: number | null;
|
|
63236
|
+
/** @enum {string} */
|
|
63237
|
+
mode?: "suggest" | "auto";
|
|
63238
|
+
on?: boolean;
|
|
63239
|
+
};
|
|
63240
|
+
AdsCopyWinnersRun: {
|
|
63241
|
+
/** @description Copies approved at once (mode auto). */
|
|
63242
|
+
applied: number;
|
|
63243
|
+
/** Format: date-time */
|
|
63244
|
+
at: string;
|
|
63245
|
+
copy_list: components["schemas"]["AdsCopyWinnerCopy"][];
|
|
63246
|
+
/** @description Targets that already have the group or a decided copy. */
|
|
63247
|
+
covered: number;
|
|
63248
|
+
/** @description Campaigns skipped because they advertise another website. */
|
|
63249
|
+
other_site: number;
|
|
63250
|
+
proposed: number;
|
|
63251
|
+
/** @description Empty when it ran; else why not (switchedOff, noFirstPartyProof, notInGoodStanding, ...). */
|
|
63252
|
+
skipped: string;
|
|
63253
|
+
waiting: number;
|
|
63254
|
+
winner_list: components["schemas"]["AdsCopyWinner"][];
|
|
63255
|
+
winners: number;
|
|
63256
|
+
};
|
|
63147
63257
|
/** @description COUNTRYCUT — our recommended values, in the connection's currency. */
|
|
63148
63258
|
AdsCountryCutRecommended: {
|
|
63149
63259
|
currency: string;
|
|
@@ -138496,6 +138606,63 @@ export interface operations {
|
|
|
138496
138606
|
429: components["responses"]["TooManyRequests"];
|
|
138497
138607
|
};
|
|
138498
138608
|
};
|
|
138609
|
+
getAdsCopyWinners: {
|
|
138610
|
+
parameters: {
|
|
138611
|
+
query?: never;
|
|
138612
|
+
header?: never;
|
|
138613
|
+
path: {
|
|
138614
|
+
connection_id: string;
|
|
138615
|
+
};
|
|
138616
|
+
cookie?: never;
|
|
138617
|
+
};
|
|
138618
|
+
requestBody?: never;
|
|
138619
|
+
responses: {
|
|
138620
|
+
/** @description The switch, mode, thresholds (each with its Recommended value) and the last run. */
|
|
138621
|
+
200: {
|
|
138622
|
+
headers: {
|
|
138623
|
+
[name: string]: unknown;
|
|
138624
|
+
};
|
|
138625
|
+
content: {
|
|
138626
|
+
"application/json": components["schemas"]["AdsCopyWinnersEnvelope"];
|
|
138627
|
+
};
|
|
138628
|
+
};
|
|
138629
|
+
401: components["responses"]["Unauthorized"];
|
|
138630
|
+
403: components["responses"]["Forbidden"];
|
|
138631
|
+
404: components["responses"]["NotFound"];
|
|
138632
|
+
429: components["responses"]["TooManyRequests"];
|
|
138633
|
+
};
|
|
138634
|
+
};
|
|
138635
|
+
updateAdsCopyWinners: {
|
|
138636
|
+
parameters: {
|
|
138637
|
+
query?: never;
|
|
138638
|
+
header?: never;
|
|
138639
|
+
path: {
|
|
138640
|
+
connection_id: string;
|
|
138641
|
+
};
|
|
138642
|
+
cookie?: never;
|
|
138643
|
+
};
|
|
138644
|
+
requestBody: {
|
|
138645
|
+
content: {
|
|
138646
|
+
"application/json": components["schemas"]["AdsCopyWinnersPatch"];
|
|
138647
|
+
};
|
|
138648
|
+
};
|
|
138649
|
+
responses: {
|
|
138650
|
+
/** @description The settings after the change. */
|
|
138651
|
+
200: {
|
|
138652
|
+
headers: {
|
|
138653
|
+
[name: string]: unknown;
|
|
138654
|
+
};
|
|
138655
|
+
content: {
|
|
138656
|
+
"application/json": components["schemas"]["AdsCopyWinnersEnvelope"];
|
|
138657
|
+
};
|
|
138658
|
+
};
|
|
138659
|
+
401: components["responses"]["Unauthorized"];
|
|
138660
|
+
403: components["responses"]["Forbidden"];
|
|
138661
|
+
404: components["responses"]["NotFound"];
|
|
138662
|
+
422: components["responses"]["UnprocessableEntity"];
|
|
138663
|
+
429: components["responses"]["TooManyRequests"];
|
|
138664
|
+
};
|
|
138665
|
+
};
|
|
138499
138666
|
listAdsCrmSources: {
|
|
138500
138667
|
parameters: {
|
|
138501
138668
|
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.1410",
|
|
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>",
|