Skip to content

Instantly share code, notes, and snippets.

@Toyz
Last active April 15, 2025 03:02
Show Gist options
  • Save Toyz/ff1414d2e460a477781424ce02322f78 to your computer and use it in GitHub Desktop.
Save Toyz/ff1414d2e460a477781424ce02322f78 to your computer and use it in GitHub Desktop.
The types for the Streamelements API for custom widgets
interface SE_API {
cheerFilter: (message: string) => Promise<void>;
sanitize: (object: any) => Promise<any>;
getOverlayStatus: () => Promise<{ isEditorMode: boolean; muted: boolean }>;
setField: (key: string, value: any, reload?: boolean) => Promise<void>;
store: {
get: <T = any>(key: string) => Promise<T>;
set: <T = any>(key: string, value: T) => Promise<void>;
};
counters: {
get: (key: string) => Promise<{
value: number;
counter: string;
}>;
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment