psn-api
Version:
A well-tested library that lets you get trophy, user, and game data from the PlayStation Network.
23 lines (22 loc) • 963 B
TypeScript
import type { AuthorizationPayload, PurchasedGamesResponse } from "../models";
import { Membership } from "../models/membership.model";
type GetPurchasedGamesOptions = {
isActive: boolean;
platform: ("ps4" | "ps5")[];
size: number;
start: number;
sortBy: "ACTIVE_DATE";
sortDirection: "asc" | "desc";
membership: Membership;
};
/**
* A call to this function will retrieve purchased games for the user associated
* with the npsso token provided to this module during initialisation.
*
* This endpoint returns only PS4 and PS5 games.
*
* @param authorization An object containing your access token, typically retrieved with `exchangeAccessCodeForAuthTokens()`.
* @param options Optional parameters to filter and sort purchased games.
*/
export declare const getPurchasedGames: (authorization: AuthorizationPayload, options?: Partial<GetPurchasedGamesOptions>) => Promise<PurchasedGamesResponse>;
export {};