Create New Account for Client
curl --request POST \
--url http://localhost:8080/api/v1/accounts \
--header 'Content-Type: application/json' \
--data '
{
"account_name": "<string>",
"client_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"currency": "<string>",
"daily_limit": "10000.00",
"description": "<string>",
"external_account_id": "<string>",
"monthly_limit": "50000.00",
"yearly_limit": "500000.00"
}
'import requests
url = "http://localhost:8080/api/v1/accounts"
payload = {
"account_name": "<string>",
"client_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"currency": "<string>",
"daily_limit": "10000.00",
"description": "<string>",
"external_account_id": "<string>",
"monthly_limit": "50000.00",
"yearly_limit": "500000.00"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
account_name: '<string>',
client_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
currency: '<string>',
daily_limit: '10000.00',
description: '<string>',
external_account_id: '<string>',
monthly_limit: '50000.00',
yearly_limit: '500000.00'
})
};
fetch('http://localhost:8080/api/v1/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "8080",
CURLOPT_URL => "http://localhost:8080/api/v1/accounts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'account_name' => '<string>',
'client_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'currency' => '<string>',
'daily_limit' => '10000.00',
'description' => '<string>',
'external_account_id' => '<string>',
'monthly_limit' => '50000.00',
'yearly_limit' => '500000.00'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "http://localhost:8080/api/v1/accounts"
payload := strings.NewReader("{\n \"account_name\": \"<string>\",\n \"client_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"currency\": \"<string>\",\n \"daily_limit\": \"10000.00\",\n \"description\": \"<string>\",\n \"external_account_id\": \"<string>\",\n \"monthly_limit\": \"50000.00\",\n \"yearly_limit\": \"500000.00\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("http://localhost:8080/api/v1/accounts")
.header("Content-Type", "application/json")
.body("{\n \"account_name\": \"<string>\",\n \"client_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"currency\": \"<string>\",\n \"daily_limit\": \"10000.00\",\n \"description\": \"<string>\",\n \"external_account_id\": \"<string>\",\n \"monthly_limit\": \"50000.00\",\n \"yearly_limit\": \"500000.00\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:8080/api/v1/accounts")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"account_name\": \"<string>\",\n \"client_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"currency\": \"<string>\",\n \"daily_limit\": \"10000.00\",\n \"description\": \"<string>\",\n \"external_account_id\": \"<string>\",\n \"monthly_limit\": \"50000.00\",\n \"yearly_limit\": \"500000.00\"\n}"
response = http.request(request)
puts response.read_body{
"account_name": "<string>",
"account_number": "<string>",
"account_type": "CURRENT",
"available_balance": "1000.50",
"client_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2023-11-07T05:31:56Z",
"currency": "<string>",
"current_balance": "1000.50",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"opened_date": "2023-11-07T05:31:56Z",
"reserved_balance": "0.00",
"status": "PENDING",
"updated_at": "2023-11-07T05:31:56Z",
"closed_date": "2023-11-07T05:31:56Z",
"daily_limit": "10000.00",
"description": "<string>",
"external_account_id": "<string>",
"last_activity_date": "2023-11-07T05:31:56Z",
"monthly_limit": "50000.00",
"yearly_limit": "500000.00"
}Accounts
Create New Account for Client
Open an account (CURRENT, SAVINGS, or ESCROW) for an existing, non-blocked client. The account starts PENDING with zero balances and must be activated before it can transact.
POST
/
api
/
v1
/
accounts
Create New Account for Client
curl --request POST \
--url http://localhost:8080/api/v1/accounts \
--header 'Content-Type: application/json' \
--data '
{
"account_name": "<string>",
"client_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"currency": "<string>",
"daily_limit": "10000.00",
"description": "<string>",
"external_account_id": "<string>",
"monthly_limit": "50000.00",
"yearly_limit": "500000.00"
}
'import requests
url = "http://localhost:8080/api/v1/accounts"
payload = {
"account_name": "<string>",
"client_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"currency": "<string>",
"daily_limit": "10000.00",
"description": "<string>",
"external_account_id": "<string>",
"monthly_limit": "50000.00",
"yearly_limit": "500000.00"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
account_name: '<string>',
client_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
currency: '<string>',
daily_limit: '10000.00',
description: '<string>',
external_account_id: '<string>',
monthly_limit: '50000.00',
yearly_limit: '500000.00'
})
};
fetch('http://localhost:8080/api/v1/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "8080",
CURLOPT_URL => "http://localhost:8080/api/v1/accounts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'account_name' => '<string>',
'client_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'currency' => '<string>',
'daily_limit' => '10000.00',
'description' => '<string>',
'external_account_id' => '<string>',
'monthly_limit' => '50000.00',
'yearly_limit' => '500000.00'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "http://localhost:8080/api/v1/accounts"
payload := strings.NewReader("{\n \"account_name\": \"<string>\",\n \"client_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"currency\": \"<string>\",\n \"daily_limit\": \"10000.00\",\n \"description\": \"<string>\",\n \"external_account_id\": \"<string>\",\n \"monthly_limit\": \"50000.00\",\n \"yearly_limit\": \"500000.00\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("http://localhost:8080/api/v1/accounts")
.header("Content-Type", "application/json")
.body("{\n \"account_name\": \"<string>\",\n \"client_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"currency\": \"<string>\",\n \"daily_limit\": \"10000.00\",\n \"description\": \"<string>\",\n \"external_account_id\": \"<string>\",\n \"monthly_limit\": \"50000.00\",\n \"yearly_limit\": \"500000.00\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:8080/api/v1/accounts")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"account_name\": \"<string>\",\n \"client_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"currency\": \"<string>\",\n \"daily_limit\": \"10000.00\",\n \"description\": \"<string>\",\n \"external_account_id\": \"<string>\",\n \"monthly_limit\": \"50000.00\",\n \"yearly_limit\": \"500000.00\"\n}"
response = http.request(request)
puts response.read_body{
"account_name": "<string>",
"account_number": "<string>",
"account_type": "CURRENT",
"available_balance": "1000.50",
"client_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2023-11-07T05:31:56Z",
"currency": "<string>",
"current_balance": "1000.50",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"opened_date": "2023-11-07T05:31:56Z",
"reserved_balance": "0.00",
"status": "PENDING",
"updated_at": "2023-11-07T05:31:56Z",
"closed_date": "2023-11-07T05:31:56Z",
"daily_limit": "10000.00",
"description": "<string>",
"external_account_id": "<string>",
"last_activity_date": "2023-11-07T05:31:56Z",
"monthly_limit": "50000.00",
"yearly_limit": "500000.00"
}Body
application/json
Account Type - Different types of accounts that can be created
Available options:
CURRENT, SAVINGS, ESCROW Example:
"10000.00"
Example:
"50000.00"
Example:
"500000.00"
Response
Account created successfully
Account - Core account entity
Account Type - Different types of accounts that can be created
Available options:
CURRENT, SAVINGS, ESCROW Example:
"1000.50"
Example:
"1000.50"
Example:
"0.00"
Account Status - Current status of the account
Available options:
PENDING, ACTIVE, SUSPENDED, CLOSED Example:
"10000.00"
Example:
"50000.00"
Example:
"500000.00"