Keys created before permissions existed keep working exactly as before. They hold full access: every permission except Manage keys (
apiKey:write), including permissions added in the future. The dashboard shows them as Acceso total.Creating a key with permissions
- In the dashboard, go to Configuraciones › Desarrollador and click Crear llave.
- Name the key after the system that will use it, for example
Tienda en líneaorERP. - Choose when it expires: never, 7, 30 or 90 days, or one year.
- Turn on the permissions it needs. Search by name or by endpoint (
/v1/payment,refund). The panel on the right lists every endpoint the chosen permissions open, each linked to its page in this reference. - Click Crear llave and copy the key. It is shown only once.
Who can give what
- You can give a key only the permissions your own dashboard role has. A member who cannot see fees cannot make a key that sees fees.
- Manage keys (
apiKey:write) is given only by an owner, signed in as themselves. - A key that manages keys can create or rotate keys only with permissions it holds itself, and never gives Manage keys.
Permissions
The same permissions apply to the payment-acceptance endpoints (
/api/one-time-payment, /api/payment-intent, /api/payment-method): a key without paymentMethod:write cannot charge a saved card there either.
Expiry and last use
A key with an expiry date stops working at that moment and answers401 with API_KEY_EXPIRED. It stays on the dashboard list as Vencida, so you can see what stopped and rotate it.
The list also shows when each key was last used, to the minute. A key nobody has used in months is a key you can revoke.
Rotating a key without downtime
Rotating creates a new secret for the same key: same name, same permissions, same lifetime counted from the rotation. The current secret keeps working for an overlap you choose (now, 1 hour, 24 hours or 7 days, 24 hours by default), so you can deploy the new one before the old one stops.1
Rotate
In the dashboard, open the key’s ⋯ menu and choose Rotar llave, or call
POST /developer/v1/api-key/{id}/roll with a key that holds apiKey:write.2
Deploy the new secret
Store the
key from the response in your secrets manager and deploy. previous.expiresAt says until when the old secret works.3
Let the old one expire
Nothing else to do. Once the overlap ends, the old secret answers
API_KEY_EXPIRED.409 API_KEY_ALREADY_ROLLED): rotate its replacement instead.
Key format
Keys created from now on start withcmp_ followed by 64 letters and digits. The dashboard shows the first eight characters and the last four, enough to tell which key a system uses. Older keys keep their format and keep working.
Compago stores only a hash of each key. Nobody, including Compago, can show a key again after it was created or rotated.