Skip to navigation

CreateApiKey

CreateApiKey makes a key and returns its secret, the only time the secret is shown; a team holds at most 10. The same request_id within 24 hours returns the same key and secret.

Authentication

AuthorizationBearer

A team API key, sent as Authorization: Bearer <key>.

OR
AuthorizationBearer

The Cognito access token of a signed-in Edulead user (edulead auth login), sent as Authorization: Bearer <token>.

Headers

Edulead-TeamstringRequired

Query parameters

request_idstringOptional1-64 characters

Caller-chosen idempotency key. The same key from the same caller within 24 hours returns the original result instead of acting again.

Request

This endpoint expects an object.
idstringOptional<=36 characters
Identifier of the resource, assigned by Edulead and opaque to callers.
namestringOptional<=100 characters

A label for the key, trimmed; may be empty. Names need not be unique.

prefixstringOptional<=8 characters
The secret's first 8 characters, to tell keys apart.
creator_idstringOptional<=128 characters

The user who created the key; empty for keys Edulead issued.

create_timedatetimeOptional
When Edulead created the resource.
secretstringOptional<=64 characters

The full key, to send as Authorization: Bearer <secret>. Set only in CreateApiKey’s response, the one time it is shown: store it. Empty everywhere else.

Response

Success
api_keyobjectOptional

ApiKey is one of the team’s API keys. Keys Edulead issued before keys could be created through the API have no create_time; they list as the oldest.