/me/change-info - Change current user information

Add MCP server to your AI tool

Allow AI tools and LLMs to interact with the API documentation portal through MCP.

MCP server URL

https://api.my.nethesis.it/mcp

Standard setup for AI tools providing an mcp.json file

mcp.json
{
  "my.nethesis.it MCP server": {
    "url": "https://api.my.nethesis.it/mcp"
  }
}

Close
POST /me/change-info

Allow the current authenticated user to change their name, email, and phone number. Name and email cannot be empty if provided.

Name and phone are applied at once. A different email is never applied by this call: a one-time code is mailed to the new address and the response is 202 with email_verification_required: true. The change is completed by POST /me/change-info/verify-email with that code. An email equal to the current one (case-insensitive) is not a change. At most one code per minute is sent per user (429 otherwise); the pending change expires after 10 minutes.

application/json

Body Required

  • name string

    User's full name (cannot be empty if provided)

    Minimum length is 1.

  • email string(email)

    User's email address (cannot be empty if provided)

    Minimum length is 1.

  • phone string | null

    User's phone number (can be empty to remove)

Responses

  • 200 application/json

    User information changed successfully (no email change requested)

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object
      Hide data attribute Show data attribute object
      • updated_fields array[string]
  • 202 application/json

    Name/phone applied (if any); a verification code was mailed to the new email, which is pending until verified

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object
      Hide data attributes Show data attributes object
      • updated_fields array[string]
      • email_verification_required boolean
      • pending_email string(email)
  • 429 application/json

    A verification code was sent less than a minute ago

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object
      Hide data attribute Show data attribute object
      • retry_after_seconds integer
  • 503

    The verification store or mail delivery is unavailable; nothing was applied for the email

  • 400 application/json

    Bad request - validation error for name, email or phone

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object
      Hide data attributes Show data attributes object
      • type string

        Value is validation_error.

      • errors array[object]
        Hide errors attributes Show errors attributes object
        • key string

          Field name that failed validation

          Values are name, email, or phone.

        • message string

          Validation error message

          Values are name cannot be empty, email cannot be empty, invalid email format, or invalid phone format.

        • value string

          Value that failed validation

  • 401 application/json

    Unauthorized - invalid or missing JWT token

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object | null
  • 500 application/json

    Internal server error

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object | null
POST /me/change-info
curl \
 --request POST 'https://my.nethesis.it/backend/api/me/change-info' \
 --header "Authorization: Bearer $ACCESS_TOKEN" \
 --header "Content-Type: application/json" \
 --data '{
  "name": "John Doe",
  "email": "john.doe@example.com",
  "phone": "+39 333 123456"
}'
Request examples
{
  "name": "John Doe",
  "email": "john.doe@example.com",
  "phone": "+39 333 123456"
}
Response examples (200)
{
  "code": 200,
  "message": "profile updated successfully",
  "data": {
    "updated_fields": [
      "name",
      "phone"
    ]
  }
}
Response examples (202)
{
  "code": 202,
  "message": "verification code sent to the new email address",
  "data": {
    "updated_fields": [
      "name"
    ],
    "email_verification_required": true,
    "pending_email": "new.address@example.com"
  }
}
Response examples (429)
{
  "code": 429,
  "message": "a verification code was sent recently, wait before requesting another",
  "data": {
    "retry_after_seconds": 42
  }
}
Response examples (400)
{
  "code": 400,
  "message": "validation failed",
  "data": {
    "type": "validation_error",
    "errors": [
      {
        "key": "name",
        "message": "name cannot be empty",
        "value": ""
      }
    ]
  }
}
Response examples (401)
{
  "code": 401,
  "message": "invalid token",
  "data": {}
}
Response examples (500)
{
  "code": 500,
  "message": "internal server error",
  "data": {}
}