---
title: "Migrate from API-keys to access token"
description: "RemotiveCloud API keys are replaced by personal access tokens. Create a token, keep it out of your code and supply it through an environment variable."
source: https://developer.remotivelabs.com/docs/cloud/Guides/migrate-from-apikeys
last_updated: 2026-10-30
deprecated: true
---

# Migrate from API-keys to access token

For security reasons API-keys have been replaced with personal access tokens. These tokens are personal and must not
be distributed.

> **Tip**
>
> Using RemotiveCLI may simplify your life when working with personal access tokens but it
> isn't required

#### Make sure to read how to create your access token [how to create your access token](https://developer.remotivelabs.com/docs/cloud/Account.md#personal-access-tokens)

#### You should now have downloaded your token file, use the following command to see what it looks like

```bash title="View token file contents"
cat ~/.config/remotive/personal-token-{TOKEN_ID}.json | jq .
```
Should result in something like this where the token attribute is the actual secret.
```json
{
  "expires": "2033-09-12",
  "token": "92B56F9C-A5869F38-F24DEBD2-09DFB027-3C760E73-243F3949-63ED57FF-E90A95C1",
  "created": "2023-09-12T07:02:34.521Z",
  "name": "EB39AFB2492D6D94"
}
```

> **Caution**
>
> It's highly discouraged to use this token in code or in anyway let it leave your personal computer. To use
> this is code you should make sure that you can use this token without hard-coding it into your program. Use environment variables,
> config file or similar so that the user who is running the code can supply her personal token.

```bash
export remotive_cloud_secret_token=92B56F9C-A5869F38-F24DEBD2-09DFB027-3C760E73-243F3949-63ED57FF-E90A95C1

export remotive_cloud_secret_token=$(remotive auth print-access-token)
```
