π Authentication
The Python SDK supports dual authentication:
api_keyjwt_token
Use one of them in ClientOptions or mate.yaml.
1. Get Credentials
- Sign in to mate.wyseos.com
- Open your dashboard
- Create an API key, or use your JWT token from your auth flow
2. Configure with mate.yaml (Recommended)
mate:
# Use one of api_key or jwt_token
api_key: "your-api-key"
# jwt_token: "your-jwt-token"
base_url: "https://api.wyseos.com"
timeout: 30Load it:
from wyseos.mate import Client
from wyseos.mate.config import load_config
client = Client(load_config("mate.yaml"))3. Configure in Code
from wyseos.mate import Client, ClientOptions
# API key
client = Client(ClientOptions(api_key="YOUR_API_KEY"))
# JWT token
client = Client(ClientOptions(jwt_token="YOUR_JWT_TOKEN"))4. Header and Query Mapping
- HTTP:
api_key->x-api-keyjwt_token->Authorization(noBearerprefix)
- WebSocket URL query:
?api_key=...?authorization=...
5. Notes
- Keep credentials out of source code in production.
- Prefer
mate.yamland secret management.