MTC Release
The MTC Release API allows Providers and Direct Merchants to remove a MTC number. Authorized users of the API will have an entry in the APIKey table
Location:
WebAPI/Controllers/MTC/ReleaseMTCNumber/
URL:
- api.contactatonce.com/api/v1.0/releasemtcnumber/
- api.contactatonce.co.uk/api/v1.0/releasemtcnumber/
- api.contactatonce.com.au/api/v1.0/releasemtcnumber/
Parameters
Authorization header: “basic” + space + ApiKey
Request | |||
---|---|---|---|
Parameter | Type | Required | Description |
ReferenceId | String | Required for Provider | The ReferenceId assigned to the Provider's merchant. |
MTCNumber | String | Required | The MTC number assigned to the account. |
Response
Response | ||
---|---|---|
Parameter | Type | Description |
ReferenceID | String | The ReferenceId provided by the user. |
PhoneNumber | String | The new provisioned MTC number. |
Status | String | Will contain one of the following messages: 0 = Success 1 = Failure |
Application Messages
- EventCode:
“MTCReleaseError” = 6401 - Error Messages:
“The ReferenceId provided does not exist for specified provider”
“The phone number is not known for the given referenceId”
“There was an upstream error releasing the requested number”
Application Tasks
Validation
- For provider, ensure referenceId matches a qualified merchant.
- Check to see if phone number belongs to MID, PID combo.
Action
- If user is DM, get MerchantId from directMerchantProvider table, otherwise use merchantId obtain from ReferenceId search
- ProviderId set from APIKey
- Set ProviderType from SmsManager
- Release number with SmsManager
- Remove number from TextToChatNumber table
- Update number in window config if no long active number
- Return Status