Update Company
curl --request PATCH \
--url https://app.yampi.ai/api/v1/accounts/{account_id}/companies/{id} \
--header 'Content-Type: application/json' \
--header 'api_access_token: <api-key>' \
--data '
{
"company": {
"name": "<string>",
"domain": "<string>",
"description": "<string>",
"legal_name": "<string>",
"tax_id_type": "<string>",
"tax_id": "<string>",
"tax_id_dv": "<string>",
"fiscal_responsibilities": [],
"address": "<string>",
"city_name": "<string>",
"city_code": "<string>",
"department_code": "<string>",
"country_code": "<string>",
"bank_id": "<string>",
"bank_account_number": "<string>",
"bank_certificate_on": "2023-12-25",
"rut": "<string>",
"bank_certificate": "<string>",
"billing_email": "<string>"
}
}
'const options = {
method: 'PATCH',
headers: {api_access_token: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
company: {
name: '<string>',
domain: '<string>',
description: '<string>',
legal_name: '<string>',
tax_id_type: '<string>',
tax_id: '<string>',
tax_id_dv: '<string>',
fiscal_responsibilities: [],
address: '<string>',
city_name: '<string>',
city_code: '<string>',
department_code: '<string>',
country_code: '<string>',
bank_id: '<string>',
bank_account_number: '<string>',
bank_certificate_on: '2023-12-25',
rut: '<string>',
bank_certificate: '<string>',
billing_email: '<string>'
}
})
};
fetch('https://app.yampi.ai/api/v1/accounts/{account_id}/companies/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.yampi.ai/api/v1/accounts/{account_id}/companies/{id}"
payload = { "company": {
"name": "<string>",
"domain": "<string>",
"description": "<string>",
"legal_name": "<string>",
"tax_id_type": "<string>",
"tax_id": "<string>",
"tax_id_dv": "<string>",
"fiscal_responsibilities": [],
"address": "<string>",
"city_name": "<string>",
"city_code": "<string>",
"department_code": "<string>",
"country_code": "<string>",
"bank_id": "<string>",
"bank_account_number": "<string>",
"bank_certificate_on": "2023-12-25",
"rut": "<string>",
"bank_certificate": "<string>",
"billing_email": "<string>"
} }
headers = {
"api_access_token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"id": 123,
"name": "<string>",
"contacts_count": 123,
"domain": "<string>",
"description": "<string>",
"legal_name": "<string>",
"tax_id_type": "<string>",
"tax_id": "<string>",
"tax_id_dv": "<string>",
"fiscal_responsibilities": [
"O-13"
],
"address": "<string>",
"city_name": "<string>",
"city_code": "<string>",
"department_code": "<string>",
"country_code": "<string>",
"bank_id": "<string>",
"bank_account_type": "savings",
"bank_account_number": "<string>",
"bank_certificate_on": "2023-12-25",
"rut_url": "<string>",
"rut_filename": "<string>",
"bank_certificate_url": "<string>",
"bank_certificate_filename": "<string>",
"fiscal_packet_complete": true,
"custom_attributes": {},
"avatar_url": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"contacts": [
{
"id": 123,
"name": "<string>",
"email": "<string>",
"thumbnail": "<string>"
}
],
"billing_email": "<string>"
}{}Companies
Update Company
Update an existing company
PATCH
/
api
/
v1
/
accounts
/
{account_id}
/
companies
/
{id}
Update Company
curl --request PATCH \
--url https://app.yampi.ai/api/v1/accounts/{account_id}/companies/{id} \
--header 'Content-Type: application/json' \
--header 'api_access_token: <api-key>' \
--data '
{
"company": {
"name": "<string>",
"domain": "<string>",
"description": "<string>",
"legal_name": "<string>",
"tax_id_type": "<string>",
"tax_id": "<string>",
"tax_id_dv": "<string>",
"fiscal_responsibilities": [],
"address": "<string>",
"city_name": "<string>",
"city_code": "<string>",
"department_code": "<string>",
"country_code": "<string>",
"bank_id": "<string>",
"bank_account_number": "<string>",
"bank_certificate_on": "2023-12-25",
"rut": "<string>",
"bank_certificate": "<string>",
"billing_email": "<string>"
}
}
'const options = {
method: 'PATCH',
headers: {api_access_token: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
company: {
name: '<string>',
domain: '<string>',
description: '<string>',
legal_name: '<string>',
tax_id_type: '<string>',
tax_id: '<string>',
tax_id_dv: '<string>',
fiscal_responsibilities: [],
address: '<string>',
city_name: '<string>',
city_code: '<string>',
department_code: '<string>',
country_code: '<string>',
bank_id: '<string>',
bank_account_number: '<string>',
bank_certificate_on: '2023-12-25',
rut: '<string>',
bank_certificate: '<string>',
billing_email: '<string>'
}
})
};
fetch('https://app.yampi.ai/api/v1/accounts/{account_id}/companies/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.yampi.ai/api/v1/accounts/{account_id}/companies/{id}"
payload = { "company": {
"name": "<string>",
"domain": "<string>",
"description": "<string>",
"legal_name": "<string>",
"tax_id_type": "<string>",
"tax_id": "<string>",
"tax_id_dv": "<string>",
"fiscal_responsibilities": [],
"address": "<string>",
"city_name": "<string>",
"city_code": "<string>",
"department_code": "<string>",
"country_code": "<string>",
"bank_id": "<string>",
"bank_account_number": "<string>",
"bank_certificate_on": "2023-12-25",
"rut": "<string>",
"bank_certificate": "<string>",
"billing_email": "<string>"
} }
headers = {
"api_access_token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"id": 123,
"name": "<string>",
"contacts_count": 123,
"domain": "<string>",
"description": "<string>",
"legal_name": "<string>",
"tax_id_type": "<string>",
"tax_id": "<string>",
"tax_id_dv": "<string>",
"fiscal_responsibilities": [
"O-13"
],
"address": "<string>",
"city_name": "<string>",
"city_code": "<string>",
"department_code": "<string>",
"country_code": "<string>",
"bank_id": "<string>",
"bank_account_type": "savings",
"bank_account_number": "<string>",
"bank_certificate_on": "2023-12-25",
"rut_url": "<string>",
"rut_filename": "<string>",
"bank_certificate_url": "<string>",
"bank_certificate_filename": "<string>",
"fiscal_packet_complete": true,
"custom_attributes": {},
"avatar_url": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"contacts": [
{
"id": 123,
"name": "<string>",
"email": "<string>",
"thumbnail": "<string>"
}
],
"billing_email": "<string>"
}{}Response
Success