---
updatedAt: 2025-02-20T00:12:51.000Z
agentTools:
  projectIndex: https://developers.credrails.com/llms.txt
---

# Payment Validation OTP

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "info": {
    "title": "Credrails OpenBanking API",
    "description": "APIs that allows customers to share their financial data with authorized third parties, such as other banks and fintech companies, to access new financial services and products.",
    "license": {
      "name": "Credrails Website",
      "url": "http://www.credrails.com"
    },
    "version": "v2,3,0"
  },
  "externalDocs": {
    "description": "API Documentation",
    "url": "https://credrails.readme.io/docs/open-banking"
  },
  "servers": [
    {
      "url": "https://dev-openbanking.pub.credrails.com",
      "description": "Dev Testing Environment"
    }
  ],
  "tags": [
    {
      "name": "Payments",
      "description": "Making payments"
    }
  ],
  "paths": {
    "/api/v2/payments/otp": {
      "post": {
        "tags": [
          "Payments"
        ],
        "summary": "Payment Validation OTP",
        "operationId": "paymentsValidationOtp",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ValidationOtpRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns informational response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SimpleRequestResponse"
                }
              }
            }
          },
          "201": {
            "description": "Returns an acknowledgement of received confirmation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SimpleRequestResponse"
                }
              }
            }
          },
          "202": {
            "description": "The request has not been completely processed. More information is required like OTP",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SimpleRequestResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad request, related to invalid parameters",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "*/*": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "SimpleRequestResponse": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "description": "Code representing request status",
            "enum": [
              "SUCCESS",
              "SECURITY_ANSWER_REQUESTED",
              "INVALID_USERNAME_OR_PASSWORD",
              "INVALID_INSTITUTION_PROVIDED",
              "INVALID_SECURITY_QUESTION_FOR_SESSION",
              "AUTH_NOT_PERFORMED_OR_TIMEDOUT",
              "INVALID_SESSION_ID",
              "UNKNOWN_ERROR",
              "OTP_REQUIRED",
              "INVALID_PAYMENT_TYPE_PROVIDED",
              "DUPLICATE_SESSION_ID",
              "UNSUPPORTED_FEATURE",
              "MISSING_KEY_VALUES",
              "FAILURE",
              "ERROR_RETRIEVING_BALANCE",
              "ERROR_LOGIN_IN",
              "INVALID_SECURITY_ANSWER",
              "INVALID_OTP",
              "ERROR_FETCHING_STATEMENTS",
              "BROWSER_CLOSED",
              "ERROR_RETRIEVING_CREDENTIALS",
              "ERROR_STARTING_BROWSER_SESSION",
              "INSTITUTION_NOT_REACHABLE",
              "BANK_NOT_FOUND",
              "ACCOUNT_PROVIDED_NOT_FOUND",
              "ERROR_MAKING_PAYMENT",
              "INSUFFICIENT_BALANCE",
              "INVALID_AMOUNT",
              "EMPTY_STATEMENT",
              "SESSION_INITIATION_ERROR",
              "OTP_OR_SECURITY_ANSWER_NOT_PROVIDED",
              "INCOMPLETE_OTP",
              "INVALID_CREDENTIALS",
              "ERROR",
              "NO_DATA",
              "RECEIVED",
              "CONSENT_ERROR",
              "USER_DISABLED",
              "REQUEST_CHANGE_PASSWORD",
              "ACCOUNT_BLOCKED",
              "CONFIG_EXISTS",
              "CONFIG_NOT_FOUND",
              "USERNAME_EXISTS",
              "INVALID_REFRESH_TOKEN",
              "LOGOUT_FAILURE",
              "BALANCE_CHECK_REQUEST_EXISTS",
              "PAYMENT_REQUEST_EXISTS",
              "CONSENT_NOT_OBTAINED",
              "INVALID_CONSENT",
              "INVALID_CONSENT_CREDENTIALS",
              "CONSENT_BEING_VALIDATED",
              "VALIDATION_FAILED",
              "PAYMENT_FAILED",
              "BALANCE_CHECK_FAILED",
              "BALANCE_CHECK_REQUEST_NOT_FOUND",
              "TRANSACTIONS_REQUEST_NOT_FOUND",
              "PAYMENT_REQUEST_NOT_FOUND",
              "INVALID_DATES",
              "CHARGES_NOT_SET",
              "INVALID_REQUEST_ID",
              "INVALID_FREQUENCY",
              "STATEMENT_FETCH_FAILED",
              "TRANSACTIONS_CALLBACK_FAILURE",
              "INVALID_USER",
              "TRANSACTIONS_QUEUING_FAILURE",
              "CHARGES_CREATION_FAILURE",
              "CHARGES_UPDATE_FAILURE",
              "GET_CHARGES_FAILURE",
              "PASSWORD_DECRYPTION_FAILED",
              "UNSUPPORTED_BANK_FOR_TRANSACTIONS",
              "INTEGRATION_TYPE_NOT_SUPPORTED",
              "SERVICE_UNAVAILABLE",
              "ERROR_RESETTING_PASSWORD",
              "SCOPE_NOT_SUPPORTED"
            ]
          },
          "message": {
            "type": "string",
            "description": "A message related with the response"
          },
          "requestId": {
            "type": "string",
            "description": "A uuid representing the request from the user"
          }
        }
      },
      "ApiErrorResponse": {
        "required": [
          "code"
        ],
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "description": "Code representing the error",
            "enum": [
              "SUCCESS",
              "SECURITY_ANSWER_REQUESTED",
              "INVALID_USERNAME_OR_PASSWORD",
              "INVALID_INSTITUTION_PROVIDED",
              "INVALID_SECURITY_QUESTION_FOR_SESSION",
              "AUTH_NOT_PERFORMED_OR_TIMEDOUT",
              "INVALID_SESSION_ID",
              "UNKNOWN_ERROR",
              "OTP_REQUIRED",
              "INVALID_PAYMENT_TYPE_PROVIDED",
              "DUPLICATE_SESSION_ID",
              "UNSUPPORTED_FEATURE",
              "MISSING_KEY_VALUES",
              "FAILURE",
              "ERROR_RETRIEVING_BALANCE",
              "ERROR_LOGIN_IN",
              "INVALID_SECURITY_ANSWER",
              "INVALID_OTP",
              "ERROR_FETCHING_STATEMENTS",
              "BROWSER_CLOSED",
              "ERROR_RETRIEVING_CREDENTIALS",
              "ERROR_STARTING_BROWSER_SESSION",
              "INSTITUTION_NOT_REACHABLE",
              "BANK_NOT_FOUND",
              "ACCOUNT_PROVIDED_NOT_FOUND",
              "ERROR_MAKING_PAYMENT",
              "INSUFFICIENT_BALANCE",
              "INVALID_AMOUNT",
              "EMPTY_STATEMENT",
              "SESSION_INITIATION_ERROR",
              "OTP_OR_SECURITY_ANSWER_NOT_PROVIDED",
              "INCOMPLETE_OTP",
              "INVALID_CREDENTIALS",
              "ERROR",
              "NO_DATA",
              "RECEIVED",
              "CONSENT_ERROR",
              "USER_DISABLED",
              "REQUEST_CHANGE_PASSWORD",
              "ACCOUNT_BLOCKED",
              "CONFIG_EXISTS",
              "CONFIG_NOT_FOUND",
              "USERNAME_EXISTS",
              "INVALID_REFRESH_TOKEN",
              "LOGOUT_FAILURE",
              "BALANCE_CHECK_REQUEST_EXISTS",
              "PAYMENT_REQUEST_EXISTS",
              "CONSENT_NOT_OBTAINED",
              "INVALID_CONSENT",
              "INVALID_CONSENT_CREDENTIALS",
              "CONSENT_BEING_VALIDATED",
              "VALIDATION_FAILED",
              "PAYMENT_FAILED",
              "BALANCE_CHECK_FAILED",
              "BALANCE_CHECK_REQUEST_NOT_FOUND",
              "TRANSACTIONS_REQUEST_NOT_FOUND",
              "PAYMENT_REQUEST_NOT_FOUND",
              "INVALID_DATES",
              "CHARGES_NOT_SET",
              "INVALID_REQUEST_ID",
              "INVALID_FREQUENCY",
              "STATEMENT_FETCH_FAILED",
              "TRANSACTIONS_CALLBACK_FAILURE",
              "INVALID_USER",
              "TRANSACTIONS_QUEUING_FAILURE",
              "CHARGES_CREATION_FAILURE",
              "CHARGES_UPDATE_FAILURE",
              "GET_CHARGES_FAILURE",
              "PASSWORD_DECRYPTION_FAILED",
              "UNSUPPORTED_BANK_FOR_TRANSACTIONS",
              "INTEGRATION_TYPE_NOT_SUPPORTED",
              "SERVICE_UNAVAILABLE",
              "ERROR_RESETTING_PASSWORD",
              "SCOPE_NOT_SUPPORTED"
            ]
          },
          "message": {
            "type": "string",
            "description": "A message related with the errors"
          },
          "errors": {
            "type": "array",
            "description": "List of errors that may help in debugging",
            "items": {
              "type": "string",
              "description": "List of errors that may help in debugging"
            }
          }
        }
      },
      "ValidationOtpRequest": {
        "required": [
          "requestId"
        ],
        "type": "object",
        "properties": {
          "requestId": {
            "maxLength": 64,
            "minLength": 6,
            "pattern": "[\\w_/.-]+",
            "type": "string",
            "description": "A uuid representing the request from the user"
          },
          "otp": {
            "type": "string",
            "description": "The one time password sent to the account owner"
          },
          "secretQuestionAnswer": {
            "type": "string",
            "description": "One of the answers pre-configured by the account owner"
          }
        }
      }
    }
  },
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true
  }
}
```