Usernames and Nicknames
Discord enforces the following restrictions for usernames and nicknames:- Names can contain most valid unicode characters. We limit some zero-width and non-rendering characters.
- Usernames must be between 2 and 32 characters long.
- Nicknames must be between 1 and 32 characters long.
- Names are sanitized and trimmed of leading, trailing, and excessive internal whitespace.
- Usernames cannot contain the following substrings:
@,#,:,```,discord - Usernames cannot be:
everyone,here
User Object
User Structure
Example User
User Flags
Premium Types
Premium types denote the level of premium a user has. Visit the Nitro page to learn more about the premium plans we currently offer.User Primary Guild
Avatar Decoration Data Object
The data for the user’s avatar decoration.Avatar Decoration Data Structure
Collectibles
The collectibles the user has, excluding Avatar Decorations and Profile Effects.Collectible Structure
Nameplate
The nameplate the user has.Nameplate Structure
Connection Object
The connection object that the user has attached.Connection Structure
Services
* Service can no longer be added by users
Visibility Types
Application Role Connection Object
The role connection object that an application has attached to a user.Application Role Connection Structure
Get Current User
Returns the user object of the requester’s account. For OAuth2, this requires theidentify scope, which will return the object without an email, and optionally the email scope, which returns the object with an email if the user has one.
Get User
Returns a user object for a given user ID.Modify Current User
Modify the requester’s user account settings. Returns a user object on success. Fires a User Update Gateway event.All parameters to this endpoint are optional.
JSON Params
Get Current User Guilds
Returns a list of partial guild objects the current user is a member of. For OAuth2, requires theguilds scope.
Example Partial Guild
This endpoint returns 200 guilds by default, which is the maximum number of guilds a non-bot user can join. Therefore, pagination is not needed for integrations that need to get a list of the users’ guilds.
Query String Params
Get Current User Guild Member
Returns a guild member object for the current user. Requires theguilds.members.read OAuth2 scope.
Leave Guild
Leave a guild. Returns a 204 empty response on success. Fires a Guild Delete Gateway event and a Guild Member Remove Gateway event.Create DM
Create a new DM channel with a user. Returns a DM channel object (if one already exists, it will be returned instead).JSON Params
Create Group DM
Create a new group DM channel with multiple users. Returns a DM channel object. This endpoint was intended to be used with the now-deprecated GameBridge SDK. Fires a Channel Create Gateway event.JSON Params
Get Current User Connections
Returns a list of connection objects. Requires theconnections OAuth2 scope.
Get Current User Application Role Connection
Returns the application role connection for the user. Requires an OAuth2 access token withrole_connections.write scope for the application specified in the path.
Update Current User Application Role Connection
Updates and returns the application role connection for the user. Requires an OAuth2 access token withrole_connections.write scope for the application specified in the path.
JSON Params
Delete Current User Application Role Connection
Deletes the application role connection for the user. Requires an OAuth2 access token withrole_connections.write scope for the application specified in the path.