PATCH
/companies/v1/{id}Modificar Compañía
El endpoint /companies/v1/{id} permite actualizar la información de una compañía a través de su id.
Sólo es posible actualizar una compañía si esta no fue validada.
Consideraciones
Para bloquear una compañía deberás enviar el status con el valor BLOCKED y el valor CLIENT_INTERNAL_REASON en el campo status_reason.
Para reactivar una compañía que bloqueaste, deberás enviar status con valor ACTIVE.
Parámetros disponibles
Header Parameters
AuthorizationStringrequired
Path Parameters
idStringrequired
Cuerpo de solicitud
application/jsonemailstring
phonestring
statusenum
status_reasonenum
Detalle de respuestas
401
No autorizado
Ejemplo de solicitud
{
"email": "[email protected]",
"phone": "1123456789",
"status": "ACTIVE",
"status_reason": "CLIENT_INTERNAL_REASON"
}Ejemplo de código
curl -X PATCH "https://api.pomelo.la/companies/v1/example_value" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"email": "[email protected]",
"phone": "1123456789",
"status": "ACTIVE",
"status_reason": "CLIENT_INTERNAL_REASON"
}'Ejemplo de respuesta (200)Compañía actualizada
{
"data": {
"id": "cmp-2E5eUyw1ZolEj1Y3NHxnob7bFZe",
"legal_name": "Pomelo SAS",
"trade_name": "Pomelo",
"tax_identification_type": "CNPJ",
"tax_identification_value": "43.856.175/0001-08",
"email": "[email protected]",
"phone": "1123456789",
"operation_country": "ARG",
"type": "MEI",
"status": "ACTIVE",
"legal_address": {
"street_name": "Av. Corrientes",
"street_number": 300,
"floor": 1,
"apartment": "A",
"zip_code": 1414,
"neighborhood": "Villa Crespo",
"city": "CABA",
"region": "Buenos Aires",
"additional_info": "Torre 2",
"country": "ARG"
}
}
}