For developers
Deploy tokens
One token, one site. It can read and publish that site, and roll back or take it offline only if you allowed it when you made it.
Two ways to get one
The easy way is approving in your browser: the CLI or your AI assistant shows a code, you approve it for one site, and it receives its access by itself. It appears in this list like any other token, and stops working after 90 days unused.
For CI and scripts, make one by hand.
Making one
Portal → Developers → Tokens → make a token for the site. It begins lm_ and is shown once, so copy it somewhere safe: we cannot show it again.
Permissions
You choose what each token can do when you make it. The list on the same page shows each token's permissions.
| Permission | Lets the token | On by default |
|---|---|---|
| Read | See the site's address, files and deploy history | Always |
| Publish | Replace the site with new files | Always |
| Roll back to an earlier version | Put a previous release back | No - tick it |
| Move the site to the trash | Take the site offline | No - tick it |
A token asked to do something it was not given is refused with a message saying which permission it needs. Permissions cannot be added to a token later: make a new one with the box ticked and revoke the old one.
Tokens made before permissions existed can read, publish and roll back. They cannot take the site offline.
What it reaches
| Can | Cannot |
|---|---|
| Publish to its own site | Touch any other site |
| Read that site's files and history | See your account or billing |
| Restore one of that site's releases, if allowed | Change a price or a plan |
| Take that site offline when it names it, if allowed | Bring it back |
That boundary is why handing one to an assistant is a reasonable thing to do. The worst a leaked token with the default permissions can do is publish to the one site it belongs to, and that is undoable. Only a token you allowed to can take the site offline, and that is undoable too.
Revoking
Same page, remove it. It takes effect immediately: the next call with it is refused, including one already in flight from a build that started before you clicked.
Where to keep it
- CI: a repository secret, passed as
LEMONADE_TOKEN. - Your machine:
lemonade loginwrites it to~/.lemonade. See the CLI. - Never in the folder you publish. The CLI skips dotfiles by default, but
--include-hiddenwould publish your token to the public internet.