Skip to main content
PATCH
/
clients
/
{id}
/
Partially update a client
curl --request PATCH \
  --url https://gate.chip-in.asia/api/v1/clients/{id}/ \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "email": "customer@example.com",
  "bank_account": "<string>",
  "bank_code": "<string>",
  "phone": "+60 123456789",
  "full_name": "<string>",
  "personal_code": "<string>",
  "street_address": "<string>",
  "country": "<string>",
  "city": "<string>",
  "zip_code": "<string>",
  "state": "<string>",
  "shipping_street_address": "<string>",
  "shipping_country": "<string>",
  "shipping_city": "<string>",
  "shipping_zip_code": "<string>",
  "shipping_state": "<string>",
  "cc": [
    "customer@example.com"
  ],
  "bcc": [
    "customer@example.com"
  ],
  "legal_name": "<string>",
  "brand_name": "<string>",
  "registration_number": "<string>",
  "tax_number": "<string>"
}
'
import requests

url = "https://gate.chip-in.asia/api/v1/clients/{id}/"

payload = {
"email": "customer@example.com",
"bank_account": "<string>",
"bank_code": "<string>",
"phone": "+60 123456789",
"full_name": "<string>",
"personal_code": "<string>",
"street_address": "<string>",
"country": "<string>",
"city": "<string>",
"zip_code": "<string>",
"state": "<string>",
"shipping_street_address": "<string>",
"shipping_country": "<string>",
"shipping_city": "<string>",
"shipping_zip_code": "<string>",
"shipping_state": "<string>",
"cc": ["customer@example.com"],
"bcc": ["customer@example.com"],
"legal_name": "<string>",
"brand_name": "<string>",
"registration_number": "<string>",
"tax_number": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

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

print(response.text)
const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
email: 'customer@example.com',
bank_account: '<string>',
bank_code: '<string>',
phone: '+60 123456789',
full_name: '<string>',
personal_code: '<string>',
street_address: '<string>',
country: '<string>',
city: '<string>',
zip_code: '<string>',
state: '<string>',
shipping_street_address: '<string>',
shipping_country: '<string>',
shipping_city: '<string>',
shipping_zip_code: '<string>',
shipping_state: '<string>',
cc: ['customer@example.com'],
bcc: ['customer@example.com'],
legal_name: '<string>',
brand_name: '<string>',
registration_number: '<string>',
tax_number: '<string>'
})
};

fetch('https://gate.chip-in.asia/api/v1/clients/{id}/', 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://gate.chip-in.asia/api/v1/clients/{id}/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'email' => 'customer@example.com',
'bank_account' => '<string>',
'bank_code' => '<string>',
'phone' => '+60 123456789',
'full_name' => '<string>',
'personal_code' => '<string>',
'street_address' => '<string>',
'country' => '<string>',
'city' => '<string>',
'zip_code' => '<string>',
'state' => '<string>',
'shipping_street_address' => '<string>',
'shipping_country' => '<string>',
'shipping_city' => '<string>',
'shipping_zip_code' => '<string>',
'shipping_state' => '<string>',
'cc' => [
'customer@example.com'
],
'bcc' => [
'customer@example.com'
],
'legal_name' => '<string>',
'brand_name' => '<string>',
'registration_number' => '<string>',
'tax_number' => '<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://gate.chip-in.asia/api/v1/clients/{id}/"

payload := strings.NewReader("{\n \"email\": \"customer@example.com\",\n \"bank_account\": \"<string>\",\n \"bank_code\": \"<string>\",\n \"phone\": \"+60 123456789\",\n \"full_name\": \"<string>\",\n \"personal_code\": \"<string>\",\n \"street_address\": \"<string>\",\n \"country\": \"<string>\",\n \"city\": \"<string>\",\n \"zip_code\": \"<string>\",\n \"state\": \"<string>\",\n \"shipping_street_address\": \"<string>\",\n \"shipping_country\": \"<string>\",\n \"shipping_city\": \"<string>\",\n \"shipping_zip_code\": \"<string>\",\n \"shipping_state\": \"<string>\",\n \"cc\": [\n \"customer@example.com\"\n ],\n \"bcc\": [\n \"customer@example.com\"\n ],\n \"legal_name\": \"<string>\",\n \"brand_name\": \"<string>\",\n \"registration_number\": \"<string>\",\n \"tax_number\": \"<string>\"\n}")

req, _ := http.NewRequest("PATCH", 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.patch("https://gate.chip-in.asia/api/v1/clients/{id}/")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"email\": \"customer@example.com\",\n \"bank_account\": \"<string>\",\n \"bank_code\": \"<string>\",\n \"phone\": \"+60 123456789\",\n \"full_name\": \"<string>\",\n \"personal_code\": \"<string>\",\n \"street_address\": \"<string>\",\n \"country\": \"<string>\",\n \"city\": \"<string>\",\n \"zip_code\": \"<string>\",\n \"state\": \"<string>\",\n \"shipping_street_address\": \"<string>\",\n \"shipping_country\": \"<string>\",\n \"shipping_city\": \"<string>\",\n \"shipping_zip_code\": \"<string>\",\n \"shipping_state\": \"<string>\",\n \"cc\": [\n \"customer@example.com\"\n ],\n \"bcc\": [\n \"customer@example.com\"\n ],\n \"legal_name\": \"<string>\",\n \"brand_name\": \"<string>\",\n \"registration_number\": \"<string>\",\n \"tax_number\": \"<string>\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://gate.chip-in.asia/api/v1/clients/{id}/")

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

request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"email\": \"customer@example.com\",\n \"bank_account\": \"<string>\",\n \"bank_code\": \"<string>\",\n \"phone\": \"+60 123456789\",\n \"full_name\": \"<string>\",\n \"personal_code\": \"<string>\",\n \"street_address\": \"<string>\",\n \"country\": \"<string>\",\n \"city\": \"<string>\",\n \"zip_code\": \"<string>\",\n \"state\": \"<string>\",\n \"shipping_street_address\": \"<string>\",\n \"shipping_country\": \"<string>\",\n \"shipping_city\": \"<string>\",\n \"shipping_zip_code\": \"<string>\",\n \"shipping_state\": \"<string>\",\n \"cc\": [\n \"customer@example.com\"\n ],\n \"bcc\": [\n \"customer@example.com\"\n ],\n \"legal_name\": \"<string>\",\n \"brand_name\": \"<string>\",\n \"registration_number\": \"<string>\",\n \"tax_number\": \"<string>\"\n}"

response = http.request(request)
puts response.read_body
{
  "email": "customer@example.com",
  "type": "<string>",
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "created_on": 1619740800,
  "updated_on": 1619740800,
  "bank_account": "<string>",
  "bank_code": "<string>",
  "phone": "+60 123456789",
  "full_name": "<string>",
  "personal_code": "<string>",
  "street_address": "<string>",
  "country": "<string>",
  "city": "<string>",
  "zip_code": "<string>",
  "state": "<string>",
  "shipping_street_address": "<string>",
  "shipping_country": "<string>",
  "shipping_city": "<string>",
  "shipping_zip_code": "<string>",
  "shipping_state": "<string>",
  "cc": [
    "customer@example.com"
  ],
  "bcc": [
    "customer@example.com"
  ],
  "legal_name": "<string>",
  "brand_name": "<string>",
  "registration_number": "<string>",
  "tax_number": "<string>"
}
"{\n  \"__all__\": {\n    \"message\": \"descriptive error message\",\n    \"code\": \"error_code\"\n  }\n}\n"

Authorizations

Authorization
string
header
required

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

Path Parameters

id
string<uuid>
required

Object ID (UUID)

Body

application/json

Record of a single customer of your business. Create one for each of your clients.

email
string<email>
required

Email address

Maximum string length: 254
Example:

"customer@example.com"

bank_account
string

Bank account number (e.g. IBAN)

Maximum string length: 34
bank_code
string

SWIFT/BIC code of the bank

Maximum string length: 11
phone
string

Phone number in the <country_code> <number> format

Maximum string length: 32
Example:

"+60 123456789"

full_name
string

Name and surname of client. It is advisable to include full_name in request body.

Maximum string length: 128
personal_code
string

Personal identification code of client

Maximum string length: 32
street_address
string

Street house number and flat address where applicable

Maximum string length: 128
country
string

Country code in the ISO 3166-1 alpha-2 format (e.g. 'GB')

Maximum string length: 2
city
string

City name

Maximum string length: 128
zip_code
string

ZIP or postal code

Maximum string length: 32
state
string

State code

Maximum string length: 128
shipping_street_address
string

Street house number and flat address where applicable

Maximum string length: 128
shipping_country
string

Country code in the ISO 3166-1 alpha-2 format (e.g. 'GB')

Maximum string length: 2
shipping_city
string

City name

Maximum string length: 128
shipping_zip_code
string

ZIP or postal code

Maximum string length: 32
shipping_state
string

State code

Maximum string length: 128
cc
string<email>[]

Email addresses to receive a carbon copy of all notification emails

Email address

Maximum string length: 254
bcc
string<email>[]

Email addresses to receive a blind carbon copy of all notification emails

Email address

Maximum string length: 254

Legal name of company

Maximum string length: 128
brand_name
string

Company brand name

Maximum string length: 128
registration_number
string

Registration number of company

Maximum string length: 32
tax_number
string

Tax payer registration number

Maximum string length: 32

Response

OK

Record of a single customer of your business. Create one for each of your clients.

email
string<email>
required

Email address

Maximum string length: 254
Example:

"customer@example.com"

type
string

Object type identifier

id
string<uuid>
created_on
integer<int64>

Object creation time

Example:

1619740800

updated_on
integer<int64>

Object last modification time

Example:

1619740800

bank_account
string

Bank account number (e.g. IBAN)

Maximum string length: 34
bank_code
string

SWIFT/BIC code of the bank

Maximum string length: 11
phone
string

Phone number in the <country_code> <number> format

Maximum string length: 32
Example:

"+60 123456789"

full_name
string

Name and surname of client. It is advisable to include full_name in request body.

Maximum string length: 128
personal_code
string

Personal identification code of client

Maximum string length: 32
street_address
string

Street house number and flat address where applicable

Maximum string length: 128
country
string

Country code in the ISO 3166-1 alpha-2 format (e.g. 'GB')

Maximum string length: 2
city
string

City name

Maximum string length: 128
zip_code
string

ZIP or postal code

Maximum string length: 32
state
string

State code

Maximum string length: 128
shipping_street_address
string

Street house number and flat address where applicable

Maximum string length: 128
shipping_country
string

Country code in the ISO 3166-1 alpha-2 format (e.g. 'GB')

Maximum string length: 2
shipping_city
string

City name

Maximum string length: 128
shipping_zip_code
string

ZIP or postal code

Maximum string length: 32
shipping_state
string

State code

Maximum string length: 128
cc
string<email>[]

Email addresses to receive a carbon copy of all notification emails

Email address

Maximum string length: 254
bcc
string<email>[]

Email addresses to receive a blind carbon copy of all notification emails

Email address

Maximum string length: 254

Legal name of company

Maximum string length: 128
brand_name
string

Company brand name

Maximum string length: 128
registration_number
string

Registration number of company

Maximum string length: 32
tax_number
string

Tax payer registration number

Maximum string length: 32