@aepstore-dev/contracts 1.54.0 → 1.57.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/gen/auth.d.ts CHANGED
@@ -110,6 +110,11 @@ export interface LogoutCurrentRequest {
110
110
  }
111
111
  export interface LogoutAllRequest {
112
112
  userId: string;
113
+ /**
114
+ * Current session's refresh token — excluded from the wipe so "log out
115
+ * everywhere" keeps THIS device signed in. Empty = revoke every session.
116
+ */
117
+ refreshToken: string;
113
118
  }
114
119
  export interface LogoutResponse {
115
120
  ok: boolean;
package/gen/auth.ts CHANGED
@@ -134,6 +134,11 @@ export interface LogoutCurrentRequest {
134
134
 
135
135
  export interface LogoutAllRequest {
136
136
  userId: string;
137
+ /**
138
+ * Current session's refresh token — excluded from the wipe so "log out
139
+ * everywhere" keeps THIS device signed in. Empty = revoke every session.
140
+ */
141
+ refreshToken: string;
137
142
  }
138
143
 
139
144
  export interface LogoutResponse {
package/gen/users.d.ts CHANGED
@@ -505,6 +505,31 @@ export interface CollectUserExportDataResponse {
505
505
  export interface GetAccountSettingsRequest {
506
506
  userId: string;
507
507
  }
508
+ /**
509
+ * Current premium plan the user holds. Mirrors a PremiumPlan catalog entry.
510
+ * Absent (null) when the user has no active subscription.
511
+ */
512
+ export interface PremiumPlanInfo {
513
+ /** MONTH_1 | MONTH_3 | MONTH_6 | MONTH_12 */
514
+ period: string;
515
+ months: number;
516
+ /** total for the period, Decimal-as-string */
517
+ price: string;
518
+ /** ≈ X ₽/month */
519
+ monthlyPrice: string;
520
+ discountPercent: string;
521
+ currency: string;
522
+ }
523
+ export interface PremiumInfo {
524
+ /** status==ACTIVE AND not past expires_at */
525
+ isActive: boolean;
526
+ /** ACTIVE | EXPIRED | CANCELED | '' (never had) */
527
+ status: string;
528
+ expiresAt: string;
529
+ autoRenew: boolean;
530
+ /** null when not active */
531
+ plan: PremiumPlanInfo | undefined;
532
+ }
508
533
  export interface AccountSettingsResponse {
509
534
  /** Identity */
510
535
  id: string;
@@ -534,11 +559,7 @@ export interface AccountSettingsResponse {
534
559
  /** Payout defaults */
535
560
  payoutMethod: string;
536
561
  payoutDetails: string;
537
- /** Premium snapshot */
538
- premiumIsActive: boolean;
539
- premiumStatus: string;
540
- premiumExpiresAt: string;
541
- premiumAutoRenew: boolean;
562
+ premium: PremiumInfo | undefined;
542
563
  /** Soft-delete state */
543
564
  deletedAt: string;
544
565
  scheduledForHardDelete: string;
package/gen/users.ts CHANGED
@@ -590,6 +590,33 @@ export interface GetAccountSettingsRequest {
590
590
  userId: string;
591
591
  }
592
592
 
593
+ /**
594
+ * Current premium plan the user holds. Mirrors a PremiumPlan catalog entry.
595
+ * Absent (null) when the user has no active subscription.
596
+ */
597
+ export interface PremiumPlanInfo {
598
+ /** MONTH_1 | MONTH_3 | MONTH_6 | MONTH_12 */
599
+ period: string;
600
+ months: number;
601
+ /** total for the period, Decimal-as-string */
602
+ price: string;
603
+ /** ≈ X ₽/month */
604
+ monthlyPrice: string;
605
+ discountPercent: string;
606
+ currency: string;
607
+ }
608
+
609
+ export interface PremiumInfo {
610
+ /** status==ACTIVE AND not past expires_at */
611
+ isActive: boolean;
612
+ /** ACTIVE | EXPIRED | CANCELED | '' (never had) */
613
+ status: string;
614
+ expiresAt: string;
615
+ autoRenew: boolean;
616
+ /** null when not active */
617
+ plan: PremiumPlanInfo | undefined;
618
+ }
619
+
593
620
  export interface AccountSettingsResponse {
594
621
  /** Identity */
595
622
  id: string;
@@ -619,11 +646,9 @@ export interface AccountSettingsResponse {
619
646
  /** Payout defaults */
620
647
  payoutMethod: string;
621
648
  payoutDetails: string;
622
- /** Premium snapshot */
623
- premiumIsActive: boolean;
624
- premiumStatus: string;
625
- premiumExpiresAt: string;
626
- premiumAutoRenew: boolean;
649
+ premium:
650
+ | PremiumInfo
651
+ | undefined;
627
652
  /** Soft-delete state */
628
653
  deletedAt: string;
629
654
  scheduledForHardDelete: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aepstore-dev/contracts",
3
- "version": "1.54.0",
3
+ "version": "1.57.0",
4
4
  "description": "Protobuf definitions for aepstore microservices",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
package/proto/auth.proto CHANGED
@@ -157,6 +157,9 @@ message LogoutCurrentRequest {
157
157
 
158
158
  message LogoutAllRequest {
159
159
  string user_id = 1;
160
+ // Current session's refresh token — excluded from the wipe so "log out
161
+ // everywhere" keeps THIS device signed in. Empty = revoke every session.
162
+ string refresh_token = 2;
160
163
  }
161
164
 
162
165
  message LogoutResponse {
package/proto/users.proto CHANGED
@@ -644,6 +644,25 @@ message GetAccountSettingsRequest {
644
644
  string user_id = 1;
645
645
  }
646
646
 
647
+ // Current premium plan the user holds. Mirrors a PremiumPlan catalog entry.
648
+ // Absent (null) when the user has no active subscription.
649
+ message PremiumPlanInfo {
650
+ string period = 1; // MONTH_1 | MONTH_3 | MONTH_6 | MONTH_12
651
+ int32 months = 2;
652
+ string price = 3; // total for the period, Decimal-as-string
653
+ string monthly_price = 4; // ≈ X ₽/month
654
+ string discount_percent = 5;
655
+ string currency = 6;
656
+ }
657
+
658
+ message PremiumInfo {
659
+ bool is_active = 1; // status==ACTIVE AND not past expires_at
660
+ string status = 2; // ACTIVE | EXPIRED | CANCELED | '' (never had)
661
+ string expires_at = 3;
662
+ bool auto_renew = 4;
663
+ PremiumPlanInfo plan = 5; // null when not active
664
+ }
665
+
647
666
  message AccountSettingsResponse {
648
667
  // Identity
649
668
  string id = 1;
@@ -678,11 +697,10 @@ message AccountSettingsResponse {
678
697
  string payout_method = 22;
679
698
  string payout_details = 23;
680
699
 
681
- // Premium snapshot
682
- bool premium_is_active = 24;
683
- string premium_status = 25;
684
- string premium_expires_at = 26;
685
- bool premium_auto_renew = 27;
700
+ // Premium snapshot — grouped under one object (was flat fields 24-27).
701
+ reserved 24, 25, 26, 27;
702
+ reserved "premium_is_active", "premium_status", "premium_expires_at", "premium_auto_renew";
703
+ PremiumInfo premium = 36;
686
704
 
687
705
  // Soft-delete state
688
706
  string deleted_at = 28;