Skip to content


Get your token

You can get your authentication token in your user account settings located in Account Settings > Authentication. You can also make requests to the API with your email and password.

Send your email and password to receive your access token. Your access token will be used to add Buckets to your account as well as other account-related access.

You do not need to use the token to access your Bucket content. Your Bucket has its own read and write keys for restricted access.

emailrequiredStringYour Cosmic login email
passwordrequiredStringYour Cosmic login password


POST $BASE_URL/authenticate

Example Body (JSON)

"email": "",
"password": "yourpassword"

Example Response

"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXV.eyJlbWFpbCI6InNwaXJvbnl..."

Use your token

You can use the Authentication token using REST requests to the API

Example -> Get Buckets

token must be passed as Authorization Bearer in the header of the request.


GET $BASE_URL/buckets


"Authorization": "Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXV.eyJlbWFpbCI6InNwaXJvbnl..."