@shipstatic/types 0.6.0 → 0.6.2

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/dist/index.d.ts CHANGED
@@ -224,6 +224,13 @@ export declare const AccountPlan: {
224
224
  readonly TERMINATED: "terminated";
225
225
  };
226
226
  export type AccountPlanType = typeof AccountPlan[keyof typeof AccountPlan];
227
+ /**
228
+ * Account usage metrics — always available regardless of billing provider.
229
+ */
230
+ export interface AccountUsage {
231
+ /** Number of active custom domains (excludes paused) */
232
+ customDomains: number;
233
+ }
227
234
  /**
228
235
  * Core account object - used in both API responses and SDK
229
236
  * All fields are readonly to prevent accidental mutations
@@ -237,12 +244,16 @@ export interface Account {
237
244
  readonly picture: string | null;
238
245
  /** Account plan status */
239
246
  readonly plan: AccountPlanType;
247
+ /** Account usage metrics (custom domains, etc.) */
248
+ readonly usage: AccountUsage;
240
249
  /** Unix timestamp (seconds) when account was created */
241
250
  readonly created: number;
242
251
  /** Unix timestamp (seconds) when account was activated (first deployment), null if not yet activated */
243
252
  readonly activated: number | null;
244
253
  /** Last 4 characters of the API key for identification, null when no key generated */
245
254
  readonly hint: string | null;
255
+ /** Grace period expiration (unix seconds), null if no grace period active */
256
+ readonly grace: number | null;
246
257
  }
247
258
  /**
248
259
  * Account-specific configuration overrides
@@ -590,8 +601,6 @@ export interface BillingStatus {
590
601
  billing: string | null;
591
602
  /** Number of billing units (1 unit = 1 custom domain), null if no billing */
592
603
  units: number | null;
593
- /** Number of custom domains currently in use, null if no billing */
594
- usage: number | null;
595
604
  /** Billing status from Creem (active, trialing, canceled, etc.), null if no billing */
596
605
  status: string | null;
597
606
  /** Link to Creem customer portal for billing management, null if unavailable */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shipstatic/types",
3
- "version": "0.6.0",
3
+ "version": "0.6.2",
4
4
  "description": "Shared types for Shipstatic platform",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
package/src/index.ts CHANGED
@@ -260,6 +260,14 @@ export const AccountPlan = {
260
260
 
261
261
  export type AccountPlanType = typeof AccountPlan[keyof typeof AccountPlan];
262
262
 
263
+ /**
264
+ * Account usage metrics — always available regardless of billing provider.
265
+ */
266
+ export interface AccountUsage {
267
+ /** Number of active custom domains (excludes paused) */
268
+ customDomains: number;
269
+ }
270
+
263
271
  /**
264
272
  * Core account object - used in both API responses and SDK
265
273
  * All fields are readonly to prevent accidental mutations
@@ -273,12 +281,16 @@ export interface Account {
273
281
  readonly picture: string | null;
274
282
  /** Account plan status */
275
283
  readonly plan: AccountPlanType;
284
+ /** Account usage metrics (custom domains, etc.) */
285
+ readonly usage: AccountUsage;
276
286
  /** Unix timestamp (seconds) when account was created */
277
287
  readonly created: number;
278
288
  /** Unix timestamp (seconds) when account was activated (first deployment), null if not yet activated */
279
289
  readonly activated: number | null;
280
290
  /** Last 4 characters of the API key for identification, null when no key generated */
281
291
  readonly hint: string | null;
292
+ /** Grace period expiration (unix seconds), null if no grace period active */
293
+ readonly grace: number | null;
282
294
  }
283
295
 
284
296
  /**
@@ -871,8 +883,6 @@ export interface BillingStatus {
871
883
  billing: string | null;
872
884
  /** Number of billing units (1 unit = 1 custom domain), null if no billing */
873
885
  units: number | null;
874
- /** Number of custom domains currently in use, null if no billing */
875
- usage: number | null;
876
886
  /** Billing status from Creem (active, trialing, canceled, etc.), null if no billing */
877
887
  status: string | null;
878
888
  /** Link to Creem customer portal for billing management, null if unavailable */