# LoyaltyLion setup for PopMCP

You paste one value into PopMCP: an API key made under Manage, API keys in LoyaltyLion.

- Auth: API credentials
- Setup time: 1 min
- API base URL: https://api.loyaltylion.com
- Credentials screen: https://app.loyaltylion.com/go/manage/settings/
- Provider docs: https://developers.loyaltylion.com/api-reference/authentication/api-keys

## Before you begin

- A LoyaltyLion account with the Admin role in the program you want to connect
- The Classic plan or above for program setup, analytics and the Headless tools
- No app, redirect URL or review is needed: the key is the whole setup

## Get your credentials

### 1. Open API keys in LoyaltyLion

Sign in to LoyaltyLion and go to Manage, then API keys. If you run more than one program, switch to the program you want to connect first: a key belongs to one program. Ignore the token and secret in Settings: LoyaltyLion is retiring them on January 10, 2027, and PopMCP does not accept them.

Screen: https://app.loyaltylion.com/go/manage/settings/

### 2. Create the key and tick its permissions

Click Create API key and follow the steps. Call it PopMCP if it asks for a name. Tick every read and write permission so all the tools work: `read_customers`, `write_customers`, `read_orders`, `write_orders`, `read_reviews`, `write_reviews`, `read_unsubscribes` and `write_unsubscribes`. Add `write_configuration` only if your AI may turn rewards on and off. For a key that can only look, tick just the ones starting with `read_`. You can change these later without reconnecting.

Screen: https://app.loyaltylion.com/go/manage/settings/

### 3. Copy the token

LoyaltyLion shows the new token, which starts with `pat_`. Copy it now: you cannot see it again. If you lose it, make a new key and delete the old one.

Screen: https://app.loyaltylion.com/go/manage/settings/

### 4. Paste it into PopMCP

Paste the token into the API key field in PopMCP and connect. PopMCP checks it straight away, names the connection after your store and tells you which permissions the key does not have.

## Fields PopMCP asks for

- API key (apiKey) [required]: In LoyaltyLion go to Manage, then API keys, and click Create API key. Tick the permissions you want your AI to have, then copy the token: LoyaltyLion shows it only once. Stored encrypted.

## Verify

PopMCP marks the LoyaltyLion connection Verified under your store's name, and lists any permissions the key does not have. Ask the AI how your program is set up, or for a customer's points balance, and it answers from your account.

## Troubleshooting

### "LoyaltyLion did not accept that API key."

Cause: The token was copied only in part, the key was disabled or deleted, or it is the older token from Settings.

Fix: Make a new key under **Manage**, **API keys**, copy the whole token, which starts with `pat_`, and connect again.

### "That looks like the older token and secret"

Cause: You pasted the token and secret from Settings. LoyaltyLion is retiring them and they do not reach the whole API.

Fix: Use **Create API key** under **Manage**, **API keys** instead.

### A tool fails with a 403 that names a permission

Cause: The key was made without it.

Fix: Add it to the key under **Manage**, **API keys**. There is no need to reconnect.

### Program setup, analytics or a Headless tool says it was refused

Cause: These need the Classic plan or above. LoyaltyLion can also add the Headless API to a lower plan.

Fix: Check your plan in LoyaltyLion, or ask LoyaltyLion about the add-on.

### A tool asks for site_id

Cause: Your program has more than one site, so the AI has to say which.

Fix: Nothing to do: the AI gets the id from `loyaltylion_list_sites`. If you added a site recently, PopMCP notices the next time it checks the connection.

### A customer is not found by id

Cause: LoyaltyLion looks customers up by their id in your store, such as the Shopify customer id, not its own id.

Fix: Ask by email, or use the `merchant_id` that `loyaltylion_list_customers` shows.

---

Source: https://www.docs.popmcp.com/docs/integrations/loyaltylion/