Create a legal entity
curl --request POST \
--url https://api.quidkey.com/v1/merchants/{id}/legal-entities \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"legal_name": "<string>",
"registration_number": "<string>",
"country_of_incorporation": "<string>",
"incorporation_date": "2023-12-25",
"contact_full_name": "<string>",
"contact_email": "jsmith@example.com",
"contact_phone": "<string>",
"vat_number": "<string>",
"tax_id": "<string>",
"first_name": "<string>",
"last_name": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"date_of_birth": "2023-12-25",
"country_of_citizenship": "<string>"
}
'import requests
url = "https://api.quidkey.com/v1/merchants/{id}/legal-entities"
payload = {
"legal_name": "<string>",
"registration_number": "<string>",
"country_of_incorporation": "<string>",
"incorporation_date": "2023-12-25",
"contact_full_name": "<string>",
"contact_email": "jsmith@example.com",
"contact_phone": "<string>",
"vat_number": "<string>",
"tax_id": "<string>",
"first_name": "<string>",
"last_name": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"date_of_birth": "2023-12-25",
"country_of_citizenship": "<string>"
}
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({
legal_name: '<string>',
registration_number: '<string>',
country_of_incorporation: '<string>',
incorporation_date: '2023-12-25',
contact_full_name: '<string>',
contact_email: 'jsmith@example.com',
contact_phone: '<string>',
vat_number: '<string>',
tax_id: '<string>',
first_name: '<string>',
last_name: '<string>',
email: 'jsmith@example.com',
phone: '<string>',
date_of_birth: '2023-12-25',
country_of_citizenship: '<string>'
})
};
fetch('https://api.quidkey.com/v1/merchants/{id}/legal-entities', 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.quidkey.com/v1/merchants/{id}/legal-entities",
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([
'legal_name' => '<string>',
'registration_number' => '<string>',
'country_of_incorporation' => '<string>',
'incorporation_date' => '2023-12-25',
'contact_full_name' => '<string>',
'contact_email' => 'jsmith@example.com',
'contact_phone' => '<string>',
'vat_number' => '<string>',
'tax_id' => '<string>',
'first_name' => '<string>',
'last_name' => '<string>',
'email' => 'jsmith@example.com',
'phone' => '<string>',
'date_of_birth' => '2023-12-25',
'country_of_citizenship' => '<string>'
]),
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.quidkey.com/v1/merchants/{id}/legal-entities"
payload := strings.NewReader("{\n \"legal_name\": \"<string>\",\n \"registration_number\": \"<string>\",\n \"country_of_incorporation\": \"<string>\",\n \"incorporation_date\": \"2023-12-25\",\n \"contact_full_name\": \"<string>\",\n \"contact_email\": \"jsmith@example.com\",\n \"contact_phone\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"tax_id\": \"<string>\",\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\",\n \"country_of_citizenship\": \"<string>\"\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.quidkey.com/v1/merchants/{id}/legal-entities")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"legal_name\": \"<string>\",\n \"registration_number\": \"<string>\",\n \"country_of_incorporation\": \"<string>\",\n \"incorporation_date\": \"2023-12-25\",\n \"contact_full_name\": \"<string>\",\n \"contact_email\": \"jsmith@example.com\",\n \"contact_phone\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"tax_id\": \"<string>\",\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\",\n \"country_of_citizenship\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.quidkey.com/v1/merchants/{id}/legal-entities")
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 \"legal_name\": \"<string>\",\n \"registration_number\": \"<string>\",\n \"country_of_incorporation\": \"<string>\",\n \"incorporation_date\": \"2023-12-25\",\n \"contact_full_name\": \"<string>\",\n \"contact_email\": \"jsmith@example.com\",\n \"contact_phone\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"tax_id\": \"<string>\",\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\",\n \"country_of_citizenship\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"result": {
"_type": "legal_entity",
"_uri": "<string>",
"_view": "full",
"id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"type": "company",
"verification_status": "pending_verification",
"legal_name": "<string>",
"registration_number": "<string>",
"vat_number": "<string>",
"tax_id": "<string>",
"legal_structure": "limited_liability_company",
"country_of_incorporation": "<string>",
"incorporation_date": "2023-12-25",
"registered_address": {
"line1": "<string>",
"city": "<string>",
"country": "<string>",
"postal_code": "<string>",
"line2": "<string>",
"region": "<string>"
},
"operating_address": {
"line1": "<string>",
"city": "<string>",
"country": "<string>",
"postal_code": "<string>",
"line2": "<string>",
"region": "<string>"
},
"contact_full_name": "<string>",
"contact_email": "jsmith@example.com",
"contact_phone": "<string>",
"annual_revenue": {
"value": 4503599627370495,
"currency": "<string>"
},
"employee_count_band": "small",
"first_name": "<string>",
"last_name": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"date_of_birth": "2023-12-25",
"country_of_citizenship": "<string>",
"residential_address": {
"line1": "<string>",
"city": "<string>",
"country": "<string>",
"postal_code": "<string>",
"line2": "<string>",
"region": "<string>"
},
"merchants": [
{
"_link": "<string>",
"_type": "merchant",
"id": "<string>"
}
],
"parties": {
"_link": "<string>",
"_type": "collection"
}
},
"entities": {},
"not_included": [
{
"link": {
"_link": "<string>",
"_type": "<string>",
"id": "<string>"
},
"reason": "no_permission"
}
]
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}Legal entities
Create a legal entity
Creates the company or sole trader a merchant is. A merchant has one, so a repeat answers LEGAL_ENTITY_ALREADY_EXISTS, naming the one it has in details, as legal_entity. consent records the person’s acknowledgment of the current nacha_acknowledgment with the create. Leave it out to record it later through agreement_acceptance. The CONSENT_AGREEMENT_* codes name the agreement in details.
Credentials: partner, merchant
Permission: legal-entities:create
Create a legal entity
curl --request POST \
--url https://api.quidkey.com/v1/merchants/{id}/legal-entities \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"legal_name": "<string>",
"registration_number": "<string>",
"country_of_incorporation": "<string>",
"incorporation_date": "2023-12-25",
"contact_full_name": "<string>",
"contact_email": "jsmith@example.com",
"contact_phone": "<string>",
"vat_number": "<string>",
"tax_id": "<string>",
"first_name": "<string>",
"last_name": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"date_of_birth": "2023-12-25",
"country_of_citizenship": "<string>"
}
'import requests
url = "https://api.quidkey.com/v1/merchants/{id}/legal-entities"
payload = {
"legal_name": "<string>",
"registration_number": "<string>",
"country_of_incorporation": "<string>",
"incorporation_date": "2023-12-25",
"contact_full_name": "<string>",
"contact_email": "jsmith@example.com",
"contact_phone": "<string>",
"vat_number": "<string>",
"tax_id": "<string>",
"first_name": "<string>",
"last_name": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"date_of_birth": "2023-12-25",
"country_of_citizenship": "<string>"
}
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({
legal_name: '<string>',
registration_number: '<string>',
country_of_incorporation: '<string>',
incorporation_date: '2023-12-25',
contact_full_name: '<string>',
contact_email: 'jsmith@example.com',
contact_phone: '<string>',
vat_number: '<string>',
tax_id: '<string>',
first_name: '<string>',
last_name: '<string>',
email: 'jsmith@example.com',
phone: '<string>',
date_of_birth: '2023-12-25',
country_of_citizenship: '<string>'
})
};
fetch('https://api.quidkey.com/v1/merchants/{id}/legal-entities', 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.quidkey.com/v1/merchants/{id}/legal-entities",
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([
'legal_name' => '<string>',
'registration_number' => '<string>',
'country_of_incorporation' => '<string>',
'incorporation_date' => '2023-12-25',
'contact_full_name' => '<string>',
'contact_email' => 'jsmith@example.com',
'contact_phone' => '<string>',
'vat_number' => '<string>',
'tax_id' => '<string>',
'first_name' => '<string>',
'last_name' => '<string>',
'email' => 'jsmith@example.com',
'phone' => '<string>',
'date_of_birth' => '2023-12-25',
'country_of_citizenship' => '<string>'
]),
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.quidkey.com/v1/merchants/{id}/legal-entities"
payload := strings.NewReader("{\n \"legal_name\": \"<string>\",\n \"registration_number\": \"<string>\",\n \"country_of_incorporation\": \"<string>\",\n \"incorporation_date\": \"2023-12-25\",\n \"contact_full_name\": \"<string>\",\n \"contact_email\": \"jsmith@example.com\",\n \"contact_phone\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"tax_id\": \"<string>\",\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\",\n \"country_of_citizenship\": \"<string>\"\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.quidkey.com/v1/merchants/{id}/legal-entities")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"legal_name\": \"<string>\",\n \"registration_number\": \"<string>\",\n \"country_of_incorporation\": \"<string>\",\n \"incorporation_date\": \"2023-12-25\",\n \"contact_full_name\": \"<string>\",\n \"contact_email\": \"jsmith@example.com\",\n \"contact_phone\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"tax_id\": \"<string>\",\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\",\n \"country_of_citizenship\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.quidkey.com/v1/merchants/{id}/legal-entities")
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 \"legal_name\": \"<string>\",\n \"registration_number\": \"<string>\",\n \"country_of_incorporation\": \"<string>\",\n \"incorporation_date\": \"2023-12-25\",\n \"contact_full_name\": \"<string>\",\n \"contact_email\": \"jsmith@example.com\",\n \"contact_phone\": \"<string>\",\n \"vat_number\": \"<string>\",\n \"tax_id\": \"<string>\",\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"phone\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\",\n \"country_of_citizenship\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"result": {
"_type": "legal_entity",
"_uri": "<string>",
"_view": "full",
"id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"type": "company",
"verification_status": "pending_verification",
"legal_name": "<string>",
"registration_number": "<string>",
"vat_number": "<string>",
"tax_id": "<string>",
"legal_structure": "limited_liability_company",
"country_of_incorporation": "<string>",
"incorporation_date": "2023-12-25",
"registered_address": {
"line1": "<string>",
"city": "<string>",
"country": "<string>",
"postal_code": "<string>",
"line2": "<string>",
"region": "<string>"
},
"operating_address": {
"line1": "<string>",
"city": "<string>",
"country": "<string>",
"postal_code": "<string>",
"line2": "<string>",
"region": "<string>"
},
"contact_full_name": "<string>",
"contact_email": "jsmith@example.com",
"contact_phone": "<string>",
"annual_revenue": {
"value": 4503599627370495,
"currency": "<string>"
},
"employee_count_band": "small",
"first_name": "<string>",
"last_name": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"date_of_birth": "2023-12-25",
"country_of_citizenship": "<string>",
"residential_address": {
"line1": "<string>",
"city": "<string>",
"country": "<string>",
"postal_code": "<string>",
"line2": "<string>",
"region": "<string>"
},
"merchants": [
{
"_link": "<string>",
"_type": "merchant",
"id": "<string>"
}
],
"parties": {
"_link": "<string>",
"_type": "collection"
}
},
"entities": {},
"not_included": [
{
"link": {
"_link": "<string>",
"_type": "<string>",
"id": "<string>"
},
"reason": "no_permission"
}
]
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"field": "<string>",
"message": "<string>"
}
],
"retryable": true,
"request_id": "<string>"
}
}Authorizations
Body
application/json
Available options:
limited_liability_company, private_limited_company, public_limited_company, general_partnership, limited_liability_partnership, limited_partnership, limited_liability_entrepreneurial_company, joint_stock_company, single_member_llc, multi_member_llc, private_partnership, private_corporation, public_company