Organizations API
The Organizations API allows you to retrieve and manage your organization information.
info
This API endpoint is available for enterprise accounts only.
Get Organizations
Retrieve your organizations list.
HTTP Request
GET https://fullhunt.io/api/v1/enterprise/organizations
Example Request
curl "https://fullhunt.io/api/v1/enterprise/organizations" \
-H "X-API-KEY: xxxx-xxxx-xxxx-xxxxxx"
Example Response
[
{
"id": "3db40e1c-1d26-4309-b0c4-105fde3b3486",
"name": "ORG Name",
"description": "ORG description",
"is_default": true
}
]
Response Fields
Field | Type | Description |
---|---|---|
id | string | Unique organization identifier |
name | string | Organization name |
description | string | Organization description |
is_default | boolean | Whether this is the default organization |
Use Cases
Organization Management
- List all organizations associated with your account
- Identify default organization for API operations
- Get organization details for reporting and analytics
Multi-Tenant Operations
- Switch between different organizational contexts
- Manage separate asset inventories per organization
- Implement organizational access controls
Integration Example
import requests
def get_organizations(api_key):
"""Get all organizations for the account."""
url = "https://fullhunt.io/api/v1/enterprise/organizations"
headers = {"X-API-KEY": api_key}
response = requests.get(url, headers=headers)
if response.status_code == 200:
organizations = response.json()
print(f"Found {len(organizations)} organizations:")
for org in organizations:
status = " (default)" if org.get('is_default') else ""
print(f"- {org['name']}: {org['description']}{status}")
return organizations
else:
print(f"Error: {response.status_code}")
return None
# Usage
api_key = "your-api-key-here"
orgs = get_organizations(api_key)
Error Responses
401 Unauthorized
{
"error": "unauthorized",
"message": "Invalid API key or insufficient permissions"
}
403 Forbidden
{
"error": "enterprise_only",
"message": "This endpoint is only available for enterprise users"
}
Rate Limiting
- Rate limit: 60 requests per minute
- Standard enterprise rate limiting applies
- Monitor rate limit headers in responses