/** * This file was auto-generated by openapi-typescript and ts-morph. * Do not make direct changes to the file. */ export interface paths { readonly "/customers": { 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?: never; readonly cookie?: never; }; /** * Get All Customers * @deprecated * @description Returns a list of all *Customers*. Default sorting is by `customer_ID`, from lowest to highest. Optional parameters can be passed in. */ readonly get: operations["getCustomers"]; /** * Create a New Customer * @deprecated * @description Creates a *Customer*. * **Required Fields** * * `first_name` * * `last_name` * * `email` * **Read Only Fields** * * `id` * * `date_created` * * `date_modified` * * `accepts_marketing` * * `addresses` * * `form_fields` * ## Notes * The `_authentication` object exposes functionality associated with the customer’s ability to log in to the store. All properties of the `_authentication` object are optional. * When the `_authentication` object is not supplied with an update request, then the existing customer password remains the same. * ## Updating Passwords * To manually update a customer password in the same way as the control panel, supply a value for the password field: * ```json * { * "_authentication": { * "password": "12w69Y217PYR96J" * } * } * ``` * ## Confirming Passwords * An additional optional `password_confirmation` field can also be sent, providing password confirmation as a service: * ```json * { * "_authentication": { * "password": "12w69Y217PYR96J", * "password_confirmation": "12w69Y217PYR96J" * } * } * ``` * ## Forcing Password Resets * To force a customer to reset their password upon their next login attempt, give the `force_reset` field a value of true, as shown here: * ```js showLineNumbers copy * { * "_authentication": { * "force_reset": true * } * } * ``` */ readonly post: operations["createCustomer"]; /** * Delete Customers * @deprecated * @description By default, it deletes all *Customers*. Up to 100 customers per batch can be deleted. */ readonly delete: operations["deleteCustomers"]; }; readonly "/customers/{customer_id}": { 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; /** * Get a Customer * @deprecated * @description Returns a single *Customer*. */ readonly get: operations["getCustomer"]; /** * Update a Customer * @deprecated * @description Updates a *Customer*. * * **Read Only Fields** * * id * * date_created * * date_modified * * accepts_marketing * * addresses * * form_fields * * ## Notes * The `_authentication` object exposes functionality associated with the customer’s ability to log in to the store. All properties of the `_authentication` object are optional. * When the `_authentication` object is not supplied with an update request, then the existing customer password remains the same. * ## Updating Passwords * To manually update a customer password in the same way as the control panel, supply a value for the `password` field: * * ```js showLineNumbers copy * { * "_authentication": { * "password": "12w69Y217PYR96J" * } * } * * ``` * * #### Confirming Passwords * An additional optional `password_confirmation` field can also be sent, providing password confirmation as a service: * ```js showLineNumbers copy * { * "_authentication": { * "password": "12w69Y217PYR96J" * "password_confirmation": "12w69Y217PYR96J" * } * } * ``` * #### Forcing Password Resets * To force a customer to reset their password upon their next login attempt, give the `force_reset` field a value of true, as shown here: * ```js showLineNumbers copy * { * "_authentication": { * "force_reset": true * } * } * ``` */ readonly put: operations["updateCustomer"]; /** * Delete a Customer * @deprecated * @description Deletes a *Customer*. */ readonly delete: operations["deleteCustomer"]; }; readonly "/customers/count": { 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?: never; readonly cookie?: never; }; /** * Get a Count of Customers * @deprecated * @description Returns a count of all *Customers*. */ readonly get: operations["getCustomersCount"]; }; readonly "/customers/{customer_id}/validate": { 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; /** * Validate a Password * @deprecated * @description **This endpoint has special rate limiting protections to protect against abuse.** * * Provided a password, will return a true/false response indicating if the provided password matches the customer’s current password. This endpoint is useful if you want to power the login of another system using BigCommerce’s stored customer accounts, or as a safe way to migrate passwords to another system (by checking them against BigCommerce’s password, and if correct, storing it in another system securely.) If the password matches what’s stored against the customer account, the response will be: * * ```js showLineNumbers copy * { * "success": "true" * } * ``` * If the password does NOT match, the response will instead be: * * ```js showLineNumbers copy * { * "success": "false" * } * ``` */ readonly post: operations["validateCustomerPassword"]; }; readonly "/customers/{customer_id}/addresses": { 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; /** * Get All Customer Addresses * @deprecated * @description Returns a list of *Customer Addresses*. Returns the addresses belonging to a customer. Default sorting is by address id, from lowest to highest. * The maximum limit is 250. If a limit isn’t provided, up to 50 `customer_addresses` are returned by default. */ readonly get: operations["getCustomerAddresses"]; /** * Create a Customer Address * @deprecated * @description Creates a new *Customer Address*. (Note: The “state” property cannot be null. As a workaround for addresses that include no state/province string, pass a space as the “state” value.) * * **Required Fields** * * first_name * * last_name * * phone * * street_1 * * city * * state * * zip * * country * * **Read Only Fields** * * id * * country_iso2 */ readonly post: operations["createCustomerAddress"]; /** * Delete Customer Address * @deprecated * @description By default, it deletes all *Customer Addresses*. */ readonly delete: operations["deleteCustomerAddresses"]; }; readonly "/customers/{customer_id}/addresses/{customer_address_id}": { 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; /** @description ID of the customer address. */ readonly customer_address_id: components["parameters"]["customer_address_id"]; }; readonly cookie?: never; }; /** * Get a Customer Address * @deprecated * @description Returns a *Customer Address*. */ readonly get: operations["getCustomerAddress"]; /** * Update a Customer Address * @deprecated * @description Updates a *Customer Address*. * * **Read Only Fields** * * id * * country_iso2 */ readonly put: operations["updateCustomerAddress"]; /** * Delete a Customer Address * @deprecated * @description Deletes a *Customer Address*. */ readonly delete: operations["deletesCustomerAddress"]; }; readonly "/customers/{customer_id}/addresses/count": { 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; /** * Get a Count of Customer Addresses * @deprecated * @description Returns a count of addresses for a customer. */ readonly get: operations["getCustomerAddressesCount"]; }; readonly "/customer_groups": { 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?: never; readonly cookie?: never; }; /** * Get All Customer Groups * @description Returns a list of *Customer Groups*. Default sorting is by customer-group ID, from lowest to highest. * * **Note:** * The default rate limit for this endpoint is 40 concurrent requests. */ readonly get: operations["getCustomerGroups"]; /** * Create a Customer Group * @description Creates a *Customer Group*. * * **Required Fields** * * name * * **Note:** * The default rate limit for this endpoint is 40 concurrent requests. */ readonly post: operations["createCustomerGroup"]; }; readonly "/customer_groups/{customer_group_id}": { 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 The ID of the customer group. */ readonly customer_group_id: components["parameters"]["customer_group_id"]; }; readonly cookie?: never; }; /** * Get a Customer Group * @description Returns a *Customer Group*. */ readonly get: operations["getCustomerGroup"]; /** * Update a Customer Group * @description Updates a *Customer Group*. * * **Notes** * * Any combination of fields can be updated at once. Discount rules are treated in bulk. The entire set of rules is overwritten when a request is sent. */ readonly put: operations["updateCustomerGroup"]; /** * Delete a Customer Group * @description Deletes a *Customer Group*. * * **Notes** * - All existing customers are unassigned from the group when it is deleted. * - The default rate limit for this endpoint is 40 concurrent requests. */ readonly delete: operations["deleteCustomerGroup"]; }; readonly "/customer_groups/count": { 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?: never; readonly cookie?: never; }; /** * Get a Count of Customer Groups * @description Returns a count of all *Customer Groups*. */ readonly get: operations["getCustomerGroupsCount"]; }; } export type webhooks = Record; export interface components { schemas: { /** billingAddress_Full */ readonly billingAddress_Full: { /** @example Jane */ readonly first_name?: string; /** @example Doe */ readonly last_name?: string; readonly company?: string; /** @example 123 Main Street */ readonly street_1?: string; readonly street_2?: string; /** @example Austin */ readonly city?: string; /** @example TX */ readonly state?: string; /** @example 12345 */ readonly zip?: string; /** @example United States */ readonly country?: string; /** @example US */ readonly country_iso2?: string; readonly phone?: string; /** @example janedoe@example.com */ readonly email?: string; readonly form_fields?: readonly { /** * @description Name of the form field. * @example License ID */ readonly name?: string; /** * @description Value of the form field. * @example 123BAF */ readonly value?: string; }[]; }; /** customerFormFields */ readonly customerFormFields: { /** * @description Name of the form field. * @example License ID */ readonly name?: string; /** * @description Value of the form field. * @example 123BAF */ readonly value?: string; }; /** shippingAddress_Full */ readonly shippingAddress_Full: { /** * @description URL of the shipping address for API requests. * @example https://api.bigcommerce.com/stores/{store_hash}/v2/orders/129/shippingaddresses */ readonly url?: string; /** @example /orders/129/shippingaddresses */ readonly resource?: string; }; /** customer_Full */ readonly customer_Full: { /** * @description Unique numeric ID of this customer. This is a Read-Only field; do not set or modify its value in a POST or PUT request. * @example 1 */ readonly id?: number; /** @description Date on which the customer registered from the storefront or was created in the control panel. This is a Read-Only field; do not set or modify its value in a POST or PUT request. */ readonly date_created?: string; /** @description Date on which the customer updated their details in the storefront or was updated in the control panel. This is a Read-Only field; do not set or modify its value in a POST or PUT request. * */ readonly date_modified?: string; } & components["schemas"]["customer_Base"]; /** categoryAccessLevel_Full */ readonly categoryAccessLevel_Full: { /** * @description + `all` - Customers can access all categories * + `specific` - Customers can access a specific list of categories * + `none` - Customers are prevented from viewing any of the categories in this group. * @enum {string} */ readonly type?: "all" | "specific" | "none"; /** * @description Is an array of category IDs and should be supplied only if `type` is specific. * @example [ * 18, * 19, * 23, * 34 * ] */ readonly categories?: readonly number[]; }; /** * count_Full * @example { * "count": 27 * } */ readonly count_Full: { /** @example 27 */ readonly count?: number; }; /** customerAddress_Full */ readonly customerAddress_Full: { /** * @description ID of this customer address. Read-Only. * @example 3 */ readonly id?: number; /** * @description 2-letter ISO Alpha-2 code for the customer’s country. Read-Only. * @example US */ readonly country_iso2?: string; } & components["schemas"]["customerAddress_Base"]; /** * customerGroup_Full * @description When creating a customer group category discount using the API it defaults to "products in this category and its subcategories". In the [store control panel](https://support.bigcommerce.com/s/article/Customer-Groups#pricing), this can be changed to either "products in this category only" or "products in this category and its subcategories". There are currently no settings to change this behavior with the API. */ readonly customerGroup_Full: { /** * @description ID of the customer group. * @example 1 */ readonly id?: number; /** * @description Name of the group. * @example Wholesale */ readonly name?: string; /** * @description Determines whether new customers are assigned to this group by default. * @example false */ readonly is_default?: boolean; readonly category_access?: components["schemas"]["categoryAccessLevel_Full"]; readonly discount_rules?: readonly { /** @enum {string} */ readonly type?: "price_list" | "all" | "category" | "product"; /** @enum {string} */ readonly method?: "percent" | "fixed" | "price"; /** * @description A float that specifies the value applied to the price modified. (Float, Float as String, Integer) * @example 5.0000 */ readonly amount?: string; /** * @description If a customer group is assigned to a price list,`method` and `amount` are not shown. `type` and `price_list_id` are returned. * @example 3 */ readonly price_list_id?: number; }[] | readonly { /** @enum {string} */ readonly type?: "price_list" | "all" | "category" | "product"; /** @enum {string} */ readonly method?: "percent" | "fixed" | "price"; /** * @description A float that specifies the value applied to the price modified. (Float, Float as String, Integer) * @example 5.0000 */ readonly amount?: string; /** * @description If a customer group is assigned to a category, `method` and `amount` are not shown. `type` and `category_id` are returned. * @example 30 */ readonly category_id?: number; }[] | readonly { /** @enum {string} */ readonly type?: "price_list" | "all" | "category" | "product"; /** @enum {string} */ readonly method?: "percent" | "fixed" | "price"; /** * @description A float that specifies the value applied to the price modified. (Float, Float as String, Integer) * @example 5.0000 */ readonly amount?: string; /** * @description If a customer group is assigned to a product,`method` and `amount` are not shown. `type` and `product` are returned. * @example 3 */ readonly product_id?: number; }[] | readonly { /** @enum {string} */ readonly type?: "price_list" | "all" | "category" | "product"; /** @enum {string} */ readonly method?: "percent" | "fixed" | "price"; /** * @description A float that specifies the value applied to the price modified. (Float, Float as String, Integer) * @example 5.0000 */ readonly amount?: string; }[]; /** * @description Date on which the customer group was created. * @example 2023-07-17 06:30:41 */ readonly date_created?: string; /** * @description Date on which the customer group was last modified. * @example 2023-07-25 01:15:19 */ readonly date_modified?: string; /** @description Describes whether the group is for guests. There can only be one customer group for guests at a time. */ readonly is_group_for_guests?: boolean; }; /** * country_Full * @example { * "id": 13, * "country": "Australia", * "country_iso2": "AU", * "country_iso3": "AUS", * "states": { * "url": "https://api.bigcommerce.com/stores/{store_hash}/v2/countries/13/states", * "resource": "/countries/13/states" * } * } */ readonly country_Full: { /** * @description ID of the country. * @example 13 */ readonly id?: number; /** * @description Country name. * @example Australia */ readonly country?: string; /** * @description 2-letter country code. * @example AU */ readonly country_iso2?: string; /** * @description 3-letter country code. * @example AUS */ readonly country_iso3?: string; /** States Resource */ readonly states?: { /** @example https://api.bigcommerce.com/stores/{store_hash}/v2/countries/13/states */ readonly url?: string; /** @example /countries/13/states */ readonly resource?: string; }; }; /** statesResource_Full */ readonly statesResource_Full: { /** @example https://api.bigcommerce.com/stores/{store_hash}/v2/countries/13/states */ readonly url?: string; /** @example /countries/13/states */ readonly resource?: string; }; /** state_Full */ readonly state_Full: { /** * @description Numeric ID of the state/province. * @example 208 */ readonly id?: number; /** * @description Name of the state/province. * @example Australian Capital Territory */ readonly state?: string; /** * @description Abbreviation for the state/province. * @example ACT */ readonly state_abbreviation?: string; /** * @description Numeric ID of the state’s/province’s associated country. * @example 13 */ readonly country_id?: number; }; /** * customerGroup_Post_Put * @description When creating a customer group category discount using the API it defaults to "products in this category and its subcategories". In the [store control panel](https://support.bigcommerce.com/s/article/Customer-Groups#pricing), this can be changed to either "products in this category only" or "products in this category and its subcategories". There are currently no settings to change this behavior with the API. */ readonly customerGroup_Post_Put: { /** * @description Name of the group. * @example Wholesale */ readonly name?: string; /** * @description Determines whether new customers are assigned to this group by default. * @example false */ readonly is_default?: boolean; readonly category_access?: components["schemas"]["categoryAccessLevel_Full"]; readonly discount_rules?: readonly { /** @enum {string} */ readonly type: "price_list"; /** * @description If a customer group is assigned to a price list,`method` and `amount` are not shown. `type` and `price_list_id` are returned. * @example 3 */ readonly price_list_id?: number; }[] | readonly ({ /** @enum {string} */ readonly type: "category"; /** @enum {string} */ readonly method: "percent" | "fixed" | "price"; /** * @description A float that specifies the value applied to the price modified. (Float, Float as String, Integer) * @example 5.0000 */ readonly amount: string; /** * @description The category the customer group discount is assigned to. * @example 3 */ readonly category_id: number; } | { /** @enum {string} */ readonly type: "product"; /** @enum {string} */ readonly method: "percent" | "fixed" | "price"; /** * @description A float that specifies the value applied to the price modified. (Float, Float as String, Integer) * @example 5.0000 */ readonly amount: string; /** * @description The `product_id` the customer group discount is assigned to. * @example 3 */ readonly product_id: number; } | { /** @enum {string} */ readonly type: "all"; /** @enum {string} */ readonly method?: "percent" | "fixed" | "price"; /** * @description A float that specifies the value applied to the price modified. (Float, Float as String, Integer) * @example 5.0000 */ readonly amount?: string; })[]; /** @description Describes whether the group is for guests. There can only be one customer group for guests at a time. */ readonly is_group_for_guests?: boolean; }; readonly validatePassword: { /** @description Will return `true` or `false`. */ readonly success?: boolean; }; /** customer_Base */ readonly customer_Base: { /** @description Not returned in any responses, but accepts up to two fields allowing you to set the customer’s password. If a password is not supplied, it is generated automatically. For further information about using this object, please see the Customers resource documentation. */ readonly _authentication?: { readonly force_reset?: boolean; readonly password?: string; readonly password_confirmation?: string; }; /** * @description The name of the company for which the customer works. * @example BigCommerce */ readonly company?: string; /** * @description First name of the customer. * @example Jane */ readonly first_name: string; /** * @description Last name of the customer. * @example Doe */ readonly last_name: string; /** * @description Email address of the customer. * @example janedoe@example.com */ readonly email: string; /** * @description Phone number of the customer. * @example 1234567890 */ readonly phone?: string; /** * @description The amount of credit the customer has. (Float, Float as String, Integer) * @example 0 */ readonly store_credit?: string; /** * @description The customer’s IP address when they signed up. * @example 12.345.678.910 */ readonly registration_ip_address?: string; /** * @description The group to which the customer belongs. * @example 2 */ readonly customer_group_id?: number; /** @description Store-owner notes on the customer. */ readonly notes?: string; /** @description If applicable, the tax-exempt category of the shopper’s customer account. You can apply a tax-exempt category to multiple customers. This code should match the exemption codes provided by the third-party integration. */ readonly tax_exempt_category?: string; /** * @description Describes whether the customer accepts product review emails or abandon cart emails. Read-Only. * @example true */ readonly accepts_marketing?: boolean; /** Address Field Resource */ readonly addresses?: { /** * @description Full URL of where the resource is located. * @example https://api.bigcommerce.com/stores/{store_hash}/v2/customers/5/addresses */ readonly url?: string; /** * @description Resource being accessed. * @example /customers/5/addresses */ readonly resource?: string; }; /** @description Array of custom fields. This is a Read-Only field; do not set or modify its value in a POST or PUT request. */ readonly form_fields?: readonly { /** * @description Name of the form field. * @example License ID */ readonly name?: string; /** @description Value of the form field. */ readonly value?: string | null; }[] | null; /** * @description Force a password change on next login. * @example false */ readonly reset_pass_on_login?: boolean; }; /** customer_Put */ readonly customer_Put: { /** * @description Unique numeric ID of this customer. This is a Read-Only field; do not set or modify its value in a POST or PUT request. * @example 1 */ readonly id?: number; /** @description Not returned in any responses, but accepts up to two fields allowing you to set the customer’s password. If a password is not supplied, it is generated automatically. For further information about using this object, please see the Customers resource documentation. */ readonly _authentication?: { readonly force_reset?: boolean; readonly password?: string; readonly password_confirmation?: string; }; /** * @description The name of the company for which the customer works. * @example BigCommerce */ readonly company?: string; /** * @description First name of the customer. * @example Jane */ readonly first_name?: string; /** * @description Last name of the customer. * @example Doe */ readonly last_name?: string; /** * @description Email address of the customer. * @example janedoe@example.com */ readonly email?: string; /** * @description Phone number of the customer. * @example 1234567890 */ readonly phone?: string; /** @description Date on which the customer registered from the storefront or was created in the control panel. This is a Read-Only field; do not set or modify its value in a POST or PUT request. */ readonly date_created?: string; /** @description Date on which the customer updated their details in the storefront or was updated in the control panel. This is a READ-ONLY field; do not set or modify its value in a POST or PUT request. */ readonly date_modified?: string; /** * @description The amount of credit the customer has. (Float, Float as String, Integer) * @example 0 */ readonly store_credit?: string; /** * @description The customer’s IP address when they signed up. * @example 12.345.678.910 */ readonly registration_ip_address?: string; /** * @description The group to which the customer belongs. * @example 2 */ readonly customer_group_id?: number; /** @description Store-owner notes on the customer. */ readonly notes?: string; /** @description If applicable, the tax-exempt category of the shopper’s customer account. You can apply a tax-exempt category to multiple customers. This code should match the exemption codes provided by the third-party integration. */ readonly tax_exempt_category?: string; /** * @description Describes whether the customer accepts product review emails and abandon cart emails. Read-Only. * @example true */ readonly accepts_marketing?: boolean; /** Address Field Resource */ readonly addresses?: { /** * @description Full URL of where the resource is located. * @example https://api.bigcommerce.com/stores/{store_hash}/v2/customers/5/addresses */ readonly url?: string; /** * @description Resource being accessed. * @example /customers/5/addresses */ readonly resource?: string; }; /** @description Array of custom fields. This is a Read-Only field; do not set or modify its value in a POST or PUT request. */ readonly form_fields?: readonly { /** * @description Name of the form field. * @example License ID */ readonly name?: string; /** * @description Value of the form field. * @example 123BAF */ readonly value?: string; }[]; /** * @description Force a password change on next login. * @example false */ readonly reset_pass_on_login?: boolean; }; readonly ErrorRequest: { readonly errors?: readonly components["schemas"]["ErrorBasic"][]; }; readonly ErrorBasic: { /** @description The HTTP status code. * */ readonly status?: number; /** @description The error title describing the particular error. * */ readonly title?: string; readonly type?: string; }; /** customerAddress_Base */ readonly customerAddress_Base: { /** * @description ID of the associated customer. * @example 5 */ readonly customer_id?: number; /** * @description The customer’s first name. * @example Jane */ readonly first_name: string; /** * @description The customer’s last name. * @example Doe */ readonly last_name: string; /** * @description The customer’s company name. * @example BigCommerce */ readonly company?: string; /** * @description The customer’s street address, line 1. * @example 123 Main Street */ readonly street_1: string; /** @description The customer’s street address, line 2. */ readonly street_2?: string; /** * @description The customer’s city/town/suburb. * @example Austin */ readonly city: string; /** * @description The customer’s state/province. Do not abbreviate the state; spell out the entire word. For example, California. (Cannot be null. As a workaround for addresses that include no state/province string, pass a space as the “state” value.) * @example Texas */ readonly state: string; /** * @description The customer’s ZIP or postal code. * @example 78726 */ readonly zip: string; /** * @description The customer’s country. Must be the full country name. * @example United States */ readonly country: string; /** * @description The customer’s phone number. * @example 123-345-7890 */ readonly phone: string; /** * @example residential * @enum {string} */ readonly address_type?: "residential" | "commercial"; }; }; responses: never; 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; /** @description Unique numeric ID of the customer. */ readonly customer_id: number; /** @description The ID of the customer group. */ readonly customer_group_id: number; /** @description ID of the customer address. */ readonly customer_address_id: number; /** @description Describes whether the group is for guests. There can only be one customer group for guests at a time. */ readonly is_group_for_guests: boolean; }; requestBodies: never; headers: never; pathItems: never; } export type $defs = Record; export interface operations { readonly getCustomers: { readonly parameters: { readonly query?: { readonly first_name?: string; readonly last_name?: string; readonly company?: string; readonly email?: string; readonly phone?: string; readonly store_credit?: string; readonly customer_group_id?: number; readonly min_id?: number; readonly max_id?: number; readonly min_date_created?: string; readonly max_date_created?: string; readonly min_date_modified?: string; readonly max_date_modified?: string; readonly tax_exempt_category?: string; }; 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?: never; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": readonly components["schemas"]["customer_Full"][]; }; }; }; }; readonly createCustomer: { 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"]; /** @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"]; }; readonly path?: never; readonly cookie?: never; }; readonly requestBody: { readonly content: { readonly "application/json": { /** @description This can vary depending on the action being taken to update, validate or force a password change. See [Customers V2, Update a customer (Deprecated)](/docs/rest-management/customers-v2#update-a-customer). */ readonly _authentication?: Record; readonly company?: string; readonly first_name?: string; readonly last_name?: string; readonly phone?: string; readonly date_modified?: string; readonly store_credit?: number; readonly registration_ip_address?: string; readonly customer_group_id?: number; readonly notes?: string; readonly tax_exempt_category?: string; }; }; }; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["customer_Full"]; }; }; }; }; readonly deleteCustomers: { 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?: never; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 204: { headers: { readonly [name: string]: unknown; }; content?: never; }; }; }; readonly getCustomer: { 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["customer_Full"]; }; }; }; }; readonly updateCustomer: { 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"]; /** @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"]; }; readonly path: { /** @description Unique numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; readonly requestBody?: { readonly content: { readonly "application/json": components["schemas"]["customer_Put"]; }; }; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["customer_Base"]; }; }; }; }; readonly deleteCustomer: { 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 204: { headers: { readonly [name: string]: unknown; }; content?: never; }; }; }; readonly getCustomersCount: { 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?: never; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { /** @example { * "count": 27 * } */ readonly "application/json": components["schemas"]["count_Full"]; }; }; }; }; readonly validateCustomerPassword: { 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"]; /** @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"]; }; readonly path: { /** @description Unique numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; readonly requestBody: { readonly content: { readonly "application/json": { /** @description String to run against customer password. Will return a true or false. */ readonly password?: string; }; }; }; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { /** @example { * "success": false * } */ readonly "application/json": components["schemas"]["validatePassword"]; }; }; }; }; readonly getCustomerAddresses: { readonly parameters: { readonly query?: { /** @description Number of pages. */ readonly page?: number; /** @description Count per page. */ readonly limit?: number; }; 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": readonly components["schemas"]["customerAddress_Full"][]; }; }; }; }; readonly createCustomerAddress: { 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"]; /** @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"]; }; readonly path: { /** @description Unique numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; readonly requestBody: { readonly content: { readonly "application/json": components["schemas"]["customerAddress_Base"]; }; }; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["customerAddress_Full"]; }; }; }; }; readonly deleteCustomerAddresses: { readonly parameters: { readonly query?: { /** @description Number of pages. */ readonly page?: number; /** @description Count per page. */ readonly limit?: number; }; 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 204: { headers: { readonly [name: string]: unknown; }; content?: never; }; }; }; readonly getCustomerAddress: { readonly parameters: { readonly query?: { /** @description Number of pages. */ readonly page?: number; /** @description Count per page. */ readonly limit?: number; }; 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; /** @description ID of the customer address. */ readonly customer_address_id: components["parameters"]["customer_address_id"]; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["customerAddress_Full"]; }; }; }; }; readonly updateCustomerAddress: { 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"]; /** @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"]; }; readonly path: { /** @description Unique numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; /** @description ID of the customer address. */ readonly customer_address_id: components["parameters"]["customer_address_id"]; }; readonly cookie?: never; }; readonly requestBody: { readonly content: { readonly "application/json": { /** * @description ID of this customer address. Read-Only. * @example 3 */ readonly id?: number; /** * @description ID of the associated customer. * @example 5 */ readonly customer_id?: number; /** * @description The customer’s first name. * @example Jane */ readonly first_name: string; /** * @description The customer’s last name. * @example Doe */ readonly last_name: string; /** * @description The customer’s company name. * @example BigCommerce */ readonly company?: string; /** * @description The customer’s street address, line 1. * @example 123 Main Street */ readonly street_1: string; /** @description The customer’s street address, line 2. */ readonly street_2?: string; /** * @description The customer’s city/town/suburb. * @example Austin */ readonly city: string; /** * @description The customer’s state/province. Do not abbreviate the state; spell out the entire word. For example, California. (Cannot be null. As a workaround for addresses that include no state/province string, pass a space as the “state” value.) * @example Texas */ readonly state: string; /** * @description The customer’s ZIP or postal code. * @example 78726 */ readonly zip: string; /** * @description The customer’s country. Must be the full country name. * @example United States */ readonly country: string; /** * @description 2-letter ISO Alpha-2 code for the customer’s country. Read-Only. * @example US */ readonly country_iso2?: string; /** * @description The customer’s phone number. * @example 123-345-7890 */ readonly phone: string; /** * @example residential * @enum {string} */ readonly address_type?: "residential" | "commercial"; }; }; }; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["customerAddress_Full"]; }; }; }; }; readonly deletesCustomerAddress: { 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; /** @description ID of the customer address. */ readonly customer_address_id: components["parameters"]["customer_address_id"]; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 204: { headers: { readonly [name: string]: unknown; }; content?: never; }; }; }; readonly getCustomerAddressesCount: { readonly parameters: { readonly query?: { /** @description Number of pages. */ readonly page?: number; /** @description Count per page. */ readonly limit?: number; }; 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 numeric ID of the customer. */ readonly customer_id: components["parameters"]["customer_id"]; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { /** @example { * "count": 27 * } */ readonly "application/json": components["schemas"]["count_Full"]; }; }; }; }; readonly getCustomerGroups: { readonly parameters: { readonly query?: { /** @description Number of pages. */ readonly page?: number; /** @description Count per page. */ readonly limit?: number; /** @description Filter customer groups by exact name match. */ readonly name?: string; /** @description Filter customer groups by name, using a fuzzy matching method. */ readonly "name:like"?: string; /** @description Filter by customers who sign up are added to this group by default. */ readonly is_default?: boolean; /** @description Filter customer groups by date_created. `date_created=2018-09-05T13:43:54` */ readonly date_created?: string; /** @description Filter customer groups by maximum date_created. `date_created:max=2018-09-10` */ readonly "date_created:max"?: string; /** @description Filter customer groups by date_created. `date_created:min=2018-09-05` */ readonly "date_created:min"?: string; /** @description Filter customer groups by date_modified. `date_modified=2018-09-05T13:45:03` */ readonly date_modified?: string; /** @description Filter customer groups by minimum date_modified. `date_modified:min=2019-09-04T:00:00:00` or `date_modified:min=2019-09-04` */ readonly "date_modified:min"?: string; /** @description Filter customer groups by maximum date_modified. `date_modified:max=2018-09-05T13:45:03` or `date_modified:max=2019-09-04` */ readonly "date_modified:max"?: string; /** @description Filter whether the group is for guests. There can only be one customer group for guests at a time. */ readonly is_group_for_guests?: boolean; }; 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?: never; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": readonly components["schemas"]["customerGroup_Full"][]; }; }; }; }; readonly createCustomerGroup: { 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"]; /** @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"]; }; readonly path?: never; readonly cookie?: never; }; readonly requestBody: { readonly content: { readonly "application/json": components["schemas"]["customerGroup_Post_Put"]; }; }; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["customerGroup_Full"]; }; }; /** @description The customer group was created, but the sitewide discount update failed. You may retry the request. */ readonly 207: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": { readonly status?: number; readonly message?: string; }; }; }; }; }; readonly getCustomerGroup: { readonly parameters: { readonly query?: { /** @description Number of pages. */ readonly page?: number; /** @description Count per page. */ readonly limit?: number; /** @description Name of the customer groups. */ readonly name?: string; /** @description Filter items by date_created. `date_created=2018-09-05T13:43:54` */ readonly date_created?: string; /** @description Filter items by maximum date_created. `date_created:max=2018-09-10` */ readonly "date_created:max"?: string; /** @description Filter items by date_created. `date_created:min=2018-09-05` */ readonly "date_created:min"?: string; /** @description Filter items by date_modified. `date_modified=2018-09-05T13:45:03` */ readonly date_modified?: string; /** @description Filter items by minimum date_modified. `date_modified:min=2019-09-04T:00:00:00` or `date_modified:min=2019-09-04` */ readonly "date_modified:min"?: string; /** @description Filter items by maximum date_modified. `date_modified:max=2018-09-05T13:45:03` or `date_modified:max=2019-09-04` */ readonly "date_modified:max"?: string; /** @description Whether customers who sign up are added to this group by default. */ readonly is_default?: boolean; }; 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 The ID of the customer group. */ readonly customer_group_id: components["parameters"]["customer_group_id"]; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { /** @description The request was successful. */ readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["customerGroup_Full"]; }; }; /** @description Bad Request. The requested resource could not be downloaded and may be invalid. Possible reasons include malformed request syntax or the file host blocking requests. */ readonly 400: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["ErrorRequest"]; }; }; }; }; readonly updateCustomerGroup: { 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"]; /** @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"]; }; readonly path: { /** @description The ID of the customer group. */ readonly customer_group_id: components["parameters"]["customer_group_id"]; }; readonly cookie?: never; }; readonly requestBody?: { readonly content: { readonly "application/json": components["schemas"]["customerGroup_Post_Put"]; }; }; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["customerGroup_Full"]; }; }; /** @description The customer group was updated, but the sitewide discount update failed. You may retry the request. */ readonly 207: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": { readonly status: number; readonly message: string; }; }; }; }; }; readonly deleteCustomerGroup: { 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 The ID of the customer group. */ readonly customer_group_id: components["parameters"]["customer_group_id"]; }; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { /** @description No content. Request was successful but produced no response. */ readonly 204: { headers: { readonly [name: string]: unknown; }; content?: never; }; /** @description Bad Request. The requested resource could not be downloaded and may be invalid. Possible reasons include malformed request syntax or the file host blocking requests. */ readonly 400: { headers: { readonly [name: string]: unknown; }; content: { readonly "application/json": components["schemas"]["ErrorRequest"]; }; }; }; }; readonly getCustomerGroupsCount: { 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?: never; readonly cookie?: never; }; readonly requestBody?: never; readonly responses: { readonly 200: { headers: { readonly [name: string]: unknown; }; content: { /** @example { * "count": 27 * } */ readonly "application/json": components["schemas"]["count_Full"]; }; }; }; }; }