Update Supplier
PATCH {{baseUrl}}/accounting/suppliers/:id?raw=false
Update Supplier
Request Params
Key | Datatype | Required | Description |
---|---|---|---|
raw | boolean | Include raw response. Mostly used for debugging purposes |
Request Body
{"display_id"=>"EMP00101", "display_name"=>"{{$randomCompanyName}}", "company_name"=>"{{$randomCompanyName}}", "company_id"=>"12345", "title"=>"CEO", "first_name"=>"{{$randomFirstName}}", "middle_name"=>"D.", "last_name"=>"{{$randomLastName}}", "suffix"=>"Jr.", "individual"=>true, "addresses"=>[{"type"=>"primary", "line1"=>"{{$randomStreetAddress}}", "line2"=>"{{$randomDepartment}}", "city"=>"{{$randomCity}}", "state"=>"CA", "postal_code"=>"94104", "country"=>"US", "latitude"=>"{{$randomLatitude}}", "longitude"=>"{{$randomLongitude}}", "contact_name"=>"{{$randomFullName}}", "salutation"=>"Ms", "phone_number"=>"{{$randomPhoneNumber}}", "fax"=>"{{$randomPhoneNumber}}", "email"=>"{{$randomEmail}}", "website"=>"{{$randomUrl}}"}, {"type"=>"shipping", "line1"=>"{{$randomStreetAddress}}", "line2"=>"{{$randomDepartment}}", "city"=>"{{$randomCity}}", "state"=>"CA", "postal_code"=>"94104", "country"=>"US", "latitude"=>"{{$randomLatitude}}", "longitude"=>"{{$randomLongitude}}", "contact_name"=>"{{$randomFullName}}", "salutation"=>"Mr", "phone_number"=>"{{$randomPhoneNumber}}", "fax"=>"{{$randomPhoneNumber}}", "email"=>"{{$randomEmail}}", "website"=>"{{$randomUrl}}"}], "phone_numbers"=>[{"number"=>"{{$randomPhoneNumber}}", "type"=>"primary"}, {"number"=>"{{$randomPhoneNumber}}", "type"=>"fax"}], "emails"=>[{"email"=>"elon@musk.com", "id"=>"123", "type"=>"primary"}, {"email"=>"elon@musk.com", "id"=>"123", "type"=>"primary"}], "websites"=>[{"url"=>"http://example.com", "id"=>"12345", "type"=>"primary"}, {"url"=>"http://example.com", "id"=>"12345", "type"=>"primary"}], "bank_accounts"=>[{"bank_name"=>"Monzo", "account_number"=>"123465", "account_name"=>"SPACEX LLC", "account_type"=>"credit_card", "iban"=>"CH2989144532982975332", "bic"=>"AUDSCHGGXXX", "routing_number"=>"012345678", "bsb_number"=>"062-001", "branch_identifier"=>"001", "bank_code"=>"BNH", "currency"=>"USD"}, {"bank_name"=>"Monzo", "account_number"=>"123465", "account_name"=>"SPACEX LLC", "account_type"=>"credit_card", "iban"=>"CH2989144532982975332", "bic"=>"AUDSCHGGXXX", "routing_number"=>"012345678", "bsb_number"=>"062-001", "branch_identifier"=>"001", "bank_code"=>"BNH", "currency"=>"USD"}], "notes"=>"{{$randomBs}}", "tax_rate"=>{"id"=>"123456", "rate"=>10}, "tax_number"=>"US123945459", "currency"=>"USD", "account"=>{"id"=>"{{accountsPayableAccountId}}", "nominal_code"=>"N091", "code"=>"453"}, "status"=>"active", "payment_method"=>"cash", "channel"=>"email", "custom_fields"=>[{"id"=>"2389328923893298", "name"=>"employee_level", "description"=>"Employee Level", "value"=>"Uses Salesforce and Marketo"}, {"id"=>"2389328923893298", "name"=>"employee_level", "description"=>"Employee Level", "value"=>"Uses Salesforce and Marketo"}], "row_version"=>"1-12345", "subsidiary_id"=>"12345"}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
x-apideck-consumer-id | string | (Required) ID of the consumer which you want to get or push data from | |
x-apideck-app-id | string | (Required) The ID of your Unify application | |
x-apideck-service-id | string | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | |
Content-Type | string | ||
Accept | string |
RESPONSES
status: OK
{"status_code":200,"status":"OK","service":"xero","resource":"suppliers","operation":"update","data":{"id":"12345"}}