1. Customers
  2. Update customer
PUT

​
Authentication

x-enterprise-key
required
string

Enterprise key with this route’s permission. See Authentication.

x-organization-id
required
string

ID of the organization (issuing company) the operation applies to.

​
Path parameters

customerId
required
string

The customer’s ID (UUID).

​
Body

application/json

xNome
string
indIEDest
string
IE
string
email
string
address
object

Address following the NF-e layout.

  • xLgr (string) (required): Street.
  • nro (string) (required): Number.
  • xCpl (string): Address line 2.
  • xBairro (string) (required): Neighborhood.
  • cMun (integer) (required): The municipality’s IBGE code (7 digits).
  • xMun (string) (required): Municipality name.
  • UF (string) (required): State abbreviation.
  • CEP (string) (required): Postal code (CEP), digits only (8 digits).
  • fone (string): Phone number, digits only.

​
Responses

StatusDescription
200Customer updated.
400Invalid body (missing required field, wrong format, or field not allowed).
404Resource not found.
curl -X PUT "https://api.treeunfe.com.br/api/v1/customers/CUSTOMERID" \
  -H "x-enterprise-key: YOUR_ENTERPRISE_KEY" \
  -H "x-organization-id: ORGANIZATION_ID" \
  -H "Content-Type: application/json" \
  -d '{
    "xNome": "Cliente Teste Novo",
    "email": "novo@exemplo.com.br"
  }'