API Keys
How to manage API keys for programmatic access to Sproobo
API keys allow you to programmatically manage your Sproobo resources using the Sproobo API or CLI tools.
What are API Keys?
API keys are authentication tokens that allow external applications to interact with your Sproobo account. Use them for:
- Automating deployments
- Integrating with CI/CD pipelines
- Managing resources programmatically
- Using the Sproobo CLI
API Key Features
- Programmatic Access: Access Sproobo API programmatically
- CLI Authentication: Use with Sproobo CLI tools
- Scoped Permissions: Limit access to specific projects or resources
- Expiration: Set expiration dates for temporary access
- Audit Logs: Track all API key usage
Creating API Keys
- 1
Navigate to API Keys
Go to Settings → API Keys and click "Create API Key".Navigate to API Keys in your account settings. - 2
Configure API Key
Configure your API key:- Name: A descriptive name for this API key
- Description: Optional description of what this key is for
- Permissions: Select permissions (read-only, read-write, admin)
- Scope: Limit to specific projects or resources
- Expiration: Set expiration date (optional)
Configure your API key with name, permissions, and scope. - 3
Create and Copy Key
Click "Create API Key". Copy the key immediately - you won't be able to see it again.✕Important: API keys are only shown once. Store it securely before closing the dialog.
Copy your API key immediately - you won't see it again.
Using API Keys
Sproobo API
Use your API key to authenticate API requests:
bash
curl -H "Authorization: Bearer YOUR_API_KEY"
https://api.sproobo.com/v1/projects
Sproobo CLI
Set your API key in the CLI:
bash
sproobo auth login --api-key YOUR_API_KEY
API Key Permissions
Permission Levels
- Read-Only: Can view resources but not modify them
- Read-Write: Can view and modify resources
- Admin: Full access including account settings
Managing API Keys
- 1
View API Keys
Go to Settings → API Keys to see all your API keys with their status and last used date.View all your API keys and their usage information. - 2
Revoke API Key
To revoke an API key, click "Revoke" next to the key. This will immediately invalidate it.⚠️Revoking an API key will immediately stop all applications using it. Make sure to update your integrations first.
- 3
Rotate API Keys
Create a new API key, update your applications to use it, then revoke the old key.
Security Best Practices
Best Practices
- Use the minimum permissions required for each API key
- Set expiration dates for temporary access
- Rotate API keys regularly (every 90 days recommended)
- Never commit API keys to version control
- Revoke unused or compromised keys immediately
- Monitor API key usage for suspicious activity
Next Steps
Now that you've created an API key: