{ "openapi": "3.0.0", "info": { "title": "B2B Contracts API", "description": "The B2B Contracts API allows you to create, retrieve, update, and delete contract documents stored in the `CL` data entity. Contracts represent B2B buyer accounts and carry restriction settings that control catalog visibility, checkout payment methods, and allowed payment systems.\r\n\r\nA contract can also represent a prospect, which is a B2B buyer account registered before its review concludes. The `prospectWorkflow` field carries that review state. To learn how to assemble a prospect and move it through review, see [Managing B2B prospects](https://developers.vtex.com/docs/guides/b2b-prospect-management).\r\n\r\n>⚠️ This feature is only available for stores using B2B Buyer Portal, which is currently available to select accounts.\r\n\r\n> ⚠️ When creating or updating contracts you must send each field according to the specifications provided. Otherwise, the Checkout module will not be able to autofill data during the shopping flow, which can block the purchase. Learn more about [SmartCheckout - Customer information automatic fill-in](https://help.vtex.com/en/tutorial/smartcheckout-preenchimento-automatico-de-dados-do-cliente--2Nuu3xAFzdhIzJIldAdtan#).", "version": "1.0" }, "servers": [ { "url": "https://{accountName}.{environment}.com.br", "description": "VTEX server URL.", "variables": { "accountName": { "description": "Name of the VTEX account. Used as part of the URL.", "default": "apiexamples" }, "environment": { "description": "Environment to use. Used as part of the URL.", "enum": [ "vtexcommercestable" ], "default": "vtexcommercestable" } } } ], "paths": { "/api/dataentities/CL/documents": { "post": { "tags": [ "Contracts" ], "summary": "Create contract", "description": "Creates a new contract with an ID automatically generated by VTEX, stored in the `CL` data entity. The request body is a JSON object where the key is the name of the field.\r\n\r\n> ⚠️ When creating contracts you must send each field according to the specifications provided. Otherwise, the Checkout module will not be able to autofill data during the shopping flow, which can block the purchase. Learn more about [SmartCheckout - Customer information automatic fill-in](https://help.vtex.com/en/tutorial/smartcheckout-preenchimento-automatico-de-dados-do-cliente--2Nuu3xAFzdhIzJIldAdtan#).\r\n\r\n>⚠️ This feature is only available for stores using B2B Buyer Portal, which is currently available to select accounts.\r\n\r\nAuthentication requires the `VtexIdclientAutCookie` header.\r\n\r\n**Note**: The following restriction fields are accepted:\r\n\r\n- `vtex.catalog.assortmentIds`\r\n- `vtex.checkout.creditCards`\r\n- `vtex.payments.paymentSystemIds`\r\n\r\n## Permissions\r\n\r\nAny user or [API key](https://developers.vtex.com/docs/guides/api-authentication-using-api-keys) must have at least one of the appropriate [License Manager resources](https://help.vtex.com/en/tutorial/license-manager-resources--3q6ztrC8YynQf6rdc6euk3) to be able to successfully run this request. Otherwise they will receive a status code `403` error. These are the applicable resources for this endpoint:\r\n\r\n| **Product** | **Category** | **Resource** |\r\n| --------------- | ----------------- | ----------------- |\r\n| Dynamic Storage | Dynamic storage generic resources | **Insert or update document (not remove)** |\r\n| Dynamic Storage | Dynamic storage generic resources | **Full access to all documents** |\r\n| Dynamic Storage | Dynamic storage generic resources | **Master Data administrator** |\r\n\r\nThere are no applicable [predefined roles](https://help.vtex.com/en/tutorial/predefined-roles--jGDurZKJHvHJS13LnO7Dy) for this resource list. You must [create a custom role](https://help.vtex.com/en/tutorial/roles--7HKK5Uau2H6wxE1rH5oRbc#creating-a-role) and add at least one of the resources above in order to use this endpoint. To learn more about machine authentication at VTEX, see [Authentication overview](https://developers.vtex.com/docs/guides/authentication).\r\n\r\n>\u2757 To prevent integrations from having excessive permissions, consider the [best practices for managing API keys](https://help.vtex.com/en/tutorial/best-practices-api-keys--7b6nD1VMHa49aI5brlOvJm) when assigning License Manager roles to integrations.", "operationId": "CreateContract", "parameters": [ { "$ref": "#/components/parameters/Content-Type" }, { "$ref": "#/components/parameters/Accept" } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateContractRequest" }, "example": { "email": "business-klub-spc@email.com", "firstName": "Business Klub", "lastName": "SPC", "document": "00000000000000", "documentType": "CNPJ", "corporateDocument": "00000000000000", "homePhone": "1122223333", "cellPhone": "1122223333", "corporateName": "Business Klub SPC", "tradeName": "Business Klub", "isCorporate": true, "stateRegistration": "", "isFreeStateRegistration": true, "priceTables": "CL4000060,CL3000007", "prospectWorkflow": "PENDING", "approved": false, "isActive": false, "restrictions": { "vtex.catalog": { "assortmentIds": [ "1", "2" ] }, "vtex.checkout": { "creditCards": [ "da89bc50-994e-4e39-9974-4a9d081cc3f4", "65ec3ec6-c504-4431-b17a-ea3800fb03d2" ] }, "vtex.payments": { "paymentSystemIds": [ "1", "2", "3", "4", "5", "7", "8", "9", "14", "21", "29", "31", "33", "34", "35", "36", "37", "48", "789" ] } } } } }, "required": true }, "responses": { "201": { "description": "Created", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateContractResponse" }, "example": { "id": "CL-2da4e9ab-050b-11f0-b37f-f4b136dbcce1", "href": "http://apiexamples.vtexcommercestable.com.br/api/dataentities/CL/documents/2da4e9ab-050b-11f0-b37f-f4b136dbcce1", "documentId": "2da4e9ab-050b-11f0-b37f-f4b136dbcce1" } } } } } } }, "/api/dataentities/CL/documents/{contractId}": { "get": { "tags": [ "Contracts" ], "summary": "Get contract by ID", "description": "This endpoint retrieves information related to a given contract, by its unique identifier. Use the `_fields=_all` query parameter to return all fields.\n\n>⚠️ This feature is only available for stores using B2B Buyer Portal, which is currently available to select accounts.\r\n\r\n## Permissions\r\n\r\nAny user or [API key](https://developers.vtex.com/docs/guides/api-authentication-using-api-keys) must have at least one of the appropriate [License Manager resources](https://help.vtex.com/en/tutorial/license-manager-resources--3q6ztrC8YynQf6rdc6euk3) to be able to successfully run this request. Otherwise they will receive a status code `403` error. These are the applicable resources for this endpoint:\r\n\r\n| **Product** | **Category** | **Resource** |\r\n| --------------- | ----------------- | ----------------- |\r\n| Dynamic Storage | Dynamic storage generic resources | **Read only documents** |\r\n| Dynamic Storage | Dynamic storage generic resources | **Insert or update document (not remove)** |\r\n| Dynamic Storage | Dynamic storage generic resources | **Full access to all documents** |\r\n| Dynamic Storage | Dynamic storage generic resources | **Master Data administrator** |\r\n\r\nThere are no applicable [predefined roles](https://help.vtex.com/en/tutorial/predefined-roles--jGDurZKJHvHJS13LnO7Dy) for this resource list. You must [create a custom role](https://help.vtex.com/en/tutorial/roles--7HKK5Uau2H6wxE1rH5oRbc#creating-a-role) and add at least one of the resources above in order to use this endpoint. To learn more about machine authentication at VTEX, see [Authentication overview](https://developers.vtex.com/docs/guides/authentication).\r\n\r\n>\u2757 To prevent integrations from having excessive permissions, consider the [best practices for managing API keys](https://help.vtex.com/en/tutorial/best-practices-api-keys--7b6nD1VMHa49aI5brlOvJm) when assigning License Manager roles to integrations.", "parameters": [ { "$ref": "#/components/parameters/Content-Type" }, { "$ref": "#/components/parameters/Accept" }, { "name": "contractId", "in": "path", "description": "ID of the contract to retrieve.", "required": true, "schema": { "type": "string" }, "example": "2da4e9ab-050b-11f0-b37f-f4b136dbcce1" }, { "name": "_fields", "in": "query", "description": "Specifies that all fields of the document should be included in the response.", "required": false, "schema": { "type": "string", "default": "_all" } } ], "responses": { "200": { "description": "OK", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ContractResponse" }, "example": { "cluster": null, "priceTables": "CL-4000060,CL3000007,NCC,NCNC", "isCorporate": null, "tradeName": null, "rclastcart": null, "rclastcartvalue": null, "rclastsession": null, "rclastsessiondate": null, "homePhone": "1122223333", "phone": null, "brandPurchasedTag": null, "brandVisitedTag": null, "categoryPurchasedTag": null, "categoryVisitedTag": null, "departmentVisitedTag": null, "productPurchasedTag": null, "productVisitedTag": null, "stateRegistration": "", "email": "business-klub-spc@email.com", "userId": "2da4e9ab-050b-11f0-b37f-f4b136dbcce1", "firstName": "Business Klub", "lastName": "SPC", "document": "00000000000000", "isNewsletterOptIn": false, "localeDefault": null, "attach": null, "approved": null, "prospectWorkflow": null, "birthDate": null, "businessPhone": "1122223333", "carttag": null, "checkouttag": null, "corporateDocument": null, "corporateName": "Business Klub SPC", "documentType": "CNPJ", "gender": null, "visitedProductWithStockOutSkusTag": null, "customerClass": null, "profilePicture": null, "birthDateMonth": null, "id": "2da4e9ab-050b-11f0-b37f-f4b136dbcce1", "accountId": "5f1fe23b-9fd1-417d-a4aa-14df38e7746e", "accountName": "qastore", "dataEntityId": "CL", "createdBy": "c83ea7ed-f875-4a10-b0a0-98d96aedab06", "createdIn": "2025-03-19T21:43:29.7132146Z", "updatedBy": null, "updatedIn": null, "lastInteractionBy": "c83ea7ed-f875-4a10-b0a0-98d96aedab06", "lastInteractionIn": "2025-03-19T21:43:29.7132146Z", "followers": [], "tags": [], "auto_filter": null, "restrictions": { "vtex.catalog": { "assortmentIds": [ "1", "2" ] }, "vtex.checkout": { "creditCards": [ "da89bc50-994e-4e39-9974-4a9d081cc3f4", "65ec3ec6-c504-4431-b17a-ea3800fb03d2" ] }, "vtex.payments": { "paymentSystemIds": [ "1", "2", "3", "4", "5", "7", "8", "9", "14", "21", "29", "31", "33", "34", "35", "36", "37", "48", "789" ] } } } } } } } }, "patch": { "tags": [ "Contracts" ], "summary": "Update contract by ID", "description": "Updates an existing contract by its unique identifier. When updating `restrictions`, send the complete object for the fields you are changing.\r\n\r\n> ⚠️ When updating contracts you must send each field according to the specifications provided. Otherwise, the Checkout module will not be able to autofill data during the shopping flow, which can block the purchase. Learn more about [SmartCheckout - Customer information automatic fill-in](https://help.vtex.com/en/tutorial/smartcheckout-preenchimento-automatico-de-dados-do-cliente--2Nuu3xAFzdhIzJIldAdtan#).\r\n\r\n>⚠️ This feature is only available for stores using B2B Buyer Portal, which is currently available to select accounts.\r\n\r\n**Note**: The following restriction fields are accepted:\r\n\r\n- `vtex.catalog.assortmentIds`\r\n- `vtex.checkout.creditCards`\r\n- `vtex.payments.paymentSystemIds`\r\n\r\n## Permissions\r\n\r\nAny user or [API key](https://developers.vtex.com/docs/guides/api-authentication-using-api-keys) must have at least one of the appropriate [License Manager resources](https://help.vtex.com/en/tutorial/license-manager-resources--3q6ztrC8YynQf6rdc6euk3) to be able to successfully run this request. Otherwise they will receive a status code `403` error. These are the applicable resources for this endpoint:\r\n\r\n| **Product** | **Category** | **Resource** |\r\n| --------------- | ----------------- | ----------------- |\r\n| Dynamic Storage | Dynamic storage generic resources | **Insert or update document (not remove)** |\r\n| Dynamic Storage | Dynamic storage generic resources | **Full access to all documents** |\r\n| Dynamic Storage | Dynamic storage generic resources | **Master Data administrator** |\r\n\r\nThere are no applicable [predefined roles](https://help.vtex.com/en/tutorial/predefined-roles--jGDurZKJHvHJS13LnO7Dy) for this resource list. You must [create a custom role](https://help.vtex.com/en/tutorial/roles--7HKK5Uau2H6wxE1rH5oRbc#creating-a-role) and add at least one of the resources above in order to use this endpoint. To learn more about machine authentication at VTEX, see [Authentication overview](https://developers.vtex.com/docs/guides/authentication).\r\n\r\n>\u2757 To prevent integrations from having excessive permissions, consider the [best practices for managing API keys](https://help.vtex.com/en/tutorial/best-practices-api-keys--7b6nD1VMHa49aI5brlOvJm) when assigning License Manager roles to integrations.", "parameters": [ { "$ref": "#/components/parameters/Content-Type" }, { "$ref": "#/components/parameters/Accept" }, { "name": "contractId", "in": "path", "description": "ID of the contract to update.", "required": true, "schema": { "type": "string" }, "example": "2da4e9ab-050b-11f0-b37f-f4b136dbcce1" } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateContractRequest" }, "example": { "email": "business-klub-spc@email.com", "firstName": "Business Klub", "lastName": "SPC", "document": "00000000000000", "documentType": "CNPJ", "corporateDocument": "00000000000000", "homePhone": "1122223333", "cellPhone": "1122223333", "corporateName": "Business Klub SPC", "tradeName": "Business Klub", "isCorporate": true, "stateRegistration": "", "isFreeStateRegistration": true, "priceTables": "CL4000060,CL3000007", "prospectWorkflow": "APPROVED", "approved": true, "isActive": false, "restrictions": { "vtex.catalog": { "assortmentIds": [ "1" ] }, "vtex.checkout": { "creditCards": [ "da89bc50-994e-4e39-9974-4a9d081cc3f4", "65ec3ec6-c504-4431-b17a-ea3800fb03d2" ] }, "vtex.payments": { "paymentSystemIds": [ "1", "2", "3", "4", "5", "7", "8", "9", "14", "21", "29", "31", "33", "34", "35", "36", "37", "48", "789" ] } } } } }, "required": true }, "responses": { "204": { "description": "No Content" } } }, "delete": { "tags": [ "Contracts" ], "summary": "Delete contract by ID", "description": "This endpoint allows you to delete a specific contract from the data entity `CL`.\n\n>⚠️ This feature is only available for stores using B2B Buyer Portal, which is currently available to select accounts.\r\n\r\n## Permissions\r\n\r\nAny user or [API key](https://developers.vtex.com/docs/guides/api-authentication-using-api-keys) must have at least one of the appropriate [License Manager resources](https://help.vtex.com/en/tutorial/license-manager-resources--3q6ztrC8YynQf6rdc6euk3) to be able to successfully run this request. Otherwise they will receive a status code `403` error. These are the applicable resources for this endpoint:\r\n\r\n| **Product** | **Category** | **Resource** |\r\n| --------------- | ----------------- | ----------------- |\r\n| Dynamic Storage | Dynamic storage generic resources | **Full access to all documents** |\r\n| Dynamic Storage | Dynamic storage generic resources | **Master Data administrator** |\r\n\r\nThere are no applicable [predefined roles](https://help.vtex.com/en/tutorial/predefined-roles--jGDurZKJHvHJS13LnO7Dy) for this resource list. You must [create a custom role](https://help.vtex.com/en/tutorial/roles--7HKK5Uau2H6wxE1rH5oRbc#creating-a-role) and add at least one of the resources above in order to use this endpoint. To learn more about machine authentication at VTEX, see [Authentication overview](https://developers.vtex.com/docs/guides/authentication).\r\n\r\n>\u2757 To prevent integrations from having excessive permissions, consider the [best practices for managing API keys](https://help.vtex.com/en/tutorial/best-practices-api-keys--7b6nD1VMHa49aI5brlOvJm) when assigning License Manager roles to integrations.", "parameters": [ { "$ref": "#/components/parameters/Content-Type" }, { "$ref": "#/components/parameters/Accept" }, { "name": "contractId", "in": "path", "description": "ID of the contract to be deleted.", "required": true, "schema": { "type": "string" }, "example": "2da4e9ab-050b-11f0-b37f-f4b136dbcce1" } ], "responses": { "204": { "description": "No Content" } } } } }, "security": [ { "appKey": [], "appToken": [] }, { "VtexIdclientAutCookie": [] } ], "components": { "securitySchemes": { "appKey": { "type": "apiKey", "in": "header", "name": "X-VTEX-API-AppKey", "description": "Unique identifier of the [API key](https://developers.vtex.com/docs/guides/api-authentication-using-api-keys)." }, "appToken": { "type": "apiKey", "in": "header", "name": "X-VTEX-API-AppToken", "description": "Secret token of the [API key](https://developers.vtex.com/docs/guides/api-authentication-using-api-keys)." }, "VtexIdclientAutCookie": { "type": "apiKey", "in": "header", "name": "VtexIdclientAutCookie", "description": "[User token](https://developers.vtex.com/docs/guides/api-authentication-using-user-tokens), valid for 24 hours." } }, "parameters": { "Content-Type": { "name": "Content-Type", "in": "header", "description": "Type of the content being sent.", "required": true, "style": "simple", "schema": { "type": "string", "default": "application/json" } }, "Accept": { "name": "Accept", "in": "header", "description": "HTTP Client Negotiation _Accept_ Header. Indicates the types of responses the client can understand.", "required": true, "style": "simple", "schema": { "type": "string", "default": "application/vnd.vtex.ds.v10+json" } } }, "schemas": { "UpdateContractRequest": { "type": "object", "description": "Request body for creating or updating a contract.", "required": [ "email", "firstName", "lastName", "document", "documentType", "isCorporate", "corporateName" ], "properties": { "email": { "type": "string", "description": "Email address of the contract.", "maxLength": 300 }, "firstName": { "type": "string", "description": "First name of the contract.", "maxLength": 300 }, "lastName": { "type": "string", "description": "Last name of the contract.", "maxLength": 300 }, "document": { "type": "string", "description": "Document number (e.g., CNPJ, CPF or Social ID).", "maxLength": 300 }, "documentType": { "type": "string", "description": "The type of document (e.g., \"EIN\", \"State Business Registration Number\").", "maxLength": 300 }, "corporateDocument": { "type": "string", "description": "Business document number if different from main document.", "maxLength": 300 }, "homePhone": { "type": "string", "description": "Home phone number.", "maxLength": 300 }, "cellPhone": { "type": "string", "description": "Cell phone number.", "maxLength": 300 }, "corporateName": { "type": "string", "description": "Legal name of the company.", "maxLength": 300 }, "tradeName": { "type": "string", "description": "Trade or fantasy name.", "maxLength": 300 }, "isCorporate": { "type": "boolean", "description": "Whether it's a legal entity. Always \"true\" for contracts.", "default": true }, "stateRegistration": { "type": "string", "description": "State registration number. Can be empty.", "maxLength": 300 }, "isFreeStateRegistration": { "type": "boolean", "description": "Indicates if the registration is free or exempt." }, "priceTables": { "type": "string", "description": "Comma-separated list of price tables." }, "prospectWorkflow": { "type": "string", "enum": [ "PENDING", "APPROVED", "REJECTED", null ], "nullable": true, "description": "Review state of a contract that represents a prospect, which is a B2B buyer account registered before its review concludes. Stored values are uppercase: `PENDING` means the prospect is under review, `APPROVED` means the review accepted the prospect, and `REJECTED` means the review refused it. At creation, omitting this field or sending `null` produces an ordinary contract rather than a prospect. The field is present on the `CL` entity for every account, with no merchant schema update. Before moving a prospect to `APPROVED`, the caller must confirm at least these two conditions: an organization unit exists whose `contractIds` scope contains this contract ID, and at least one active address in the `AD` data entity carries this contract ID in `userId`. A direct write does not refuse an ineligible approval, so those checks are yours to run. Send `approved` as `true` in the same request. Approval is a state change, not provisioning: moving a prospect to `APPROVED` creates no organization unit, address, or storefront user. To learn more, see [Managing B2B prospects](https://developers.vtex.com/docs/guides/b2b-prospect-management)." }, "approved": { "type": "boolean", "description": "Indicates whether the contract is approved to operate. Send `false` when creating a prospect. When moving `prospectWorkflow` to `APPROVED`, send `true` in the same request. When moving it to `REJECTED`, send `false`." }, "isActive": { "type": "boolean", "description": "Indicates whether the contract is active. Send `false` when creating a prospect so that the contract stays inactive while its review runs." }, "restrictions": { "type": "object", "description": "Object with restriction definitions for `vtex.catalog`, `vtex.checkout`, and `vtex.payments`.", "properties": { "vtex.catalog": { "type": "object", "description": "Contains catalog restrictions for the contract.", "properties": { "assortmentIds": { "type": "array", "description": "IDs of product assortments authorized for this contract (maximum of 20). An assortment is a reusable, merchant-level catalog profile, built from inclusion and exclusion collections, that controls which SKUs buyers can browse and purchase. This field defines the allowlist at the contract level. When empty, buyers fall back to the Sales Channel catalog associated with their navigation context. Organization Unit managers select one active assortment from this allowlist for their unit. Assortments supersede the legacy `collectionIds` restriction.", "items": { "type": "string", "description": "Unique identifier of a product assortment." } } } }, "vtex.checkout": { "type": "object", "description": "Contains restrictions regarding checkout.", "properties": { "creditCards": { "type": "array", "description": "A list of credit card IDs that the customer is allowed to use during checkout. These IDs reference cards stored in the BK entity, managed by the VTEX Checkout system.", "items": { "type": "string", "description": "Credit card ID." } } } }, "vtex.payments": { "type": "object", "description": "Contains restrictions regarding payments.", "properties": { "paymentSystemIds": { "type": "array", "description": "A list of numeric IDs that represent the allowed payment systems for the customer.", "items": { "type": "string", "description": "Payment system ID." } } } } } } } }, "CreateContractResponse": { "type": "object", "description": "Response body for a created contract.", "properties": { "id": { "type": "string", "description": "The ID of the created contract document." }, "href": { "type": "string", "description": "URL of the created document." }, "documentId": { "type": "string", "description": "The document ID." } } }, "ContractResponse": { "type": "object", "description": "Response body for a contract document.", "properties": { "cluster": { "type": "string", "nullable": true, "description": "Internal or optional analytics or tags fields." }, "priceTables": { "type": "string", "nullable": true, "description": "Comma-separated list of assigned price table codes." }, "isCorporate": { "type": "boolean", "nullable": true, "description": "Whether it's a legal entity." }, "tradeName": { "type": "string", "nullable": true, "description": "The trade name of the contract." }, "homePhone": { "type": "string", "nullable": true, "description": "contract phone number." }, "phone": { "type": "string", "nullable": true, "description": "contract phone number." }, "businessPhone": { "type": "string", "nullable": true, "description": "contract business phone number." }, "email": { "type": "string", "nullable": true, "description": "The email of the contract." }, "firstName": { "type": "string", "nullable": true, "description": "The first name of the contract." }, "lastName": { "type": "string", "nullable": true, "description": "The last name of the contract." }, "document": { "type": "string", "nullable": true, "description": "The document number of the contract." }, "documentType": { "type": "string", "nullable": true, "description": "The type of document (e.g., \"EIN\", \"State Business Registration Number\")." }, "corporateDocument": { "type": "string", "nullable": true, "description": "Business document number if different from main document." }, "corporateName": { "type": "string", "nullable": true, "description": "Company's registered corporate name." }, "stateRegistration": { "type": "string", "nullable": true, "description": "State-level registration number." }, "isNewsletterOptIn": { "type": "boolean", "nullable": true, "description": "Indicates newsletter opt-in status." }, "prospectWorkflow": { "type": "string", "enum": [ "PENDING", "APPROVED", "REJECTED", null ], "nullable": true, "description": "Review state of a contract that represents a prospect, which is a B2B buyer account registered before its review concludes. The field carries uppercase `PENDING` while the prospect is under review, `APPROVED` after the review accepts the prospect, and `REJECTED` after the review refuses it. On ordinary contracts, which never went through prospect review, the field carries `null`." }, "approved": { "type": "boolean", "nullable": true, "description": "Indicates whether the contract is approved to operate. A prospect carries `false` at creation and `true` after you move `prospectWorkflow` to `APPROVED`. This field can be `null` on contracts that never went through prospect review." }, "isActive": { "type": "boolean", "nullable": true, "description": "Indicates whether the contract is active. A prospect carries `false` at creation and stays inactive while its review runs." }, "createdIn": { "type": "string", "nullable": true, "description": "Timestamp of document creation." }, "lastInteractionIn": { "type": "string", "nullable": true, "description": "Timestamp of last update." }, "id": { "type": "string", "nullable": true, "description": "Unique contract ID." }, "userId": { "type": "string", "nullable": true, "description": "Same value as this contract's `id`. Before approving a prospect, confirm that at least one active address in the `AD` data entity has its own `userId` set to this contract ID." }, "dataEntityId": { "type": "string", "nullable": true, "description": "Fixed entity ID (always \"CL\")." }, "accountId": { "type": "string", "nullable": true, "description": "ID of the account related to this address." }, "accountName": { "type": "string", "nullable": true, "description": "Name of the account related to this address." }, "followers": { "type": "array", "nullable": true, "description": "List of users following this address record.", "items": { "type": "string", "description": "User ID." } }, "tags": { "type": "array", "nullable": true, "description": "List of tags associated with this address.", "items": { "type": "string", "description": "Tag value." } }, "restrictions": { "type": "object", "nullable": true, "description": "Object with restriction definitions for `vtex.catalog`, `vtex.checkout`, and `vtex.payments`.", "properties": { "vtex.catalog": { "type": "object", "description": "Contains catalog restrictions for the contract.", "properties": { "assortmentIds": { "type": "array", "description": "IDs of product assortments authorized for this contract (maximum of 20). An assortment is a reusable, merchant-level catalog profile, built from inclusion and exclusion collections, that controls which SKUs buyers can browse and purchase. This field defines the allowlist at the contract level. When empty, buyers fall back to the Sales Channel catalog associated with their navigation context. Organization Unit managers select one active assortment from this allowlist for their unit. Assortments supersede the legacy `collectionIds` restriction.", "items": { "type": "string", "description": "Unique identifier of a product assortment." } } } }, "vtex.checkout": { "type": "object", "description": "Contains restrictions regarding checkout.", "properties": { "creditCards": { "type": "array", "description": "A list of credit card IDs that the customer is allowed to use during checkout. These IDs reference cards stored in the BK entity, managed by the VTEX Checkout system.", "items": { "type": "string", "description": "Credit card ID." } } } }, "vtex.payments": { "type": "object", "description": "Contains restrictions regarding payments.", "properties": { "paymentSystemIds": { "type": "array", "description": "A list of numeric IDs that represent the allowed payment systems for the customer.", "items": { "type": "string", "description": "Payment system ID." } } } } } } } } } }, "tags": [ { "name": "Contracts" } ] }