{ "openapi": "3.1.1", "info": { "title": "Commerce API", "version": "2" }, "servers": [ { "url": "https://api.squarespace.com", "description": "Commerce API" } ], "security": [ { "Authorization": [] } ], "tags": [ { "description": "Manage customer contacts and address book entries for a website: create, read, update, delete, and query contacts; maintain addresses for shipping and fulfillment.", "name": "Contacts", "x-zudoku-collapsed": true }, { "description": "Query analytics for a website", "name": "Analytics", "x-zudoku-collapsed": true }, { "description": "Manage discounts for a website.", "name": "Discounts", "x-zudoku-collapsed": true }, { "name": "Products", "x-zudoku-collapsed": true }, { "name": "Websites", "x-zudoku-collapsed": true }, { "name": "Inventory", "x-zudoku-collapsed": true }, { "name": "Orders", "x-zudoku-collapsed": true }, { "name": "Transactions", "x-zudoku-collapsed": true }, { "name": "Profiles", "x-zudoku-collapsed": true }, { "name": "WebhookSubscriptions", "x-zudoku-collapsed": true } ], "paths": { "/v1/analytics/transaction-summaries": { "post": { "operationId": "getTransactionsSummaries", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RetrieveTransactionsSummariesRequest" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RetrieveTransactionsSummariesResponse" } } }, "description": "Transaction summaries retrieved" }, "400": { "description": "contactIds shouldn't be empty or too big, groupBy should have a valid value" } }, "summary": "Retrieve transaction summaries grouped by contact", "tags": [ "Analytics" ], "parameters": [ { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ] } }, "/v1/commerce/discounts": { "get": { "description": "Returns a paginated list of discounts for the website. Requires OAuth website scope website.discounts.read or website.discounts, or API key scope DISCOUNTS_READONLY or DISCOUNTS.", "operationId": "listDiscounts", "parameters": [ { "description": "Sort field for the result set.", "in": "query", "name": "sortBy", "required": false, "schema": { "type": "string", "default": "CREATED_ON", "enum": [ "CREATED_ON", "PROMO_CODE", "USES_COUNT" ] } }, { "description": "Sort direction.", "in": "query", "name": "sortDirection", "required": false, "schema": { "type": "string", "default": "DESCENDING", "enum": [ "ASCENDING", "DESCENDING" ] } }, { "description": "Free-text search across a discount's name and promo code.", "in": "query", "name": "search", "required": false, "schema": { "type": "string" } }, { "description": "Filter by discount lifecycle status.", "in": "query", "name": "status", "required": false, "schema": { "type": "string", "default": "ALL", "enum": [ "ALL", "ACTIVE", "EXPIRED", "SCHEDULED" ] } }, { "description": "Filter by one or more criteria types (comma-separated). When omitted, defaults to all allowable values.", "in": "query", "name": "criteria", "required": false, "schema": { "type": "array", "items": { "type": "string", "enum": [ "ANY_ORDER", "CART_TOTAL", "PRODUCT", "BUY_X_GET_Y" ] }, "default": [ "ANY_ORDER", "CART_TOTAL", "PRODUCT", "BUY_X_GET_Y" ] } }, { "description": "Filter by one or more template types (comma-separated). When omitted, defaults to all allowable values.", "in": "query", "name": "template", "required": false, "schema": { "type": "array", "items": { "type": "string", "enum": [ "FIXED_AMOUNT", "PERCENTAGE", "BUY_X_GET_Y_FIXED_AMOUNT", "BUY_X_GET_Y_PERCENTAGE", "FREE_SHIPPING" ] }, "default": [ "FIXED_AMOUNT", "PERCENTAGE", "BUY_X_GET_Y_FIXED_AMOUNT", "BUY_X_GET_Y_PERCENTAGE", "FREE_SHIPPING" ] } }, { "description": "Filter by one or more trigger types (comma-separated): AUTO (auto-applied) or CODE (promo code). When omitted, or when all allowable values are supplied, defaults to all allowable values.", "in": "query", "name": "trigger", "required": false, "schema": { "type": "array", "items": { "type": "string", "enum": [ "AUTO", "CODE" ] }, "enum": [ "AUTO", "CODE" ] } }, { "description": "When true, only discounts with limited-use semantics (per product rules) are returned.", "in": "query", "name": "limitedUseOnly", "required": false, "schema": { "type": "boolean", "default": false } }, { "description": "Zero-based offset into the result set. Must be non-negative. Default 0.", "in": "query", "name": "offset", "required": false, "schema": { "minimum": 0, "type": "integer", "format": "int32", "default": 0 } }, { "description": "Page size (1–1000; default 50).", "in": "query", "name": "limit", "required": false, "schema": { "maximum": 1000, "minimum": 1, "type": "integer", "format": "int32", "default": 50 } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PaginatedDiscountListResponse" } } }, "description": "Paginated discounts for the website (empty page is a successful response)." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Invalid query parameters (e.g. limit over cap, unknown enum value)." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Rate limit exceeded." } }, "summary": "List discounts", "tags": [ "Discounts" ] }, "post": { "description": "Creates a discount. A successful request returns the created Discount resource. Requires OAuth website scope website.discounts, or API key scope DISCOUNTS.", "operationId": "createDiscount", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateDiscountRequest" } } }, "description": "The discount to create.", "required": true }, "responses": { "201": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiscountResponse" } } }, "description": "The created discount." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. Missing or invalid fields, invalid criteria/template pairing, or promo code reserved for gift cards." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. The promo code is already in use by another discount, or the maximum number of auto-trigger discounts has been reached." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Rate limit exceeded." } }, "summary": "Create discount", "tags": [ "Discounts" ], "parameters": [ { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ] } }, "/v1/commerce/discounts/{discountId}": { "delete": { "description": "Deletes the discount for the given discount ID. Deletion is permitted for any discount owned by the website, including discounts whose criteria, template, or trigger types are not supported by this API version; no type validation is performed. Requires OAuth website scope website.discounts, or API key scope DISCOUNTS.", "operationId": "deleteDiscount", "parameters": [ { "description": "The discount's ID.", "in": "path", "name": "discountId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64b8f4e3d9a2ca6f41b25e3c" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "204": { "description": "No content. The discount was deleted successfully." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The requested discount was not found." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Rate limit exceeded." } }, "summary": "Delete discount", "tags": [ "Discounts" ] }, "get": { "description": "Returns the discount for the given discount ID. Requires OAuth website scope website.discounts.read or website.discounts, or API key scope DISCOUNTS_READONLY or DISCOUNTS.", "operationId": "getDiscount", "parameters": [ { "description": "The discount's ID", "in": "path", "name": "discountId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64b8f4e3d9a2ca6f41b25e3c" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiscountResponse" } } }, "description": "Discount found." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Discount not found for this website." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Rate limit exceeded." } }, "summary": "Get discount", "tags": [ "Discounts" ] }, "put": { "description": "Replaces the discount for the given discount ID. Requires OAuth website scope website.discounts, or API key scope DISCOUNTS.", "operationId": "updateDiscount", "parameters": [ { "description": "The discount's unique identifier.", "in": "path", "name": "discountId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64b8f4e3d9a2ca6f41b25e3c" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Discount" } } }, "description": "The discount replacement payload.", "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiscountResponse" } } }, "description": "The updated discount." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. Missing or invalid fields, invalid criteria/template pairing, or promo code reserved for gift cards." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Discount not found for this website." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. The promo code is already in use by another discount, or the maximum number of auto-trigger discounts has been reached." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Rate limit exceeded." } }, "summary": "Update discount", "tags": [ "Discounts" ] } }, "/v1/contacts": { "get": { "description": "Returns a paginated list of contacts for the website. Requires OAuth website scope website.contacts.read or website.contacts, or API key scope CONTACT_READONLY or CONTACT, or OAuth website scope website.profiles.read or website.profiles (OAuth only).", "operationId": "getContacts", "parameters": [ { "description": "number of contacts to retrieve per request", "in": "query", "name": "pageSize", "required": false, "schema": { "maximum": 1000, "minimum": 0, "type": "integer", "format": "int32", "default": 50 } }, { "description": "where next page of results begins. should be {pagination.nextPageCursor} from previous response.", "in": "query", "name": "cursor", "required": false, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PaginatedGetContactsResponse" } } }, "description": "A paginated list of contacts." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Invalid pagination parameters: page size out of range or cursor not from a previous response." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "List contacts", "tags": [ "Contacts" ] }, "post": { "description": "Creates a new contact. Requires OAuth website scope website.contacts, or API key scope CONTACT, or OAuth website scope website.profiles (OAuth only).", "operationId": "createContact", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateContactRequest" } } }, "description": "The contact to create.", "required": true }, "responses": { "201": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateContactResponse" } } }, "description": "The created contact." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Invalid input or malformed JSON." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "A contact with the same unique fields already exists." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Create contact", "tags": [ "Contacts" ], "parameters": [ { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ] } }, "/v1/contacts/query": { "post": { "description": "Returns a paginated list of contacts matching filters and sort options in the request body. Requires OAuth website scope website.contacts.read or website.contacts, or API key scope CONTACT_READONLY or CONTACT, or OAuth website scope website.profiles.read or website.profiles (OAuth only).", "operationId": "queryContacts", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/QueryContactsRequest" } } }, "description": "Filters and sort order for the contact query.", "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PaginatedQueryContactsResponse" } } }, "description": "A paginated list of contacts matching the query." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Invalid input or malformed JSON." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Query contacts", "tags": [ "Contacts" ], "parameters": [ { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ] } }, "/v1/contacts/{contactId}": { "delete": { "description": "Deletes the contact for the given contact ID. Requires OAuth website scope website.contacts, or API key scope CONTACT, or OAuth website scope website.profiles (OAuth only).", "operationId": "deleteContact", "parameters": [ { "description": "The contact's ID.", "in": "path", "name": "contactId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64a7e3d2c8f1b95e30a14d2b" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "204": { "description": "No content." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The contact was not found." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Delete contact", "tags": [ "Contacts" ] }, "get": { "description": "Returns the contact for the given contact ID. Requires OAuth website scope website.contacts.read or website.contacts, or API key scope CONTACT_READONLY or CONTACT, or OAuth website scope website.profiles.read or website.profiles (OAuth only).", "operationId": "getContact", "parameters": [ { "description": "The contact's ID.", "in": "path", "name": "contactId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64a7e3d2c8f1b95e30a14d2b" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GetContactResponse" } } }, "description": "The requested contact." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The contact was not found." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Get contact", "tags": [ "Contacts" ] }, "patch": { "description": "Updates a contact using JSON merge patch. Requires OAuth website scope website.contacts, or API key scope CONTACT, or OAuth website scope website.profiles (OAuth only).", "operationId": "patchContact", "parameters": [ { "description": "The contact's ID.", "in": "path", "name": "contactId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64a7e3d2c8f1b95e30a14d2b" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/merge-patch+json": { "schema": { "$ref": "#/components/schemas/PatchContactRequest" } } }, "description": "Fields to update on the contact.", "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PatchContactResponse" } } }, "description": "The updated contact." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Malformed syntax or invalid request body." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The contact was not found." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The email address is already associated with another contact." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Update contact", "tags": [ "Contacts" ] } }, "/v1/contacts/{contactId}/address-book": { "get": { "description": "Returns paginated addresses for the contact. When there is at least one entry, exactly one is the default shipping address (defaultShippingAddressId and each entry's defaultShipping reflect this). The default shipping address (when present) is always included on the first page of results. Requires OAuth website scope website.contacts.read or website.contacts, or API key scope CONTACT_READONLY or CONTACT, or OAuth website scope website.profiles.read or website.profiles (OAuth only).", "operationId": "getAddressBook", "parameters": [ { "description": "The contact's ID.", "in": "path", "name": "contactId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64a7e3d2c8f1b95e30a14d2b" } } }, { "description": "number of contacts to retrieve per request", "in": "query", "name": "pageSize", "required": false, "schema": { "maximum": 1000, "minimum": 0, "type": "integer", "format": "int32", "default": 50 } }, { "description": "where next page of results begins. should be {pagination.nextPageCursor} from previous response.", "in": "query", "name": "cursor", "required": false, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GetAddressBookResponse" } } }, "description": "Paginated list of the contact's addresses. When there is at least one entry, the first page always includes the default shipping address, and defaultShippingAddressId identifies it. On later pages, addressBookEntries is the next slice only; defaultShippingAddressId is present only when the default shipping entry appears in that slice." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The contact was not found." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Get address book", "tags": [ "Contacts" ] }, "post": { "description": "Creates a new address book entry for the contact. If this is the contact's only address book entry after creation, it becomes the default shipping address even when defaultShipping is false. Requires OAuth website scope website.contacts, or API key scope CONTACT, or OAuth website scope website.profiles (OAuth only).", "operationId": "createAddressBookEntry", "parameters": [ { "description": "The contact's ID.", "in": "path", "name": "contactId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64a7e3d2c8f1b95e30a14d2b" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateAddressBookEntryRequest" } } }, "description": "The address book entry to create.", "required": true }, "responses": { "201": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateAddressBookEntryResponse" } } }, "description": "The created address book entry." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Invalid input or malformed JSON." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The contact was not found." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Create address book entry", "tags": [ "Contacts" ] } }, "/v1/contacts/{contactId}/address-book/{addressBookEntryId}": { "delete": { "description": "Deletes the address book entry for the contact. If the deleted entry was the default shipping address, another entry is assigned as the default. Requires OAuth website scope website.contacts, or API key scope CONTACT, or OAuth website scope website.profiles (OAuth only).", "operationId": "deleteAddressBookEntry", "parameters": [ { "description": "The contact's ID.", "in": "path", "name": "contactId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64a7e3d2c8f1b95e30a14d2b" } } }, { "description": "The address book entry's ID.", "in": "path", "name": "addressBookEntryId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "5f8d0d55b54764421b7156aa" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "204": { "description": "No content." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The contact or address book entry was not found." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Delete address book entry", "tags": [ "Contacts" ] }, "get": { "description": "Returns a single address book entry for the contact. Requires OAuth website scope website.contacts.read or website.contacts, or API key scope CONTACT_READONLY or CONTACT, or OAuth website scope website.profiles.read or website.profiles (OAuth only).", "operationId": "getAddressBookEntry", "parameters": [ { "description": "The contact's ID.", "in": "path", "name": "contactId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64a7e3d2c8f1b95e30a14d2b" } } }, { "description": "The address book entry's ID.", "in": "path", "name": "addressBookEntryId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "5f8d0d55b54764421b7156aa" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GetAddressBookEntryResponse" } } }, "description": "The requested address book entry." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The contact or address book entry was not found." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Get address book entry", "tags": [ "Contacts" ] }, "put": { "description": "Replaces an address book entry for the contact with a full JSON body. When updating the entry that is currently the default, setting \"defaultShipping\" from true to false has no effect. Requires OAuth website scope website.contacts, or API key scope CONTACT, or OAuth website scope website.profiles (OAuth only).", "operationId": "updateAddressBookEntry", "parameters": [ { "description": "The contact's ID.", "in": "path", "name": "contactId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "64a7e3d2c8f1b95e30a14d2b" } } }, { "description": "The address book entry's ID.", "in": "path", "name": "addressBookEntryId", "required": true, "schema": { "type": "string" }, "examples": { "default": { "value": "5f8d0d55b54764421b7156aa" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateAddressBookEntryRequest" } } }, "description": "The replacement address book entry.", "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateAddressBookEntryResponse" } } }, "description": "The updated address book entry." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Invalid input or malformed JSON." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The contact or address book entry was not found." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Replace address book entry", "tags": [ "Contacts" ] } }, "/v1/fulfillments/fulfillment-options": { "get": { "description": "Returns a list of fulfillment option IDs and carrier services that can be used with discounts. Requires OAuth website scope website.discounts.read or website.discounts, or API key scope DISCOUNTS_READONLY or DISCOUNTS.", "operationId": "getFulfillmentOptions", "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/FulfillmentOptionsList" } } }, "description": "List of fulfillment option IDs and carrier services for the website." }, "403": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Forbidden. Insufficient scope (OAuth or API key), or the requested resource is not accessible for the authenticated website." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Rate limit exceeded." } }, "summary": "Get fulfillment options", "tags": [ "Discounts" ], "parameters": [ { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ] } }, "/v2/commerce/products": { "get": { "description": "Retrieves information for products; products can be filtered within a date range and by product type. The response contains product information in a Product, up to 50 Products ordered by their modification date (modifiedOn), and supports dynamic cursors for pagination.", "operationId": "getProducts", "parameters": [ { "in": "query", "name": "modifiedAfter", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "modifiedBefore", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "cursor", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "query", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "type", "required": false, "schema": { "type": "array", "items": { "type": "string" } } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PaginatedProductListResponseV2" } } }, "description": "A paginated list of products." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The cursor parameter contains an invalid value." } }, "summary": "List products", "tags": [ "Products" ] }, "post": { "description": "Creates a product with appropriate subresources based on product type.", "operationId": "createProduct", "requestBody": { "content": { "application/json": { "schema": { "oneOf": [ { "$ref": "#/components/schemas/CreateGiftCardProductRequest" }, { "$ref": "#/components/schemas/CreatePhysicalProductRequest" }, { "$ref": "#/components/schemas/CreateServiceProductRequest" } ] } } }, "required": true }, "responses": { "201": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProductV2" } } }, "description": "The product was created successfully." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The request body does not conform to the required specification." }, "405": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Method not allowed. The Product requested is not a supported product type for this operation." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. The request conflicts with the current state of the resource." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Create product", "tags": [ "Products" ], "parameters": [ { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ] } }, "/v2/commerce/products/{productIdCsvs}": { "get": { "description": "Retrieves information for specific products, including information for any variants or images. Up to 50 products can be retrieved per request.", "operationId": "getSpecificProducts", "parameters": [ { "in": "path", "name": "productIdCsvs", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProductListResponseV2" } } }, "description": "The requested products." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The provided product IDs are invalid or exceed the maximum of 50." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. One or more requested Products were not found." } }, "summary": "Get products", "tags": [ "Products" ] } }, "/v2/commerce/products/{productId}": { "delete": { "description": "Delete specified product", "operationId": "deleteProduct", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "204": { "description": "The Product was deleted successfully." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The requested Product was not found." }, "405": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Method not allowed. The Product requested is not a supported product type for this operation." } }, "summary": "Delete specified product", "tags": [ "Products" ] }, "post": { "description": "Updates information for a product. The endpoint supports partial updates.", "operationId": "updateProduct", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateProductRequest" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProductV2" } } }, "description": "Return the updated Product" }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The request body does not conform to the required specification." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The requested Product was not found." }, "405": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Method not allowed. The Product requested is not a supported product type for this operation." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. The provided URL slug is already in use." } }, "summary": "Update product", "tags": [ "Products" ] } }, "/v2/commerce/products/{productId}/images": { "post": { "description": "Uploads an image for a product. Uploading an image doesn't set the product's featured image. A successful request creates a ProductImage subresource of the Product.", "operationId": "uploadProductImage", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "multipart/form-data": {} }, "required": true }, "responses": { "202": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UploadProductImageResponse" } } }, "description": "The request was accepted and the uploaded image is being processed." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The request body does not conform to specification." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The requested Product was not found." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. The specified Product has reached its limit of 100 images." } }, "summary": "Upload product image", "tags": [ "Products" ] } }, "/v2/commerce/products/{productId}/images/{imageId}": { "delete": { "description": "Delete one product image", "operationId": "deleteProductImage", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "path", "name": "imageId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "204": { "description": "The ProductImage was deleted successfully." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. Either the Product or the ProductImage was not found." } }, "summary": "Delete one product image", "tags": [ "Products" ] }, "post": { "description": "Updates information for a product image. Currently, the endpoint only supports updates to the alt text for an image.", "operationId": "updateProductImage", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "path", "name": "imageId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateProductImageRequest" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProductImage" } } }, "description": "Return the updated ProductImage" }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The request body does not conform to the required specification." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. Either the Product or the ProductImage was not found." } }, "summary": "Update product image", "tags": [ "Products" ] } }, "/v2/commerce/products/{productId}/images/{imageId}/order": { "post": { "description": "Updates the ordering of a product image on the product details page.", "operationId": "updateProductImageOrder", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "path", "name": "imageId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateProductImageOrderRequest" } } }, "required": true }, "responses": { "204": { "description": "The request was successful." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The request body does not conform to the required specification." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The ProductImage specified in the URL was not found." }, "405": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Method not allowed. The Product requested is not a supported product type for this operation." } }, "summary": "Update product image order", "tags": [ "Products" ] } }, "/v2/commerce/products/{productId}/images/{imageId}/status": { "get": { "description": "Retrieves the processing status for an uploaded product image. A successful request indicates that a ProductImage is processing, ready, or in an error state.", "operationId": "getProductImageProcessingStatus", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "path", "name": "imageId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProductImageProcessingStatus" } } }, "description": "Return the processing status for the ProductImage" }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. Either the Product or the ProductImage was not found." } }, "summary": "Get image processing status", "tags": [ "Products" ] } }, "/v2/commerce/products/{productId}/variants": { "post": { "description": "Creates a variant of a product. Creating a variant for a physical or service product requires that the product already has at least one attribute.", "operationId": "createProductVariant", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateVariantRequestV2" } } }, "required": true }, "responses": { "201": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProductVariantV2" } } }, "description": "The ProductVariant was created successfully." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The request body does not conform to the required specification." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The requested Product was not found." }, "405": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Method not allowed. The Product requested does not support variants." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. The provided SKU is already in use by the requested Product, or the Product has reached its limit of 250 variants." } }, "summary": "Create product variant", "tags": [ "Products" ] } }, "/v2/commerce/products/{productId}/variants/{variantId}": { "delete": { "description": "Delete one product variant", "operationId": "deleteProductVariant", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "path", "name": "variantId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "204": { "description": "The ProductVariant was deleted successfully." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. Either the Product or the ProductVariant was not found." }, "405": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Method not allowed. The Product requested does not support variants." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. The ProductVariant requested is the only variant for the Product and cannot be deleted." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Delete one product variant", "tags": [ "Products" ] }, "post": { "description": "Updates a variant of a product. The endpoint supports partial updates.", "operationId": "updateProductVariant", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "path", "name": "variantId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateVariantRequestV2" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProductVariantV2" } } }, "description": "Return the updated ProductVariant" }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The request body does not conform to the required specification." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. Either the Product or the ProductVariant was not found." }, "405": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Method not allowed. The Product requested does not support variants." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. The provided SKU is already in use by the requested Product." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Update product variant", "tags": [ "Products" ] } }, "/v2/commerce/products/{productId}/variants/{variantId}/image": { "post": { "description": "Assigns a product image to a product variant. Specifying imageId of null will delete the association.", "operationId": "associateProductVariantImage", "parameters": [ { "in": "path", "name": "productId", "required": true, "schema": { "type": "string" } }, { "in": "path", "name": "variantId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AssociateProductImageToVariantRequest" } } } }, "responses": { "204": { "description": "The request was successful." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The imageId field does not represent a ProductImage belonging to the specified Product." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. Either the Product or the ProductVariant was not found." }, "405": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Method not allowed. The Product requested does not support variants." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Associate variant image", "tags": [ "Products" ] } }, "/1.0/authorization/member": { "get": { "description": "Retrieves basic details about the Squarespace member who owns the provided OAuth token", "operationId": "getMemberProfile", "parameters": [ { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MemberProfile" } } }, "description": "OK" }, "401": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MemberProfile" } } }, "description": "Authorization error" }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The API version is not supported." } }, "summary": "Retrieves basic details about the Squarespace member who owns the provided OAuth token", "tags": [ "Websites" ] } }, "/1.0/authorization/website": { "get": { "description": "Retrieves basic details about the website that owns the provided API key or OAuth token", "operationId": "getWebsiteProfile", "parameters": [ { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebsiteProfile" } } }, "description": "OK" }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The API version is not supported." } }, "summary": "Retrieves basic details about the website that owns the provided API key or OAuth token", "tags": [ "Websites" ] } }, "/1.0/commerce/inventory": { "get": { "description": "Retrieves real-time stock information for all product variants. Stock information is stored in an InventoryItem for each product variant. The response contains up to 50 InventoryItems and supports dynamic cursors for pagination.", "operationId": "getInventoryItems", "parameters": [ { "description": "Identifies where the next page of results should begin. Should be the value of pagination.nextPageCursor from a previous response. If not present or empty, the endpoint returns up to 50 InventoryItems.", "in": "query", "name": "cursor", "required": false, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PaginatedInventoryItemListResponse" } } }, "description": "OK" }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad Request. Type: INVALID_REQUEST_ERROR. The cursor parameter contains an invalid value." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The API version is not supported." } }, "summary": "List inventory", "tags": [ "Inventory" ] } }, "/1.0/commerce/inventory/adjustments": { "post": { "description": "Adjusts stock quantities for product variants. Stock quantities can be added or subtracted, set with a given number, or marked as \"unlimited\". All quantity information is stored in InventoryItems.", "operationId": "adjustInventoryStockLevels", "parameters": [ { "description": "Required for idempotent requests. Refer to the idempotency key guide for requirements.", "in": "header", "name": "Idempotency-Key", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateInventoryAdjustmentRequest" } } } }, "responses": { "204": { "description": "No content. The request was successful. If this is a request with a previously used Idempotency-Key, the previous operation was successful and no new changes were made." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad Request. Type: INVALID_REQUEST_ERROR. The request body is missing a required field or a field is an incorrect type; no operations were specified; greater than 50 operations were specified; one or more InventoryItems were not found; the same InventoryItem was referenced in more than one operation; a specified quantity is invalid; or the Idempotency-Key header is missing or invalid." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The API version is not supported." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. Type: CONFLICT. Possible subtypes: CONCURRENT_MODIFICATION (a request using the provided Idempotency-Key is already in progress, or a request modifying one or more of the specified InventoryItems could not be completed due to an overlapping request), INSUFFICIENT_STOCK (a decrement operation cannot be completed because the referenced InventoryItem does not have sufficient stock), STOCK_EXCEEDS_MAX (an increment operation cannot be completed because the referenced InventoryItem will exceed the maximum allowed stock), STOCK_NOT_TRACKED (an increment or decrement operation cannot be completed because the referenced InventoryItem has unlimited inventory)." } }, "summary": "Adjust stock quantities", "tags": [ "Inventory" ] } }, "/1.0/commerce/inventory/{variantIdCsvs}": { "get": { "description": "Retrieves real-time stock information for specific product variants. Stock information is stored in an InventoryItem and up to 50 InventoryItems can be retrieved per request.", "operationId": "getSpecificInventoryItems", "parameters": [ { "description": "Specifies the InventoryItems to retrieve. Multiple InventoryItems can be retrieved by providing a comma-separated list: {id1},{id2}..., though the same sequence is not guaranteed in the response.", "in": "path", "name": "variantIdCsvs", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/InventoryItemListResponse" } } }, "description": "OK" }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad Request. Type: INVALID_REQUEST_ERROR. ids specifies greater than 50 InventoryItems." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not Found. Type: INVALID_REQUEST_ERROR. Subtype: INVALID_ARGUMENT. One or more requested InventoryItems were not found." } }, "summary": "Get inventory", "tags": [ "Inventory" ] } }, "/1.0/commerce/orders": { "get": { "description": "Retrieves information about all orders. Orders can be filtered by Customer ID and date ranges. The response contains order information in an Order, up to 50 Orders ordered by their modification date (modifiedOn), and supports dynamic cursors for pagination.", "operationId": "getOrders", "parameters": [ { "description": "Used to filter Orders by Customer ID.", "in": "query", "name": "customerId", "required": false, "schema": { "type": "string" } }, { "description": "Time-boxes the request to Orders that were modified after a given ISO 8601 UTC date and time string (YYYY-MM-DDThh:mm:ss.sZ). Required when modifiedBefore is passed; cannot be used with cursor.", "in": "query", "name": "modifiedAfter", "required": false, "schema": { "type": "string" } }, { "description": "Time-boxes the request to Orders that were modified before a given ISO 8601 UTC date and time string (YYYY-MM-DDThh:mm:ss.sZ). Required when modifiedAfter is passed; cannot be used with cursor.", "in": "query", "name": "modifiedBefore", "required": false, "schema": { "type": "string" } }, { "description": "Identifies where the next page of results should begin. Should be the value of pagination.nextPageCursor from a previous response. Cannot be used with other parameters.", "in": "query", "name": "cursor", "required": false, "schema": { "type": "string" } }, { "description": "Used to filter Orders by fulfillment status. Values may be PENDING, FULFILLED, or CANCELED.", "in": "query", "name": "fulfillmentStatus", "required": false, "schema": { "type": "string" } }, { "description": "Used to filter Orders by payment state. Accepts a comma-separated list of values. Possible values are: NOT_CHARGED, AUTHORIZED, PAID, REFUNDED, PENDING, FAILED, REFUND_PENDING, REFUND_FAILED, PARTIALLY_PAID. If not specified, defaults to NOT_CHARGED, AUTHORIZED, PAID, and REFUNDED.", "in": "query", "name": "paymentStates", "required": false, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OrderListResponse" } } }, "description": "A paginated list of orders." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The cursor parameter contains an invalid value, cursor was specified with other parameters, modifiedAfter or modifiedBefore is not a valid ISO 8601 UTC date and time string, paymentStates is not a valid value, modifiedBefore occurred before or at the same time as modifiedAfter, fulfillmentStatus is not one of the recognized values, or modifiedAfter or modifiedBefore was specified without the other parameter." } }, "summary": "List orders", "tags": [ "Orders" ] }, "post": { "description": "Creates an order using information from a third-party sales channel. A successful request creates an Order resource.", "operationId": "createOrder", "parameters": [ { "description": "Idempotency key to prevent duplicate order creation.", "in": "header", "name": "Idempotency-Key", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateOrderRequest" } } } }, "responses": { "201": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Order" } } }, "description": "The created order." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The request body does not conform to the required specification, the Idempotency-Key header is missing or invalid, or the provided Idempotency-Key has already been used by another request bearing a different body." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. A request using the provided Idempotency-Key is already in progress, or one or more specified product variants have insufficient stock." }, "429": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Too many requests. The rate limit for this endpoint has been exceeded." } }, "summary": "Create order", "tags": [ "Orders" ] } }, "/1.0/commerce/orders/{id}": { "get": { "description": "Retrieves information for a specific order. The response contains order information in an Order.", "operationId": "getOrder", "parameters": [ { "description": "Specifies the Order to retrieve.", "in": "path", "name": "id", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Order" } } }, "description": "The requested order." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The id is not in the expected format." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The requested Order was not found." } }, "summary": "Get order", "tags": [ "Orders" ] } }, "/1.0/commerce/orders/{id}/fulfillments": { "post": { "description": "Updates the status of a specific order to fulfilled, with options to include shipment information and send a customer notification.", "operationId": "fulfillOrder", "parameters": [ { "description": "Specifies the Order to update.", "in": "path", "name": "id", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OrderFulfillmentRequest" } } } }, "responses": { "204": { "description": "No content. The order was successfully fulfilled." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. One or more trackingUrls are invalid, or one or more required fields are missing." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The requested Order was not found." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Conflict. A request using the provided Order is already in progress." } }, "summary": "Fulfill order", "tags": [ "Orders" ] } }, "/1.0/commerce/store_pages": { "get": { "description": "Retrieves information for all store pages on the website. The response supports dynamic cursors for pagination.", "operationId": "getStorePages", "parameters": [ { "in": "query", "name": "cursor", "required": false, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PaginatedStorePagesResponse" } } }, "description": "OK" }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The API version is not supported." } }, "summary": "List store pages", "tags": [ "Websites" ] } }, "/1.0/commerce/transactions": { "get": { "description": "Retrieves all financial transactions for orders and donations. Per order and donation, the response groups transactions into a Document, contains up to 50 Documents ordered by their modification date (modifiedOn), and supports dynamic cursors for pagination.", "operationId": "getDocumentsByUpdatedOn", "parameters": [ { "description": "Identifies where the next page of results should begin. Should be the value of pagination.nextPageCursor from a previous response.", "in": "query", "name": "cursor", "required": false, "schema": { "type": "string" } }, { "description": "Time-boxes the request to Documents that were modified after a given ISO 8601 UTC date and time string (YYYY-MM-DDThh:mm:ss.sZ).", "in": "query", "name": "modifiedAfter", "required": false, "schema": { "type": "string" } }, { "description": "Time-boxes the request to Documents that were modified before a given ISO 8601 UTC date and time string (YYYY-MM-DDThh:mm:ss.sZ).", "in": "query", "name": "modifiedBefore", "required": false, "schema": { "type": "string" } }, { "in": "query", "name": "orderId", "required": false, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PaginatedTransactionListResponse" } } }, "description": "A paginated list of transaction documents." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. The cursor parameter contains an invalid value." } }, "summary": "List transactions", "tags": [ "Transactions" ] } }, "/1.0/commerce/transactions/{documentIds}": { "get": { "description": "Retrieves information for specific transaction Documents. The response contains up to 50 Documents. Multiple Documents can be retrieved by providing a comma-separated list of Document ids.", "operationId": "getDocumentsById", "parameters": [ { "description": "Specifies the Documents to retrieve. Multiple Documents can be retrieved by providing a comma-separated list of Document ids.", "in": "path", "name": "documentIds", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TransactionListResponse" } } }, "description": "The requested transaction documents." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. ids specifies greater than 50 Documents." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. One or more requested Documents were not found." } }, "summary": "Get transactions", "tags": [ "Transactions" ] } }, "/1.0/profiles": { "get": { "description": "Retrieves all profiles; profiles can be filtered and sorted. The response contains up to 50 Profiles and supports dynamic cursors for pagination.", "operationId": "getProfiles", "parameters": [ { "description": "Identifies the sort direction of the result list; asc for ascending or dsc for descending. If not specified, the returned list is in descending order.", "in": "query", "name": "sortDirection", "required": false, "schema": { "type": "string" } }, { "description": "Identifies the sort field of the result list. Values include: createdOn, id, email, or lastName. If not specified, the returned list is sorted by id.", "in": "query", "name": "sortField", "required": false, "schema": { "type": "string" } }, { "description": "Semicolon separated list used to filter profile results. Values include: isCustomer and/or hasAccount, or email. The email filter cannot be used with isCustomer or hasAccount.", "in": "query", "name": "filter", "required": false, "schema": { "type": "string" } }, { "description": "Email address filter (URL-encoded, case insensitive).", "in": "query", "name": "email", "required": false, "schema": { "type": "string" } }, { "description": "Identifies where the next page of results should begin. Should be the value of pagination.nextPageCursor from a previous response. Cannot be used with other parameters.", "in": "query", "name": "cursor", "required": false, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PaginatedProfileListResponse" } } }, "description": "A paginated list of profiles." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The API version is not supported." } }, "summary": "List profiles", "tags": [ "Profiles" ] } }, "/1.0/profiles/{profileIdCsvs}": { "get": { "description": "Retrieves information for specific profiles. The response contains a list of up to 50 Profiles. Multiple Profiles can be retrieved by providing a comma-separated list of profile ids.", "operationId": "getSpecificProfiles", "parameters": [ { "description": "Specifies the profiles to retrieve. Multiple Profiles can be retrieved by providing a comma-separated list of profile ids.", "in": "path", "name": "profileIdCsvs", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProfileListResponse" } } }, "description": "The requested profiles." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Bad request. ids specifies greater than 50 profiles." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. One or more profiles were not found." } }, "summary": "Get profiles", "tags": [ "Profiles" ] } }, "/1.0/webhook_subscriptions": { "get": { "description": "Retrieves information for all webhook subscriptions. The response contains up to 25 Webhook Subscriptions. Requires an OAuth access token; API keys are not supported.", "operationId": "getWebhookSubscriptions", "parameters": [ { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExternalWebhookSubscriptionListResponse" } } }, "description": "OK" }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The API version is not supported." } }, "summary": "List webhook subscriptions", "tags": [ "WebhookSubscriptions" ] }, "post": { "callbacks": { "address.create": { "{$request.body#/endpointUrl}": { "post": { "description": "Address created details pushed to the registered callback URL", "operationId": "createAddressEvent", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddressCreatePayload" } } }, "description": "address.create event details payload", "required": true }, "responses": { "200": { "description": "Notification received by the external service." } } } } }, "address.delete": { "{$request.body#/endpointUrl}": { "post": { "description": "Address delete details pushed to the registered callback URL", "operationId": "deleteAddressEvent", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddressDeletePayload" } } }, "description": "address.delete event details payload", "required": true }, "responses": { "200": { "description": "Notification received by the external service." } } } } }, "address.update": { "{$request.body#/endpointUrl}": { "post": { "description": "Address update details pushed to the registered callback URL", "operationId": "updateAddressEvent", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddressUpdatePayload" } } }, "description": "address.update event details payload", "required": true }, "responses": { "200": { "description": "Notification received by the external service." } } } } }, "contact.create": { "{$request.body#/endpointUrl}": { "post": { "description": "Contact created details pushed to the registered callback URL", "operationId": "createContactEvent", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ContactCreatePayload" } } }, "description": "contact.create event details payload", "required": true }, "responses": { "200": { "description": "Notification received by the external service." } } } } }, "contact.delete": { "{$request.body#/endpointUrl}": { "post": { "description": "Contact delete details pushed to the registered callback URL", "operationId": "deleteContactEvent", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ContactDeletePayload" } } }, "description": "contact.delete event details payload", "required": true }, "responses": { "200": { "description": "Notification received by the external service." } } } } }, "contact.update": { "{$request.body#/endpointUrl}": { "post": { "description": "Contact update details pushed to the registered callback URL", "operationId": "updateContactEvent", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ContactUpdatePayload" } } }, "description": "contact.update event details payload", "required": true }, "responses": { "200": { "description": "Notification received by the external service." } } } } }, "extension.uninstall": { "{$request.body#/endpointUrl}": { "post": { "description": "Extension uninstalled details pushed to the registered callback URL", "operationId": "uninstallExtensionEvent", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExtensionUninstallPayload" } } }, "description": "extension.uninstall event details payload", "required": true }, "responses": { "200": { "description": "Notification received by the external service." } } } } }, "order.create": { "{$request.body#/endpointUrl}": { "post": { "description": "Order created details pushed to the registered callback URL", "operationId": "createOrderEvent", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OrderCreatePayload" } } }, "description": "order.create event details payload", "required": true }, "responses": { "200": { "description": "Notification received by the external service." } } } } }, "order.update": { "{$request.body#/endpointUrl}": { "post": { "description": "Order update details pushed to the registered callback URL", "operationId": "updateOrderEvent", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OrderUpdatePayload" } } }, "description": "order.update event details payload", "required": true }, "responses": { "200": { "description": "Notification received by the external service." } } } } } }, "description": "Creates a webhook subscription. A successful request returns the created Webhook Subscription resource. Requires an OAuth access token; API keys are not supported. The OAuth token must hold scopes appropriate for each subscribed event topic: order.create and order.update require website.orders or website.orders.read; contact.create, contact.update, contact.delete, address.create, address.update, and address.delete require website.contacts; extension.uninstall requires no event-specific scope.", "operationId": "createWebhookSubscription", "parameters": [ { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExternalCreateWebhookSubscriptionRequest" } } }, "description": "Subscription details", "required": true }, "responses": { "201": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExternalCreateWebhookSubscriptionResponse" } } }, "description": "The created webhook subscription." }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Invalid input or malformed JSON" }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "Not found. The API version is not supported." }, "409": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The Squarespace website has reached its limit of 25 webhook subscriptions." } }, "summary": "Create webhook subscription", "tags": [ "WebhookSubscriptions" ] } }, "/1.0/webhook_subscriptions/{subscriptionId}": { "delete": { "description": "Deletes a webhook subscription. Requires an OAuth access token; API keys are not supported.", "operationId": "deleteWebhookSubscription", "parameters": [ { "description": "Specifies the Webhook Subscription to delete.", "in": "path", "name": "subscriptionId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "204": { "description": "No content. The webhook subscription was deleted successfully." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The requested Webhook Subscription was not found." } }, "summary": "Delete webhook subscription", "tags": [ "WebhookSubscriptions" ] }, "get": { "description": "Retrieves information for a specific webhook subscription. Requires an OAuth access token; API keys are not supported.", "operationId": "getWebhookSubscription", "parameters": [ { "description": "Specifies the Webhook Subscription to retrieve.", "in": "path", "name": "subscriptionId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExternalWebhookSubscriptionResponse" } } }, "description": "OK" }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The requested Webhook Subscription was not found." } }, "summary": "Get webhook subscription", "tags": [ "WebhookSubscriptions" ] }, "post": { "description": "Updates information for a webhook subscription. A successful request returns the updated Webhook Subscription resource. Requires an OAuth access token; API keys are not supported. The OAuth token must hold scopes appropriate for each subscribed event topic: order.create and order.update require website.orders or website.orders.read; contact.create, contact.update, contact.delete, address.create, address.update, and address.delete require website.contacts; extension.uninstall requires no event-specific scope.", "operationId": "updateWebhookSubscription", "parameters": [ { "description": "Specifies the Webhook Subscription to update.", "in": "path", "name": "subscriptionId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExternalUpdateWebhookSubscriptionRequest" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExternalWebhookSubscriptionResponse" } } }, "description": "OK" }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The request body does not conform to the required specification." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The requested Webhook Subscription was not found." } }, "summary": "Update webhook subscription", "tags": [ "WebhookSubscriptions" ] } }, "/1.0/webhook_subscriptions/{subscriptionId}/actions/rotateSecret": { "post": { "description": "Rotates a webhook subscription's secret. The previous secret for a subscription is no longer valid after a new one is generated. Requires an OAuth access token; API keys are not supported.", "operationId": "rotateSubscriptionSecret", "parameters": [ { "description": "Specifies the Webhook Subscription to update.", "in": "path", "name": "subscriptionId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExternalRotateSecretResponse" } } }, "description": "OK" }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The requested Webhook Subscription was not found." } }, "summary": "Rotate webhook subscription secret", "tags": [ "WebhookSubscriptions" ] } }, "/1.0/webhook_subscriptions/{subscriptionId}/actions/sendTestNotification": { "post": { "description": "Sends a notification to a subscribed webhook endpoint for testing purposes. This is a one-time notification, and will not be retried if it fails or times out. Requires an OAuth access token; API keys are not supported.", "operationId": "sendTestNotificationForWebhookSubscription", "parameters": [ { "description": "Specifies the Webhook Subscription to send a notification to.", "in": "path", "name": "subscriptionId", "required": true, "schema": { "type": "string" } }, { "in": "header", "name": "Authorization", "required": true, "description": "API key or OAuth access token", "schema": { "type": "string", "default": "Bearer YOUR_API_KEY_OR_OAUTH_TOKEN" } }, { "in": "header", "name": "User-Agent", "required": true, "description": "User Agent", "schema": { "type": "string", "default": "YOUR_CUSTOM_APP_DESCRIPTION" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExternalSendTestNotificationRequest" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExternalTestNotificationResponse" } } }, "description": "OK" }, "400": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The request body does not conform to the required specification." }, "404": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StandardErrorPayload" } } }, "description": "The requested Webhook Subscription was not found." } }, "summary": "Send test notification", "tags": [ "WebhookSubscriptions" ] } } }, "components": { "schemas": { "AcceptsMarketing": { "type": "object", "properties": { "acceptsMarketing": { "type": "boolean", "description": "Whether the contact accepts marketing email." }, "joinedOn": { "type": "string", "description": "The date and time the contact was added to the marketing list.The value returned in the creation response is a near-real-time estimate; the Get Contact endpoint should be used to verify the exact persisted timestamp.", "format": "date-time" }, "leftOn": { "type": "string", "description": "The date and time the contact left Marketing list", "format": "date-time" } }, "description": "Marketing subscription state for the contact's email." }, "AcceptsMarketingWithDate": { "type": "object", "properties": { "acceptsMarketing": { "type": "boolean", "description": "If contact's email accepts marketing" }, "joinedOn": { "$ref": "#/components/schemas/DateFilter" } }, "description": "Contact's marketing settings with joined on date" }, "Address": { "type": "object", "properties": { "address1": { "type": "string", "description": "Primary street address", "examples": [ "459 Broadway" ] }, "address2": { "type": "string", "description": "Secondary address line" }, "city": { "type": "string", "description": "City", "examples": [ "New York" ] }, "countryCode": { "type": "string", "description": "ISO 3166-1 alpha-2 country code", "examples": [ "US" ] }, "firstName": { "type": "string", "description": "First name", "examples": [ "Bob" ] }, "lastName": { "type": "string", "description": "Last name", "examples": [ "Loblaw" ] }, "phone": { "type": "string", "description": "Phone number", "examples": [ "5553334444" ] }, "postalCode": { "type": "string", "description": "Postal or ZIP code", "examples": [ "10003" ] }, "state": { "type": "string", "description": "State or province", "examples": [ "NY" ] } }, "description": "Customer's shipping address provided at checkout or, for recurring subscription orders, the customer's current mailing address." }, "AddressBook": { "type": "object", "properties": { "addressBookEntries": { "type": "array", "description": "List of Address Book Entries", "items": { "$ref": "#/components/schemas/AddressBookEntry" } }, "defaultShippingAddressId": { "type": "string", "description": "The id of the address book entry that is the default shipping address." } }, "description": "Address settings for a contact. When there is at least one address book entry, exactly one is the default shipping address; default shipping address is always returned on the first page of paginated results)." }, "AddressBookEntry": { "type": "object", "properties": { "address": { "$ref": "#/components/schemas/ContactAddress" }, "defaultShipping": { "type": "boolean", "description": "Whether this entry is the current default shipping address. When the contact has any address book entries, exactly one entry has this value set to true." }, "id": { "type": "string", "description": "The address book entry's ID.", "readOnly": true, "examples": [ "5f8d0d55b54764421b7156aa" ] } }, "description": "An address book entry for a contact." }, "AddressCreateData": { "required": [ "addressBookEntries", "contactId" ], "type": "object", "properties": { "addressBookEntries": { "type": "array", "description": "The address book entries that were created.", "items": { "$ref": "#/components/schemas/AddressBookEntry" } }, "contactId": { "type": "string", "description": "The contact's ID.", "examples": [ "64a7e3d2c8f1b95e30a14d2b" ] }, "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of the address book entries.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] } }, "description": "The address data for the created address book entries." }, "AddressCreatePayload": { "required": [ "createdOn", "id", "subscriptionsId", "topic", "websiteId" ], "type": "object", "properties": { "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of this message.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "data": { "$ref": "#/components/schemas/AddressCreateData" }, "id": { "type": "string", "description": "Unique notification id.", "examples": [ "5c2ba184b63ed3cb411ce2b1" ] }, "subscriptionsId": { "type": "string", "description": "Unique Webhook Subscriptions id.", "examples": [ "5f3c2155d947844beedda991" ] }, "topic": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "default": "address.create", "enum": [ "address.create" ], "examples": [ "address.create" ] }, "websiteId": { "type": "string", "description": "Squarespace website id that triggered the notification.", "examples": [ "5f3c3d55ac435e1a051f77b3" ] } } }, "AddressDeleteData": { "required": [ "addressBookEntryIds", "contactId" ], "type": "object", "properties": { "addressBookEntryIds": { "type": "array", "description": "The IDs of the deleted address book entries.", "items": { "type": "string", "description": "The IDs of the deleted address book entries." } }, "contactId": { "type": "string", "description": "The contact's ID.", "examples": [ "64a7e3d2c8f1b95e30a14d2b" ] }, "deletedOn": { "type": "string", "description": "Deletion date and time in UTC (ISO 8601 format) of the address book entries.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] } }, "description": "Identifiers and metadata for the deleted address book entries." }, "AddressDeletePayload": { "required": [ "createdOn", "id", "subscriptionsId", "topic", "websiteId" ], "type": "object", "properties": { "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of this message.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "data": { "$ref": "#/components/schemas/AddressDeleteData" }, "id": { "type": "string", "description": "Unique notification id.", "examples": [ "5c2ba184b63ed3cb411ce2b1" ] }, "subscriptionsId": { "type": "string", "description": "Unique Webhook Subscriptions id.", "examples": [ "5f3c2155d947844beedda991" ] }, "topic": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "default": "address.delete", "enum": [ "address.delete" ], "examples": [ "address.delete" ] }, "websiteId": { "type": "string", "description": "Squarespace website id that triggered the notification.", "examples": [ "5f3c3d55ac435e1a051f77b3" ] } } }, "AddressRequest": { "type": "object", "properties": { "address1": { "type": "string" }, "address2": { "type": "string" }, "city": { "type": "string" }, "countryCode": { "type": "string" }, "firstName": { "type": "string" }, "lastName": { "type": "string" }, "phone": { "type": "string" }, "postalCode": { "type": "string" }, "state": { "type": "string" } }, "description": "Customer's shipping address." }, "AddressUpdateData": { "required": [ "addressBookEntries", "contactId" ], "type": "object", "properties": { "addressBookEntries": { "type": "array", "description": "The address book entries after the update.", "items": { "$ref": "#/components/schemas/AddressBookEntry" } }, "contactId": { "type": "string", "description": "The contact's ID.", "examples": [ "64a7e3d2c8f1b95e30a14d2b" ] }, "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of the address book entries.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "updatedOn": { "type": "string", "description": "Last update date and time in UTC (ISO 8601 format) of the address book entries.", "format": "date-time", "examples": [ "2024-02-15T14:30:00Z" ] } }, "description": "The address data after the update." }, "AddressUpdatePayload": { "required": [ "createdOn", "id", "subscriptionsId", "topic", "websiteId" ], "type": "object", "properties": { "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of this message.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "data": { "$ref": "#/components/schemas/AddressUpdateData" }, "id": { "type": "string", "description": "Unique notification id.", "examples": [ "5c2ba184b63ed3cb411ce2b1" ] }, "subscriptionsId": { "type": "string", "description": "Unique Webhook Subscriptions id.", "examples": [ "5f3c2155d947844beedda991" ] }, "topic": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "default": "address.update", "enum": [ "address.update" ], "examples": [ "address.update" ] }, "websiteId": { "type": "string", "description": "Squarespace website id that triggered the notification.", "examples": [ "5f3c3d55ac435e1a051f77b3" ] } } }, "AnyOrderCriteria": { "title": "AnyOrderCriteria", "type": "object", "description": "Discount applies to any order. No additional conditions.", "required": [ "type" ], "properties": { "type": { "type": "string" } }, "discriminator": { "propertyName": "type" } }, "AssociateProductImageToVariantRequest": { "required": [ "imageId" ], "type": "object", "properties": { "imageId": { "$ref": "#/components/schemas/ChangeString" } } }, "AutoTrigger": { "title": "AutoTrigger", "type": "object", "description": "Trigger for a discount that is automatically applied; no promo code required.", "required": [ "type" ], "properties": { "type": { "type": "string" } }, "discriminator": { "propertyName": "type" } }, "BuyXGetYCriteria": { "title": "BuyXGetYCriteria", "required": [ "eligibleForDiscountQuantity", "requiredFullPriceQuantity", "type" ], "type": "object", "description": "Discount applies when the cart contains a required quantity of qualifying items (buy side), granting a discount on a quantity of eligible items (reward side).", "properties": { "type": { "type": "string" }, "criteriaAppliesTo": { "type": "string", "description": "Specifies the possible targets for a BuyXGetYCriteria buy-side.", "enum": [ "PRODUCT" ] }, "criteriaProductIds": { "uniqueItems": true, "type": "array", "description": "Product ids the cart must contain. Required if criteriaAppliesTo=PRODUCT.", "items": { "type": "string", "description": "Product ids the cart must contain. Required if criteriaAppliesTo=PRODUCT." } }, "eligibleForDiscountQuantity": { "minimum": 1, "type": "integer", "description": "Quantity of eligible items the discount applies to.", "format": "int32" }, "requiredFullPriceQuantity": { "minimum": 1, "type": "integer", "description": "Quantity of qualifying items required at full price.", "format": "int32" }, "rewardAppliesTo": { "type": "string", "description": "Specifies the possible targets for a BuyXGetYCriteria reward-side.", "enum": [ "PRODUCT" ] }, "rewardProductIds": { "uniqueItems": true, "type": "array", "description": "Product ids eligible for the reward. Required if rewardAppliesTo=PRODUCT.", "items": { "type": "string", "description": "Product ids eligible for the reward. Required if rewardAppliesTo=PRODUCT." } } }, "discriminator": { "propertyName": "type" } }, "BuyXGetYFixedAmountTemplate": { "title": "BuyXGetYFixedAmountTemplate", "required": [ "discountAmount", "type" ], "type": "object", "description": "Apply a fixed monetary amount off each reward item in a BUY_X_GET_Y discount.", "properties": { "type": { "type": "string" }, "discountAmount": { "$ref": "#/components/schemas/MonetaryAmount" }, "maxApplicationsPerCart": { "minimum": 0, "type": "integer", "description": "Caps how many times the discount can be applied per cart. 0 means unlimited.", "format": "int32" } }, "discriminator": { "propertyName": "type" } }, "BuyXGetYPercentageTemplate": { "title": "BuyXGetYPercentageTemplate", "required": [ "discountPercentage", "type" ], "type": "object", "description": "Apply a percentage discount off each reward item in a BUY_X_GET_Y discount.", "properties": { "type": { "type": "string" }, "discountPercentage": { "maximum": 100, "exclusiveMinimum": 0, "type": "number", "description": "Percentage to subtract from each reward item. Range (0, 100]." }, "maxApplicationsPerCart": { "minimum": 0, "type": "integer", "description": "Caps how many times the discount can be applied per cart. 0 means unlimited.", "format": "int32" } }, "discriminator": { "propertyName": "type" } }, "CarrierService": { "required": [ "description", "name" ], "type": "object", "properties": { "description": { "type": "string", "description": "Human-readable carrier service name.", "examples": [ "FedEx Ground®" ] }, "name": { "type": "string", "description": "Carrier service identifier.", "examples": [ "FEDEX_GROUND" ] } }, "description": "Carrier service identifier and display name." }, "CartTotalCriteria": { "title": "CartTotalCriteria", "required": [ "minimumCartTotal", "type" ], "type": "object", "description": "Discount applies when the cart total meets or exceeds a minimum.", "properties": { "type": { "type": "string" }, "minimumCartTotal": { "$ref": "#/components/schemas/MonetaryAmount" } }, "discriminator": { "propertyName": "type" } }, "ChangeBoolean": { "type": "object", "properties": { "present": { "type": "boolean" }, "value": { "type": "boolean" } } }, "ChangeListString": { "type": "object", "properties": { "present": { "type": "boolean" }, "value": { "type": "array", "items": { "type": "string" } } }, "description": "Optional; list of event topics that trigger a webhook notification. Possible values include: extension.uninstall, order.create, order.update." }, "ChangeMapStringString": { "type": "object", "properties": { "present": { "type": "boolean" }, "value": { "type": "object", "additionalProperties": { "type": "string" } } }, "description": "Specifies attribute-value pairs for the variant. Supported for PHYSICAL products only." }, "ChangeMonetaryAmount": { "type": "object", "properties": { "present": { "type": "boolean" }, "value": { "$ref": "#/components/schemas/MonetaryAmount" } } }, "ChangeProductDimensions": { "type": "object", "properties": { "present": { "type": "boolean" }, "value": { "$ref": "#/components/schemas/ProductDimensions" } } }, "ChangeProductWeight": { "type": "object", "properties": { "present": { "type": "boolean" }, "value": { "$ref": "#/components/schemas/ProductWeight" } } }, "ChangeSeoOptions": { "type": "object", "properties": { "present": { "type": "boolean" }, "value": { "$ref": "#/components/schemas/SeoOptions" } }, "description": "Options for search engine optimization." }, "ChangeString": { "type": "object", "properties": { "present": { "type": "boolean" }, "value": { "type": "string" } }, "description": "Optional; HTTPS URL to receive webhook notifications." }, "ChangeUpdateProductMeasurements": { "type": "object", "properties": { "present": { "type": "boolean" }, "value": { "$ref": "#/components/schemas/UpdateProductMeasurements" } }, "description": "Measurements of the variant when it's shipped. Supported for PHYSICAL products only." }, "ChangeUpdateProductPricing": { "type": "object", "properties": { "present": { "type": "boolean" }, "value": { "$ref": "#/components/schemas/UpdateProductPricing" } }, "description": "Pricing data for the product." }, "Contact": { "type": "object", "properties": { "createdOn": { "type": "string", "description": "The date and time when the contact was created.", "format": "date-time", "readOnly": true }, "defaultShippingAddress": { "$ref": "#/components/schemas/AddressBookEntry" }, "firstName": { "type": "string", "description": "The contact's first name." }, "id": { "type": "string", "description": "The contact's ID.", "readOnly": true, "examples": [ "64a7e3d2c8f1b95e30a14d2b" ] }, "lastName": { "type": "string", "description": "The contact's last name." }, "locale": { "type": "string", "description": "The contact's locale.", "examples": [ "en-US" ] }, "primaryEmail": { "$ref": "#/components/schemas/Email" } }, "description": "A contact." }, "ContactAddress": { "required": [ "countryCode" ], "type": "object", "properties": { "city": { "type": "string", "description": "Address' city", "examples": [ "Springfield" ] }, "countryCode": { "type": "string", "description": "ISO 3166 alpha-2 country code string.", "enum": [ "AF", "AX", "AL", "DZ", "AS", "AD", "AO", "AI", "AQ", "AG", "AR", "AM", "AW", "AU", "AT", "AZ", "BS", "BH", "BD", "BB", "BY", "BE", "BZ", "BJ", "BM", "BT", "BO", "BA", "BW", "BV", "BR", "IO", "BN", "BG", "BF", "BI", "BQ", "KH", "CM", "CA", "CV", "KY", "CF", "TD", "CL", "CN", "CX", "CC", "CO", "KM", "CG", "CD", "CK", "CR", "CI", "CW", "HR", "CU", "CY", "CZ", "DK", "DJ", "DM", "DO", "EC", "EG", "SV", "GQ", "ER", "EE", "ET", "FK", "FO", "FJ", "FI", "FR", "GF", "PF", "TF", "GA", "GM", "GE", "DE", "GH", "GI", "GR", "GL", "GD", "GP", "GU", "GT", "GG", "GN", "GW", "GY", "HT", "HM", "VA", "HN", "HK", "HU", "IS", "IN", "ID", "IR", "IQ", "IE", "IM", "IL", "IT", "JM", "JP", "JE", "JO", "KZ", "KE", "KI", "XK", "KP", "KR", "KW", "KG", "LA", "LV", "LB", "LS", "LR", "LY", "LI", "LT", "LU", "MO", "MF", "MK", "MG", "MW", "MY", "MV", "ML", "MT", "MH", "MQ", "MR", "MU", "YT", "MX", "FM", "MD", "MC", "MN", "ME", "MS", "MA", "MZ", "MM", "NA", "NR", "NP", "NL", "AN", "NC", "NZ", "NI", "NE", "NG", "NU", "NF", "MP", "NO", "OM", "PK", "PW", "PS", "PA", "PG", "PY", "PE", "PH", "PN", "PL", "PT", "PR", "QA", "RE", "RO", "RU", "RW", "BL", "SH", "KN", "LC", "PM", "VC", "WS", "SM", "ST", "SA", "SN", "RS", "SC", "SL", "SG", "SK", "SI", "SB", "SO", "SX", "ZA", "GS", "ES", "LK", "SD", "SR", "SJ", "SS", "SZ", "SY", "SE", "CH", "TW", "TJ", "TZ", "TH", "TL", "TG", "TK", "TO", "TT", "TN", "TR", "TM", "TC", "TV", "UG", "UA", "AE", "GB", "US", "UM", "UY", "UZ", "VU", "VE", "VN", "VG", "VI", "WF", "EH", "YE", "ZM", "ZW" ], "examples": [ "US" ] }, "firstName": { "type": "string", "description": "Contact's first name", "examples": [ "John" ] }, "lastName": { "type": "string", "description": "Contact's last name", "examples": [ "Doe" ] }, "line1": { "type": "string", "description": "First line of address", "examples": [ "100 Main St" ] }, "line2": { "type": "string", "description": "Second line of address", "examples": [ "Apt 1A" ] }, "phoneNumber": { "type": "string", "description": "Contact's phone number", "examples": [ "215-555-4321" ] }, "postalCode": { "type": "string", "description": "zip/postal code", "examples": [ "10900" ] }, "region": { "type": "string", "description": "General region (State, Province, County, etc...)", "examples": [ "IL" ] } }, "description": "Address properties for a contact." }, "ContactCreatePayload": { "required": [ "createdOn", "id", "subscriptionsId", "topic", "websiteId" ], "type": "object", "properties": { "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of this message.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "data": { "$ref": "#/components/schemas/Contact" }, "id": { "type": "string", "description": "Unique notification id.", "examples": [ "5c2ba184b63ed3cb411ce2b1" ] }, "subscriptionsId": { "type": "string", "description": "Unique Webhook Subscriptions id.", "examples": [ "5f3c2155d947844beedda991" ] }, "topic": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "default": "contact.create", "enum": [ "contact.create" ], "examples": [ "contact.create" ] }, "websiteId": { "type": "string", "description": "Squarespace website id that triggered the notification.", "examples": [ "5f3c3d55ac435e1a051f77b3" ] } } }, "ContactDeleteData": { "required": [ "deletedOn", "id" ], "type": "object", "properties": { "deletedOn": { "type": "string", "description": "Deletion date and time in UTC (ISO 8601 format) of the contact.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "id": { "type": "string", "description": "The contact's ID.", "examples": [ "64a7e3d2c8f1b95e30a14d2b" ] } }, "description": "Identifiers and metadata for the deleted contact." }, "ContactDeletePayload": { "required": [ "createdOn", "id", "subscriptionsId", "topic", "websiteId" ], "type": "object", "properties": { "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of this message.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "data": { "$ref": "#/components/schemas/ContactDeleteData" }, "id": { "type": "string", "description": "Unique notification id.", "examples": [ "5c2ba184b63ed3cb411ce2b1" ] }, "subscriptionsId": { "type": "string", "description": "Unique Webhook Subscriptions id.", "examples": [ "5f3c2155d947844beedda991" ] }, "topic": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "default": "contact.delete", "enum": [ "contact.delete" ], "examples": [ "contact.delete" ] }, "websiteId": { "type": "string", "description": "Squarespace website id that triggered the notification.", "examples": [ "5f3c3d55ac435e1a051f77b3" ] } } }, "ContactUpdatePayload": { "required": [ "createdOn", "id", "subscriptionsId", "topic", "websiteId" ], "type": "object", "properties": { "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of this message.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "data": { "$ref": "#/components/schemas/Contact" }, "id": { "type": "string", "description": "Unique notification id.", "examples": [ "5c2ba184b63ed3cb411ce2b1" ] }, "subscriptionsId": { "type": "string", "description": "Unique Webhook Subscriptions id.", "examples": [ "5f3c2155d947844beedda991" ] }, "topic": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "default": "contact.update", "enum": [ "contact.update" ], "examples": [ "contact.update" ] }, "websiteId": { "type": "string", "description": "Squarespace website id that triggered the notification.", "examples": [ "5f3c3d55ac435e1a051f77b3" ] } } }, "CreateAddressBookEntryRequest": { "required": [ "address" ], "type": "object", "properties": { "address": { "$ref": "#/components/schemas/ContactAddress" }, "defaultShipping": { "type": "boolean", "description": "Whether this entry should be the default shipping address. If this is the only address book entry for the contact after creation, it becomes the default even when set to false." } } }, "CreateAddressBookEntryResponse": { "type": "object", "properties": { "addressBookEntry": { "$ref": "#/components/schemas/AddressBookEntry" } } }, "CreateContactRequest": { "required": [ "firstName", "lastName", "locale", "primaryEmail" ], "type": "object", "properties": { "firstName": { "type": "string", "description": "Contact's first name", "examples": [ "john" ] }, "lastName": { "type": "string", "description": "Contact's last name", "examples": [ "doe" ] }, "locale": { "type": "string", "description": "Contact's locale", "examples": [ "en-US" ] }, "primaryEmail": { "$ref": "#/components/schemas/CreateEmail" } } }, "CreateContactResponse": { "type": "object", "properties": { "contact": { "$ref": "#/components/schemas/Contact" } } }, "CreateDiscountLineRequest": { "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "name": { "type": "string" }, "promoCode": { "type": "string" } }, "description": "Array of discount line items. Describes the promotions redeemed during checkout." }, "CreateDiscountRequest": { "required": [ "criteria", "name", "template", "trigger", "validFrom" ], "type": "object", "properties": { "criteria": { "oneOf": [ { "$ref": "#/components/schemas/AnyOrderCriteria" }, { "$ref": "#/components/schemas/BuyXGetYCriteria" }, { "$ref": "#/components/schemas/CartTotalCriteria" }, { "$ref": "#/components/schemas/ProductCriteria" } ] }, "isLimitedUses": { "type": "boolean", "description": "If true, the discount can only be used `maxUsesAllowed` times site-wide." }, "isOncePerCustomer": { "type": "boolean", "description": "If true, a given customer can only use this discount once." }, "maxUsesAllowed": { "type": "integer", "description": "Maximum site-wide redemptions. Required when isLimitedUses=true; null otherwise.", "format": "int32" }, "name": { "type": "string", "description": "Display name for the discount." }, "paymentPlanOptions": { "$ref": "#/components/schemas/PaymentPlanOptions" }, "subscriptionOptions": { "$ref": "#/components/schemas/SubscriptionOptions" }, "template": { "oneOf": [ { "$ref": "#/components/schemas/BuyXGetYFixedAmountTemplate" }, { "$ref": "#/components/schemas/BuyXGetYPercentageTemplate" }, { "$ref": "#/components/schemas/FixedAmountTemplate" }, { "$ref": "#/components/schemas/FreeShippingTemplate" }, { "$ref": "#/components/schemas/PercentageTemplate" } ] }, "trigger": { "oneOf": [ { "$ref": "#/components/schemas/AutoTrigger" }, { "$ref": "#/components/schemas/PromoCodeTrigger" } ] }, "validFrom": { "type": "string", "description": "When the discount becomes active.", "format": "date-time" }, "validTo": { "type": "string", "description": "When the discount expires. Null = no expiry.", "format": "date-time" } }, "description": "Request body for creating a discount." }, "CreateEmail": { "required": [ "email" ], "type": "object", "properties": { "acceptsMarketing": { "type": "boolean", "description": "If contact's email accepts marketing", "default": false }, "email": { "type": "string", "format": "email", "description": "The email address.", "examples": [ "jane.doe@example.com" ] } }, "description": "Primary email supplied when creating a contact." }, "CreateGiftCardProductRequest": { "title": "CreateGiftCardProductRequest", "type": "object", "description": "Request payload to create a GIFT_CARD product.", "properties": { "description": { "type": "string" }, "isVisible": { "type": "boolean" }, "name": { "type": "string" }, "storePageId": { "type": "string" }, "tags": { "type": "array", "items": { "type": "string" } }, "type": { "type": "string" }, "urlSlug": { "type": "string" }, "variants": { "type": "array", "items": { "$ref": "#/components/schemas/CreateGiftCardProductVariantRequest" } } }, "discriminator": { "propertyName": "type" } }, "CreateGiftCardProductVariantRequest": { "type": "object", "properties": { "pricing": { "$ref": "#/components/schemas/SimpleProductPricing" }, "sku": { "type": "string" } } }, "CreateInventoryAdjustmentRequest": { "type": "object", "properties": { "decrementOperations": { "type": "array", "description": "Optional; array of objects. Subtracts stock quantity for InventoryItems.", "items": { "$ref": "#/components/schemas/InventoryQuantityExpression" } }, "incrementOperations": { "type": "array", "description": "Optional; array of objects. Increments stock quantity for InventoryItems.", "items": { "$ref": "#/components/schemas/InventoryQuantityExpression" } }, "setFiniteOperations": { "type": "array", "description": "Optional; array of objects. Sets the exact stock quantity for InventoryItems.", "items": { "$ref": "#/components/schemas/InventoryQuantityExpression" } }, "setUnlimitedOperations": { "type": "array", "description": "Optional; array of InventoryItem ids. Marks stock quantity as \"unlimited\" for the given InventoryItems.", "items": { "type": "string", "description": "Optional; array of InventoryItem ids. Marks stock quantity as \"unlimited\" for the given InventoryItems." } } } }, "CreateLineItemRequest": { "required": [ "lineItemType", "quantity", "unitPricePaid" ], "type": "object", "properties": { "lineItemType": { "$ref": "#/components/schemas/OrderCreateLineItemType" }, "nonSaleUnitPrice": { "$ref": "#/components/schemas/MonetaryAmount" }, "quantity": { "type": "integer", "description": "Amount of the item purchased. 1,000,000 limit.", "format": "int32" }, "title": { "type": "string", "description": "Title of the custom line item." }, "unitPricePaid": { "$ref": "#/components/schemas/MonetaryAmount" }, "variantId": { "type": "string", "description": "Required if lineItemType is PHYSICAL_PRODUCT. Unique id of the ProductVariant sold." } }, "description": "Array of purchased line items; cannot be empty." }, "CreateOrderInventoryBehavior": { "type": "string", "description": "Indicates whether to deduct stock quantity for the product variant upon Order creation. Values may be DEDUCT or SKIP. Defaults to SKIP.", "enum": [ "DEDUCT", "SKIP" ] }, "CreateOrderRequest": { "required": [ "channelName", "createdOn", "externalOrderReference", "fulfillments", "grandTotal", "lineItems", "priceTaxInterpretation" ], "type": "object", "properties": { "billingAddress": { "$ref": "#/components/schemas/AddressRequest" }, "channelName": { "maxLength": 30, "type": "string", "description": "Name of third-party sales channel." }, "createdOn": { "type": "string", "description": "ISO 8601 UTC date and time string. Represents the date and time when the order was placed through the third-party sales channel.", "format": "date-time" }, "customerEmail": { "type": "string", "format": "email", "description": "Email address provided at checkout on the third-party sales channel.", "examples": [ "john.doe@example.com" ] }, "discountLines": { "type": "array", "description": "Array of discount line items. Describes the promotions redeemed during checkout.", "items": { "$ref": "#/components/schemas/CreateDiscountLineRequest" } }, "discountTotal": { "$ref": "#/components/schemas/MonetaryAmount" }, "externalOrderReference": { "maxLength": 200, "type": "string", "description": "Order reference identifier used by the third-party sales channel." }, "fulfilledOn": { "type": "string", "description": "ISO 8601 UTC date and time string. Represents the moment the order was fulfilled. Required if fulfillmentStatus is FULFILLED.", "format": "date-time" }, "fulfillmentStatus": { "$ref": "#/components/schemas/OrderCreateFulfillmentStatus" }, "fulfillments": { "type": "array", "description": "Array of shipping fulfillments; up to 100 entries. Describes shipment information for the order.", "items": { "$ref": "#/components/schemas/CreateOrderShipmentRequest" } }, "grandTotal": { "$ref": "#/components/schemas/MonetaryAmount" }, "inventoryBehavior": { "$ref": "#/components/schemas/CreateOrderInventoryBehavior" }, "lineItems": { "type": "array", "description": "Array of purchased line items; cannot be empty.", "items": { "$ref": "#/components/schemas/CreateLineItemRequest" } }, "priceTaxInterpretation": { "$ref": "#/components/schemas/TaxInterpretation" }, "shippingAddress": { "$ref": "#/components/schemas/AddressRequest" }, "shippingLines": { "type": "array", "description": "Array of shipping line items. Describes the shipping options chosen at checkout. Currently accepts only one shipping entry.", "items": { "$ref": "#/components/schemas/CreateShippingLineRequest" } }, "shippingTotal": { "$ref": "#/components/schemas/MonetaryAmount" }, "shopperFulfillmentNotificationBehavior": { "$ref": "#/components/schemas/ShopperFulfillmentNotificationBehavior" }, "subtotal": { "$ref": "#/components/schemas/MonetaryAmount" }, "taxTotal": { "$ref": "#/components/schemas/MonetaryAmount" } } }, "CreateOrderShipmentRequest": { "required": [ "carrierName", "service", "shipDate", "trackingNumber" ], "type": "object", "properties": { "carrierName": { "maxLength": 100, "type": "string", "description": "Name of the carrier handling the shipment." }, "service": { "maxLength": 100, "type": "string", "description": "Carrier's level of service for shipping." }, "shipDate": { "type": "string", "description": "ISO 8601 UTC date and time string. Represents the moment the shipment occurred.", "format": "date-time" }, "trackingNumber": { "maxLength": 100, "type": "string", "description": "Carrier's parcel tracking number." }, "trackingUrl": { "type": "string", "description": "URL provided by carrier to track the shipment; must adhere to valid URL formatting." } }, "description": "Array of shipping fulfillments; up to 100 entries. Describes shipment information for the order." }, "CreatePhysicalProductRequest": { "title": "CreatePhysicalProductRequest", "type": "object", "description": "Request payload to create a PHYSICAL product.", "properties": { "description": { "type": "string" }, "isVisible": { "type": "boolean" }, "name": { "type": "string" }, "storePageId": { "type": "string" }, "tags": { "type": "array", "items": { "type": "string" } }, "type": { "type": "string" }, "urlSlug": { "type": "string" }, "variantAttributes": { "type": "array", "items": { "type": "string" } }, "variants": { "type": "array", "items": { "$ref": "#/components/schemas/CreatePhysicalProductVariantRequest" } } }, "discriminator": { "propertyName": "type" } }, "CreatePhysicalProductVariantRequest": { "type": "object", "properties": { "attributes": { "type": "object", "additionalProperties": { "type": "string" } }, "gtin": { "type": "string", "description": "Global Trade Item Number (GTIN). Optional. Must be 8, 12, 13, or 14 numeric digits. Whitespace, hyphens, and underscores are stripped before validation." }, "mpn": { "type": "string", "description": "Manufacturer Part Number (MPN). Optional. Must be alphanumeric and 70 characters or fewer. Whitespace, hyphens, and underscores are stripped before validation." }, "pricing": { "$ref": "#/components/schemas/FullProductPricing" }, "shippingMeasurements": { "$ref": "#/components/schemas/ProductMeasurements" }, "sku": { "type": "string" }, "stock": { "$ref": "#/components/schemas/ProductStock" } } }, "CreateProductRequest": { "required": [ "storePageId", "type", "variants" ], "type": "object", "properties": { "description": { "maxLength": 102400, "type": "string", "description": "Long-form product description represented in HTML." }, "isVisible": { "type": "boolean", "description": "Indicates whether the product is available for purchase. If not specified, the new product is marked as Hidden." }, "name": { "maxLength": 200, "type": "string", "description": "Product name." }, "pricing": { "$ref": "#/components/schemas/ProductPricing" }, "storePageId": { "type": "string", "description": "Identifier of the product's Store Page." }, "tags": { "type": "array", "description": "Keywords for search and organization purposes.", "items": { "type": "string", "description": "Keywords for search and organization purposes." } }, "type": { "$ref": "#/components/schemas/ProductType" }, "urlSlug": { "maxLength": 200, "type": "string", "description": "URL slug for the new product. Value can only consist of alphanumeric characters and non-contiguous hyphens." }, "variantAttributes": { "type": "array", "description": "List of attributes to distinguish variants of the product. Supported for PHYSICAL products only.", "items": { "type": "string", "description": "List of attributes to distinguish variants of the product. Supported for PHYSICAL products only." } }, "variants": { "type": "array", "description": "List of variants of the product. Array must contain at least one object but no more than 100 objects.", "items": { "$ref": "#/components/schemas/CreateProductVariantRequest" } } } }, "CreateProductVariantRequest": { "required": [ "pricing", "sku" ], "type": "object", "properties": { "attributes": { "type": "object", "additionalProperties": { "type": "string", "description": "Specifies attribute-value pairs for the variant. 100 char limit per key and per value with no more than six key-value pairs. Supported for PHYSICAL products only." }, "description": "Specifies attribute-value pairs for the variant. 100 char limit per key and per value with no more than six key-value pairs. Supported for PHYSICAL products only." }, "pricing": { "$ref": "#/components/schemas/ProductPricing" }, "shippingMeasurements": { "$ref": "#/components/schemas/ProductMeasurements" }, "sku": { "maxLength": 60, "type": "string", "description": "Merchant-defined code that identifies the product variant. Value must be unique among variants. Leading and trailing whitespace is removed." }, "stock": { "$ref": "#/components/schemas/ProductStock" } } }, "CreateServiceProductRequest": { "title": "CreateServiceProductRequest", "type": "object", "description": "Request payload to create a SERVICE product.", "properties": { "description": { "type": "string" }, "isVisible": { "type": "boolean" }, "name": { "type": "string" }, "storePageId": { "type": "string" }, "tags": { "type": "array", "items": { "type": "string" } }, "type": { "type": "string" }, "urlSlug": { "type": "string" }, "variantAttributes": { "type": "array", "items": { "type": "string" } }, "variants": { "type": "array", "items": { "$ref": "#/components/schemas/CreateServiceProductVariantRequest" } } }, "discriminator": { "propertyName": "type" } }, "CreateServiceProductVariantRequest": { "type": "object", "properties": { "attributes": { "type": "object", "additionalProperties": { "type": "string" } }, "pricing": { "$ref": "#/components/schemas/FullProductPricing" }, "sku": { "type": "string" }, "stock": { "$ref": "#/components/schemas/ProductStock" } } }, "CreateShippingLineRequest": { "required": [ "amount", "method" ], "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "method": { "maxLength": 100, "type": "string", "description": "Description of the shipping option." } }, "description": "Array of shipping line items. Describes the shipping options chosen at checkout. Currently accepts only one shipping entry." }, "CreateVariantRequestV2": { "required": [ "pricing", "sku" ], "type": "object", "properties": { "attributes": { "type": "object", "additionalProperties": { "type": "string", "description": "Specifies attribute-value pairs for the variant. 100 char limit per key and per value with no more than six key-value pairs. Supported for PHYSICAL products only." }, "description": "Specifies attribute-value pairs for the variant. 100 char limit per key and per value with no more than six key-value pairs. Supported for PHYSICAL products only." }, "gtin": { "type": "string", "description": "Global Trade Item Number (GTIN). Optional. Must be 8, 12, 13, or 14 numeric digits. Whitespace, hyphens, and underscores are stripped before validation. Supported for PHYSICAL products only.", "examples": [ "01234567890128" ] }, "mpn": { "type": "string", "description": "Manufacturer Part Number (MPN). Optional. Must be alphanumeric and 70 characters or fewer. Whitespace, hyphens, and underscores are stripped before validation. Supported for PHYSICAL products only.", "examples": [ "MPN-1234" ] }, "pricing": { "$ref": "#/components/schemas/ProductPricing" }, "shippingMeasurements": { "$ref": "#/components/schemas/ProductMeasurements" }, "sku": { "maxLength": 60, "type": "string", "description": "Merchant-defined code that identifies the product variant. Value must be unique among variants. Leading and trailing whitespace is removed." }, "stock": { "$ref": "#/components/schemas/ProductStock" } } }, "DateFilter": { "type": "object", "properties": { "after": { "type": "string", "description": "Filter out any dates after", "format": "date-time" }, "before": { "type": "string", "description": "Filter out any dates before", "format": "date-time" } }, "description": "Object for filtering by before and after dates" }, "DigitalGood": { "type": "object", "properties": { "filename": { "type": "string", "description": "Filename of the downloadable file." }, "id": { "type": "string", "description": "Unique DigitalGood id." } }, "description": "Present for DIGITAL products only." }, "DigitalProduct": { "title": "DigitalProduct", "required": [ "createdOn", "id", "modifiedOn", "storePageId", "type" ], "type": "object", "description": "A DIGITAL product.", "properties": { "createdOn": { "type": "string", "format": "date-time" }, "description": { "type": "string" }, "id": { "type": "string" }, "images": { "type": "array", "items": { "$ref": "#/components/schemas/ProductImage" } }, "isVisible": { "type": "boolean" }, "modifiedOn": { "type": "string", "format": "date-time" }, "name": { "type": "string" }, "seoOptions": { "$ref": "#/components/schemas/SeoOptions" }, "storePageId": { "type": "string" }, "tags": { "type": "array", "items": { "type": "string" } }, "type": { "$ref": "#/components/schemas/ProductTypeV2" }, "url": { "type": "string" }, "urlSlug": { "type": "string" }, "digitalGood": { "$ref": "#/components/schemas/DigitalGood" }, "pricing": { "$ref": "#/components/schemas/ProductPricing" } }, "discriminator": { "propertyName": "type" } }, "Discount": { "required": [ "criteria", "name", "template", "trigger", "validFrom" ], "type": "object", "properties": { "criteria": { "oneOf": [ { "$ref": "#/components/schemas/AnyOrderCriteria" }, { "$ref": "#/components/schemas/BuyXGetYCriteria" }, { "$ref": "#/components/schemas/CartTotalCriteria" }, { "$ref": "#/components/schemas/ProductCriteria" } ] }, "id": { "type": "string", "description": "Discount id.", "readOnly": true }, "isLimitedUses": { "type": "boolean", "description": "If true, the discount can only be used `maxUsesAllowed` times site-wide." }, "isOncePerCustomer": { "type": "boolean", "description": "If true, a given customer can only use this discount once." }, "lastRedeemedAt": { "type": "string", "description": "Timestamp of the most recent redemption. Null if never redeemed.", "format": "date-time", "readOnly": true }, "maxUsesAllowed": { "type": "integer", "description": "Maximum site-wide redemptions. Required when isLimitedUses=true; null otherwise.", "format": "int32" }, "name": { "type": "string", "description": "Display name for the discount." }, "numberOfUses": { "type": "integer", "description": "Number of times this discount has been redeemed.", "format": "int32", "readOnly": true }, "paymentPlanOptions": { "$ref": "#/components/schemas/PaymentPlanOptions" }, "status": { "type": "string", "description": "Defines the lifecycle status of a discount.", "readOnly": true, "enum": [ "ACTIVE", "SCHEDULED", "EXPIRED" ] }, "subscriptionOptions": { "$ref": "#/components/schemas/SubscriptionOptions" }, "template": { "oneOf": [ { "$ref": "#/components/schemas/BuyXGetYFixedAmountTemplate" }, { "$ref": "#/components/schemas/BuyXGetYPercentageTemplate" }, { "$ref": "#/components/schemas/FixedAmountTemplate" }, { "$ref": "#/components/schemas/FreeShippingTemplate" }, { "$ref": "#/components/schemas/PercentageTemplate" } ] }, "trigger": { "oneOf": [ { "$ref": "#/components/schemas/AutoTrigger" }, { "$ref": "#/components/schemas/PromoCodeTrigger" } ] }, "validFrom": { "type": "string", "description": "When the discount becomes active.", "format": "date-time" }, "validTo": { "type": "string", "description": "When the discount expires. Null = no expiry.", "format": "date-time" }, "websiteId": { "type": "string", "description": "24-char website id.", "readOnly": true } }, "description": "Discount configured for a Commerce store." }, "DiscountLine": { "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "description": { "type": "string", "description": "A plain-English description of the promotion", "examples": [ "20% off all orders over $50" ] }, "name": { "type": "string", "description": "Name of the promotion", "examples": [ "Summer Sale - 20% Off" ] }, "promoCode": { "type": "string", "description": "The user-entered promo code that triggered the discount", "examples": [ "SUMMER20" ] } }, "description": "Array of discount line items; describes the promotions redeemed during checkout." }, "DiscountResponse": { "required": [ "discount" ], "type": "object", "properties": { "discount": { "$ref": "#/components/schemas/Discount" } }, "description": "Envelope for a single discount response." }, "Email": { "type": "object", "properties": { "acceptsMarketing": { "$ref": "#/components/schemas/AcceptsMarketing" }, "createdOn": { "type": "string", "description": "The date and time when the email was created.", "format": "date-time", "readOnly": true }, "email": { "type": "string", "format": "email", "description": "The email address.", "examples": [ "jane.doe@example.com" ] } }, "description": "The contact's primary email." }, "ExtensionUninstallData": { "required": [ "clientId" ], "type": "object", "properties": { "clientId": { "type": "string", "description": "Third-party client id.", "examples": [ "A125dfPqdKJDqPAcJQgLo3A5mwcKIq2G" ] } }, "description": "The extension uninstall details." }, "ExtensionUninstallPayload": { "required": [ "createdOn", "id", "subscriptionsId", "topic", "websiteId" ], "type": "object", "properties": { "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of this message.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "data": { "$ref": "#/components/schemas/ExtensionUninstallData" }, "id": { "type": "string", "description": "Unique notification id.", "examples": [ "5c2ba184b63ed3cb411ce2b1" ] }, "subscriptionsId": { "type": "string", "description": "Unique Webhook Subscriptions id.", "examples": [ "5f3c2155d947844beedda991" ] }, "topic": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "enum": [ "extension.uninstall" ], "examples": [ "extension.uninstall" ] }, "websiteId": { "type": "string", "description": "Squarespace website id that triggered the notification.", "examples": [ "5f3c3d55ac435e1a051f77b3" ] } } }, "ExternalCreateWebhookSubscriptionRequest": { "required": [ "endpointUrl" ], "type": "object", "properties": { "endpointUrl": { "type": "string", "description": "HTTPS URL to POST webhook notifications.", "examples": [ "https://example-extension.com/uninstall" ] }, "topics": { "type": "array", "description": "List of event topics that trigger a webhook notification.", "items": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "enum": [ "order.create", "order.update", "extension.uninstall", "contact.create", "contact.update", "contact.delete", "address.create", "address.update", "address.delete" ], "examples": [ "extension.uninstall" ] } } } }, "ExternalCreateWebhookSubscriptionResponse": { "required": [ "clientId", "createdOn", "endpointUrl", "id", "secret", "updatedOn", "websiteId" ], "type": "object", "properties": { "clientId": { "type": "string", "description": "Third-party client id.", "readOnly": true, "examples": [ "A125dfPqdKJDqPAcJQgLo3A5mwcKIq2G" ] }, "createdOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the webhook subscription was created.", "format": "date-time", "readOnly": true, "examples": [ "2020-04-22T22:18:00Z" ] }, "endpointUrl": { "type": "string", "description": "HTTPS URL to POST webhook notifications.", "examples": [ "https://example-extension.com/uninstall" ] }, "id": { "type": "string", "description": "Unique Webhook Subscription id.", "readOnly": true, "examples": [ "7aff04bb-90e0-4002-96c2-69d8162c8dae" ] }, "secret": { "type": "string", "description": "Hexadecimal value used to generate a signature for a webhook notification;\nfield is only returned when creating a new subscription or rotating a secret.\nStore the secret in a safe location to verify notifications from Squarespace.\nSee the 'Verifying notifications' guide under Webhooks for details.\n", "readOnly": true, "examples": [ "F3F9B981C78E7A6187E42853F6CE2804177E98206164779423B02DEC981ACD6B" ] }, "topics": { "type": "array", "description": "List of event topics that trigger a webhook notification.", "items": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "enum": [ "order.create", "order.update", "extension.uninstall", "contact.create", "contact.update", "contact.delete", "address.create", "address.update", "address.delete" ], "examples": [ "extension.uninstall" ] } }, "updatedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the webhook subscription was last modified.", "format": "date-time", "readOnly": true, "examples": [ "2020-04-22T22:18:00Z" ] }, "websiteId": { "type": "string", "description": "Unique Webhook Subscription id.", "readOnly": true, "examples": [ "7aff04bb-90e0-4002-96c2-69d8162c8dae" ] } } }, "ExternalRotateSecretResponse": { "type": "object", "properties": { "secret": { "type": "string", "description": "Hexadecimal value used to generate a signature for a webhook notification; field is only returned when creating a new subscription or rotating a secret. Store the secret in a safe location to verify notifications from Squarespace." } } }, "ExternalSendTestNotificationRequest": { "required": [ "topic" ], "type": "object", "properties": { "topic": { "type": "string", "description": "Required; Squarespace event topic that triggers a webhook notification. Possible values include: extension.uninstall, order.create, order.update." } } }, "ExternalTestNotificationResponse": { "type": "object", "properties": { "statusCode": { "type": "integer", "description": "Status code returned by the subscribed webhook endpoint.", "format": "int32" } } }, "ExternalTransactionProperty": { "type": "object", "properties": { "key": { "type": "string" }, "value": { "type": "string" } }, "description": "Array of properties for the payment transaction provided by the payment gateway. Properties are listed in key/value pairs." }, "ExternalUpdateWebhookSubscriptionRequest": { "type": "object", "properties": { "endpointUrl": { "$ref": "#/components/schemas/ChangeString" }, "topics": { "$ref": "#/components/schemas/ChangeListString" } } }, "ExternalWebhookSubscriptionListResponse": { "type": "object", "properties": { "webhookSubscriptions": { "type": "array", "description": "Array of Webhook Subscription resources. If the merchant site doesn't have any webhook subscriptions, this array is empty.", "items": { "$ref": "#/components/schemas/ExternalWebhookSubscriptionResponse" } } } }, "ExternalWebhookSubscriptionResponse": { "type": "object", "properties": { "clientId": { "type": "string", "description": "Third-party client id." }, "createdOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the webhook subscription was created." }, "endpointUrl": { "type": "string", "description": "HTTPS URL that receives webhook notifications." }, "id": { "type": "string", "description": "Unique Webhook Subscription id." }, "topics": { "type": "array", "description": "List of event topics that trigger a webhook notification. Possible values include: extension.uninstall, order.create, order.update.", "items": { "type": "string", "description": "List of event topics that trigger a webhook notification. Possible values include: extension.uninstall, order.create, order.update." } }, "updatedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the webhook subscription was last modified." }, "websiteId": { "type": "string", "description": "Unique website id." } } }, "FixedAmountTemplate": { "title": "FixedAmountTemplate", "required": [ "discountAmount", "type" ], "type": "object", "description": "Apply a fixed monetary amount off the cart total.", "properties": { "type": { "type": "string" }, "discountAmount": { "$ref": "#/components/schemas/MonetaryAmount" } }, "discriminator": { "propertyName": "type" } }, "FormItem": { "type": "object", "properties": { "label": { "type": "string", "description": "The name of the form field", "examples": [ "How did you hear about us?" ] }, "value": { "type": "string", "description": "The value of the field, as entered by the shopper", "examples": [ "Facebook" ] } }, "description": "Array of form data submitted via the checkout page." }, "FreeShippingTemplate": { "title": "FreeShippingTemplate", "type": "object", "description": "Waive shipping cost for eligible carts.", "required": [ "type" ], "properties": { "type": { "type": "string" }, "appliesToFulfillmentOptionType": { "type": "string", "description": "Fulfillment channel a free-shipping discount applies to.", "enum": [ "SHIPPING", "PICKUP", "LOCAL_DELIVERY" ] }, "selectedShippingOption": { "$ref": "#/components/schemas/SelectedShippingOption" } }, "discriminator": { "propertyName": "type" } }, "Fulfillment": { "type": "object", "properties": { "carrierName": { "type": "string", "description": "Name of the carrier handling the shipment.", "examples": [ "FedEx" ] }, "service": { "type": "string", "description": "Carrier's level of service for shipping.", "examples": [ "Same-Day Delivery" ] }, "shipDate": { "type": "string", "description": "ISO 8601 UTC date and time string; represents the moment the fulfillment was shipped.", "format": "date-time", "examples": [ "2017-01-29T22:19:26.98Z" ] }, "trackingNumber": { "type": "string", "description": "Carrier's parcel tracking number.", "examples": [ "103932814692659" ] }, "trackingUrl": { "type": "string", "description": "URL provided by the carrier to track the shipment.", "examples": [ "https://www.fedex.com/apps/fedextrack/?tracknumbers=103932814692659" ] } }, "description": "Array of shipping fulfillments; describes shipment information for the order." }, "FulfillmentOption": { "required": [ "availableServices", "id", "name", "type" ], "type": "object", "properties": { "availableServices": { "type": "array", "description": "Available carrier services.", "items": { "$ref": "#/components/schemas/CarrierService" } }, "id": { "type": "string", "description": "Fulfillment option id." }, "name": { "type": "string", "description": "Display name for the option.", "examples": [ "Standard Shipping" ] }, "type": { "type": "string", "description": "Fulfillment channel for this option.", "enum": [ "SHIPPING", "PICKUP", "LOCAL_DELIVERY" ] } }, "description": "Fulfillment option IDs and carrier services for a website." }, "FulfillmentOptionsList": { "required": [ "fulfillmentOptions" ], "type": "object", "properties": { "fulfillmentOptions": { "type": "array", "description": "Fulfillment option IDs and carrier services for this website.", "items": { "$ref": "#/components/schemas/FulfillmentOption" } } }, "description": "List of fulfillment option IDs and carrier services." }, "FulfillmentStatus": { "type": "string", "description": "Current fulfillment status of the order. Value may be: PENDING, FULFILLED, or CANCELED.", "enum": [ "PENDING", "FULFILLED", "CANCELED" ] }, "FullProductPricing": { "type": "object", "properties": { "basePrice": { "$ref": "#/components/schemas/MonetaryAmount" }, "onSale": { "type": "boolean" }, "salePrice": { "$ref": "#/components/schemas/MonetaryAmount" } } }, "GetAddressBookEntryResponse": { "type": "object", "properties": { "addressBookEntry": { "$ref": "#/components/schemas/AddressBookEntry" } } }, "GetAddressBookResponse": { "type": "object", "properties": { "addressBook": { "$ref": "#/components/schemas/AddressBook" }, "pagination": { "$ref": "#/components/schemas/PaginationDetails" } } }, "GetContactResponse": { "type": "object", "properties": { "contact": { "$ref": "#/components/schemas/Contact" } } }, "GiftCardProduct": { "title": "GiftCardProduct", "required": [ "createdOn", "id", "modifiedOn", "storePageId", "type" ], "type": "object", "description": "A GIFT_CARD product.", "properties": { "createdOn": { "type": "string", "format": "date-time" }, "description": { "type": "string" }, "id": { "type": "string" }, "images": { "type": "array", "items": { "$ref": "#/components/schemas/ProductImage" } }, "isVisible": { "type": "boolean" }, "modifiedOn": { "type": "string", "format": "date-time" }, "name": { "type": "string" }, "seoOptions": { "$ref": "#/components/schemas/SeoOptions" }, "storePageId": { "type": "string" }, "tags": { "type": "array", "items": { "type": "string" } }, "type": { "$ref": "#/components/schemas/ProductTypeV2" }, "url": { "type": "string" }, "urlSlug": { "type": "string" }, "variants": { "type": "array", "items": { "$ref": "#/components/schemas/GiftCardProductVariant" } } }, "discriminator": { "propertyName": "type" } }, "GiftCardProductVariant": { "title": "GiftCardProductVariant", "type": "object", "properties": { "id": { "type": "string" }, "image": { "$ref": "#/components/schemas/ProductImage" }, "pricing": { "$ref": "#/components/schemas/SimpleProductPricing" }, "sku": { "type": "string" } }, "description": "A variant of a GIFT_CARD product." }, "ImageProcessingStatus": { "type": "string", "enum": [ "QUEUED", "PROCESSING", "READY", "ERROR" ] }, "IntegerFilter": { "type": "object", "properties": { "max": { "type": "integer", "description": "Filter out any numbers greater", "format": "int32" }, "min": { "type": "integer", "description": "Filter out any numbers lower", "format": "int32" } }, "description": "Object for filtering by a min and max integer" }, "InventoryItem": { "type": "object", "properties": { "descriptor": { "type": "string", "description": "Generated description using the product's title and any available variant attributes including, but not limited to, color and size." }, "isUnlimited": { "type": "boolean", "description": "Indicates whether stock is currently tracked for the item." }, "quantity": { "type": "integer", "description": "Current amount in stock, or the last known stock amount prior to becoming unlimited. This value is modified by purchases and returns only when `isUnlimited` is `false`.", "format": "int32" }, "sku": { "type": "string", "description": "Stock keeping unit (SKU) code assigned by the Squarespace merchant for the variant; used to identify an exact variant of a product using a naming scheme preferred by the merchant." }, "variantId": { "type": "string", "description": "The product variant id, which also serves as a unique id for the InventoryItem." } }, "description": "Array of InventoryItem resources. If the merchant site doesn't have any physical or service products, this array is empty." }, "InventoryItemListResponse": { "type": "object", "properties": { "inventory": { "type": "array", "description": "Array of InventoryItem resources. If the merchant site doesn't have any physical or service products, this array is empty.", "items": { "$ref": "#/components/schemas/InventoryItem" } } } }, "InventoryQuantityExpression": { "type": "object", "properties": { "quantity": { "type": "integer", "description": "Quantity value for the inventory operation.", "format": "int32" }, "variantId": { "type": "string", "description": "Unique id for the InventoryItem." } }, "description": "Optional; array of objects. Sets the exact stock quantity for InventoryItems." }, "LineItem": { "type": "object", "properties": { "customizations": { "type": "array", "description": "Array of form data submitted via a product's custom form prior to being added to the cart.", "items": { "$ref": "#/components/schemas/FormItem" } }, "height": { "type": "number", "description": "Shipping height of the physical product variant. 0.0 when not specified or when the variant is not a physical product.", "format": "float", "examples": [ 4 ] }, "id": { "type": "string", "description": "Unique line item id.", "examples": [ "585d4975dee9f31a60284a16" ] }, "imageUrl": { "type": "string", "description": "URL of the primary image for the item.", "examples": [ "https://static.squarespace.com/universal/commerce/images/brine-32oz-spring-mix-v2.jpg?format=300w" ] }, "length": { "type": "number", "description": "Shipping length of the physical product variant. 0.0 when not specified or when the variant is not a physical product.", "format": "float", "examples": [ 3 ] }, "lineItemType": { "type": "string", "description": "Product type of the item.", "examples": [ "PHYSICAL_PRODUCT" ] }, "productId": { "type": "string", "description": "Unique product id; unless null, every line item with a variantId is a variant of a product with productId.", "examples": [ "565c8f3da7c8a3cf71d5fd0a" ] }, "productName": { "type": "string", "description": "Name of the purchased product.", "examples": [ "Product" ] }, "quantity": { "type": "integer", "description": "Amount of the item purchased.", "format": "int32", "examples": [ 1 ] }, "sku": { "type": "string", "description": "Stock keeping unit (SKU) code assigned by the Squarespace merchant for a variant. Null for digital products.", "examples": [ "SQ3381024" ] }, "unitPricePaid": { "$ref": "#/components/schemas/MonetaryAmount" }, "variantId": { "type": "string", "description": "Unique id of the ProductVariant sold. Populated for physical, service, or gift card line items created on or after May 28, 2019.", "examples": [ "88c16ee4-547b-445e-a392-bded9991ae30" ] }, "variantOptions": { "type": "array", "description": "Array of variant options; represents variant choices made by the customer. Null for download and gift card products.", "items": { "$ref": "#/components/schemas/VariantOption" } }, "weight": { "type": "number", "description": "Shipping weight of the physical product variant. 0.0 when not specified or when the variant is not a physical product.", "format": "float", "examples": [ 1 ] }, "width": { "type": "number", "description": "Shipping width of the physical product variant. 0.0 when not specified or when the variant is not a physical product.", "format": "float", "examples": [ 2 ] } }, "description": "Array of purchased line items; line items describe what product or product variant was purchased, how many of that item were purchased, and additional details." }, "Location": { "type": "object", "properties": { "country": { "type": "string" }, "region": { "type": "string" } } }, "MeasurementStandard": { "type": "string", "enum": [ "IMPERIAL", "METRIC" ] }, "MemberProfile": { "type": "object", "properties": { "email": { "type": "string", "description": "Profile email address." }, "firstName": { "type": "string", "description": "Profile first name." }, "id": { "type": "string", "description": "Unique Profile id." }, "lastName": { "type": "string", "description": "Profile last name." } } }, "MonetaryAmount": { "type": "object", "properties": { "currency": { "type": "object", "description": "ISO 4217 currency code.", "properties": { "currencyCode": { "type": "string" }, "defaultFractionDigits": { "type": "integer", "format": "int32" }, "displayName": { "type": "string" }, "numericCode": { "type": "integer", "format": "int32" }, "numericCodeAsString": { "type": "string" }, "symbol": { "type": "string" } }, "examples": [ "USD" ] }, "value": { "type": "number", "description": "Decimal monetary value.", "examples": [ 49.99 ] } }, "description": "A monetary amount with currency code and decimal value." }, "Order": { "type": "object", "properties": { "billingAddress": { "$ref": "#/components/schemas/Address" }, "channel": { "type": "string", "description": "Where the order originated; possible values are: web and pos.", "examples": [ "web" ] }, "channelName": { "type": "string", "description": "Name of the third-party sales channel.", "examples": [ "Faire Wholesale" ] }, "createdOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents the moment when the order was placed.", "format": "date-time", "examples": [ "2016-12-23T15:58:07.187Z" ] }, "customerEmail": { "type": "string", "description": "Email address entered at checkout or, for recurring subscription orders, the customer's current email address.", "examples": [ "foo@example.com" ] }, "customerId": { "type": "string", "description": "Unique customer id.", "examples": [ "585d498fdee9f31a60284a38" ] }, "discountLines": { "type": "array", "description": "Array of discount line items; describes the promotions redeemed during checkout.", "items": { "$ref": "#/components/schemas/DiscountLine" } }, "discountTotal": { "$ref": "#/components/schemas/MonetaryAmount" }, "externalOrderReference": { "type": "string", "description": "Order reference identifier used by the third-party sales channel.", "examples": [ "EXT-98765" ] }, "formSubmission": { "type": "array", "description": "Array of form data submitted via the checkout page.", "items": { "$ref": "#/components/schemas/FormItem" } }, "fulfilledOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents the moment the order was fulfilled.", "format": "date-time" }, "fulfillmentStatus": { "$ref": "#/components/schemas/FulfillmentStatus" }, "fulfillments": { "type": "array", "description": "Array of shipping fulfillments; describes shipment information for the order.", "items": { "$ref": "#/components/schemas/Fulfillment" } }, "grandTotal": { "$ref": "#/components/schemas/MonetaryAmount" }, "id": { "type": "string", "description": "Unique Order id.", "examples": [ "585d498fdee9f31a60284a37" ] }, "internalNotes": { "type": "array", "description": "Array of internal notes added to the order by the merchant.", "items": { "$ref": "#/components/schemas/OrderNote" } }, "lineItems": { "type": "array", "description": "Array of purchased line items; line items describe what product or product variant was purchased, how many of that item were purchased, and additional details.", "items": { "$ref": "#/components/schemas/LineItem" } }, "modifiedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the order was last modified.", "format": "date-time", "examples": [ "2016-12-23T15:58:07.187Z" ] }, "orderNumber": { "type": "string", "description": "Unique, sequential number for the Order.", "examples": [ "3" ] }, "paymentState": { "$ref": "#/components/schemas/PaymentState" }, "priceTaxInterpretation": { "type": "string", "description": "Indicates whether lineItems.unitPricePaid includes tax. Values may be EXCLUSIVE or INCLUSIVE.", "examples": [ "EXCLUSIVE" ] }, "refundedTotal": { "$ref": "#/components/schemas/MonetaryAmount" }, "shippingAddress": { "$ref": "#/components/schemas/Address" }, "shippingLines": { "type": "array", "description": "Array of shipping line items; describes the shipping options chosen at checkout.", "items": { "$ref": "#/components/schemas/ShippingLine" } }, "shippingOptionName": { "type": "string", "description": "the specific shipping service name selected at checkout (e.g. \"USPS Ground Advantage\", \"Royal Mail Tracked 48\")." }, "shippingOptionServiceType": { "type": "string", "description": "The carrier service type identifier.", "enum": [ "FEDEX_GROUND", "FEDEX_GROUND_HOME_DELIVERY", "FEDEX_PRIORITY_OVERNIGHT", "FEDEX_STANDARD_OVERNIGHT", "FEDEX_2_DAY", "FEDEX_2_DAY_AM", "FEDEX_EXPRESS_SAVER", "FEDEX_FIRST_FREIGHT", "FEDEX_FREIGHT_PRIORITY", "FEDEX_FREIGHT_ECONOMY", "FEDEX_FIRST_OVERNIGHT", "FEDEX_SAME_DAY", "FEDEX_SAME_DAY_CITY", "FEDEX_EUROPE_FIRST_INTERNATIONAL_PRIORITY", "FEDEX_INTERNATIONAL_ECONOMY", "FEDEX_INTERNATIONAL_FIRST", "FEDEX_INTERNATIONAL_PRIORITY", "FEDEX_INTERNATIONAL_ECONOMY_FREIGHT", "FEDEX_INTERNATIONAL_PRIORITY_FREIGHT", "UPS_GROUND", "UPS_NEXT_DAY_AIR", "UPS_NEXT_DAY_AIR_SAVER", "UPS_NEXT_DAY_AIR_EARLY_AM", "UPS_TWO_DAY_AIR", "UPS_THREE_DAY_SELECT", "UPS_TWO_DAY_AIR_AM", "USPS_UNKNOWN", "USPS_FIRST_CLASS", "USPS_PRIORITY", "USPS_EXPRESS", "USPS_STANDARD", "USPS_ALL", "USPS_ONLINE", "OTHER" ] }, "shippingTotal": { "$ref": "#/components/schemas/MonetaryAmount" }, "subtotal": { "$ref": "#/components/schemas/MonetaryAmount" }, "taxTotal": { "$ref": "#/components/schemas/MonetaryAmount" }, "testmode": { "type": "boolean", "description": "If true, the order is a test order created using a payment method in test mode." } } }, "OrderCreateData": { "required": [ "orderId" ], "type": "object", "properties": { "orderId": { "type": "string", "description": "Unique order id.", "examples": [ "5f3c39ce69e11e796f19990e" ] } }, "description": "The created order details." }, "OrderCreateFulfillmentStatus": { "type": "string", "description": "Current fulfillment status of the order. Value may be PENDING or FULFILLED.", "enum": [ "PENDING", "FULFILLED" ] }, "OrderCreateLineItemType": { "type": "string", "description": "Product type sold; values may be PHYSICAL_PRODUCT or CUSTOM.", "enum": [ "PHYSICAL_PRODUCT", "CUSTOM" ] }, "OrderCreatePayload": { "required": [ "createdOn", "id", "subscriptionsId", "topic", "websiteId" ], "type": "object", "properties": { "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of this message.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "data": { "$ref": "#/components/schemas/OrderCreateData" }, "id": { "type": "string", "description": "Unique notification id.", "examples": [ "5c2ba184b63ed3cb411ce2b1" ] }, "subscriptionsId": { "type": "string", "description": "Unique Webhook Subscriptions id.", "examples": [ "5f3c2155d947844beedda991" ] }, "topic": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "default": "order.create", "enum": [ "order.create" ], "examples": [ "order.create" ] }, "websiteId": { "type": "string", "description": "Squarespace website id that triggered the notification.", "examples": [ "5f3c3d55ac435e1a051f77b3" ] } } }, "OrderFulfillmentRequest": { "type": "object", "properties": { "shipments": { "type": "array", "description": "Array of shipment data.", "items": { "$ref": "#/components/schemas/CreateOrderShipmentRequest" } }, "shouldSendNotification": { "type": "boolean", "description": "Indicates whether the customer should receive an email notification about the added shipments." } } }, "OrderListResponse": { "type": "object", "properties": { "pagination": { "examples": [ { "hasNextPage": true, "nextPageCursor": "ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ", "nextPageUrl": "/1.0/commerce/orders?cursor=ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ" } ], "type": "object", "properties": { "hasNextPage": { "type": "boolean" }, "nextPageCursor": { "type": "string" }, "nextPageUrl": { "type": "string" } } }, "result": { "type": "array", "items": { "$ref": "#/components/schemas/Order" } } } }, "OrderNote": { "type": "object", "properties": { "content": { "type": "string", "description": "Content for the note", "examples": [ "First note" ] } }, "description": "Array of internal notes added to the order by the merchant." }, "OrderUpdateData": { "required": [ "orderId", "update" ], "type": "object", "properties": { "orderId": { "type": "string", "description": "Unique order id.", "examples": [ "5f3c39ce69e11e796f19990e" ] }, "update": { "type": "string", "description": "The type of update on the order.", "enum": [ "FULFILLED", "REFUNDED", "CANCELED", "MARKED_PENDING", "EMAIL_UPDATED" ], "examples": [ "FULFILLED" ] } }, "description": "The updated order details." }, "OrderUpdatePayload": { "required": [ "createdOn", "id", "subscriptionsId", "topic", "websiteId" ], "type": "object", "properties": { "createdOn": { "type": "string", "description": "Creation date and time in UTC (ISO 8601 format) of this message.", "format": "date-time", "examples": [ "2024-01-28T10:44:00Z" ] }, "data": { "$ref": "#/components/schemas/OrderUpdateData" }, "id": { "type": "string", "description": "Unique notification id.", "examples": [ "5c2ba184b63ed3cb411ce2b1" ] }, "subscriptionsId": { "type": "string", "description": "Unique Webhook Subscriptions id.", "examples": [ "5f3c2155d947844beedda991" ] }, "topic": { "type": "string", "description": "Description of the event that triggered the notification.\n* `order.create` - always value for OrderCreatePayload.topic ref\n* `order.update` - always value for OrderUpdatePayload.topic\n* `extension.uninstall` - always value for ExtensionUninstallPayload.topic\n* `contact.create` - always value for ContactCreatePayload.topic\n* `contact.update` - always value for ContactUpdatePayload.topic\n* `contact.delete` - always value for ContactDeletePayload.topic\n* `address.create` - always value for AddressCreatePayload.topic\n* `address.update` - always value for AddressUpdatePayload.topic\n* `address.delete` - always value for AddressDeletePayload.topic\n", "default": "order.update", "enum": [ "order.update" ], "examples": [ "order.update" ] }, "websiteId": { "type": "string", "description": "Squarespace website id that triggered the notification.", "examples": [ "5f3c3d55ac435e1a051f77b3" ] } } }, "PaginatedDiscountListResponse": { "required": [ "discounts" ], "type": "object", "properties": { "discounts": { "type": "array", "description": "Discounts for this page.", "items": { "$ref": "#/components/schemas/Discount" } }, "hasNextPage": { "type": "boolean", "description": "True when more results exist after the current window." }, "hasPreviousPage": { "type": "boolean", "description": "True when a page of results exists before the current window." } }, "description": "Offset-paginated list of discounts for a website." }, "PaginatedGetContactsResponse": { "type": "object", "properties": { "contacts": { "type": "array", "description": "paginated list of contacts retrieved", "items": { "$ref": "#/components/schemas/Contact" } }, "pagination": { "examples": [ { "hasNextPage": true, "nextPageCursor": "ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ", "nextPageUrl": "/v1/contacts?cursor=ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ" } ], "type": "object", "properties": { "hasNextPage": { "type": "boolean" }, "nextPageCursor": { "type": "string" }, "nextPageUrl": { "type": "string" } } } } }, "PaginatedInventoryItemListResponse": { "type": "object", "properties": { "inventory": { "type": "array", "description": "Array of InventoryItem resources. If the merchant site doesn't have any physical or service product variants, this array is empty.", "items": { "$ref": "#/components/schemas/InventoryItem" } }, "pagination": { "examples": [ { "hasNextPage": true, "nextPageCursor": "ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ", "nextPageUrl": "/1.0/commerce/inventory?cursor=ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ" } ], "type": "object", "properties": { "hasNextPage": { "type": "boolean" }, "nextPageCursor": { "type": "string" }, "nextPageUrl": { "type": "string" } } } } }, "PaginatedProductListResponse": { "type": "object", "properties": { "pagination": { "examples": [ { "hasNextPage": true, "nextPageCursor": "ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ", "nextPageUrl": "/1.0/commerce/products?cursor=ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ" } ], "type": "object", "properties": { "hasNextPage": { "type": "boolean" }, "nextPageCursor": { "type": "string" }, "nextPageUrl": { "type": "string" } } }, "products": { "type": "array", "items": { "$ref": "#/components/schemas/Product" } } } }, "PaginatedProductListResponseV2": { "type": "object", "properties": { "pagination": { "examples": [ { "hasNextPage": true, "nextPageCursor": "ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ", "nextPageUrl": "/v2/commerce/products?cursor=ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ" } ], "type": "object", "properties": { "hasNextPage": { "type": "boolean" }, "nextPageCursor": { "type": "string" }, "nextPageUrl": { "type": "string" } } }, "products": { "type": "array", "items": { "oneOf": [ { "$ref": "#/components/schemas/DigitalProduct" }, { "$ref": "#/components/schemas/GiftCardProduct" }, { "$ref": "#/components/schemas/PhysicalProduct" }, { "$ref": "#/components/schemas/ServiceProduct" } ] } } } }, "PaginatedProfileListResponse": { "type": "object", "properties": { "pagination": { "examples": [ { "hasNextPage": true, "nextPageCursor": "ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ", "nextPageUrl": "/1.0/profiles?cursor=ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ" } ], "type": "object", "properties": { "hasNextPage": { "type": "boolean" }, "nextPageCursor": { "type": "string" }, "nextPageUrl": { "type": "string" } } }, "profiles": { "type": "array", "items": { "$ref": "#/components/schemas/Profile" } } } }, "PaginatedQueryContactsResponse": { "type": "object", "properties": { "contacts": { "type": "array", "description": "paginated list of contacts retrieved", "items": { "$ref": "#/components/schemas/Contact" } }, "pagination": { "examples": [ { "hasNextPage": true, "nextPageCursor": "ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ", "nextPageUrl": "/v1/contacts?cursor=ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ" } ], "type": "object", "properties": { "hasNextPage": { "type": "boolean" }, "nextPageCursor": { "type": "string" }, "nextPageUrl": { "type": "string" } } } } }, "PaginatedStorePagesResponse": { "type": "object", "properties": { "pagination": { "examples": [ { "hasNextPage": true, "nextPageCursor": "ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ", "nextPageUrl": "/1.0/commerce/store_pages?cursor=ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ" } ], "type": "object", "properties": { "hasNextPage": { "type": "boolean" }, "nextPageCursor": { "type": "string" }, "nextPageUrl": { "type": "string" } } }, "storePages": { "type": "array", "items": { "$ref": "#/components/schemas/StorePage" } } } }, "PaginatedTransactionListResponse": { "type": "object", "properties": { "documents": { "type": "array", "description": "Array of Document resources. If the merchant site doesn't have any payment transactions for orders or donations, this array is empty.", "items": { "$ref": "#/components/schemas/TransactionDocument" } }, "pagination": { "examples": [ { "hasNextPage": true, "nextPageCursor": "ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ", "nextPageUrl": "/1.0/commerce/transactions?cursor=ewogICJhIiA6ICI2OWNhOWExZjgxNGMwYTY0MmIwMTIzYzkiLAogICJiIiA6ICJJRCIKfQ" } ], "type": "object", "properties": { "hasNextPage": { "type": "boolean" }, "nextPageCursor": { "type": "string" }, "nextPageUrl": { "type": "string" } } } } }, "PaginationDetails": { "type": "object", "properties": { "hasNextPage": { "type": "boolean" }, "nextPageCursor": { "type": "string" }, "nextPageUrl": { "type": "string" } } }, "PatchContactRequest": { "type": "object", "properties": { "firstName": { "type": "string", "description": "The contact's first name.", "examples": [ "John" ] }, "lastName": { "type": "string", "description": "The contact's last name.", "examples": [ "Smith" ] }, "locale": { "type": "string", "description": "The contact's locale.", "examples": [ "en-US" ] }, "primaryEmail": { "$ref": "#/components/schemas/PatchEmail" } }, "description": "Fields to update on an existing contact.", "examples": [ { "firstName": "John", "lastName": "Smith", "locale": "en-US", "primaryEmail": { "email": "johnsmith@mail.com", "acceptsMarketing": true } } ] }, "PatchContactResponse": { "type": "object", "properties": { "contact": { "$ref": "#/components/schemas/Contact" } } }, "PatchEmail": { "type": "object", "properties": { "acceptsMarketing": { "type": "boolean", "description": "If contact's email accepts marketing", "examples": [ true ] }, "email": { "type": "string", "format": "email", "description": "The email address.", "examples": [ "jane.doe@example.com" ] } }, "description": "Primary email fields for an update request.", "examples": [ { "email": "johnsmith@mail.com", "acceptsMarketing": true } ] }, "PaymentGatewayError": { "type": "string", "description": "Captures errors from the payment gateway; value is null if not applicable.", "enum": [ "GATEWAY_FEE_PROCEESING_ERROR", "GATEWAY_API_PERMISSION_ERROR", "GATEWAY_DISCONNNECTED" ] }, "PaymentPlanOptions": { "required": [ "type" ], "type": "object", "properties": { "type": { "type": "string", "description": "Defines how the discount applies to payment-plan payments.", "enum": [ "NONE", "ALL_PAYMENTS" ] } }, "description": "Payment-plan applicability settings for this discount. When omitted from a create or update request, defaults to NONE." }, "PaymentState": { "type": "string", "description": "Current state of payment for the order.", "enum": [ "NOT_CHARGED", "AUTHORIZED", "PAID", "REFUNDED", "PENDING", "FAILED", "REFUND_PENDING", "REFUND_FAILED", "PARTIALLY_PAID" ] }, "PercentageTemplate": { "title": "PercentageTemplate", "required": [ "percentage", "type" ], "type": "object", "description": "Apply a percentage discount off the cart total.", "properties": { "type": { "type": "string" }, "percentage": { "maximum": 100, "exclusiveMinimum": 0, "type": "number", "description": "Percentage to subtract from the cart total. Range (0, 100]." } }, "discriminator": { "propertyName": "type" } }, "PhysicalProduct": { "title": "PhysicalProduct", "required": [ "createdOn", "id", "modifiedOn", "storePageId", "type" ], "type": "object", "description": "A PHYSICAL product.", "properties": { "createdOn": { "type": "string", "format": "date-time" }, "description": { "type": "string" }, "id": { "type": "string" }, "images": { "type": "array", "items": { "$ref": "#/components/schemas/ProductImage" } }, "isVisible": { "type": "boolean" }, "modifiedOn": { "type": "string", "format": "date-time" }, "name": { "type": "string" }, "seoOptions": { "$ref": "#/components/schemas/SeoOptions" }, "storePageId": { "type": "string" }, "tags": { "type": "array", "items": { "type": "string" } }, "type": { "$ref": "#/components/schemas/ProductTypeV2" }, "url": { "type": "string" }, "urlSlug": { "type": "string" }, "variantAttributes": { "type": "array", "items": { "type": "string" } }, "variants": { "type": "array", "items": { "$ref": "#/components/schemas/PhysicalProductVariant" } } }, "discriminator": { "propertyName": "type" } }, "PhysicalProductVariant": { "title": "PhysicalProductVariant", "type": "object", "properties": { "attributes": { "type": "object", "additionalProperties": { "type": "string" } }, "gtin": { "type": "string" }, "id": { "type": "string" }, "image": { "$ref": "#/components/schemas/ProductImage" }, "mpn": { "type": "string" }, "pricing": { "$ref": "#/components/schemas/FullProductPricing" }, "shippingMeasurements": { "$ref": "#/components/schemas/ProductMeasurements" }, "sku": { "type": "string" }, "stock": { "$ref": "#/components/schemas/ProductStock" } }, "description": "A variant of a PHYSICAL product." }, "Product": { "type": "object", "properties": { "createdOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the Product was created.", "format": "date-time" }, "description": { "type": "string", "description": "Long-form product description represented in HTML." }, "digitalGood": { "$ref": "#/components/schemas/DigitalGood" }, "id": { "type": "string", "description": "Unique Product id." }, "images": { "type": "array", "description": "List of product images.", "items": { "$ref": "#/components/schemas/ProductImage" } }, "isVisible": { "type": "boolean", "description": "Indicates whether the product is available for purchase." }, "modifiedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the Product was last modified.", "format": "date-time" }, "name": { "type": "string", "description": "Product name." }, "pricing": { "$ref": "#/components/schemas/ProductPricing" }, "seoOptions": { "$ref": "#/components/schemas/SeoOptions" }, "storePageId": { "type": "string", "description": "Identifier of the product's Store Page." }, "tags": { "type": "array", "description": "Keywords for search and organization purposes.", "items": { "type": "string", "description": "Keywords for search and organization purposes." } }, "type": { "$ref": "#/components/schemas/ProductType" }, "url": { "type": "string", "description": "Absolute URL of the product details page." }, "urlSlug": { "type": "string", "description": "URL slug for the new product." }, "variantAttributes": { "type": "array", "description": "List of attributes to distinguish variants of the product. Present for PHYSICAL products only.", "items": { "type": "string", "description": "List of attributes to distinguish variants of the product. Present for PHYSICAL products only." } }, "variants": { "type": "array", "description": "List of variants of the product. Present for PHYSICAL and GIFT_CARD products only.", "items": { "$ref": "#/components/schemas/ProductVariant" } } } }, "ProductCriteria": { "title": "ProductCriteria", "type": "object", "description": "Discount applies when the cart contains a specific product.", "required": [ "type" ], "properties": { "type": { "type": "string" }, "productId": { "type": "string", "description": "Identifier of the product the discount targets." }, "productName": { "type": "string", "description": "Display-time snapshot of the product name at the time the discount was created." } }, "discriminator": { "propertyName": "type" } }, "ProductDimensions": { "type": "object", "properties": { "height": { "type": "number", "description": "Height of the variant.", "format": "float" }, "length": { "type": "number", "description": "Length of the variant.", "format": "float" }, "unit": { "$ref": "#/components/schemas/ProductDimensionsUnit" }, "width": { "type": "number", "description": "Width of the variant.", "format": "float" } }, "description": "Physical dimensions of the variant." }, "ProductDimensionsUnit": { "type": "string", "description": "Unit of measurement. Supported values: `INCH`, `CENTIMETER`.", "enum": [ "CENTIMETER", "INCH" ] }, "ProductImage": { "type": "object", "properties": { "altText": { "type": "string", "description": "Alt text for the image; impacts SEO and appears in search results." }, "availableFormats": { "type": "array", "description": "Available image sizes. Use with `images.url` and a `format` query parameter to retrieve the image at a particular width.", "items": { "type": "string", "description": "Available image sizes. Use with `images.url` and a `format` query parameter to retrieve the image at a particular width." } }, "id": { "type": "string", "description": "Unique ProductImage id." }, "orderIndex": { "type": "integer", "description": "Position of the image in the product's image list.", "format": "int32" }, "originalSize": { "type": "object", "description": "Image size when first uploaded." }, "url": { "type": "string", "description": "Absolute URL of the image hosted on Squarespace." } }, "description": "Product image assigned to the variant." }, "ProductImageProcessingStatus": { "type": "object", "properties": { "id": { "type": "string" }, "status": { "$ref": "#/components/schemas/ImageProcessingStatus" } } }, "ProductListResponse": { "type": "object", "properties": { "products": { "type": "array", "items": { "$ref": "#/components/schemas/Product" } } } }, "ProductListResponseV2": { "type": "object", "properties": { "products": { "type": "array", "items": { "oneOf": [ { "$ref": "#/components/schemas/DigitalProduct" }, { "$ref": "#/components/schemas/GiftCardProduct" }, { "$ref": "#/components/schemas/PhysicalProduct" }, { "$ref": "#/components/schemas/ServiceProduct" } ] } } } }, "ProductMeasurements": { "type": "object", "properties": { "dimensions": { "$ref": "#/components/schemas/ProductDimensions" }, "weight": { "$ref": "#/components/schemas/ProductWeight" } }, "description": "Measurements of the variant when it's shipped. Present for PHYSICAL products only." }, "ProductPricing": { "type": "object", "properties": { "basePrice": { "$ref": "#/components/schemas/MonetaryAmount" }, "onSale": { "type": "boolean", "description": "Indicates whether the variant is sold according to its sale price. Present for PHYSICAL products only." }, "salePrice": { "$ref": "#/components/schemas/MonetaryAmount" } }, "description": "Present for DIGITAL products only. Digital products don't have variants, so pricing is at the product level." }, "ProductStock": { "type": "object", "properties": { "quantity": { "type": "integer", "description": "Number of units that can be purchased.", "format": "int32" }, "unlimited": { "type": "boolean", "description": "Indicates whether the variant has unlimited stock." } }, "description": "Available stock for the variant. Present for PHYSICAL products only." }, "ProductType": { "type": "string", "description": "Product type indicator. Value may be: `PHYSICAL` or `DIGITAL`.", "enum": [ "PHYSICAL", "DIGITAL" ] }, "ProductTypeV2": { "type": "string", "enum": [ "PHYSICAL", "SERVICE", "GIFT_CARD", "DIGITAL" ] }, "ProductV2": { "required": [ "createdOn", "id", "modifiedOn", "storePageId", "type" ], "type": "object", "properties": { "createdOn": { "type": "string", "format": "date-time" }, "description": { "type": "string" }, "id": { "type": "string" }, "images": { "type": "array", "items": { "$ref": "#/components/schemas/ProductImage" } }, "isVisible": { "type": "boolean" }, "modifiedOn": { "type": "string", "format": "date-time" }, "name": { "type": "string" }, "seoOptions": { "$ref": "#/components/schemas/SeoOptions" }, "storePageId": { "type": "string" }, "tags": { "type": "array", "items": { "type": "string" } }, "type": { "$ref": "#/components/schemas/ProductTypeV2" }, "url": { "type": "string" }, "urlSlug": { "type": "string" } }, "discriminator": { "propertyName": "type" } }, "ProductVariant": { "type": "object", "properties": { "attributes": { "type": "object", "description": "Specifies attribute-value pairs for the variant. Present for PHYSICAL products only." }, "id": { "type": "string", "description": "Unique ProductVariant id." }, "image": { "$ref": "#/components/schemas/ProductImage" }, "pricing": { "$ref": "#/components/schemas/ProductPricing" }, "shippingMeasurements": { "$ref": "#/components/schemas/ProductMeasurements" }, "sku": { "type": "string", "description": "Merchant-defined code that identifies the product variant." }, "stock": { "$ref": "#/components/schemas/ProductStock" } }, "description": "List of variants of the product. Present for PHYSICAL and GIFT_CARD products only." }, "ProductVariantV2": { "type": "object", "properties": { "id": { "type": "string" }, "image": { "$ref": "#/components/schemas/ProductImage" }, "sku": { "type": "string" } }, "description": "A product variant. The shape depends on the product type.", "oneOf": [ { "$ref": "#/components/schemas/PhysicalProductVariant" }, { "$ref": "#/components/schemas/GiftCardProductVariant" }, { "$ref": "#/components/schemas/ServiceProductVariant" } ] }, "ProductWeight": { "type": "object", "properties": { "unit": { "$ref": "#/components/schemas/ProductWeightUnit" }, "value": { "type": "number", "description": "Weight amount.", "format": "float" } }, "description": "Weight of the variant." }, "ProductWeightUnit": { "type": "string", "description": "Unit of measurement. Supported values: `KILOGRAM`, `POUND`.", "enum": [ "KILOGRAM", "POUND" ] }, "Profile": { "type": "object", "properties": { "acceptsMarketing": { "type": "boolean", "description": "Indicates whether the profile opted to receive marketing." }, "address": { "$ref": "#/components/schemas/Address" }, "createdOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the profile was created.", "format": "date-time" }, "email": { "type": "string", "description": "Profile email address." }, "firstName": { "type": "string", "description": "Profile first name." }, "hasAccount": { "type": "boolean", "description": "Indicates whether the profile has an account with the website." }, "id": { "type": "string", "description": "Unique Profile id." }, "isCustomer": { "type": "boolean", "description": "Indicates whether the profile has any commerce orders or donations with the website." }, "lastName": { "type": "string", "description": "Profile last name." }, "transactionsSummary": { "$ref": "#/components/schemas/TransactionsSummary" } } }, "ProfileListResponse": { "type": "object", "properties": { "profiles": { "type": "array", "items": { "$ref": "#/components/schemas/Profile" } } } }, "PromoCodeTrigger": { "title": "PromoCodeTrigger", "required": [ "promoCode", "type" ], "type": "object", "description": "Trigger for a discount that is unlocked by a shopper-entered promo code.", "properties": { "type": { "type": "string" }, "promoCode": { "pattern": "^[A-Za-z0-9_\\-]{1,50}$", "type": "string", "description": "Shopper-entered promo code. Required, non-empty, 1–50 characters; allowed characters: letters, digits, underscore, hyphen." } }, "discriminator": { "propertyName": "type" } }, "QueryContactsRequest": { "type": "object", "properties": { "acceptsMarketingWithDate": { "$ref": "#/components/schemas/AcceptsMarketingWithDate" }, "cursor": { "type": "string", "description": "The cursor for the next page of results. Use the value of `pagination.nextPageCursor` from the previous response." }, "donationAmount": { "$ref": "#/components/schemas/IntegerFilter" }, "donationCount": { "$ref": "#/components/schemas/IntegerFilter" }, "firstDonationOn": { "$ref": "#/components/schemas/DateFilter" }, "firstOrderOn": { "$ref": "#/components/schemas/DateFilter" }, "lastDonationOn": { "$ref": "#/components/schemas/DateFilter" }, "lastOrderOn": { "$ref": "#/components/schemas/DateFilter" }, "orderAmount": { "$ref": "#/components/schemas/IntegerFilter" }, "orderCount": { "$ref": "#/components/schemas/IntegerFilter" }, "pageSize": { "maximum": 1000, "minimum": 1, "type": "integer", "description": "The number of contacts to return per request.", "format": "int32", "default": 50 }, "searchString": { "type": "string", "description": "Search string for Name and Email address" }, "sortDirection": { "type": "string", "description": "Direction to sort results, ASCENDING or DESCENDING", "enum": [ "ASCENDING", "DESCENDING" ] }, "sortField": { "type": "string", "description": "Field to sort results by", "enum": [ "ID", "CREATED_ON", "EMAIL", "ACCEPTS_MARKETING_JOINED_ON", "FIRST_NAME", "LAST_NAME", "ORDER_COUNT", "LAST_ORDER_ON", "ORDER_AMOUNT", "DONATION_COUNT", "LAST_DONATION_ON", "DONATION_AMOUNT" ] } }, "examples": [ { "acceptsMarketingWithDate": { "acceptsMarketing": true, "joinedOn": { "before": "2025-11-21T10:00:00Z", "after": "2020-11-26T14:30:00Z" } }, "searchString": "jane", "firstOrderOn": { "before": "2025-11-21T10:00:00Z", "after": "2025-11-26T14:30:00Z" }, "lastOrderOn": { "before": "2025-11-21T10:00:00Z", "after": "2025-11-26T14:30:00Z" }, "orderCount": { "min": 1, "max": 10 }, "firstDonationOn": { "before": "2025-11-21T10:00:00Z", "after": "2025-11-26T14:30:00Z" }, "lastDonationOn": { "before": "2025-11-21T10:00:00Z", "after": "2025-11-26T14:30:00Z" }, "donationCount": { "min": 1, "max": 10 }, "pageSize": 50, "cursor": "abc", "sortField": "createdOn", "sortDirection": "ASCENDING" } ] }, "RetrieveTransactionsSummariesRequest": { "required": [ "contactIds", "groupBy" ], "type": "object", "properties": { "contactIds": { "maxItems": 1000, "minItems": 1, "type": "array", "items": { "type": "string", "description": "Unique contactId" } }, "groupBy": { "minLength": 1, "type": "string", "description": "Field to group results by, should be a contactId", "enum": [ "contactId" ], "examples": [ "contactId" ] } } }, "RetrieveTransactionsSummariesResponse": { "type": "object", "properties": { "transactionsSummaryWrappers": { "type": "array", "description": "List of transaction summary wrappers", "items": { "$ref": "#/components/schemas/TransactionsSummaryWrapper" } } } }, "SelectedShippingOption": { "required": [ "shippingOptionId", "shippingOptionName" ], "type": "object", "properties": { "isAllServicesSelected": { "type": "boolean", "description": "If true, all services within the shipping option are eligible." }, "selectedService": { "type": "string", "description": "Carrier service eligible for a free-shipping discount.", "enum": [ "FEDEX_GROUND", "FEDEX_GROUND_HOME_DELIVERY", "FEDEX_PRIORITY_OVERNIGHT", "FEDEX_STANDARD_OVERNIGHT", "FEDEX_2_DAY", "FEDEX_2_DAY_AM", "FEDEX_EXPRESS_SAVER", "FEDEX_FIRST_OVERNIGHT", "FEDEX_SAME_DAY", "FEDEX_SAME_DAY_CITY", "UPS_GROUND", "UPS_NEXT_DAY_AIR", "UPS_NEXT_DAY_AIR_SAVER", "UPS_NEXT_DAY_AIR_EARLY_AM", "UPS_TWO_DAY_AIR", "UPS_TWO_DAY_AIR_AM", "UPS_THREE_DAY_SELECT", "USPS_PRIORITY", "USPS_EXPRESS", "USPS_STANDARD" ] }, "shippingOptionId": { "type": "string", "description": "Identifier of the shipping option." }, "shippingOptionName": { "type": "string", "description": "Display-time snapshot of the shipping option name." } }, "description": "A shipping option targeted by a free-shipping discount." }, "SeoOptions": { "type": "object", "properties": { "description": { "type": "string" }, "title": { "type": "string" } }, "description": "Options for search engine optimization." }, "ServiceProduct": { "title": "ServiceProduct", "required": [ "createdOn", "id", "modifiedOn", "storePageId", "type" ], "type": "object", "description": "A SERVICE product.", "properties": { "createdOn": { "type": "string", "format": "date-time" }, "description": { "type": "string" }, "id": { "type": "string" }, "images": { "type": "array", "items": { "$ref": "#/components/schemas/ProductImage" } }, "isVisible": { "type": "boolean" }, "modifiedOn": { "type": "string", "format": "date-time" }, "name": { "type": "string" }, "seoOptions": { "$ref": "#/components/schemas/SeoOptions" }, "storePageId": { "type": "string" }, "tags": { "type": "array", "items": { "type": "string" } }, "type": { "$ref": "#/components/schemas/ProductTypeV2" }, "url": { "type": "string" }, "urlSlug": { "type": "string" }, "variantAttributes": { "type": "array", "items": { "type": "string" } }, "variants": { "type": "array", "items": { "$ref": "#/components/schemas/ServiceProductVariant" } } }, "discriminator": { "propertyName": "type" } }, "ServiceProductVariant": { "title": "ServiceProductVariant", "type": "object", "properties": { "attributes": { "type": "object", "additionalProperties": { "type": "string" } }, "id": { "type": "string" }, "image": { "$ref": "#/components/schemas/ProductImage" }, "pricing": { "$ref": "#/components/schemas/FullProductPricing" }, "sku": { "type": "string" }, "stock": { "$ref": "#/components/schemas/ProductStock" } }, "description": "A variant of a SERVICE product." }, "ShippingLine": { "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "method": { "type": "string", "description": "Description of the shipping option", "examples": [ "UPS Ground" ] } }, "description": "Array of shipping line items; describes the shipping options chosen at checkout." }, "ShopperFulfillmentNotificationBehavior": { "type": "string", "description": "Indicates whether to send a fulfillment notification email to the customer. Value may be SEND or SKIP.", "enum": [ "SEND", "SKIP" ] }, "SimpleProductPricing": { "type": "object", "properties": { "basePrice": { "$ref": "#/components/schemas/MonetaryAmount" } } }, "StandardErrorPayload": { "type": "object", "properties": { "contextId": { "type": "string" }, "details": { "type": "object" }, "message": { "type": "string" }, "subtype": { "type": "string", "enum": [ "MISSING_ARGUMENT", "INVALID_ARGUMENT", "INVALID_CONTENT_TYPE", "CONCURRENT_MODIFICATION", "INSUFFICIENT_STOCK", "STOCK_NOT_TRACKED", "STOCK_EXCEEDS_MAX", "CURRENCY_MISMATCH", "MEASUREMENT_STANDARD_MISMATCH", "INSUFFICIENT_PRODUCT_VARIANTS", "URL_SLUG_UNAVAILABLE", "SKU_UNAVAILABLE", "STORE_PAGE_NOT_FOUND", "STORE_PAGE_PRODUCT_LIMIT_REACHED", "IMAGE_LIMIT_REACHED", "WEBHOOK_SUBSCRIPTION_LIMIT_REACHED", "MISSING_SCOPE", "PROFILE_CANNOT_ACCEPT_MARKETING", "ENTITY_LIMIT_REACHED", "PRODUCT_UPDATE_CONFLICT", "DUPLICATE_USER_CONFLICT", "PROMO_CODE_CONFLICT", "INVENTORY_ITEM_NOT_FOUND", "PRODUCT_IMAGE_NOT_FOUND", "PRODUCT_VARIANT_NOT_FOUND", "OAUTH_TOKEN_REQUIRED", "FORBIDDEN_RESOURCE", "OPERATION_NOT_ALLOWED_FOR_PRODUCT_TYPE" ] }, "type": { "type": "string", "enum": [ "INVALID_REQUEST_ERROR", "AUTHORIZATION_ERROR", "WEBSITE_EXPIRED", "METHOD_NOT_ALLOWED", "CONFLICT", "TOO_MANY_REQUESTS", "SERVER_ERROR", "SERVICE_UNAVAILABLE" ] } } }, "StorePage": { "type": "object", "properties": { "id": { "type": "string" }, "isEnabled": { "type": "boolean" }, "title": { "type": "string" }, "urlSlug": { "type": "string" } } }, "SubscriptionOptions": { "required": [ "type" ], "type": "object", "properties": { "type": { "type": "string", "description": "Defines how the discount applies to subscription payments.", "enum": [ "EXCLUDED", "ALL_PAYMENTS", "LIMITED_PAYMENTS" ] } }, "description": "Subscription applicability settings for this discount. When omitted from a create or update request, defaults to EXCLUDED." }, "TaxInterpretation": { "type": "string", "description": "Indicates that lineItems.unitPricePaid includes tax. Values may be EXCLUSIVE or INCLUSIVE.", "enum": [ "INCLUSIVE", "EXCLUSIVE" ] }, "TransactionDiscount": { "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "description": { "type": "string", "description": "Discount description.", "examples": [ "Discount description" ] }, "name": { "type": "string", "description": "Discount name.", "examples": [ "Sales Discount" ] } }, "description": "Array of discounts for an order payment transaction; empty for donations." }, "TransactionDocument": { "type": "object", "properties": { "createdOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the Document was created.", "format": "date-time", "examples": [ "2019-11-18T21:20:05.354Z" ] }, "customerEmail": { "type": "string", "format": "email", "description": "Customer or donor email address. May be null for point of sale orders because email wasn't collected.", "examples": [ "customer@squarespace.com" ] }, "discounts": { "type": "array", "description": "Array of discounts for an order payment transaction; empty for donations.", "items": { "$ref": "#/components/schemas/TransactionDiscount" } }, "id": { "type": "string", "description": "Unique Document id.", "examples": [ "a7e4c6b5-d1fe-4e42-a932-f185b4b86829" ] }, "modifiedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the Document was last modified.", "format": "date-time", "examples": [ "2019-11-18T21:23:02.87Z" ] }, "paymentGatewayError": { "$ref": "#/components/schemas/PaymentGatewayError" }, "payments": { "type": "array", "description": "Array of payment transactions for the order or donation.", "items": { "$ref": "#/components/schemas/TransactionPayment" } }, "salesLineItems": { "type": "array", "description": "Array of sales items for an order payment transaction; empty for donations.", "items": { "$ref": "#/components/schemas/TransactionSalesLineItem" } }, "salesOrderId": { "type": "string", "description": "Unique order id; not applicable if payment transaction is a donation.", "examples": [ "5d71991aac180c3e7857e1df" ] }, "shippingLineItems": { "type": "array", "description": "Array of shipping line items.", "items": { "$ref": "#/components/schemas/TransactionShippingLineItem" } }, "total": { "$ref": "#/components/schemas/MonetaryAmount" }, "totalNetPayment": { "$ref": "#/components/schemas/MonetaryAmount" }, "totalNetSales": { "$ref": "#/components/schemas/MonetaryAmount" }, "totalNetShipping": { "$ref": "#/components/schemas/MonetaryAmount" }, "totalSales": { "$ref": "#/components/schemas/MonetaryAmount" }, "totalTaxes": { "$ref": "#/components/schemas/MonetaryAmount" }, "voided": { "type": "boolean", "description": "Flag; indicates order cancellation." } }, "description": "Array of Document resources." }, "TransactionListResponse": { "type": "object", "properties": { "documents": { "type": "array", "description": "Array of Document resources.", "items": { "$ref": "#/components/schemas/TransactionDocument" } } } }, "TransactionPayment": { "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "creditCardType": { "type": "string", "description": "Payment credit card type; possible values: VISA, MASTERCARD, DISCOVER, AMEX, JCB, and OTHER. null if credit card processing isn't available for the payment gateway.", "examples": [ "VISA" ] }, "externalCustomerId": { "type": "string", "description": "Unique customer id for the payment transaction provided by the payment gateway. Value is null if not available." }, "externalTransactionId": { "type": "string", "description": "Unique id for the payment transaction provided by the payment gateway.", "examples": [ "ch_1FFCJCLMG4qggZ0BzchTZjwR" ] }, "externalTransactionProperties": { "type": "array", "description": "Array of properties for the payment transaction provided by the payment gateway. Properties are listed in key/value pairs.", "items": { "$ref": "#/components/schemas/ExternalTransactionProperty" } }, "giftCardId": { "type": "string", "description": "Unique id for a Squarespace gift card. Value is null if a gift card was not used.", "format": "uuid", "examples": [ "ece69479-50bc-4763-9067-4473f3abcf83" ] }, "id": { "type": "string", "description": "Unique payment id.", "examples": [ "ece69479-50bc-4763-9067-4473f3abcf83" ] }, "netAmount": { "$ref": "#/components/schemas/MonetaryAmount" }, "paidOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the payment was made.", "format": "date-time", "examples": [ "2019-09-05T23:24:09.845Z" ] }, "processingFees": { "type": "array", "description": "Array of processing fees associated with the payment.", "items": { "$ref": "#/components/schemas/TransactionProcessingFee" } }, "provider": { "type": "string", "description": "Payment gateway used for processing.", "examples": [ "STRIPE" ] }, "refundedAmount": { "$ref": "#/components/schemas/MonetaryAmount" }, "refunds": { "type": "array", "description": "Array of refunds for the payment transaction.", "items": { "$ref": "#/components/schemas/TransactionRefund" } } }, "description": "Array of payment transactions for the order or donation." }, "TransactionProcessingFee": { "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "amountGatewayCurrency": { "$ref": "#/components/schemas/MonetaryAmount" }, "exchangeRate": { "type": "number", "description": "Foreign exchange rate between the payment gateway's and payment's currencies; determined when the payment is processed.", "examples": [ 1 ] }, "feeRefunds": { "type": "array", "description": "Array of processing fee refunds for the payment.", "items": { "$ref": "#/components/schemas/TransactionProcessingFeeRefund" } }, "id": { "type": "string", "description": "Unique processing fee id.", "examples": [ "2Jdsno3mdk" ] }, "netAmount": { "$ref": "#/components/schemas/MonetaryAmount" }, "netAmountGatewayCurrency": { "$ref": "#/components/schemas/MonetaryAmount" }, "refundedAmount": { "$ref": "#/components/schemas/MonetaryAmount" }, "refundedAmountGatewayCurrency": { "$ref": "#/components/schemas/MonetaryAmount" } }, "description": "Array of processing fees associated with the payment." }, "TransactionProcessingFeeRefund": { "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "amountGatewayCurrency": { "$ref": "#/components/schemas/MonetaryAmount" }, "exchangeRate": { "type": "number", "description": "Foreign exchange rate between the payment gateway's and payment's currencies; determined when the payment is processed.", "examples": [ 1 ] }, "externalTransactionId": { "type": "string", "description": "Unique id for the processing fee refund transaction provided by the payment gateway.", "examples": [ "3fjowGck2f" ] }, "id": { "type": "string", "description": "Unique processing fee refund id.", "examples": [ "c413a46c-b3e8-426d-8e0f-a4bc7a18cdd0" ] }, "refundedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the processing fee refund was issued.", "format": "date-time", "examples": [ "2019-11-18T21:22:06.5Z" ] } }, "description": "Array of processing fee refunds for the payment." }, "TransactionRefund": { "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "externalTransactionId": { "type": "string", "description": "Unique id for the refund transaction provided by the payment gateway.", "examples": [ "re_1Flhp8J4wh083J8f7qYtzU9m" ] }, "id": { "type": "string", "description": "Unique refund id.", "examples": [ "cfdb6b87-64bf-461a-b48b-eca7bd2389fc" ] }, "refundedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents refund issue date.", "format": "date-time", "examples": [ "2019-11-18T21:22:06.5Z" ] } }, "description": "Array of refunds for the payment transaction." }, "TransactionSalesLineItem": { "type": "object", "properties": { "discountAmount": { "$ref": "#/components/schemas/MonetaryAmount" }, "id": { "type": "string", "description": "Unique id for the sales item.", "examples": [ "d93f9637-fba6-4e8b-a1f3-24008f60c774" ] }, "taxes": { "type": "array", "description": "Array of taxes for the sale item.", "items": { "$ref": "#/components/schemas/TransactionTax" } }, "total": { "$ref": "#/components/schemas/MonetaryAmount" }, "totalNetSales": { "$ref": "#/components/schemas/MonetaryAmount" }, "totalSales": { "$ref": "#/components/schemas/MonetaryAmount" } }, "description": "Array of sales items for an order payment transaction; empty for donations." }, "TransactionShippingLineItem": { "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "description": { "type": "string", "description": "Description of the shipping line item as defined by the Squarespace merchant.", "examples": [ "USPS Flat Rate" ] }, "discountAmount": { "$ref": "#/components/schemas/MonetaryAmount" }, "id": { "type": "string", "description": "Unique id for the shipping line item.", "examples": [ "bd63d55e-0066-400e-9aa9-e75d4e6215b0" ] }, "netAmount": { "$ref": "#/components/schemas/MonetaryAmount" }, "taxes": { "type": "array", "description": "Array of taxes for the shipping line item.", "items": { "$ref": "#/components/schemas/TransactionTax" } } }, "description": "Array of shipping line items." }, "TransactionTax": { "type": "object", "properties": { "amount": { "$ref": "#/components/schemas/MonetaryAmount" }, "jurisdiction": { "type": "string", "description": "Tax jurisdiction in COUNTRY:{value},STATE:{value},LOCAL:{value} format. Examples: COUNTRY:US, COUNTRY:US,STATE:NY, and COUNTRY:US,STATE:NY,LOCAL:10001.", "examples": [ "COUNTRY:US,STATE:NY,LOCAL:10001" ] }, "name": { "type": "string", "description": "Tax classification as defined by the Squarespace merchant.", "examples": [ "Local Sales Tax" ] }, "rate": { "type": "string", "description": "Tax rate as a percent. For example, a value of 7.00 is a 7% tax.", "examples": [ "10.0" ] } }, "description": "Array of taxes for the shipping line item." }, "TransactionsSummary": { "type": "object", "properties": { "donationCount": { "type": "integer", "description": "Count of donations submitted.", "format": "int32" }, "firstDonationSubmittedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the profile's first donation was submitted.", "format": "date-time" }, "firstOrderSubmittedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the profile's first order was submitted.", "format": "date-time" }, "lastDonationSubmittedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the profile's latest donation was submitted.", "format": "date-time" }, "lastOrderSubmittedOn": { "type": "string", "description": "ISO 8601 UTC date and time string; represents when the profile's latest order was submitted.", "format": "date-time" }, "orderCount": { "type": "integer", "description": "Count of orders submitted.", "format": "int32" }, "totalDonationAmount": { "$ref": "#/components/schemas/MonetaryAmount" }, "totalOrderAmount": { "$ref": "#/components/schemas/MonetaryAmount" }, "totalRefundAmount": { "$ref": "#/components/schemas/MonetaryAmount" } }, "description": "Summary of profile's commerce transactions. If a profile has no commerce transactions, the object is still returned with null or 0 values. This information is calculated asynchronously; there may be a slight delay between when an order is created, and when it's reflected in the object." }, "TransactionsSummaryWrapper": { "type": "object", "properties": { "contactId": { "type": "string", "description": "Unique contact identifier", "examples": [ "a6e74e0c-2b4a-4b63-b4a3-9c5d1f3e8a7b" ] }, "transactionsSummary": { "$ref": "#/components/schemas/TransactionsSummary" } }, "description": "List of transaction summary wrappers" }, "UpdateAddressBookEntryRequest": { "required": [ "address" ], "type": "object", "properties": { "address": { "$ref": "#/components/schemas/ContactAddress" }, "defaultShipping": { "type": "boolean", "description": "Whether this entry should be the default shipping address. When updating the entry that is currently the default, changing this value from true to false has no effect." } } }, "UpdateAddressBookEntryResponse": { "type": "object", "properties": { "addressBookEntry": { "$ref": "#/components/schemas/AddressBookEntry" } } }, "UpdateProductImageOrderRequest": { "type": "object", "properties": { "afterImageId": { "$ref": "#/components/schemas/ChangeString" } } }, "UpdateProductImageRequest": { "type": "object", "properties": { "altText": { "$ref": "#/components/schemas/ChangeString" } } }, "UpdateProductMeasurements": { "type": "object", "properties": { "dimensions": { "$ref": "#/components/schemas/ChangeProductDimensions" }, "weight": { "$ref": "#/components/schemas/ChangeProductWeight" } } }, "UpdateProductPricing": { "type": "object", "properties": { "basePrice": { "$ref": "#/components/schemas/ChangeMonetaryAmount" }, "onSale": { "$ref": "#/components/schemas/ChangeBoolean" }, "salePrice": { "$ref": "#/components/schemas/ChangeMonetaryAmount" } } }, "UpdateProductRequest": { "type": "object", "properties": { "description": { "$ref": "#/components/schemas/ChangeString" }, "isVisible": { "$ref": "#/components/schemas/ChangeBoolean" }, "name": { "$ref": "#/components/schemas/ChangeString" }, "pricing": { "$ref": "#/components/schemas/ChangeUpdateProductPricing" }, "productAttributeNames": { "$ref": "#/components/schemas/ChangeListString" }, "seoData": { "$ref": "#/components/schemas/ChangeSeoOptions" }, "tags": { "$ref": "#/components/schemas/ChangeListString" }, "urlSlug": { "$ref": "#/components/schemas/ChangeString" } } }, "UpdateProductVariantRequest": { "type": "object", "properties": { "attributes": { "$ref": "#/components/schemas/ChangeMapStringString" }, "pricing": { "$ref": "#/components/schemas/ChangeUpdateProductPricing" }, "shippingMeasurements": { "$ref": "#/components/schemas/ChangeUpdateProductMeasurements" }, "sku": { "$ref": "#/components/schemas/ChangeString" } } }, "UpdateVariantRequestV2": { "type": "object", "properties": { "attributes": { "$ref": "#/components/schemas/ChangeMapStringString" }, "gtin": { "$ref": "#/components/schemas/ChangeString" }, "mpn": { "$ref": "#/components/schemas/ChangeString" }, "pricing": { "$ref": "#/components/schemas/ChangeUpdateProductPricing" }, "shippingMeasurements": { "$ref": "#/components/schemas/ChangeUpdateProductMeasurements" }, "sku": { "$ref": "#/components/schemas/ChangeString" } } }, "UploadProductImageResponse": { "type": "object", "properties": { "imageId": { "type": "string", "description": "Unique ProductImage id." } } }, "VariantOption": { "type": "object", "properties": { "optionName": { "type": "string", "description": "The name of the option (e.g. color, size, material)", "examples": [ "Size" ] }, "value": { "type": "string", "description": "The shopper-selected value for the option (e.g. red, small, cotton)", "examples": [ "Large" ] } }, "description": "Array of variant options; represents variant choices made by the customer. Null for download and gift card products." }, "WebsiteProfile": { "type": "object", "properties": { "currency": { "type": "string" }, "id": { "type": "string" }, "language": { "type": "string" }, "location": { "$ref": "#/components/schemas/Location" }, "measurementStandard": { "$ref": "#/components/schemas/MeasurementStandard" }, "siteId": { "type": "string" }, "timeZone": { "type": "string" }, "title": { "type": "string" }, "url": { "type": "string" } } } }, "securitySchemes": { "Authorization": { "in": "header", "scheme": "bearer", "type": "http" } } } }