Key |
Value |
Description |
---|---|---|
company_name (string)
|
alexander
|
REQUIRED
|
attn (string)
|
|
REQUIRED
|
address (string)
|
|
REQUIRED
|
pincode (number)
|
|
REQUIRED - 6 DIGIT
|
city (string)
|
|
REQUIRED
|
state (string)
|
|
REQUIRED
|
country (string)
|
India
|
REQUIRED
|
gst_code (number)
|
|
REQUIRED - 2 DIGIT
|
pan_number (string)
|
|
REQUIRED - 10 Characters
|
curl -X POST \ https://obligr.io/api_v2/user/billing_address \ -H 'authorization: Bearer [YOUR_API_KEY]' \ -H 'cache-control: no-cache' \ -H 'content-type: application/json' -d 'company_name=XXXX&attn=XXXX'
<?php $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://obligr.io/api_v2/user/billing_address", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_POSTFIELDS => array( 'company_name' => 'XXXX', 'attn' => 'XXXX', 'address' => 'XXXX', 'pincode' => '000000', 'city' => 'XXXX', 'state' => 'XXXX', 'country' => 'India', 'gst_number' => 'XXXX', 'gst_code' => '00', 'pan_number' => 'XXXX' ), CURLOPT_HTTPHEADER => array( "Authorization: Bearer [YOUR_API_KEY]", "Content-Type: application/json" ), )); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #:" . $err; } else { echo $response; }
{ "success": true, "error": null, "data": "Billing Address Successfully Saved." }