@@ -53,14 +53,6 @@ import { WebSocketConnectionProvider } from "./messaging/browser/connection";
53
53
import { PermissionName } from "./permission" ;
54
54
import { LicenseService } from "./license-protocol" ;
55
55
import { Emitter } from "./util/event" ;
56
- import { AccountStatement , CreditAlert } from "./accounting-protocol" ;
57
- import { GithubUpgradeURL , PlanCoupon } from "./payment-protocol" ;
58
- import {
59
- TeamSubscription ,
60
- TeamSubscription2 ,
61
- TeamSubscriptionSlot ,
62
- TeamSubscriptionSlotResolved ,
63
- } from "./team-subscription-protocol" ;
64
56
import { RemotePageMessage , RemoteTrackMessage , RemoteIdentifyMessage } from "./analytics" ;
65
57
import { IDEServer } from "./ide-protocol" ;
66
58
import { ListUsageRequest , ListUsageResponse , CostCenterJSON } from "./usage" ;
@@ -74,8 +66,6 @@ export interface GitpodClient {
74
66
75
67
onPrebuildUpdate ( update : PrebuildWithStatus ) : void ;
76
68
77
- onCreditAlert ( creditAlert : CreditAlert ) : void ;
78
-
79
69
//#region propagating reconnection to iframe
80
70
notifyDidOpenConnection ( ) : void ;
81
71
notifyDidCloseConnection ( ) : void ;
@@ -242,50 +232,10 @@ export interface GitpodServer extends JsonRpcServer<GitpodClient>, AdminServer,
242
232
* gitpod.io concerns
243
233
*/
244
234
isStudent ( ) : Promise < boolean > ;
245
- /**
246
- *
247
- */
248
- getAccountStatement ( options : GitpodServer . GetAccountStatementOptions ) : Promise < AccountStatement | undefined > ;
249
- getRemainingUsageHours ( ) : Promise < number > ;
250
235
251
236
/**
252
- *
237
+ * Stripe/Usage
253
238
*/
254
- getChargebeeSiteId ( ) : Promise < string > ;
255
- createPortalSession ( ) : Promise < { } > ;
256
- createTeamPortalSession ( teamId : string ) : Promise < { } > ;
257
- checkout ( planId : string , planQuantity ?: number ) : Promise < { } > ;
258
- teamCheckout ( teamId : string , planId : string ) : Promise < { } > ;
259
- getAvailableCoupons ( ) : Promise < PlanCoupon [ ] > ;
260
- getAppliedCoupons ( ) : Promise < PlanCoupon [ ] > ;
261
-
262
- getShowPaymentUI ( ) : Promise < boolean > ;
263
- isChargebeeCustomer ( ) : Promise < boolean > ;
264
-
265
- subscriptionUpgradeTo ( subscriptionId : string , chargebeePlanId : string ) : Promise < void > ;
266
- subscriptionDowngradeTo ( subscriptionId : string , chargebeePlanId : string ) : Promise < void > ;
267
- subscriptionCancel ( subscriptionId : string ) : Promise < void > ;
268
- subscriptionCancelDowngrade ( subscriptionId : string ) : Promise < void > ;
269
-
270
- getTeamSubscription ( teamId : string ) : Promise < TeamSubscription2 | undefined > ;
271
- cancelTeamSubscription ( teamId : string ) : Promise < void > ;
272
- tsCancel ( teamSubscriptionId : string ) : Promise < void > ;
273
- tsGet ( ) : Promise < TeamSubscription [ ] > ;
274
- tsGetSlots ( ) : Promise < TeamSubscriptionSlotResolved [ ] > ;
275
- tsGetUnassignedSlot ( teamSubscriptionId : string ) : Promise < TeamSubscriptionSlot | undefined > ;
276
- tsAddSlots ( teamSubscriptionId : string , quantity : number ) : Promise < void > ;
277
- tsAssignSlot (
278
- teamSubscriptionId : string ,
279
- teamSubscriptionSlotId : string ,
280
- identityStr : string | undefined ,
281
- ) : Promise < void > ;
282
- tsReassignSlot ( teamSubscriptionId : string , teamSubscriptionSlotId : string , newIdentityStr : string ) : Promise < void > ;
283
- tsDeactivateSlot ( teamSubscriptionId : string , teamSubscriptionSlotId : string ) : Promise < void > ;
284
- tsReactivateSlot ( teamSubscriptionId : string , teamSubscriptionSlotId : string ) : Promise < void > ;
285
- tsAddMembersToOrg ( teamSubscriptionId : string , organizationId : string ) : Promise < void > ;
286
-
287
- getGithubUpgradeUrls ( ) : Promise < GithubUpgradeURL [ ] > ;
288
-
289
239
getStripePublishableKey ( ) : Promise < string > ;
290
240
getStripeSetupIntentClientSecret ( ) : Promise < string > ;
291
241
findStripeSubscriptionId ( attributionId : string ) : Promise < string | undefined > ;
@@ -608,18 +558,6 @@ export class GitpodCompositeClient<Client extends GitpodClient> implements Gitpo
608
558
}
609
559
}
610
560
}
611
-
612
- onCreditAlert ( creditAlert : CreditAlert ) : void {
613
- for ( const client of this . clients ) {
614
- if ( client . onCreditAlert ) {
615
- try {
616
- client . onCreditAlert ( creditAlert ) ;
617
- } catch ( error ) {
618
- console . error ( error ) ;
619
- }
620
- }
621
- }
622
- }
623
561
}
624
562
625
563
export type GitpodService = GitpodServiceImpl < GitpodClient , GitpodServer > ;
0 commit comments