gplayapi-ts
Version:
Google Play API wrapper in TypeScript
84 lines (80 loc) • 2.02 kB
TypeScript
import { Image } from '../gen_proto/googleplay_pb.js';
import '@bufbuild/protobuf';
/**
* App-related models and interfaces
*/
interface GPImage {
imageType: number;
imageUrl?: string;
altTextLocalized?: string;
secureUrl?: string;
positionInSequence?: number;
supportsFifeUrlOptions?: boolean;
autogen?: string;
citation?: string;
}
interface App {
packageName: string;
appInfo?: AppInfo;
categoryImage?: Image;
categoryId: number;
categoryName: string;
changes: string;
containsAds: boolean;
coverImage?: Image;
description: string;
developerName: string;
displayName: string;
downloadString: string;
earlyAccess: boolean;
iconImage?: Image;
instantAppLink?: string;
isFree: boolean;
isSystem: boolean;
liveStreamUrl?: string;
offerDetails: Record<string, string>;
offerType: number;
price: string;
promotionStreamUrl?: string;
screenshots: Image[];
shareUrl: string;
shortDescription: string;
size: number | bigint;
targetSdk: number;
testingProgram?: TestingProgram;
updatedOn: string;
versionCode: number;
versionName: string;
video?: Image;
}
interface AppInfo {
appInfoMap: Record<string, string>;
}
interface TestingProgram {
image?: Image;
displayName: string;
email: string;
isAvailable: boolean;
isSubscribed: boolean;
isSubscribedAndInstalled: boolean;
}
interface AppOffer {
offerType?: number;
micros?: number;
formattedAmount?: string;
}
interface AppDetails {
versionString?: string;
versionCode?: number;
categoryName?: string;
infoDownloadSize?: number | bigint;
downloadLabelAbbreviated?: string;
recentChangesHtml?: string;
installNotes?: string;
earlyAccessInfo?: any;
developerName?: string;
targetSdkVersion?: number;
infoUpdatedOn?: string;
instantLink?: string;
}
export type { App, AppDetails, AppInfo, AppOffer, GPImage, TestingProgram };