API Key acquisition and usage
Memory API uses API Key authentication. Pass the key via the
Configure as an environment variable:
Each request carries the
Authorization header.
Get credentials
- Open the console: Open the Bailian console and log in with your Alibaba Cloud account.
-
Get API Key: Obtain
DASHSCOPE_API_KEYfrom the console, starting withsk-. See Get API Key.
Usage
Configure as an environment variable:
Authorization header:
Permissions
- Alibaba Cloud primary account: can call all endpoints directly
- RAM sub-accounts: require appropriate permissions
- API Key scope is configured in the console
Security best practices
- Never in repos: use environment variables
- Per-app keys: use separate keys for each app
- Rotate regularly: change keys periodically