cURL
curl -X PATCH "$EXSITED_BASE_URL/api/v4/accounts/ACC0001/information" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"account": {
"description": "Key wholesale customer"
}
}'from exsited import build_client
client = build_client()
response = client.accounts.update_account_information(
"ACC0001", {"account": {"description": "Key wholesale customer"}}
)
print(response.data)
import {buildClient} from 'exsited';
const client = await buildClient();
const response = await client.accounts.updateAccountInformation('ACC0001', {
account: {description: 'Key wholesale customer'},
});
console.log(response.data);
use Exsited\Client\ClientRegistry;
$client = ClientRegistry::buildClient();
$response = $client->accounts->updateAccountInformation('ACC0001', [
'account' => ['description' => 'Key wholesale customer'],
]);
print_r($response->data);
import com.exsited.client.ApiResponse;
import com.exsited.client.ClientRegistry;
import com.exsited.client.ExsitedClient;
import com.exsited.resources.accounts.accounts_dto.AccountsDto.Account;
import java.util.Map;
ExsitedClient client = ClientRegistry.buildClient();
ApiResponse<Account> response = client.accounts().updateAccountInformation(
"ACC0001",
Map.of("account", Map.of("description", "Key wholesale customer")));
System.out.println(response.getMap());
using Exsited.Client;
await using var client = ExsitedClient.BuildClient();
var response = await client.Accounts.UpdateAccountInformationAsync(
"ACC0001",
new Dictionary<string, object?>
{
["account"] = new Dictionary<string, object?>
{
["description"] = "Key wholesale customer",
},
});
Console.WriteLine(response.Json);
import 'package:exsited/exsited.dart';
final client = buildClient();
final response = await client.accounts.updateAccountInformation('ACC0001', {
'account': {'description': 'Key wholesale customer'},
});
print(response.map);
import (
"context"
"fmt"
"log"
exsited "github.com/exsited/exsited-sdk-go/v4"
)
client, err := exsited.BuildClient(nil)
if err != nil {
log.Fatal(err)
}
defer client.Close()
response, err := client.Accounts().UpdateAccountInformation(context.Background(), "ACC0001", map[string]any{
"account": map[string]any{"description": "Key wholesale customer"},
}, nil)
if err != nil {
log.Fatal(err)
}
fmt.Println(response.Map)
{
"account": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"status": "<string>",
"type": "<string>",
"display_name": "<string>",
"email_address": "<string>",
"description": "<string>",
"currency": {
"code": "<string>",
"href": "<string>",
"id": "<string>",
"name": "<string>",
"object": "<string>"
},
"time_zone": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"href": "<string>"
},
"tax": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"custom_form": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"href": "<string>"
},
"parent_account_id": "<string>",
"image_url": "<unknown>",
"workflow_status": "<string>",
"social_links": {
"website": "<string>",
"linkedin": "<string>",
"twitter": "<string>",
"facebook": "<string>"
},
"communication_preferences": [
{
"channel": "<string>",
"enabled": true
}
],
"invoice_parent_account": true,
"portal_access": true,
"origin": "<string>",
"group": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"manager": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"sales_rep": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"user_team": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"accounting_code": {
"account_receivable": "<string>"
},
"pricing_level": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"referral_tracking": "<string>",
"created_on": "<string>",
"last_updated_on": "<string>",
"created_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"last_updated_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"version": 123,
"href": "<string>",
"addresses": [
{
"object": "<string>",
"id": "<string>",
"address_line_1": "<string>",
"address_line_2": "<string>",
"address_line_3": "<string>",
"address_line_4": "<string>",
"address_line_5": "<string>",
"city": "<string>",
"state": "<string>",
"country": "<string>",
"postal_code": "<string>",
"default_billing": true,
"default_shipping": true,
"href": "<string>"
}
],
"contacts": [
{
"object": "<string>",
"id": "<string>",
"type": "<string>",
"billing_contact": true,
"shipping_contact": true,
"receives_billing_information": true,
"name": {
"salutation": "<string>",
"first": "<string>",
"middle": "<string>",
"last": "<string>",
"designation": "<string>"
},
"email": {
"address": "<string>",
"do_not_email": true,
"email_opted_out": true
},
"phone": {
"country_code": "<string>",
"area_code": "<string>",
"number": "<string>",
"do_not_call": true,
"call_opted_out": true,
"dialing_code": "<string>",
"formatted": "<string>"
},
"mobile": {
"country_code": "<string>",
"area_code": "<string>",
"number": "<string>",
"do_not_call": true,
"call_opted_out": true,
"dialing_code": "<string>",
"formatted": "<string>"
},
"fax": {
"country_code": "<string>",
"area_code": "<string>",
"number": "<string>",
"do_not_call": true,
"call_opted_out": true,
"dialing_code": "<string>",
"formatted": "<string>"
},
"address": {
"city": "<string>",
"country": "<string>",
"country_code": "<unknown>",
"line_1": "<string>",
"line_2": "<string>",
"postal_code": "<string>",
"state": "<string>"
},
"custom_attributes": [
{
"name": "<string>",
"value": "<unknown>"
}
],
"created_on": "<string>",
"last_updated_on": "<string>",
"created_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"last_updated_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"version": 123
}
],
"payment_methods": [
{
"object": "<string>",
"id": "<string>",
"processor_type": "<string>",
"status": "<string>",
"default": true,
"restricted_to_orders": true,
"specified_order_ids": "<unknown>",
"processor": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"href": "<string>"
},
"reference": "<string>",
"payment_count": 123,
"last_used_at": "<string>",
"created_on": "<string>",
"last_updated_on": "<string>",
"created_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"last_updated_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"version": 123
}
],
"billing_preferences": {
"communication_profile": "<string>",
"invoice_mode": "<string>",
"invoice_term": "<string>",
"billing_period": "<string>",
"billing_start_date": "<string>",
"billing_start_day_of_month": 123,
"charges_aligned_to_billing": true,
"payment_processor": "<string>",
"payment_mode": "<string>",
"payment_term": "<string>",
"payment_term_alignment": "<string>",
"consolidate_invoice": true,
"fulfillment_mode": "<string>",
"fulfillment_term": "<string>",
"proforma_properties": "<unknown>",
"communication_group": "<string>",
"billing_mode": "<string>",
"charging_period": "<string>",
"charging_and_billing_alignment": "<string>",
"charging_start_date": "<string>",
"event_profile": "<string>"
},
"custom_attributes": [
{
"href": "<string>",
"id": "<string>",
"name": "<string>",
"object": "<string>",
"type": "<string>",
"value": "<unknown>"
}
],
"custom_objects": [
{
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
}
],
"inventories": "<array>",
"partial_invoices": "<array>",
"activity_logs": "<array>",
"payment_method": {
"object": "<string>",
"id": "<string>",
"processor_type": "<string>",
"status": "<string>",
"default": true,
"restricted_to_orders": true,
"specified_order_ids": "<unknown>",
"processor": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"href": "<string>"
},
"reference": "<string>",
"payment_count": 123,
"last_used_at": "<string>",
"created_on": "<string>",
"last_updated_on": "<string>",
"created_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"last_updated_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"version": 123
},
"tax_id": "<unknown>",
"tax_id_number": "<unknown>"
}
}Accounts
Update an account's information
Changes an account’s core fields and returns the account.
PATCH
/
accounts
/
{account_id}
/
information
cURL
curl -X PATCH "$EXSITED_BASE_URL/api/v4/accounts/ACC0001/information" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"account": {
"description": "Key wholesale customer"
}
}'from exsited import build_client
client = build_client()
response = client.accounts.update_account_information(
"ACC0001", {"account": {"description": "Key wholesale customer"}}
)
print(response.data)
import {buildClient} from 'exsited';
const client = await buildClient();
const response = await client.accounts.updateAccountInformation('ACC0001', {
account: {description: 'Key wholesale customer'},
});
console.log(response.data);
use Exsited\Client\ClientRegistry;
$client = ClientRegistry::buildClient();
$response = $client->accounts->updateAccountInformation('ACC0001', [
'account' => ['description' => 'Key wholesale customer'],
]);
print_r($response->data);
import com.exsited.client.ApiResponse;
import com.exsited.client.ClientRegistry;
import com.exsited.client.ExsitedClient;
import com.exsited.resources.accounts.accounts_dto.AccountsDto.Account;
import java.util.Map;
ExsitedClient client = ClientRegistry.buildClient();
ApiResponse<Account> response = client.accounts().updateAccountInformation(
"ACC0001",
Map.of("account", Map.of("description", "Key wholesale customer")));
System.out.println(response.getMap());
using Exsited.Client;
await using var client = ExsitedClient.BuildClient();
var response = await client.Accounts.UpdateAccountInformationAsync(
"ACC0001",
new Dictionary<string, object?>
{
["account"] = new Dictionary<string, object?>
{
["description"] = "Key wholesale customer",
},
});
Console.WriteLine(response.Json);
import 'package:exsited/exsited.dart';
final client = buildClient();
final response = await client.accounts.updateAccountInformation('ACC0001', {
'account': {'description': 'Key wholesale customer'},
});
print(response.map);
import (
"context"
"fmt"
"log"
exsited "github.com/exsited/exsited-sdk-go/v4"
)
client, err := exsited.BuildClient(nil)
if err != nil {
log.Fatal(err)
}
defer client.Close()
response, err := client.Accounts().UpdateAccountInformation(context.Background(), "ACC0001", map[string]any{
"account": map[string]any{"description": "Key wholesale customer"},
}, nil)
if err != nil {
log.Fatal(err)
}
fmt.Println(response.Map)
{
"account": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"status": "<string>",
"type": "<string>",
"display_name": "<string>",
"email_address": "<string>",
"description": "<string>",
"currency": {
"code": "<string>",
"href": "<string>",
"id": "<string>",
"name": "<string>",
"object": "<string>"
},
"time_zone": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"href": "<string>"
},
"tax": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"custom_form": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"href": "<string>"
},
"parent_account_id": "<string>",
"image_url": "<unknown>",
"workflow_status": "<string>",
"social_links": {
"website": "<string>",
"linkedin": "<string>",
"twitter": "<string>",
"facebook": "<string>"
},
"communication_preferences": [
{
"channel": "<string>",
"enabled": true
}
],
"invoice_parent_account": true,
"portal_access": true,
"origin": "<string>",
"group": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"manager": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"sales_rep": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"user_team": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"accounting_code": {
"account_receivable": "<string>"
},
"pricing_level": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
},
"referral_tracking": "<string>",
"created_on": "<string>",
"last_updated_on": "<string>",
"created_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"last_updated_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"version": 123,
"href": "<string>",
"addresses": [
{
"object": "<string>",
"id": "<string>",
"address_line_1": "<string>",
"address_line_2": "<string>",
"address_line_3": "<string>",
"address_line_4": "<string>",
"address_line_5": "<string>",
"city": "<string>",
"state": "<string>",
"country": "<string>",
"postal_code": "<string>",
"default_billing": true,
"default_shipping": true,
"href": "<string>"
}
],
"contacts": [
{
"object": "<string>",
"id": "<string>",
"type": "<string>",
"billing_contact": true,
"shipping_contact": true,
"receives_billing_information": true,
"name": {
"salutation": "<string>",
"first": "<string>",
"middle": "<string>",
"last": "<string>",
"designation": "<string>"
},
"email": {
"address": "<string>",
"do_not_email": true,
"email_opted_out": true
},
"phone": {
"country_code": "<string>",
"area_code": "<string>",
"number": "<string>",
"do_not_call": true,
"call_opted_out": true,
"dialing_code": "<string>",
"formatted": "<string>"
},
"mobile": {
"country_code": "<string>",
"area_code": "<string>",
"number": "<string>",
"do_not_call": true,
"call_opted_out": true,
"dialing_code": "<string>",
"formatted": "<string>"
},
"fax": {
"country_code": "<string>",
"area_code": "<string>",
"number": "<string>",
"do_not_call": true,
"call_opted_out": true,
"dialing_code": "<string>",
"formatted": "<string>"
},
"address": {
"city": "<string>",
"country": "<string>",
"country_code": "<unknown>",
"line_1": "<string>",
"line_2": "<string>",
"postal_code": "<string>",
"state": "<string>"
},
"custom_attributes": [
{
"name": "<string>",
"value": "<unknown>"
}
],
"created_on": "<string>",
"last_updated_on": "<string>",
"created_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"last_updated_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"version": 123
}
],
"payment_methods": [
{
"object": "<string>",
"id": "<string>",
"processor_type": "<string>",
"status": "<string>",
"default": true,
"restricted_to_orders": true,
"specified_order_ids": "<unknown>",
"processor": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"href": "<string>"
},
"reference": "<string>",
"payment_count": 123,
"last_used_at": "<string>",
"created_on": "<string>",
"last_updated_on": "<string>",
"created_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"last_updated_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"version": 123
}
],
"billing_preferences": {
"communication_profile": "<string>",
"invoice_mode": "<string>",
"invoice_term": "<string>",
"billing_period": "<string>",
"billing_start_date": "<string>",
"billing_start_day_of_month": 123,
"charges_aligned_to_billing": true,
"payment_processor": "<string>",
"payment_mode": "<string>",
"payment_term": "<string>",
"payment_term_alignment": "<string>",
"consolidate_invoice": true,
"fulfillment_mode": "<string>",
"fulfillment_term": "<string>",
"proforma_properties": "<unknown>",
"communication_group": "<string>",
"billing_mode": "<string>",
"charging_period": "<string>",
"charging_and_billing_alignment": "<string>",
"charging_start_date": "<string>",
"event_profile": "<string>"
},
"custom_attributes": [
{
"href": "<string>",
"id": "<string>",
"name": "<string>",
"object": "<string>",
"type": "<string>",
"value": "<unknown>"
}
],
"custom_objects": [
{
"object": "<string>",
"id": "<string>",
"name": "<string>",
"code": "<string>",
"href": "<string>",
"rate": 123
}
],
"inventories": "<array>",
"partial_invoices": "<array>",
"activity_logs": "<array>",
"payment_method": {
"object": "<string>",
"id": "<string>",
"processor_type": "<string>",
"status": "<string>",
"default": true,
"restricted_to_orders": true,
"specified_order_ids": "<unknown>",
"processor": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"href": "<string>"
},
"reference": "<string>",
"payment_count": 123,
"last_used_at": "<string>",
"created_on": "<string>",
"last_updated_on": "<string>",
"created_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"last_updated_by": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"email": "<string>",
"href": "<string>"
},
"version": 123
},
"tax_id": "<unknown>",
"tax_id_number": "<unknown>"
}
}Send only the fields to change, under
account. Writes are flatter than reads: currency goes in as a currency code and time_zone as a time zone name. grant_portal_access turns on portal access for the account.
The SDK samples get their client from credentials your app registers once when it starts, as shown in Authentication. To try the call here, click Try it, set
host to your Exsited API host name and paste an access token from Get an access token. To send a raw JSON body instead of filling in fields, copy the cURL sample and edit its -d payload.Authorizations
An access token from POST /api/v4/oauth2/token. The SDKs get and renew it for you.
Path Parameters
The account's id, such as ACC0001. Not its uuid.
Body
application/json
Show child attributes
Show child attributes
Response
200 - application/json
The account, under account, with the change applied.
The account, under account.
One account.
Show child attributes
Show child attributes