Skip to main content
Documentation - Discord Docs

Search documentation

Type to search this documentation.

On this pageOverview

Application Role Connection Metadata

A representation of role connection metadata for an application.

When a guild has added a bot and that bot has configured its role_connections_verification_url (in the developer portal), the application will render as a potential verification method in the guild's role verification configuration.

If an application has configured role connection metadata, its metadata will appear in the role verification configuration when the application has been added as a verification method to the role.

When a user connects their account using the bot's role_connections_verification_url, the bot will update a user's role connection with metadata using the OAuth2 role_connections.write scope.

Application Role Connection Metadata Structure
Section titled “Application Role Connection Metadata Structure”
Field Type Description
type ApplicationRoleConnectionMetadataType type of metadata value
key string dictionary key for the metadata field (must be a-z, 0-9, or _ characters; 1-50 characters)
name string name of the metadata field (1-100 characters)
name_localizations? dictionary with keys in available locales translations of the name
description string description of the metadata field (1-200 characters)
description_localizations? dictionary with keys in available locales translations of the description
Type Value Description
INTEGER_LESS_THAN_OR_EQUAL 1 the metadata value (integer) is less than or equal to the guild's configured value (integer)
INTEGER_GREATER_THAN_OR_EQUAL 2 the metadata value (integer) is greater than or equal to the guild's configured value (integer)
INTEGER_EQUAL 3 the metadata value (integer) is equal to the guild's configured value (integer)
INTEGER_NOT_EQUAL 4 the metadata value (integer) is not equal to the guild's configured value (integer)
DATETIME_LESS_THAN_OR_EQUAL 5 the metadata value (ISO8601 string) is less than or equal to the guild's configured value (integer; days before current date)
DATETIME_GREATER_THAN_OR_EQUAL 6 the metadata value (ISO8601 string) is greater than or equal to the guild's configured value (integer; days before current date)
BOOLEAN_EQUAL 7 the metadata value (integer) is equal to the guild's configured value (integer; 1)
BOOLEAN_NOT_EQUAL 8 the metadata value (integer) is not equal to the guild's configured value (integer; 1)

Get Application Role Connection Metadata Records

Section titled “Get Application Role Connection Metadata Records”

/applications/{application.id}/role-connections/metadata

Returns a list of application role connection metadata objects for the given application.

Update Application Role Connection Metadata Records

Section titled “Update Application Role Connection Metadata Records”

/applications/{application.id}/role-connections/metadata

Updates and returns a list of application role connection metadata objects for the given application.

Suggest an edit

Propose a replacement for this page. The site team reviews it before applying any changes.

Export
Documentation menu