Ramp CLI and MCP integration: Manage agent keys

Overview

Early Access. Opt in from your Early Access settings.

Agent keys let you securely connect external agents to your Ramp account through the Ramp CLI and supported Ramp MCP tools. Each key is named, scoped, and tied to you, and your admin has full visibility into agent connections across the company.

What are agent keys?

When you connect to Ramp through the Ramp CLI or supported Ramp MCP tools, an agent key controls that connection. The key inherits your Ramp role permissions, so an external agent can only access what you can access, and every action it takes is logged separately from your own.

Each key has:

Your Ramp role permissions define the maximum access available to the agent. The OAuth scopes granted during authorization further limit which data and actions the connected CLI or MCP tool can use. If either your role or the granted OAuth scopes do not allow an action, the agent cannot perform it.

Connecting Ramp CLI and MCP

When you authenticate the Ramp CLI or a supported Ramp MCP tool, you are taken to an authorization screen that lists your existing agent keys. Select the key you want to use for the connection. The screen shows the read or write permissions the key grants so you can confirm the right level of access before proceeding.

If you select an expired key during this flow, its expiration is automatically extended by 30 days so the connection can proceed without requiring you to create a new key.

Managing your keys

Go to Settings > Agent keys to see all your active and inactive agent keys.

Settings Agent keys page showing the Connect AI assistants banner, an Active agents section with one key listed, and an Inactive agents section

Creating a key

  1. Go to Settings > Agent keys .
  2. Click Add agent .
  3. Fill in the fields in the Add an agent key dialog:
  1. Click Create agent .

Add an agent key dialog with Name, Expiration, and Scope fields and a Developer Terms of Service checkbox

Important: After you click Create agent, the key value is shown once in a "Copy agent secret" dialog. Copy it immediately and store it securely — you won't be able to retrieve it again. If you lose it, revoke the key and create a new one.

Editing a key

You can edit a key's name or extend its expiration at any time, including after it has expired. To edit, click the edit icon on the key's row in Settings > Agent keys. Use the date picker or quick-select buttons to choose a new expiration date.

Note: Scope cannot be changed after a key is created. To use a different scope, revoke the existing key and create a new one.

Revoking a key

Keys are listed under Active agents and Inactive agents. To revoke an active key, click the Revoke agent button on its row.

Revoked keys stop working immediately. If you believe a key has been compromised, revoke it right away and create a new one.

For Admins and managers

Admins and managers can view and manage agent keys at Settings > Developer > Agents. Admins see all keys across the business; managers see keys belonging to members of their team.

From this view, admins and managers can:

Scope is immutable and cannot be changed by admins or managers after a key is created.

The view shows each key's name, the user who created it, status (Active or Inactive), creation date, expiration, scope, and last-used date. You can filter by inactive or expired keys using the controls at the top of the table.

Admin Agent Keys page showing a table of agent keys with columns for Name, Created by, Status, Created date, Expiration, Scope, and Last used

Frequently asked questions

Can the CLI or MCP tool do more than I can?

No. The key inherits your permissions and can be scoped down, but never up.

What happens when a key expires?

The key stops working and moves to your Inactive agents list. You can extend the expiration at any time, including after it has expired, by clicking the edit icon on the key's row. If you select an expired key during the authorization flow, its expiration is automatically extended by 30 days so the connection proceeds without a new key.

What happens when my agent-key session expires?

Agent-key sessions can expire separately from the key itself. When a session expires, reconnect through the same channel before continuing: Ramp CLI users can run ramp auth login, and Ramp MCP users can follow the troubleshooting guidance in Ramp MCP.

Can I change a key's scope after creating it?

No. Scope is locked at creation. To use a different scope, revoke the existing key and create a new one with the scope you need.

Can I have multiple keys?

Yes — you can create separate keys for different tools or purposes.

Can my admin see my keys?

Yes. Admins can view all agent keys across the business. Managers can view keys belonging to members of their team. Both can see each key's scope and last-used date.

What's the difference between read-only access and read and write access?

I lost my key value.

Key values are shown once at creation. Revoke the old key and create a new one.

Where can I learn more about Ramp MCP?

For setup options and supported use cases, see Ramp MCP.