There are a number of keys and base level platform items to consider such as request construction. Please read our Platform and Integration guide before you start integration.
POST
https://api-sbox.dnlsrv.com/cigateway/id/v1/phoneIdUrl
An API that allows a customer to fetch a unique URL to be used to start the Silent Network Auth process. Note that the URL provided by Twilio is valid only for ten minutes.
Param Name | Type | Description |
---|---|---|
merchantId | string | Required. Your merchant ID that will be provided to you during onboarding. |
subMerchantId | string | Optional. Used by resellers, an ID that is assigned to the end customer. |
consentId | string | Required. Unique ID for the consent that is traceable if consent audit is required. |
consentTimeStamp | date-time | Required. The time stamp that the consentId was generated. Format must be as date time RFC3339. |
consumerMdn | string | Required. The MSISDN of the user that you want to check. Number to be provided in E.164 format. |
correlationId | string | Required. A nonce used by the customer that is unique to this transaction. |
consumerDeviceIP | string | Optional. The IP address of the user at the time of customer interaction, if known. IP address is used to identify if the user is on a supported carrier network. |
consumerDeviceUA | string | Optional. The User Agent string of the device which will help Twilio understand the type of device that is being used. |
air | Boolean | Optional. Allow HTTPS to HTTP redirect, if detection is supported only via http by the user's mobile carrier. |
redirectUrl | string | Optional. The redirectUrl allows the customer to regain control of the consumer flow after the phone number verification process is completed.If redirect parameter is not provided, Twilio will send HTTP 200 response. |
useCase | string | Optional. Numeric identifier attribute which contains use case information for the Silent Network Auth transaction. Can be one of:"1": Login use case"2": Registration use case"3": Transactional use case |
Header Name | Type | Description |
---|---|---|
Authorization | string | Required. The security key to use for Twilio APIs.NOTE: This may be different than your Twilio Account Auth Token - please confirm with your Sales Specialist. |
Content-Type | string | Required. Media type sent in the request. Only application/json is supported. |
Accept | string | Required. Media type for the response. Only application/json is supported. |
RequestTime | date-time | Required. Current date time when request is sent. |
A results
JSON object will be returned with the following values if the request was successful.
Value Name | Type | Description |
---|---|---|
correlationId | string | A nonce used by the customer that is unique to this transaction. This value is echoed back from the request, if it was provided. |
referenceId | string | Twilio's unique transaction identifier. |
EVURL | string | URL to which the end user's device should be redirected to complete Silent Network Auth. |
Sample successful response
1HTTP/1.1 200 OK2Content-Type: application/json34{5"results": {6"correlationId": "ABC0881973286793",7"referenceId": "20210204234640M163C264030",8"EVURL": "https://mi-sbox.dnlsrv.com/msbox/id/t20AHVnl?data=rmGtT04jwmgYhzW9OPw9P%2F1h1nZPqMZXbo%2B03SWQFJtXOq5SYHGhK1Bg4%2F666V55Zdq0dKkDVPNZjfS3duY1i1WCvaFEAIh6Cau4nuW29akzZxAfpWZCyDMFnrLihmpO54olamo6AOJCTzg4fIdGQEO9J291b8QhziMbd1RDWm5i9aCTg5O6v156vS%2BQQz0HwBfjJPPZ0eY5OR3sTUI58sK%2BgFEdV6pRPjN7VZz%2BKAJ3hwFWljJoHurWYHyqoIwnSuDh2EToE1JSRdSjaqEY2wedSJyYHMPjSTtXDm0H45ERO8tw7sdke8gkAE1Clcbj5mlCBBA%3D&cipherSalt=6tKfsd76F7j3hvbK&redirect=https%3A%2F%2FMerchantSite%2FRedirect&air=false"9}10}
An error
JSON object will be returned with the following values if the request failed.
Value Name | Type | Description |
---|---|---|
code | string | Indicates the reason the API call failed. Refer to Error Codes and Descriptions for a complete list. |
description | string | Additional information regarding the error condition. Sent only if error code is included in the response. |
correlationId | string | A nonce used by the customer that is unique to this transaction. This value is echoed back from the request, if it was provided. |
referenceId | string | Twilio's unique transaction identifier, if available. |
Sample failed response
1HTTP/1.1 400 Bad Request2Content-Type: application/json34{5"error": {6"correlationId": "ABC0881973286793",7"referenceId": "20210204234640M163C264030",8"code": "-5003",9"description": "Required parameter missing"10}11}
HTTP Status Code | Description |
---|---|
200 | Successful operation. |
400 | Malformed request submitted. |
500 | Internal system error. |
1// Installation2// npm install api --save34// Request5const sdk = require('api')('@boku/v4.4.1#1b5wc11kl6dx748s');67sdk.postV1Phoneidurl({8merchantId: '02200013919FB4',9subMerchantId: '00DF00000016',10consentId: '9783471AFDB69NH34',11consentTimeStamp: '2020-08-20T12:00:57+00:00',12consumerMdn: '+14085040458',13correlationId: '244464DFCB537E56',14consumerDeviceIP: '213.27.12.111',15consumerDeviceUA: 'Mozilla/5.0 (Linux; Android 6.0; Nexus 5 Build/MRA58N) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Mobile Safari/537.36',16air: false,17redirectUrl: 'https://MerchantSite/Redirect',18useCase: '1'19}, {20authorization: 'sha512-OrXJ9cUS2ZeapEbLBiONVK/eQtBwF1Mi7z2Zg9jNB9g71zvGSBXHqqhwfrfTD9WiNT+FIKOPvjToU/nhjml6Mw==?E5No',21requesttime: '2022-08-01T09:33:43+00:00'22})23.then(({ data }) => console.log(data))24.catch(err => console.error(err));
1{2"results": {3"evurl": "https://mi-sbox.dnlsrv.com/msbox/id/t20AHVnl?data=rmGtT04jwmgYhzW9OPw9P%2F1h1nZPqMZXbo%2B03SWQFJtXOq5SYHGhK1Bg4%2F666V55Zdq0dKkDVPNZjfS3duY1i1WCvaFEAIh6Cau4nuW29akzZxAfpWZCyDMFnrLihmpO54olamo6AOJCTzg4fIdGQEO9J291b8QhziMbd1RDWm5i9aCTg5O6v156vS%2BQQz0HwBfjJPPZ0eY5OR3sTUI58sK%2BgFEdV6pRPjN7VZz%2BKAJ3hwFWljJoHurWYHyqoIwnSuDh2EToE1JSRdSjaqEY2wedSJyYHMPjSTtXDm0H45ERO8tw7sdke8gkAE1Clcbj5mlCBBA%3D&cipherSalt=6tKfsd76F7j3hvbK&redirect=https%3A%2F%2FMerchantSite%2FRedirect&air=false",4"correlationId": "244464DFCB537E56",5"referenceId": "20221202163744M16301C147600"6}7}