Skip to main content

Add a username​

Add a new unique username to a user. The username will be used to identify the user on authentication.

Path Parameters
    userId string required

    unique identifier of the user.

Request Body required
    username object

    Set the user's new username.

    username string required

    Possible values: non-empty and <= 200 characters

    Set the user's username. This will be used for identification during authentication.

    isOrganizationSpecific boolean

    By default username must be unique across all organizations in an instance. This option allow to restrict the uniqueness to the user's own organization. As a result, this username can only be used if the authentication is limited to the corresponding organization.

    This can be useful if you provide multiple usernames for a single user, where one if specific to your organization, e.g.:

    • gigi-giraffe@zitadel.com (unique across organizations)
    • gigi-giraffe (unique only inside the ZITADEL organization)
Responses

Username successfully added


Schema
    details object
    sequence uint64

    on read: the sequence of the last event reduced by the projection

    on manipulation: the timestamp of the event(s) added by the manipulation

    changeDate date-time

    on read: the timestamp of the last event reduced by the projection

    on manipulation: the timestamp of the event(s) added by the manipulation

    resourceOwner resource_owner is the organization or instance_id an object belongs to
    usernameId string

    unique identifier of the username.

Loading...