Create and manage API keys for programmatic access.
Get my API keys
/me/api-keysReturns all active API keys belonging to the current user. Each key includes its ID, name, creation date, expiration date, and associated organization. The secret key value is not returned for security.
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: apiKeys } = await gc.apiKeys.listMyApiKeys();Get organization API keys
/organizations/{id}/api-keysReturns all active API keys for an organization. Each key object includes its ID, name, creation date, expiration date, and the user it is associated with. The secret key value is never returned in list responses. Requires admin or owner role within the organization.
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: apiKeys } = await gc.apiKeys.listOrganizationApiKeys("org_123");