API Keys
Create and manage API keys for programmatic access.
GET
List your own API keys across organizations; never returns the secret value
/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.
Parameters
page
query · numberPage number to return, 1-indexed. Defaults to 1.
pageSize
query · numberItems per page (1-100). Defaults to 10.
lite
query · stringWhen 'true', return only essential fields (id, slug, title/name) to reduce payload size. Useful for context fetching and link resolution.
sort
query · stringSort specifier as 'field:direction'. Sortable fields: name, createdAt, lastUsedAt, expiresAt. Direction is 'asc' or 'desc' and defaults to 'asc'.
search
query · stringFree-text search. Matched against: name.
name
query · stringFilter by name. Operators: name=value (equals), name_ne, name_gt, name_gte, name_lt, name_lte, name_like (contains), name_isnull=true|false, name_has=value (jsonb array contains), name[]=a&name[]=b (in).
organizationId
query · stringFilter by organizationId. Operators: organizationId=value (equals), organizationId_ne, organizationId_gt, organizationId_gte, organizationId_lt, organizationId_lte, organizationId_like (contains), organizationId_isnull=true|false, organizationId_has=value (jsonb array contains), organizationId[]=a&organizationId[]=b (in).
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: apiKeys } = await gc.apiKeys.listMyApiKeys();
GET
List all API keys in an organization; metadata only, no secret values
/organizations/{organizationId}/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.
Parameters
page
query · numberPage number to return, 1-indexed. Defaults to 1.
pageSize
query · numberItems per page (1-100). Defaults to 10.
lite
query · stringWhen 'true', return only essential fields (id, slug, title/name) to reduce payload size. Useful for context fetching and link resolution.
sort
query · stringSort specifier as 'field:direction'. Sortable fields: name, createdAt, lastUsedAt, expiresAt. Direction is 'asc' or 'desc' and defaults to 'asc'.
search
query · stringFree-text search. Matched against: name.
name
query · stringFilter by name. Operators: name=value (equals), name_ne, name_gt, name_gte, name_lt, name_lte, name_like (contains), name_isnull=true|false, name_has=value (jsonb array contains), name[]=a&name[]=b (in).
userId
query · stringFilter by userId. Operators: userId=value (equals), userId_ne, userId_gt, userId_gte, userId_lt, userId_lte, userId_like (contains), userId_isnull=true|false, userId_has=value (jsonb array contains), userId[]=a&userId[]=b (in).
organizationIdRequired
path · string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { id: organizationId } = await gc.organizations.getOrganizationBySlug({ slug: "my-org" });
const { data: apiKeys } = await gc.apiKeys.listOrganizationApiKeys({ organizationId });
BuiltAutonomously With AI
This content was built autonomously. Giant Context analyzed the site, determined what was missing, created and submitted an idea and draft, which Jesse accepted and published.