Update a user account
const url = 'https://client-api.abi.ai/user/abi1234';const options = { method: 'PUT', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"uniqueId":"123abc789xyz","firstName":"Jane","lastName":"Doe","email":"janedoe@example.com","phone":"+441234567890","address":"123 Main St, Apt 4B","age":34,"dateOfBirth":"1994-10-07","gender":"male","language":"en","country":"it","location":"es","origin":"gb","physicianCountry":"es"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://client-api.abi.ai/user/abi1234 \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "uniqueId": "123abc789xyz", "firstName": "Jane", "lastName": "Doe", "email": "janedoe@example.com", "phone": "+441234567890", "address": "123 Main St, Apt 4B", "age": 34, "dateOfBirth": "1994-10-07", "gender": "male", "language": "en", "country": "it", "location": "es", "origin": "gb", "physicianCountry": "es" }'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The Abi identifier of the user account.
Example
abi1234Request Bodyrequired
Section titled “Request Bodyrequired”Supply only the fields that should change; omitted fields are left unchanged.
object
Your stable identifier for the user.
Example
123abc789xyzThe user’s first name.
Example
JaneThe user’s surname.
Example
DoeThe user’s email address.
Example
janedoe@example.comThe user’s mobile number including international dialing code (E.164).
Example
+441234567890The user’s address.
Example
123 Main St, Apt 4BThe user’s age.
Example
34The user’s date of birth.
Example
1994-10-07The user’s gender
Example
femaleThe language Abi uses to communicate with the user.
Example
enThe user’s nationality or country code.
Example
itThe country where the user lives or is currently located.
Example
esThe country in which the user was born.
Example
gbThe country in which responding healthcare professionals are licensed.
Example
esResponses
Section titled “Responses”User updated. See the User account model for the full response-field reference.
object
Example
{ "id": "abi1234", "uniqueId": "123abc789xyz", "userStatus": "activeUser", "firstName": "Jane", "lastName": "Doe", "email": "janedoe@gmail.com", "gender": "female", "phone": "+441234567890", "origin": "gb", "location": "es", "country": "it", "physicianCountry": "es", "language": "en", "dateOfBirth": "1994-10-07", "partnerName": "Abi", "associatedAccounts": 5}Request could not be completed.
object
Short machine-readable error code.
Human-readable explanation of the error.
Examplegenerated
{ "code": "example", "message": "example"}Request could not be completed.
object
Short machine-readable error code.
Human-readable explanation of the error.
Examplegenerated
{ "code": "example", "message": "example"}