Table of Contents

Method GetEntitlementsAsync

Namespace
DisCatSharp
Assembly
DisCatSharp.dll

GetEntitlementsAsync(ulong?, ulong?, List<ulong>?, ulong?, ulong?, int, bool?, bool?)

Gets the application's entitlements.

[RequiresFeature(Features.MonetizedApplication)]
public Task<IReadOnlyList<DiscordEntitlement>> GetEntitlementsAsync(ulong? guildId = null, ulong? userId = null, List<ulong>? skuIds = null, ulong? before = null, ulong? after = null, int limit = 100, bool? excludeEnded = null, bool? excludeDeleted = null)

Parameters

guildId ulong?

Filter returned entitlements to a specific guild id.

userId ulong?

Filter returned entitlements to a specific user id.

skuIds List<ulong>

Optional list of SKU IDs to check entitlements for.

before ulong?

Retrieve entitlements before this entitlement ID.

after ulong?

Retrieve entitlements after this entitlement ID.

limit int

Number of entitlements to return, 1-100, default 100.

excludeEnded bool?

Whether or not ended entitlements should be omitted. Defaults to false, ended entitlements are included by default.

excludeDeleted bool?

Whether or not deleted entitlements should be omitted. Defaults to true, deleted entitlements are not included by default.

Returns

Task<IReadOnlyList<DiscordEntitlement>>

A list of DiscordEntitlement.

Exceptions

NotFoundException

Thrown when the entitlements do not exist.