List OAuth Applications
List all OAuth applications associated with your account.
GET
/o/apps/
Retrieve a list of all OAuth2 applications registered to your account.
Authentication
Requires OAuth 2.0 authentication with read scope.
Example Request
curl -X GET https://api.cryptofuse.io/o/apps/ \
-H "Authorization: Bearer your_access_token"
Response
Success Response (200 OK)
{
"count": 2,
"results": [
{
"id": 1,
"name": "Production API",
"client_id": "prod_client_id_here",
"client_type": "confidential",
"authorization_grant_type": "client-credentials",
"redirect_uris": [],
"created": "2025-01-01T10:00:00Z",
"updated": "2025-01-15T08:30:00Z",
"skip_authorization": true
},
{
"id": 2,
"name": "Development API",
"client_id": "dev_client_id_here",
"client_type": "confidential",
"authorization_grant_type": "client-credentials",
"redirect_uris": [],
"created": "2025-01-10T14:00:00Z",
"updated": "2025-01-10T14:00:00Z",
"skip_authorization": true
}
]
}
Response Fields
| Field | Type | Description |
|---|---|---|
id | integer | Application ID |
name | string | Application display name |
client_id | string | OAuth2 client ID |
client_type | string | Client type: "confidential" or "public" |
authorization_grant_type | string | Grant type (usually "client-credentials") |
redirect_uris | array | Redirect URIs (empty for client credentials) |
created | datetime | When the application was created |
updated | datetime | When the application was last updated |
Important Notes
- Client secrets are never returned in API responses
- Client secrets are only shown once when creating the application
- If you lose a client secret, you must regenerate it
- Each application has its own rate limits and usage statistics
Managing Applications
To create or manage OAuth applications:
- Log into the Cryptofuse dashboard
- Navigate to Settings → API Keys
- Create new applications or manage existing ones
- Store client secrets securely - they cannot be retrieved later
Example: List and Display Applications
async function listApplications(accessToken) {
const response = await fetch('https://api.cryptofuse.io/o/apps/', {
headers: {
'Authorization': `Bearer ${accessToken}`
}
});
const data = await response.json();
console.log(`You have ${data.count} OAuth application(s):`);
data.results.forEach(app => {
console.log(`\n${app.name}`);
console.log(` Client ID: ${app.client_id}`);
console.log(` Type: ${app.client_type}`);
console.log(` Created: ${new Date(app.created).toLocaleDateString()}`);
});
}
Python Example
import requests
from datetime import datetime
def list_oauth_applications(access_token):
"""List all OAuth applications."""
response = requests.get(
'https://api.cryptofuse.io/o/apps/',
headers={'Authorization': f'Bearer {access_token}'}
)
if response.status_code == 200:
data = response.json()
print(f"Total applications: {data['count']}")
print("-" * 50)
for app in data['results']:
created = datetime.fromisoformat(app['created'].replace('Z', '+00:00'))
print(f"\nName: {app['name']}")
print(f"Client ID: {app['client_id']}")
print(f"Type: {app['client_type']}")
print(f"Grant Type: {app['authorization_grant_type']}")
print(f"Created: {created.strftime('%Y-%m-%d %H:%M')}")
return data['results']
else:
print(f"Error: {response.status_code}")
return None
# Usage
apps = list_oauth_applications('your_access_token')
Security Best Practices
- Create separate applications for different environments (dev, staging, prod)
- Rotate client secrets regularly
- Never expose client secrets in client-side code
- Use environment variables to store credentials
- Monitor application usage for suspicious activity