Update a customer/v1/customers/{id}Renew the data of a customer. Indicate the customer ID and send the parameters with the information you want to update.
PUT
Request's parameters
idnumber
Localization: pathCustomer's IdREQUIRED
address
Localization: bodyDefault address's information.object
date_registered
Localization: bodyCustomer's registration date.Date(ISO_8601)
default_address
Localization: bodyCustomer's default address.String
Response parameters
id
Localization: bodyidstring
email
Localization: bodyemailstring
first_name
Localization: bodyfirst_namestring
last_name
Localization: bodylast_namestring
Request
curl
curl -X PUT \
'https://api.mercadopago.com/v1/customers/{id}' \
-H 'Authorization: Bearer ACCESS_TOKEN_ENV' \
-d '{
"email": "jhon@doe.com",
"first_name": "Jhon",
"last_name": "Doe",
"phone": {
"area_code": "55",
"number": "991234567"
},
"identification": {
"type": "CPF",
"number": "12345678900"
},
"default_address": "Home",
"address": {
"id": "123123",
"zip_code": "01234567",
"street_name": "Rua Exemplo",
"street_number": "123 A"
},
"date_registered": "2000-01-18",
"description": "Description del user",
"default_card": "None"
}'
Answer
json
{
"id": "000000001-sT93QZFAsfxU9P5",
"email": "jhon@doe.com",
"first_name": "Bruce",
"last_name": "Wayne",
"phone": {
"area_code": 23,
"number": 12345678
},
"identification": {
"type": "DNI",
"number": 12345678
},
"address": {
"zip_code": "SG1 2AX",
"street_name": "Old Knebworth Ln"
},
"description": "This is my description",
"date_created": "2018-02-20T15:36:23.541Z",
"metadata": {},
"cards": [
{}
],
"addresses": [
{}
]
}
Errors
400bad_request
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
140
150
200
201
202
203
204
205
206
207
208
401bad_request
unauthorized
404bad_request
not_found
Was this information helpful?