InterfaceListNotificationsParams

interface ListNotificationsParams {
    accountId?: string;
    excludeTypes?: null | readonly ("follow" | "follow_request" | "admin.sign_up")[];
    expandAccounts?: "full" | "partial_avatars";
    groupedTypes?: null | readonly ("follow" | "follow_request" | "admin.sign_up")[];
    includeFiltered?: boolean;
    limit?: null | number;
    maxId?: null | string;
    minId?: null | string;
    sinceId?: null | string;
    types?: null | readonly ("follow" | "follow_request" | "admin.sign_up")[];
}

Hierarchy (view full)

Properties

accountId?: string

Return only notifications received from the specified account.

excludeTypes?: null | readonly ("follow" | "follow_request" | "admin.sign_up")[]

Types to exclude from the results.

expandAccounts?: "full" | "partial_avatars"

One of full (default) or partial_avatars. When set to partial_avatars, some accounts will not be rendered in full in the returned accounts list but will be instead returned in stripped-down form in the partial_accounts list. The most recent account in a notification group is always rendered in full in the accounts attribute.

groupedTypes?: null | readonly ("follow" | "follow_request" | "admin.sign_up")[]

Restrict which notification types can be grouped. Use this if there are notification types for which your client does not support grouping. If omitted, the server will group notifications of all types it supports (currently, favourite, follow and reblog). If you do not want any notification grouping, use GET /api/v1/notifications instead. Notifications that would be grouped if not for this parameter will instead be returned as individual single-notification groups with a unique group_key that can be assumed to be of the form ungrouped-{notification_id}.

Please note that neither the streaming API nor the individual notification APIs are aware of this parameter and will always include a “proper” group_key that can be different from what is returned here, meaning that you may have to ignore group_key for such notifications that you do not want grouped and use ungrouped-{notification_id} instead for consistency.

includeFiltered?: boolean

Whether to include notifications filtered by the user’s NotificationPolicy. Defaults to false.

limit?: null | number

Maximum number of results to return per page. Defaults to 40. NOTE: Pagination is done with the Link header from the response.

maxId?: null | string

Return results older than this ID.

minId?: null | string

Get a list of items with ID greater than this value excluding this ID

sinceId?: null | string

Return results newer than this ID.

types?: null | readonly ("follow" | "follow_request" | "admin.sign_up")[]

Types to include in the result.