Skip to main content
POST
/
v1
/
platform
/
businesses
Create
curl --request POST \
  --url https://api.cadanapay.com/v1/platform/businesses \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "businessName": "Wayne Enterprise",
  "adminFirstName": "Jane",
  "adminLastName": "Founder",
  "address": {
    "countryCode": "US",
    "line1": "Street 1",
    "line2": "Apt 1",
    "city": "Gotham",
    "postalCode": "10001",
    "state": "NY"
  },
  "adminEmail": "admin@example.com",
  "idempotencyKey": "b6ae5da9-6342-4a58-bd50-8564d68d3f7e",
  "country": "US",
  "businessShortName": "W.E.",
  "suppressWelcomeEmail": false,
  "registrationId": "991234567",
  "adminPhoneNumber": {
    "countryCode": "1",
    "number": "2345678901"
  }
}
'
import requests

url = "https://api.cadanapay.com/v1/platform/businesses"

payload = {
"businessName": "Wayne Enterprise",
"adminFirstName": "Jane",
"adminLastName": "Founder",
"address": {
"countryCode": "US",
"line1": "Street 1",
"line2": "Apt 1",
"city": "Gotham",
"postalCode": "10001",
"state": "NY"
},
"adminEmail": "admin@example.com",
"idempotencyKey": "b6ae5da9-6342-4a58-bd50-8564d68d3f7e",
"country": "US",
"businessShortName": "W.E.",
"suppressWelcomeEmail": False,
"registrationId": "991234567",
"adminPhoneNumber": {
"countryCode": "1",
"number": "2345678901"
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
businessName: 'Wayne Enterprise',
adminFirstName: 'Jane',
adminLastName: 'Founder',
address: {
countryCode: 'US',
line1: 'Street 1',
line2: 'Apt 1',
city: 'Gotham',
postalCode: '10001',
state: 'NY'
},
adminEmail: 'admin@example.com',
idempotencyKey: 'b6ae5da9-6342-4a58-bd50-8564d68d3f7e',
country: 'US',
businessShortName: 'W.E.',
suppressWelcomeEmail: false,
registrationId: '991234567',
adminPhoneNumber: {countryCode: '1', number: '2345678901'}
})
};

fetch('https://api.cadanapay.com/v1/platform/businesses', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.cadanapay.com/v1/platform/businesses",
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([
'businessName' => 'Wayne Enterprise',
'adminFirstName' => 'Jane',
'adminLastName' => 'Founder',
'address' => [
'countryCode' => 'US',
'line1' => 'Street 1',
'line2' => 'Apt 1',
'city' => 'Gotham',
'postalCode' => '10001',
'state' => 'NY'
],
'adminEmail' => 'admin@example.com',
'idempotencyKey' => 'b6ae5da9-6342-4a58-bd50-8564d68d3f7e',
'country' => 'US',
'businessShortName' => 'W.E.',
'suppressWelcomeEmail' => false,
'registrationId' => '991234567',
'adminPhoneNumber' => [
'countryCode' => '1',
'number' => '2345678901'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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 := "https://api.cadanapay.com/v1/platform/businesses"

payload := strings.NewReader("{\n \"businessName\": \"Wayne Enterprise\",\n \"adminFirstName\": \"Jane\",\n \"adminLastName\": \"Founder\",\n \"address\": {\n \"countryCode\": \"US\",\n \"line1\": \"Street 1\",\n \"line2\": \"Apt 1\",\n \"city\": \"Gotham\",\n \"postalCode\": \"10001\",\n \"state\": \"NY\"\n },\n \"adminEmail\": \"admin@example.com\",\n \"idempotencyKey\": \"b6ae5da9-6342-4a58-bd50-8564d68d3f7e\",\n \"country\": \"US\",\n \"businessShortName\": \"W.E.\",\n \"suppressWelcomeEmail\": false,\n \"registrationId\": \"991234567\",\n \"adminPhoneNumber\": {\n \"countryCode\": \"1\",\n \"number\": \"2345678901\"\n }\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("Authorization", "Bearer <token>")
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("https://api.cadanapay.com/v1/platform/businesses")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"businessName\": \"Wayne Enterprise\",\n \"adminFirstName\": \"Jane\",\n \"adminLastName\": \"Founder\",\n \"address\": {\n \"countryCode\": \"US\",\n \"line1\": \"Street 1\",\n \"line2\": \"Apt 1\",\n \"city\": \"Gotham\",\n \"postalCode\": \"10001\",\n \"state\": \"NY\"\n },\n \"adminEmail\": \"admin@example.com\",\n \"idempotencyKey\": \"b6ae5da9-6342-4a58-bd50-8564d68d3f7e\",\n \"country\": \"US\",\n \"businessShortName\": \"W.E.\",\n \"suppressWelcomeEmail\": false,\n \"registrationId\": \"991234567\",\n \"adminPhoneNumber\": {\n \"countryCode\": \"1\",\n \"number\": \"2345678901\"\n }\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.cadanapay.com/v1/platform/businesses")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"businessName\": \"Wayne Enterprise\",\n \"adminFirstName\": \"Jane\",\n \"adminLastName\": \"Founder\",\n \"address\": {\n \"countryCode\": \"US\",\n \"line1\": \"Street 1\",\n \"line2\": \"Apt 1\",\n \"city\": \"Gotham\",\n \"postalCode\": \"10001\",\n \"state\": \"NY\"\n },\n \"adminEmail\": \"admin@example.com\",\n \"idempotencyKey\": \"b6ae5da9-6342-4a58-bd50-8564d68d3f7e\",\n \"country\": \"US\",\n \"businessShortName\": \"W.E.\",\n \"suppressWelcomeEmail\": false,\n \"registrationId\": \"991234567\",\n \"adminPhoneNumber\": {\n \"countryCode\": \"1\",\n \"number\": \"2345678901\"\n }\n}"

response = http.request(request)
puts response.read_body
{
  "businessId": "8ef9a712-cdae-4110-b1ea-9ba95abbee6e",
  "tenantKey": "biz123456"
}
{
"code": "invalid_request_body",
"message": "The request body provided is not valid",
"params": {
"field": "Value is invalid."
}
}
{
"code": "internal_error",
"message": "An unexpected error occurred. Please try again later."
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Create business request payload

businessName
string
required

Business name

Example:

"Wayne Enterprise"

adminFirstName
string
required

First name of the admin of the business

Example:

"Jane"

adminLastName
string
required

Last name of the admin of the business

Example:

"Founder"

address
object
required

Address

adminEmail
string
required

Person's email

Example:

"admin@example.com"

idempotencyKey
string
required

Unique string to prevent dedupe

Example:

"b6ae5da9-6342-4a58-bd50-8564d68d3f7e"

country
string
required
Example:

"US"

businessShortName
string

Shortname of the business

Example:

"W.E."

suppressWelcomeEmail
boolean
default:false

Whether you want to suppress the welcome email

registrationId
string

Registration id/number of the business

Example:

"991234567"

adminPhoneNumber
object

Person's phone number

Response

get user kyc response

businessId
string<uuid>
Example:

"8ef9a712-cdae-4110-b1ea-9ba95abbee6e"

tenantKey
string
Example:

"biz123456"