# Retrieve accountContractId source: https://developer.mastercard.com/mastercard-processing-core/documentation/use-cases/cms-identifiers-search/retrieve-accountcontractid/index.md ## Overview {#overview} The use case describes how you retrieve the `accountContractId` based on different account contract identifiers and pass in the account contract creation request (a `POST` request sent to the `/accounts` endpoint) so that the CMS keeps mapping between them. ## Sequence diagram {#sequence-diagram} Diagram retrieve-accountcontractid ### Explanation {#explanation} 1. The server sends a `POST` request to the `/accounts/searches` endpoint by passing the following required fields in the request body: * `accountContractIdentifierType`, where you can choose from one of the following values: * `ACCOUNT_CONTRACT_NUMBER` * `CBS_NUMBER` * `accountContractIdentifier`, where you send the value of the selected `accountContractIdentifierType` field value 2. The API returns the `accountContractId` number stored in the CMS. Refer to [Sandbox testing](https://developer.mastercard.com/mastercard-processing-core/documentation/sandbox-testing/cms-identifiers-search/retrieve-accountcontractid/index.md) for information on how to execute the use case in the Sandbox environment. ## Endpoint {#endpoint} API Reference: `POST /accounts/searches`