The One Time Passcode (OTP) API is a JSON-based RESTful API that enables merchants to verify OTP codes sent to buyers.
API requests
/- 2. Payment API 2.0
- One Time Passcode
Operations
- Regenerate OTP code for an active OTP process
Validate an OTP code
Regenerate OTP code for a...
One Time Passcode API (1.0.0)
Download OpenAPI description
Overview
URL
Ratepay GmbH
Languages
Servers
Ratepay Production Platform
https://api.ratepay.com
Ratepay Integration Platform
https://api-integration.ratepay.com
- Ratepay Production Platformhttps://api.ratepay.com/transaction/management/2fa/v1/verify/{transactionId}
- Ratepay Integration Platformhttps://api-integration.ratepay.com/transaction/management/2fa/v1/verify/{transactionId}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
https://api.ratepay.com/transaction/management/2fa/v1/verify/684CWYHCK05X2CN5K_N6 \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"otp_code": 15316
}'OTP code verified successfully
The time until another OTP can be sent. Might be null in error responses or when the OTP is verified.
The id of the transaction that was tied to the OTP process
Example: "684CWYHCK05X2CN5K_N6"
The machine-readable outcome of the operation of the OTP process
Enum"otp_sent""unexpected_client_input""otp_verified""otp_regenerated""unexpected_server_error""otp_exists""otp_failed""verify_attempt_failed""no_more_verification_attempts_left""transaction_not_found"
A detailed description of the outcome in English and German
Response
application/json
{ "timestamp": "2025-10-02T09:14:37.507714Z", "ratepayTransactionId": "684CWYHCK05X2CN5K_N6", "result": "otp_verified", "message": { "en": "Your code has been successfully verified.", "de": "Ihr Code wurde erfolgreich überprüft." }, "links": [ { … } ] }
- Ratepay Production Platformhttps://api.ratepay.com/transaction/management/2fa/v1/regenerate/{transactionId}
- Ratepay Integration Platformhttps://api-integration.ratepay.com/transaction/management/2fa/v1/regenerate/{transactionId}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
https://api.ratepay.com/transaction/management/2fa/v1/regenerate/684CWYHCK05X2CN5K_N6 \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'OTP code was regenerated successfully
The time until another OTP can be sent. Might be null in error responses or when the OTP is verified.
The id of the transaction that was tied to the OTP process
Example: "684CWYHCK05X2CN5K_N6"
The machine-readable outcome of the operation of the OTP process
Enum"otp_sent""unexpected_client_input""otp_verified""otp_regenerated""unexpected_server_error""otp_exists""otp_failed""verify_attempt_failed""no_more_verification_attempts_left""transaction_not_found"
A detailed description of the outcome in English and German
The time until the OTP process will expire and the OTP will be invalid.
Response
application/json
{ "timestamp": "2025-10-02T09:14:37.507764Z", "regenerationPossibleInSeconds": 60, "ratepayTransactionId": "684CWYHCK05X2CN5K_N6", "result": "otp_sent", "message": { "en": "The code has been sent to your phone number 0049123411223344.", "de": "Der Code wurde an Ihre Telefonnummer 0049123411223344 gesendet." }, "timeToLiveInSeconds": 120, "links": [ { … }, { … } ] }