@zinn-digital/sdk 0.1.1754 → 0.1.1756

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.
@@ -46718,6 +46718,92 @@ export interface paths {
46718
46718
  patch?: never;
46719
46719
  trace?: never;
46720
46720
  };
46721
+ "/v1/public/signup": {
46722
+ parameters: {
46723
+ query?: never;
46724
+ header?: never;
46725
+ path?: never;
46726
+ cookie?: never;
46727
+ };
46728
+ get?: never;
46729
+ put?: never;
46730
+ /**
46731
+ * Start an in-app sign-up by mailing a confirm link.
46732
+ * @description docs/576 §9. Unauthenticated (no permission: the person has no account yet), so it is throttled per trusted client (`signup_start`, 10/hour) on top of a per-address mail budget (one mail per 60 s, five per hour).
46733
+ *
46734
+ * ⛔ **No enumeration.** The answer is the same `202` whether or not the address already has an account. A known address with a password is mailed "you already have an account, sign in or reset your password"; any other address is mailed our branded link to `/signup/verify?token=…`, valid for 48 hours. No Keycloak user is created until the password is chosen (`completeSignup`).
46735
+ *
46736
+ * A disposable or invalid address is refused with `403 SIGNUP_EMAIL_REFUSED`, the same refusal the Keycloak form path gets at its first sign-in (docs/1174).
46737
+ */
46738
+ post: operations["startSignup"];
46739
+ delete?: never;
46740
+ options?: never;
46741
+ head?: never;
46742
+ patch?: never;
46743
+ trace?: never;
46744
+ };
46745
+ "/v1/public/signup/complete": {
46746
+ parameters: {
46747
+ query?: never;
46748
+ header?: never;
46749
+ path?: never;
46750
+ cookie?: never;
46751
+ };
46752
+ get?: never;
46753
+ put?: never;
46754
+ /**
46755
+ * Choose the password and finish the sign-up.
46756
+ * @description docs/576 §9. Unauthenticated (no permission: the token is the credential), throttled per trusted client (`signup_token`). A valid, unused link is claimed atomically, the account is created with its address already verified, and a single-use sign-in URL (about two minutes) is returned that lands the person in the dashboard.
46757
+ *
46758
+ * `409` with `details[0].code` `EXPIRED`, `USED` or `INVALID` for a link that cannot be used; `409 ACCOUNT_EXISTS` when the address already has a password; `422` with `details[0].field = password` when the password policy refuses it (at least 12 characters, not the username, not the address).
46759
+ */
46760
+ post: operations["completeSignup"];
46761
+ delete?: never;
46762
+ options?: never;
46763
+ head?: never;
46764
+ patch?: never;
46765
+ trace?: never;
46766
+ };
46767
+ "/v1/public/signup/resend": {
46768
+ parameters: {
46769
+ query?: never;
46770
+ header?: never;
46771
+ path?: never;
46772
+ cookie?: never;
46773
+ };
46774
+ get?: never;
46775
+ put?: never;
46776
+ /**
46777
+ * Mail a fresh sign-up link, including from an expired one.
46778
+ * @description docs/576 §9. Unauthenticated (no permission: the token is the credential), throttled per trusted client (`signup_token`) and by the same per-address mail budget as `startSignup`. ⭐ Works for an EXPIRED link: an expired link's page always offers "Send me a new link". A used or unknown token is a `409` whose `details[0].code` is `USED` or `INVALID`.
46779
+ */
46780
+ post: operations["resendSignup"];
46781
+ delete?: never;
46782
+ options?: never;
46783
+ head?: never;
46784
+ patch?: never;
46785
+ trace?: never;
46786
+ };
46787
+ "/v1/public/signup/verify": {
46788
+ parameters: {
46789
+ query?: never;
46790
+ header?: never;
46791
+ path?: never;
46792
+ cookie?: never;
46793
+ };
46794
+ get?: never;
46795
+ put?: never;
46796
+ /**
46797
+ * Read what state a sign-up link is in.
46798
+ * @description docs/576 §9. Unauthenticated (no permission: the token is the credential), throttled per trusted client (`signup_token`, 60/hour). `POST`, not `GET ?token=`, so the token stays out of access logs and referrers. Reading never consumes the link.
46799
+ */
46800
+ post: operations["inspectSignup"];
46801
+ delete?: never;
46802
+ options?: never;
46803
+ head?: never;
46804
+ patch?: never;
46805
+ trace?: never;
46806
+ };
46721
46807
  "/v1/public/site-forms/submit": {
46722
46808
  parameters: {
46723
46809
  query?: never;
@@ -93693,7 +93779,7 @@ export interface components {
93693
93779
  MarketplacePayoutReadiness: {
93694
93780
  permitted: boolean;
93695
93781
  /** @description Every reason at once, not the first — a seller told one problem at a time makes one round trip per problem. */
93696
- reasons: ("no_verification" | "verification_not_approved" | "document_expired" | "document_missing" | "subject_not_approved" | "sanctions_not_screened" | "sanctions_not_clear" | "document_request_holds_payouts" | "vendor_not_approved" | "no_destination" | "destination_cooling_off" | "dac7_data_incomplete")[];
93782
+ reasons: ("no_verification" | "verification_not_approved" | "document_expired" | "document_missing" | "subject_not_approved" | "sanctions_not_screened" | "sanctions_not_clear" | "document_request_holds_payouts" | "vendor_not_approved" | "no_destination" | "destination_cooling_off" | "dac7_data_incomplete" | "identity_unverified")[];
93697
93783
  };
93698
93784
  MarketplacePayoutSchedule: {
93699
93785
  currency: components["schemas"]["CurrencyCode"];
@@ -105923,6 +106009,68 @@ export interface components {
105923
106009
  * @enum {string}
105924
106010
  */
105925
106011
  ShowcaseStatus: "pending" | "approved" | "removed";
106012
+ SignupAccepted: {
106013
+ /** @description How long the page waits before offering "Resend" again. */
106014
+ resend_after_seconds: number;
106015
+ /** @enum {string} */
106016
+ status: "sent";
106017
+ };
106018
+ SignupCompleted: {
106019
+ /**
106020
+ * Format: uri
106021
+ * @description A single-use sign-in link, valid about two minutes.
106022
+ */
106023
+ sign_in_url: string;
106024
+ };
106025
+ SignupCompleteRequest: {
106026
+ /** Format: password */
106027
+ password: string;
106028
+ token: string;
106029
+ };
106030
+ SignupLinkState: {
106031
+ /** @description The address the link was sent to, or empty for an invalid token. */
106032
+ email: string;
106033
+ intent: string;
106034
+ plan: string;
106035
+ /**
106036
+ * @description `valid` shows the password form; `expired` offers a new link; `used` and `exists` offer sign-in; `invalid` offers starting again.
106037
+ * @enum {string}
106038
+ */
106039
+ state: "valid" | "expired" | "used" | "invalid" | "exists";
106040
+ trial: string;
106041
+ };
106042
+ SignupStartRequest: {
106043
+ /** Format: email */
106044
+ email: string;
106045
+ /**
106046
+ * @default register
106047
+ * @enum {string}
106048
+ */
106049
+ intent: "register" | "trial";
106050
+ /**
106051
+ * @description The language the mail is written in and the account is created with.
106052
+ * @default en
106053
+ */
106054
+ locale: string;
106055
+ /**
106056
+ * @description Ticked "do not send me marketing email"; stored on the account.
106057
+ * @default false
106058
+ */
106059
+ marketing_opt_out: boolean;
106060
+ /**
106061
+ * @description The plan the person picked on the public site, carried to the dashboard.
106062
+ * @default
106063
+ */
106064
+ plan: string;
106065
+ /**
106066
+ * @description The trial the person picked on the public site, carried to the dashboard.
106067
+ * @default
106068
+ */
106069
+ trial: string;
106070
+ };
106071
+ SignupTokenRequest: {
106072
+ token: string;
106073
+ };
105926
106074
  Site: {
105927
106075
  /** @description The exact blueprint version the site was built from; null for imports. */
105928
106076
  blueprint_id?: components["schemas"]["Uuid"] | null;
@@ -197924,6 +198072,125 @@ export interface operations {
197924
198072
  429: components["responses"]["TooManyRequests"];
197925
198073
  };
197926
198074
  };
198075
+ startSignup: {
198076
+ parameters: {
198077
+ query?: never;
198078
+ header?: never;
198079
+ path?: never;
198080
+ cookie?: never;
198081
+ };
198082
+ requestBody: {
198083
+ content: {
198084
+ "application/json": components["schemas"]["SignupStartRequest"];
198085
+ };
198086
+ };
198087
+ responses: {
198088
+ /** @description Accepted. A mail is on its way if the address can receive one. */
198089
+ 202: {
198090
+ headers: {
198091
+ [name: string]: unknown;
198092
+ };
198093
+ content: {
198094
+ "application/json": components["schemas"]["SignupAccepted"];
198095
+ };
198096
+ };
198097
+ /** @description The address is refused (`SIGNUP_EMAIL_REFUSED`). */
198098
+ 403: {
198099
+ headers: {
198100
+ [name: string]: unknown;
198101
+ };
198102
+ content: {
198103
+ "application/json": components["schemas"]["Error"];
198104
+ };
198105
+ };
198106
+ 422: components["responses"]["UnprocessableEntity"];
198107
+ 429: components["responses"]["TooManyRequests"];
198108
+ 503: components["responses"]["ServiceUnavailable"];
198109
+ };
198110
+ };
198111
+ completeSignup: {
198112
+ parameters: {
198113
+ query?: never;
198114
+ header?: never;
198115
+ path?: never;
198116
+ cookie?: never;
198117
+ };
198118
+ requestBody: {
198119
+ content: {
198120
+ "application/json": components["schemas"]["SignupCompleteRequest"];
198121
+ };
198122
+ };
198123
+ responses: {
198124
+ /** @description The account exists; follow `sign_in_url`. */
198125
+ 200: {
198126
+ headers: {
198127
+ [name: string]: unknown;
198128
+ };
198129
+ content: {
198130
+ "application/json": components["schemas"]["SignupCompleted"];
198131
+ };
198132
+ };
198133
+ 409: components["responses"]["Conflict"];
198134
+ 422: components["responses"]["UnprocessableEntity"];
198135
+ 429: components["responses"]["TooManyRequests"];
198136
+ 503: components["responses"]["ServiceUnavailable"];
198137
+ };
198138
+ };
198139
+ resendSignup: {
198140
+ parameters: {
198141
+ query?: never;
198142
+ header?: never;
198143
+ path?: never;
198144
+ cookie?: never;
198145
+ };
198146
+ requestBody: {
198147
+ content: {
198148
+ "application/json": components["schemas"]["SignupTokenRequest"];
198149
+ };
198150
+ };
198151
+ responses: {
198152
+ /** @description Accepted. A fresh link is on its way. */
198153
+ 202: {
198154
+ headers: {
198155
+ [name: string]: unknown;
198156
+ };
198157
+ content: {
198158
+ "application/json": components["schemas"]["SignupAccepted"];
198159
+ };
198160
+ };
198161
+ 409: components["responses"]["Conflict"];
198162
+ 422: components["responses"]["UnprocessableEntity"];
198163
+ 429: components["responses"]["TooManyRequests"];
198164
+ 503: components["responses"]["ServiceUnavailable"];
198165
+ };
198166
+ };
198167
+ inspectSignup: {
198168
+ parameters: {
198169
+ query?: never;
198170
+ header?: never;
198171
+ path?: never;
198172
+ cookie?: never;
198173
+ };
198174
+ requestBody: {
198175
+ content: {
198176
+ "application/json": components["schemas"]["SignupTokenRequest"];
198177
+ };
198178
+ };
198179
+ responses: {
198180
+ /** @description The link's state. */
198181
+ 200: {
198182
+ headers: {
198183
+ [name: string]: unknown;
198184
+ };
198185
+ content: {
198186
+ "application/json": components["schemas"]["SignupLinkState"];
198187
+ };
198188
+ };
198189
+ 422: components["responses"]["UnprocessableEntity"];
198190
+ 429: components["responses"]["TooManyRequests"];
198191
+ 503: components["responses"]["ServiceUnavailable"];
198192
+ };
198193
+ };
197927
198194
  submitSiteForm: {
197928
198195
  parameters: {
197929
198196
  query?: never;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zinn-digital/sdk",
3
- "version": "0.1.1754",
3
+ "version": "0.1.1756",
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>",