Class DonationAlertsApiPaginator<D, T>

Donation Alerts API paginator.

Allows fetching data by page, or all at once.

Type Parameters

  • D

  • T

Hierarchy

  • DonationAlertsApiPaginator

Accessors

Methods

  • Makes it possible to use async iterator to sequentially loop over all available pages.

    Returns AsyncGenerator<T[], void, undefined>

    Example

    const apiClient = new ApiClient({ ...config });
    const paginator = apiClient.donations.createDonationsPaginator();

    for await (const data of paginator) {
    ...
    }

    Throws

    HttpError if response status code is out of 200-299 range.

    Throws

    UnregisteredUserError if the user you are trying to get is not registered in authentication provider.

    Throws

    MissingScopeError if the access token does not have required scope.

  • Gets donations by page number.

    Returns empty array if the requested page is greater than the last page.

    Parameters

    • page: number = 1

      Page number to request. Default is 1.

    Returns Promise<T[]>

    Throws

    HttpError if response status code is out of 200-299 range.

    Throws

    UnregisteredUserError if the user you are trying to get is not registered in authentication provider.

    Throws

    MissingScopeError if the access token does not have required scope.

Generated using TypeDoc