/** * This file was auto-generated by openapi-typescript and ts-morph. * Do not make direct changes to the file. */ export interface paths { readonly "/abandoned-carts/settings": { readonly parameters: { readonly query?: never; readonly path?: never; readonly cookie?: never; }; /** * Get global abandoned cart settings * @description Return the global abandoned cart settings of a store. */ readonly get: operations["getGlobalAbandonedCartSettings"]; /** * Update global abandoned cart settings * @description Update the global abandoned cart settings of a store. */ readonly put: operations["updateGlobalAbandonedCartSettings"]; }; readonly "/abandoned-carts/settings/channels/{channel_id}": { readonly parameters: { readonly query?: never; readonly path?: never; readonly cookie?: never; }; /** * Get channel abandoned cart settings * @description Return the per-channel overrides for the abandoned cart settings of a store. */ readonly get: operations["getChannelAbandonedCartSettings"]; /** * Update channel abandoned cart settings * @description Updates the per-channel overrides for the abandoned cart settings of a store. * * #### OAuth Scopes * | UI Name | Permission | Parameter | * |----------------------------------------------|------------|-----------------------------------------------| * | Information & Settings | modify | `store_v2_information` | */ readonly put: operations["updateChannelAbandonedCartSettings"]; }; readonly "/abandoned-carts/{token}": { readonly parameters: { readonly query?: never; readonly header: { /** @description The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) of the response body. */ readonly Accept: components["parameters"]["Accept"]; }; readonly path: { /** @description Unique cart `UUID`. * * Unique cart `UUID` token that is generated for abandoned cart emails. */ readonly token: string; }; readonly cookie?: never; }; /** * Get an abandoned cart * @description Return the `cart_id` corresponding to the abandoned cart `{token}` passed in. * * **Usage Notes**: * * `{token}` is the token in the query string of the abandoned cart link found in abandoned cart email notifications to shoppers */ readonly get: operations["getAbandonedCarts"]; }; } export type webhooks = Record; export interface components { schemas: { /** * Response meta * @description Response metadata */ readonly metaEmpty_Full: { readonly [key: string]: unknown; }; /** error_Full */ readonly error_Full: { /** * Format: int32 * @description The HTTP status code * */ readonly status?: number; /** @description The error title describing the particular error * */ readonly title?: string; readonly type?: string; }; /** errorDetailed_Full */ readonly errorDetailed_Full: { /** DetailedErrors */ readonly errors?: { readonly [key: string]: string; }; }; /** abandonedCartInfo_Full */ readonly abandonedCartInfo_Full: { /** @description The `cart_id` of the abandoned cart. Can be used to display the abandoned cart to the customer using storefront cart or server-to-server cart APIs */ readonly cart_id?: string; }; /** @description Represents all settings related to the abandoned cart functionality of a store */ readonly AbandonedCartSettings: { /** @description Indicates whether or not abandoned cart notification is on */ readonly enable_notification?: boolean; /** @description Indicates whether or not a customer should continue to receive abandoned cart emails until their cart is recovered */ readonly email_customer_until_cart_is_recovered?: boolean; /** @description Indicates whether or not a customer should receive abandoned cart emails based on their consent. By default customers will not receive emails */ readonly marketing_emails_require_customer_consent?: boolean; /** @description Indicates whether or not a merchant should receive a notification email when a cart is converted into an order */ readonly email_merchant_when_cart_is_converted?: boolean; /** @description Indicates whether or not a merchant should receive a notification email when a cart is abandoned */ readonly email_merchant_when_cart_is_abandoned?: boolean; /** * Format: email * @description The email address for receiving merchant notifications */ readonly merchant_email_address?: string; /** * @description Indicates whether to send an email for every abandoned cart, or to send a digest email after X number of abandoned carts * @enum {string} */ readonly merchant_abandoned_cart_email_frequency_type?: "digest" | "individual"; /** * Format: int32 * @description The number of abandoned carts to accumulate before a digest email is sent to a merchant */ readonly merchant_abandoned_cart_digest_email_frequency?: number; }; /** @description Represents all settings overrides related to the abandoned cart functionality of a store for a channel */ readonly ChannelAbandonedCartSettings: { /** @description Indicates whether or not abandoned cart notification is on. If it is null, it means there is no override for the specified channel. */ readonly enable_notification?: boolean | null; /** @description Indicates whether or not a customer should continue to receive abandoned cart emails until their cart is recovered. If it is null, it means there is no override for the specified channel. */ readonly email_customer_until_cart_is_recovered?: boolean | null; /** @description Indicates whether or not a customer should receive abandoned cart emails based on their consent. If it is null, it means there is no override for the specified channel. By default customers will not receive emails. */ readonly marketing_emails_require_customer_consent?: boolean | null; /** @description Indicates whether or not a merchant should receive a notification email when a cart is converted into an order. If it is null, it means there is no override for the specified channel. */ readonly email_merchant_when_cart_is_converted?: boolean | null; /** @description Indicates whether or not a merchant should receive a notification email when a cart is abandoned. If it is null, it means there is no override for the specified channel. */ readonly email_merchant_when_cart_is_abandoned?: boolean | null; /** * Format: email * @description The email address for receiving merchant notifications. If it is null, it means there is no override for the specified channel. */ readonly merchant_email_address?: string | null; /** * @description Indicates whether to send an email for every abandoned cart or to send a digest email after X number of abandoned carts. If it is null, it means there is no override for the specified channel. * @enum {string|null} */ readonly merchant_abandoned_cart_email_frequency_type?: "digest" | "individual" | null; /** * Format: int32 * @description The number of abandoned carts to accumulate before a digest email is sent to a merchant. If it is null, it means there is no override for the specified channel. */ readonly merchant_abandoned_cart_digest_email_frequency?: number | null; }; readonly ChannelAbandonedCartSettingsRequest: components["schemas"]["ChannelAbandonedCartSettings"] & unknown; /** @description The response object of abandoned cart settings overrides for a channel */ readonly ChannelAbandonedCartSettingsResponse: { readonly data?: components["schemas"]["ChannelAbandonedCartSettings"]; readonly meta?: components["schemas"]["metaEmpty_Full"]; }; readonly GlobalAbandonedCartSettingsRequest: components["schemas"]["AbandonedCartSettings"] & unknown; /** @description The response object of abandoned cart settings at the global level */ readonly GlobalAbandonedCartSettingsResponse: { readonly data?: components["schemas"]["AbandonedCartSettings"]; readonly meta?: components["schemas"]["metaEmpty_Full"]; }; /** @description The response object containing details of an error */ readonly ErrorResponse: { /** Format: int32 */ readonly status?: number; readonly title?: string; readonly type?: string; readonly instance?: string; readonly errors?: { readonly [key: string]: unknown; }; }; }; responses: { /** @description If something happens during the request that causes it to fail, a 502 response will be returned. A new request should be made; however, it could fail. */ readonly "502_GatewayError": { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["error_Full"]; }; }; /** @description If this occurs, you should retry the request. Typically retrying the request several times will result in a successful request; However, if you are unable to successfully make a request, please check the BigCommerce system status [here](https://status.bigcommerce.com/). A service is likely down and the request will need to be made again when it is back up (in several hours usually) */ readonly "504_GatewayTimeout": { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["errorDetailed_Full"]; }; }; /** @description Malformed request syntax. Typically need to fix the JSON * Body to resend successfully. */ readonly "400_BadRequest": { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["error_Full"]; }; }; /** @description If the requested account resource is not found for the franchise, return a 404 Not Found. */ readonly "404_NotFound": { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["error_Full"]; }; }; /** @description This occurs when missing or unacceptable data is passed for one or more fields. Please correct the values for the fields listed in the errors object. */ readonly "422_UnprocessableEntity": { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["errorDetailed_Full"]; }; }; /** @description If this occurs, you should retry the request. If you are unable to successfully make a request, please check the BigCommerce system status [here](https://status.bigcommerce.com/). A service is likely down and the request will need to be made again when it is back up (in several hours usually) */ readonly "503_ServiceUnavailable": { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["error_Full"]; }; }; /** @description Returned on `GET` requests to `/abandoned_carts`. */ readonly abandonedCart_Resp: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": { readonly data?: components["schemas"]["abandonedCartInfo_Full"]; readonly meta?: components["schemas"]["metaEmpty_Full"]; }; }; }; }; parameters: { /** @description The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) of the response body. */ readonly Accept: string; /** @description The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) of the request body. */ readonly ContentType: string; }; requestBodies: never; headers: never; pathItems: never; } export type $defs = Record; export interface operations { readonly getGlobalAbandonedCartSettings: { readonly parameters: { readonly query?: { /** @description How many pages to return */ readonly pagination?: number; }; readonly header?: never; readonly path?: never; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { /** @description OK */ readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["GlobalAbandonedCartSettingsResponse"]; }; }; /** @description Unauthorized */ readonly 401: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["ErrorResponse"]; }; }; }; }; readonly updateGlobalAbandonedCartSettings: { readonly parameters: { readonly query?: never; readonly header?: { /** @description The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) of the request body. */ readonly "Content-Type"?: components["parameters"]["ContentType"]; /** @description The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) of the response body. */ readonly Accept?: components["parameters"]["Accept"]; }; readonly path?: never; readonly cookie?: never; }; readonly requestBody: { readonly content: { readonly "application/json": components["schemas"]["GlobalAbandonedCartSettingsRequest"]; }; }; readonly responses: { /** @description OK */ readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["GlobalAbandonedCartSettingsResponse"]; }; }; /** @description Unauthorized */ readonly 401: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["ErrorResponse"]; }; }; /** @description Unprocessable entity */ readonly 422: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["ErrorResponse"]; }; }; }; }; readonly getChannelAbandonedCartSettings: { readonly parameters: { readonly query?: never; readonly header?: never; readonly path: { /** @description The channel ID of the settings overrides */ readonly channel_id: number; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { /** @description OK */ readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["ChannelAbandonedCartSettingsResponse"]; }; }; /** @description Unauthorized */ readonly 401: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["ErrorResponse"]; }; }; }; }; readonly updateChannelAbandonedCartSettings: { readonly parameters: { readonly query?: never; readonly header?: { /** @description The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) of the request body. */ readonly "Content-Type"?: components["parameters"]["ContentType"]; /** @description The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) of the response body. */ readonly Accept?: components["parameters"]["Accept"]; }; readonly path: { /** @description The channel ID of the settings overrides */ readonly channel_id: number; }; readonly cookie?: never; }; readonly requestBody: { readonly content: { readonly "application/json": components["schemas"]["ChannelAbandonedCartSettingsRequest"]; }; }; readonly responses: { /** @description OK */ readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["ChannelAbandonedCartSettingsResponse"]; }; }; /** @description Unauthorized */ readonly 401: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["ErrorResponse"]; }; }; /** @description Unprocessable entity */ readonly 422: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["ErrorResponse"]; }; }; }; }; readonly getAbandonedCarts: { readonly parameters: { readonly query?: never; readonly header?: { /** @description The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) of the response body. */ readonly Accept?: components["parameters"]["Accept"]; }; readonly path: { /** @description Unique cart `UUID`. * * Unique cart `UUID` token that is generated for abandoned cart emails. */ readonly token: string; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 200: components["responses"]["abandonedCart_Resp"]; readonly 400: components["responses"]["400_BadRequest"]; readonly 404: components["responses"]["404_NotFound"]; readonly 422: components["responses"]["422_UnprocessableEntity"]; readonly 502: components["responses"]["502_GatewayError"]; readonly 503: components["responses"]["503_ServiceUnavailable"]; readonly 504: components["responses"]["504_GatewayTimeout"]; readonly default: { headers: { readonly [name: string]: unknown; }; content?: never; }; }; }; }