@omniplex/api-types 0.6.0 → 0.7.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.
Files changed (2) hide show
  1. package/dist/index.d.ts +18 -2
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -380,6 +380,8 @@ export interface ApiSession {
380
380
  /** Empty means unrestricted — the token inherits whatever perms its owner has at request time. */
381
381
  perm_limits: string[];
382
382
  expiry: string;
383
+ /** True for the session making the request, so a UI can mark "this device". */
384
+ current: boolean;
383
385
  }
384
386
  export interface CreateSessionPayload {
385
387
  name: string;
@@ -1012,7 +1014,7 @@ export interface ListIndexServer {
1012
1014
  spotlight: IndexServer[];
1013
1015
  recently_bumped?: IndexServer[];
1014
1016
  }
1015
- export type PageGradient = "aurora" | "sunset" | "ocean" | "forest" | "candy" | "midnight" | "ember" | "mono";
1017
+ export type PageGradient = "aurora" | "sunset" | "ocean" | "forest" | "candy" | "midnight" | "ember" | "mono" | `custom:#${string}:#${string}`;
1016
1018
  export interface PageStyle {
1017
1019
  gradient: PageGradient | null;
1018
1020
  accent: string | null;
@@ -1436,10 +1438,24 @@ export interface ServerTemplate {
1436
1438
  tags: string[];
1437
1439
  nsfw: boolean;
1438
1440
  owner: PlatformUser;
1439
- /** Discord's own reported usage count, as of submission time. */
1441
+ /** Discord's own reported usage count, as of the last sync. */
1440
1442
  usage_count: number;
1441
1443
  created_at: string;
1442
1444
  updated_at: string;
1445
+ /** Version of the custom icon, for `templateIconUrl()`. Null when there's none. */
1446
+ icon_version: string | null;
1447
+ /** How many channels (not counting categories) the template has. */
1448
+ channel_count: number;
1449
+ /** How many roles (not counting @everyone) the template has. */
1450
+ role_count: number;
1451
+ /** When the template was last updated on Discord. */
1452
+ source_updated_at: string | null;
1453
+ /** The source server has changes not yet synced into the template on Discord. */
1454
+ out_of_date: boolean;
1455
+ /** The template no longer exists on Discord. Hidden from browse. */
1456
+ unavailable: boolean;
1457
+ /** When Omniplex last refreshed the template from Discord. */
1458
+ synced_at: string | null;
1443
1459
  /** Only populated on a single-template fetch, not the browse list. */
1444
1460
  channels: TemplateChannel[];
1445
1461
  /** Only populated on a single-template fetch, not the browse list. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@omniplex/api-types",
3
- "version": "0.6.0",
3
+ "version": "0.7.0",
4
4
  "description": "TypeScript types for the Omniplex API (Popplio).",
5
5
  "license": "MIT",
6
6
  "type": "module",