@zinn-digital/sdk 0.1.2116 → 0.1.2117
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 +95 -0
- package/package.json +1 -1
|
@@ -36768,6 +36768,26 @@ export interface paths {
|
|
|
36768
36768
|
patch?: never;
|
|
36769
36769
|
trace?: never;
|
|
36770
36770
|
};
|
|
36771
|
+
"/v1/email-marketing/cold/sequences/{sequence_id}/steps/ai-draft": {
|
|
36772
|
+
parameters: {
|
|
36773
|
+
query?: never;
|
|
36774
|
+
header?: never;
|
|
36775
|
+
path?: never;
|
|
36776
|
+
cookie?: never;
|
|
36777
|
+
};
|
|
36778
|
+
get?: never;
|
|
36779
|
+
put?: never;
|
|
36780
|
+
/**
|
|
36781
|
+
* Write one cold sequence step (1-5 variants) from a short brief with Zinn® AI.
|
|
36782
|
+
* @description Gated on `email_marketing.manage`. One model call during the request, billed exactly like the Campaigns writer ("Writing campaign emails" on the AI spend page): the organisation's own provider key, its credit balance or its included AI allowance. Returns 1-5 plain-text variants (A-E), each a subject and a body, in the requested language, using the organisation's brand kit. A follow-up step (`follow_up: true`) may leave the subject empty so it replies in the same thread. Nothing is saved: the step editor fills empty fields and asks before replacing text the customer typed. Refused with `402` while the account is on hold or there is no AI allowance left, and `422` with a `failure` object (provider outage, a problem with the customer's own key, or ours) when the model call fails. Nothing is charged for a failed call.
|
|
36783
|
+
*/
|
|
36784
|
+
post: operations["draftEmailMarketingColdSequenceStepWithAi"];
|
|
36785
|
+
delete?: never;
|
|
36786
|
+
options?: never;
|
|
36787
|
+
head?: never;
|
|
36788
|
+
patch?: never;
|
|
36789
|
+
trace?: never;
|
|
36790
|
+
};
|
|
36771
36791
|
"/v1/email-marketing/contacts": {
|
|
36772
36792
|
parameters: {
|
|
36773
36793
|
query?: never;
|
|
@@ -90744,6 +90764,38 @@ export interface components {
|
|
|
90744
90764
|
variants: components["schemas"]["EmailMarketingColdVariant"][];
|
|
90745
90765
|
wait_days?: number;
|
|
90746
90766
|
};
|
|
90767
|
+
EmailMarketingColdStepAiDraft: {
|
|
90768
|
+
model: string;
|
|
90769
|
+
variants: {
|
|
90770
|
+
/** @description Plain text; merge fields such as {{first_name}} are kept. */
|
|
90771
|
+
body: string;
|
|
90772
|
+
/** @enum {string} */
|
|
90773
|
+
label: "A" | "B" | "C" | "D" | "E";
|
|
90774
|
+
/** @description Empty on a follow-up that replies in the same thread. */
|
|
90775
|
+
subject: string;
|
|
90776
|
+
}[];
|
|
90777
|
+
};
|
|
90778
|
+
EmailMarketingColdStepAiDraftRequest: {
|
|
90779
|
+
/** @description What the step should say */
|
|
90780
|
+
brief: string;
|
|
90781
|
+
/**
|
|
90782
|
+
* @description A later step that replies in the same thread (the subject may be empty).
|
|
90783
|
+
* @default false
|
|
90784
|
+
*/
|
|
90785
|
+
follow_up: boolean;
|
|
90786
|
+
/** @description The language to write in (a BCP 47 tag); defaults to en. */
|
|
90787
|
+
locale?: string;
|
|
90788
|
+
/**
|
|
90789
|
+
* @default friendly
|
|
90790
|
+
* @enum {string}
|
|
90791
|
+
*/
|
|
90792
|
+
tone: "friendly" | "professional" | "playful" | "urgent" | "calm";
|
|
90793
|
+
/**
|
|
90794
|
+
* @description How many variants (A-E) to write.
|
|
90795
|
+
* @default 2
|
|
90796
|
+
*/
|
|
90797
|
+
variants: number;
|
|
90798
|
+
};
|
|
90747
90799
|
EmailMarketingColdSteps: {
|
|
90748
90800
|
steps: components["schemas"]["EmailMarketingColdStep"][];
|
|
90749
90801
|
};
|
|
@@ -188112,6 +188164,49 @@ export interface operations {
|
|
|
188112
188164
|
409: components["responses"]["Conflict"];
|
|
188113
188165
|
};
|
|
188114
188166
|
};
|
|
188167
|
+
draftEmailMarketingColdSequenceStepWithAi: {
|
|
188168
|
+
parameters: {
|
|
188169
|
+
query?: {
|
|
188170
|
+
/** @description The organization this call acts on. Optional for a caller with exactly one direct membership; **required** for anyone with more than one — which is every reseller and every agency — because the engine refuses rather than guesses (a wrong guess here writes one tenant's gateway credentials under another tenant's Vault path). */
|
|
188171
|
+
org_id?: components["parameters"]["OrgIdQuery"];
|
|
188172
|
+
};
|
|
188173
|
+
header?: never;
|
|
188174
|
+
path: {
|
|
188175
|
+
sequence_id: string;
|
|
188176
|
+
};
|
|
188177
|
+
cookie?: never;
|
|
188178
|
+
};
|
|
188179
|
+
requestBody: {
|
|
188180
|
+
content: {
|
|
188181
|
+
"application/json": components["schemas"]["EmailMarketingColdStepAiDraftRequest"];
|
|
188182
|
+
};
|
|
188183
|
+
};
|
|
188184
|
+
responses: {
|
|
188185
|
+
/** @description The drafted variants. */
|
|
188186
|
+
200: {
|
|
188187
|
+
headers: {
|
|
188188
|
+
[name: string]: unknown;
|
|
188189
|
+
};
|
|
188190
|
+
content: {
|
|
188191
|
+
"application/json": components["schemas"]["EmailMarketingColdStepAiDraft"];
|
|
188192
|
+
};
|
|
188193
|
+
};
|
|
188194
|
+
401: components["responses"]["Unauthorized"];
|
|
188195
|
+
/** @description The account is on hold, or there is no AI allowance left to pay for the call. */
|
|
188196
|
+
402: {
|
|
188197
|
+
headers: {
|
|
188198
|
+
[name: string]: unknown;
|
|
188199
|
+
};
|
|
188200
|
+
content: {
|
|
188201
|
+
"application/json": components["schemas"]["Error"];
|
|
188202
|
+
};
|
|
188203
|
+
};
|
|
188204
|
+
403: components["responses"]["Forbidden"];
|
|
188205
|
+
404: components["responses"]["NotFound"];
|
|
188206
|
+
409: components["responses"]["Conflict"];
|
|
188207
|
+
422: components["responses"]["UnprocessableEntity"];
|
|
188208
|
+
};
|
|
188209
|
+
};
|
|
188115
188210
|
listEmailMarketingContacts: {
|
|
188116
188211
|
parameters: {
|
|
188117
188212
|
query?: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zinn-digital/sdk",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2117",
|
|
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>",
|