PATCH /user/{uid}

Met à jour les informations d'un utilisateur.

Restrictions:

  • L'email ne peut pas être modifié via cette route
  • Le mot de passe ne peut pas être modifié via cette route (utiliser /auth/password/reset)
  • Déclenche un événement UPDATE_USER

Path parameters

  • uid string Required
application/json

Body Required

  • first_name string

    Prénom

  • last_name string

    Nom de famille

  • title string

    Civilité (MR, MME, etc.)

  • gender string

    Genre

    Values are H, F, or Other.

  • birthdate string(date-time)

    Date de naissance

  • phone object

    Téléphone principal

    Hide phone attribute Show phone attribute object
    • number string
  • address object

    Adresse postale

    Hide address attributes Show address attributes object
    • street string
    • street_end string
    • zip_code string
    • city string
    • country string
  • avatar string

    URL ou fichier base64 de l'avatar

  • personal_email string(email)
  • professional_email string(email)
  • personal_phone_fixe string
  • professional_phone string
  • professional_phone_fixe string
  • social_secu_number string

    Numéro de sécurité sociale

Responses

  • 200 application/json

    Utilisateur mis à jour

    Hide response attribute Show response attribute object
    • updatedUser object
      Hide updatedUser attributes Show updatedUser attributes object
      • _id string

        Unique identifier for the user

      • email string(email)

        User's email address

      • first_name string

        User's first name

      • last_name string

        User's last name

      • avatar string

        URL to user's avatar

      • state string

        User's state

        Values are inactive, created, confirmed, linkedin, google, or deleted.

      • positions array[string]

        List of positions associated with the user

      • phone object
        Hide phone attribute Show phone attribute object
        • number string

          User's phone number

      • address object
        Hide address attributes Show address attributes object
        • street string

          Street address

        • street_end string

          Additional street address information

        • zip_code string

          Zip code

        • city string

          City

        • country string

          Country

      • birthdate string(date-time)

        User's birthdate

      • gender string

        User's gender

        Values are H, F, null, or Other.

      • terms_of_sale_signature string(date-time)

        Date when user accepted terms of sale

      • createdAt string(date-time)

        Date when user was created

      • updatedAt string(date-time)

        Date when user was last updated

  • 404

    Utilisateur non trouvé

  • 422

    Erreur de validation

PATCH /user/{uid}
curl \
 --request PATCH 'https://wuro.pro/api/v3.2/user/{uid}' \
 --header "X-APP-ID: $API_KEY" \
 --header "X-APP-SECRET: $API_KEY" \
 --header "Content-Type: application/json" \
 --data '{"first_name":"string","last_name":"string","title":"string","gender":"H","birthdate":"2025-05-04T09:42:00Z","phone":{"number":"string"},"address":{"street":"string","street_end":"string","zip_code":"string","city":"string","country":"string"},"avatar":"string","personal_email":"hello@example.com","professional_email":"hello@example.com","personal_phone_fixe":"string","professional_phone":"string","professional_phone_fixe":"string","social_secu_number":"string"}'
Request examples
{
  "first_name": "string",
  "last_name": "string",
  "title": "string",
  "gender": "H",
  "birthdate": "2025-05-04T09:42:00Z",
  "phone": {
    "number": "string"
  },
  "address": {
    "street": "string",
    "street_end": "string",
    "zip_code": "string",
    "city": "string",
    "country": "string"
  },
  "avatar": "string",
  "personal_email": "hello@example.com",
  "professional_email": "hello@example.com",
  "personal_phone_fixe": "string",
  "professional_phone": "string",
  "professional_phone_fixe": "string",
  "social_secu_number": "string"
}
Response examples (200)
{
  "updatedUser": {
    "_id": "string",
    "email": "hello@example.com",
    "first_name": "string",
    "last_name": "string",
    "avatar": "string",
    "state": "inactive",
    "positions": [
      "string"
    ],
    "phone": {
      "number": "string"
    },
    "address": {
      "street": "string",
      "street_end": "string",
      "zip_code": "string",
      "city": "string",
      "country": "string"
    },
    "birthdate": "2025-05-04T09:42:00Z",
    "gender": "H",
    "terms_of_sale_signature": "2025-05-04T09:42:00Z",
    "createdAt": "2025-05-04T09:42:00Z",
    "updatedAt": "2025-05-04T09:42:00Z"
  }
}