Utilities
Overview of utilities
Utilities for data access and widget lifecycle
The @eney/api package provides several utilities to use inside your widget components.
Available utilities
useLogger
Write debug, info, warn, and error messages to the Eney log.
useCloseWidget
Finalize a widget interaction and pass context back to Eney.
runScript
Run AppleScript via osascript and return the output as a string.
useOAuth
Handle PKCE OAuth sign-in, token access, and refresh inside a widget.
Import
Import utilities directly from the Eney API package:
import { useLogger, useCloseWidget, runScript, useOAuth } from "@eney/api";