This document describes the API that returns the name of the bank account associated with the submitted account details
Base URL
https://identity.cladfy.app/api/v1
API Endpoint:
POST /bank
Request Headers:
-
Payload: The data sent to the server in the request body. Here, it's a JSON object with a single key-value pair:
"bankid": 0
– A placeholder value that should be replaced with Bank ID from the Bank LIst Endpoint See Bank List Here.
"account": 0
– A placeholder value that should be replaced with an actual Bank Account number. -
Content-Type:
"application/json"
Indicates that the data in the request body is in JSON format. -
Accept:
"application/json"
Tells the server that the client expects the response to be in JSON format. -
Authorization:
"Basic 123"
Used for HTTP Basic Authentication, where"123"
is a placeholder for the base64-encodedusername:password
credentials. See guide here
Request Body:
The request body contains the driver's license. It should be JSON with the properties below.
bankid
: A given bank id. -string
.account
: A bank account number. -string
.
Example Request Body:
{
"bankid": 0,
"account": "string"
}
Response - 200:
The response will be a JSON object following the request data type specification: A typed dictionary containing the detailed results. Properties include:
-
success
- Type: boolean
- Required: Yes
-
response_code
- Type: integer
- Required: Yes
- Example:
200
-
message
- Type: string
- Required: Yes
- Example:
Bank Account Checked Successfully
-
data
- Type: object
- Required: Yes
- name
- Type: string
- Required: Yes
- Example:
XXXXXX XXXXX XXXXXXX
- account_number
- Type: string
- Required: Yes
- Example:
XXXXXXXXXX
- bank_name
- Type: string
- Required: Yes
- Example:
XXX
-
request_id
- Type: string
- Required: Yes
- Example:
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Example Response:
{
"success": true,
"response_code": 200,
"message": "Bank Account Checked Successfully",
"data": {
"name": "XXXXXX XXXXX XXXXXXX",
"account_number": "XXXXXXXXXX",
"bank_name": "XXX"
},
"request_id": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
}
Error Handling:
401 Unauthorized: If the API key is invalid.
400 Bad Request: If the request body is not valid JSON or missing required fields.
500 Internal Server Error: If an internal server error occurs during API request processing. The response will include an error message.
Python Test Example:
This test example demonstrates sending a POST request to the API endpoint with the Bank ID and Bank Account Number . The response will include the associated details.
import requests
url = "https://identity.cladfy.app/api/v1/bank"
payload = {
"bankid": 0,
"account": "string"
}
headers = {
"Content-Type": "application/json",
"Accept": "application/json",
"Authorization": "Basic 123"
}
response = requests.post(url, json=payload, headers=headers)
print(response.json())