Create Download Token Endpoint
const url = 'https://example.com/auth/download-token/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0';const options = {method: 'POST'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/auth/download-token/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0Mint a short-lived download-scoped JWT for a single dataset.
IA-P0-01 / SEC-04: the existing COG download URL path requires a
typ='download' JWT on the ?token= query parameter — session JWTs
are rejected. This endpoint issues that token after verifying the caller
has read access to the dataset.
Anonymous callers are allowed for public datasets. The returned token has
typ='download', scope='dataset:{dataset_id}', and a TTL of 120s.
Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ”Responses
Section titled “ Responses ”Successful Response
object
Seconds until the download token expires
Short-lived download-scoped JWT (typ=‘download’, TTL ≤ 120s)
Example
{ "expires_in": 120}Bad request — invalid query parameters or payload
Unauthorized — missing or invalid credentials
Forbidden — caller lacks access to this resource
Not found
Validation error
Too many requests — retry after the advertised interval
Headers
Section titled “Headers ”Seconds until the request may be retried
Internal server error
Service unavailable — the database could not serve the request