BulkGate Helpdesk
  • Languages iconEnglish
    • Czech

›Specification

Specification

  • Send One Time Password (OTP)
  • Verify One Time Password (OTP)
  • Resend One Time Password (OTP)

Send One Time Password (OTP)

API URL

URL used to send HTTP requests:

https://portal.bulkgate.com/api/1.0/otp/send
POST /api/1.0/otp/send HTTP/1.1
Host: portal.bulkgate.com
Content-Type: application/json
Cache-Control: no-cache

Parameters table

PARAMETER NAMEVALUEMANDATORYDEFAULT VALUE
application_idApplication IDYes-
application_tokenApplication tokenYes-
numberPhone number to which send the verification codeYes-
countryCountry code of phone numbernoThe value is taken from the profile.
languageLanguage of send otp messagenoen
code_typeType of code. (string, int, or combined)noint
code_lengthLength of verification code (4-100).no6
request_quota_numberThe number of requests per minute for request_quota_identificationno1
request_quota_identificationIdentification of the "OTP user / requester" to whom the request_quota_number quota per minute will apply. We recommend using an IP address for this identification.Yes-
trials_available_resendLimit of available resendsnonull - unlimited
trials_available_verificationLimit of available verificationnonull - unlimited
expirationExpiration of OTP request in seconds, after completion of this time request is not possible.no604800 - 7 days
channelAlternative channels. Channels are listed in a cascade, if we are unable to deliver your message via highest priority channel, channels lower in the cascade list will be used. If none of them manages to deliver sms will be used instead.noSMS object and/or Viber object

SMS object parameters table

PARAMETER NAMEVALUEMANDATORYDEFAULT VALUE
sender_idSender ID, see sender ID typenogSystem
sender_id_valueSender value - gOwn (e.g. "420 777 777 777"), gText (e.g. "BulkGate"), gProfile (e.g. "423"), gMobile or gPush (KEY)nonull

Viber object parameters table

PARAMETER NAMEVALUEMANDATORYDEFAULT VALUE
senderName of your registered sender for ViberYes-
expirationSeconds to wait until trying another channelno120

Example of full request

POST /api/1.0/otp/send HTTP/1.1
Host: portal.bulkgate.com
Content-Type: application/json
Cache-Control: no-cache

{
  "application_id": "APPLICATION_ID",
  "application_token": "APPLICATION_TOKEN",
  "number": "44777777777",
  "country": "gb",
  "language": "en",
  "code_type": "string",
  "code_length": 7,
  "request_quota_number": 1,
  "request_quota_identification": "127.0.0.1",
  "trials_available_resend": 2,
  "trials_available_verification": 5,
  "expiration": 3600,
  "channel": {
    "viber": {
      "sender": "Lt. Hagan",
      "expiration": 100
    },
    "sms": {
      "sender_id": "gText",
      "sender_id_value": "Lt-Hagan",
      "unicode": true
    }
  }
}

Response to this command may be:

In case of success:

{
    "data": {
        "id": "otp-id"
    }
}

In case of error:

{
    "type": "unknown_identity",
    "code": 400,
    "error": "Unknown identity",
    "detail": null
}
{
    "type": "invalid_input_parameters",
    "code": 400,
    "error": "Invalid input parameters",
    "detail": null
}
Verify One Time Password (OTP) →
  • API URL
    • Parameters table
    • SMS object parameters table
    • Viber object parameters table
    • Example of full request
  • Response to this command may be:
SolutionsSMS GatewayViber for BusinessBroadcastBulk SMSSMS NotificationsTwo-way SMSMobile ConnectWeb Portal
Partners & DevelopersSMS APIIntegrationsAffiliate programWhite label
SourcesBlogYouTubeFacebookLinkedInTwitterGitHubPackagist
CompanyContactPrivacyTerms and Conditions
Price listsPrice list SMSPrice list ViberPrice list Mobile Connect
SMS GatewayTOPefekt s.r.o. © 2023