Skip to content

APIEntitlement

https://docs.discord.com/developers/monetization/entitlements#entitlement-object-entitlement-structure Some fields below only show up in real payloads and the example response, they are kept optional here. https://docs.discord.com/developers/resources/entitlement#entitlement-object-entitlement-example

Signature

export interface APIEntitlement

Properties

user_id?: Snowflake;

ID of the user that is granted access to the entitlement's sku

guild_id?: Snowflake;

ID of the guild that is granted access to the entitlement's sku

promotion_id?: Snowflake | null;

ID of the promotion that granted this entitlement. https://docs.discord.com/developers/resources/entitlement#entitlement-object-entitlement-example

gift_code_flags?: number;

Flags for the gift code that granted this entitlement, if any. https://docs.discord.com/developers/resources/entitlement#entitlement-object-entitlement-example

subscription_id?: Snowflake;

ID of the subscription that granted this entitlement, if any. https://docs.discord.com/developers/resources/entitlement#entitlement-object-entitlement-example

deleted: boolean;

Whether the entitlement was deleted

starts_at: string | null;

Start date at which the entitlement is valid.

ends_at: string | null;

Date at which the entitlement is no longer valid.

consumed?: boolean;

For consumable items, whether or not the entitlement has been consumed