Interface: CreateApiKeyResponse
Gala Launchpad SDK 9.0.0-rc.5 / index / CreateApiKeyResponse
Interface: CreateApiKeyResponse
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:284
Response when creating a new API key.
CRITICAL: rawKey is ONLY returned on creation and never again!
Example
const result = await sdk.createApiKey({ role: 'MODERATOR' });
console.log('Save this key:', result.rawKey); // Only chance to see it!
// rawKey format: "glp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
Extends
Properties
createdAt
createdAt:
string
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:269
Creation timestamp (ISO 8601)
Inherited from
delegateAllTokens
delegateAllTokens:
boolean
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:255
Whether key has access to all owner's tokens
Inherited from
description
description:
string|null
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:246
User's description/label
Inherited from
expiresAt
expiresAt:
string|null
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:265
Expiration timestamp (ISO 8601) or null if never expires
Inherited from
id
id:
number
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:242
Unique identifier
Inherited from
keyPrefix
keyPrefix:
string
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:244
First 8 characters for identification (e.g., "glp_abc1")
Inherited from
lastUsedAt
lastUsedAt:
string|null
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:267
Last time key was used (ISO 8601) or null if never used
Inherited from
rawKey
rawKey:
string
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:292
The full API key - ONLY shown once on creation! Format: glp_{base64url_encoded_random_bytes} Example: "glp_abc1234defghijklmnopqrstuvwxyz012345678"
CRITICAL: Store this securely - it cannot be retrieved again!
role
role:
ApiKeyRole
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:248
Role determining permissions
Inherited from
sourceType
sourceType:
ApiKeySource
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:253
Indicates whether the key holder owns tokens (OWNER) or only has moderator access (MODERATOR).
Since
9.1.0
Inherited from
tokenNames
tokenNames:
string[] |null
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:257
List of specifically delegated token names (null if delegateAllTokens is true)
Inherited from
tokenPermissions?
optionaltokenPermissions?:Record<string,Permission[]> |null
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:263
Per-token permission overrides (null if no overrides set). Maps tokenName to Permission[].
Since
5.8.0
Inherited from
updatedAt
updatedAt:
string
Defined in: packages/launchpad-sdk/dist/types/api-key.dto.d.ts:271
Last update timestamp (ISO 8601)