Skip to content

Commit 3308a68

Browse files
authored
Stripe (#1498)
1 parent 9e08243 commit 3308a68

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

packages/types/src/client/user.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,20 @@ export interface IUserData {
4040
createdAt: Timestamp;
4141
activated: boolean;
4242
tier: Tier;
43+
tierRequestQuota: number; // how many requests the user is entitled to in this tier (note this may vary for the same tier, e.g. pro @ 100k, pro @ 200k, etc)
4344
marketingPreferences: boolean;
4445
originUrl: string;
4546
settings?: IUserSettings;
4647
updatedAtTimestamp?: Timestamp;
48+
tierCheckoutId?: string; // prosopo (not stripe!) checkout session id / lock
49+
stripeCustomerId?: string; // stripe customer id
50+
stripeTierCheckoutId?: string; // stripe checkout session id
51+
stripeTierSubscriptionId?: string; // stripe subscription id
52+
stripeTierPriceId?: string; // stripe price id for the subscription
53+
stripeTierNext?: string; // the next tier the user is moving to, if any
54+
stripeTierNextAt?: number; // the time the user will move to the next tier, if any
55+
stripeTierCancelAt?: number; // the time the user's subscription will be cancelled (e.g. if cancelling at end of billing period)
56+
stripeUpdatedAt?: number; // the time the user's stripe details were last updated (needed for webhook ordering)
4757
}
4858

4959
export interface IUserSettings {

0 commit comments

Comments
 (0)