Requisição HTTP
curl https://api.iagenify.com/api/auth/profile \
-X PUT \
-H "Authorization: Bearer $IAGENIFY_TOKEN" \
-H "Content-Type: application/json" \
-d '{"prenom":"Ada","nom":"Lovelace","ville":"London"}'JavaScript
const response = await fetch("https://api.iagenify.com/api/auth/profile", {
method: "PUT",
headers: { Authorization: `Bearer ${process.env.IAGENIFY_TOKEN}`, "Content-Type": "application/json" },
body: JSON.stringify({
"prenom": "Ada",
"nom": "Lovelace",
"ville": "London"
}),
});
const result = await response.json();
if (!response.ok) throw new Error(result.error);Python
import os, requests
response = requests.request(
"PUT",
"https://api.iagenify.com/api/auth/profile",
headers={"Authorization": "Bearer " + os.environ["IAGENIFY_TOKEN"]},
json={
"prenom": "Ada",
"nom": "Lovelace",
"ville": "London"
},
timeout=30,
)
response.raise_for_status()
result = response.json()Corpo da requisição
nomstringNome di parentesco.
prenomstringNome.
genrestringPerfil valore di genere.
telstringNumber telefonic.
adressestring- Addresse postal.
villestringCitù.
Resposta bem-sucedida
{ ok: true, user: { id: "…", prenom: "Ada", nom: "Lovelace" } }Inviare solo i cambiamenti intenzionali
I valori vuoti sono ignorati da questo endpoint. Non inviare un profile cached intero quando un solo campo è stato editato.
I mots de passe non sono un pubblico API operazion
Usare i parametris del conto logn-in per cambiare un mot de passe. Fornitura <code>password</code> aquí restitue <code>403 password_change_private</code>.