curl --request GET \
--url https://api.diversion.dev/v0/organizations \
--header 'Authorization: Bearer <token>'{
"object": "Organization",
"items": [
{
"id": "org_123456",
"name": "Example Organization",
"owner_id": "user_123456",
"total_storage": 1000000,
"description": "This is an example organization.",
"members": [
{
"id": "member_123456",
"user_id": "user_123456",
"organization_id": "org_123456",
"role": "READ"
}
],
"invites": [
{
"id": 123456,
"organization_id": "org_123456",
"organization_name": "Great Organization",
"inviting_user_id": "user_123456",
"inviting_user_name": "John Doe",
"invited_email": "[email protected]",
"role": "READ",
"status": "PENDING",
"created": "2023-01-01T00:00:00Z",
"expires": "2023-01-31T00:00:00Z"
}
],
"in_warning_group": true
}
]
}Lists all organizations the user is a member of, optionally filtered to show only owned organizations when owned=true.
Sorting: Results are sorted alphabetically by organization name.
Information included: Each organization includes:
Returns: An empty list if the user is not a member of any organizations.
curl --request GET \
--url https://api.diversion.dev/v0/organizations \
--header 'Authorization: Bearer <token>'{
"object": "Organization",
"items": [
{
"id": "org_123456",
"name": "Example Organization",
"owner_id": "user_123456",
"total_storage": 1000000,
"description": "This is an example organization.",
"members": [
{
"id": "member_123456",
"user_id": "user_123456",
"organization_id": "org_123456",
"role": "READ"
}
],
"invites": [
{
"id": 123456,
"organization_id": "org_123456",
"organization_name": "Great Organization",
"inviting_user_id": "user_123456",
"inviting_user_name": "John Doe",
"invited_email": "[email protected]",
"role": "READ",
"status": "PENDING",
"created": "2023-01-01T00:00:00Z",
"expires": "2023-01-31T00:00:00Z"
}
],
"in_warning_group": true
}
]
}This API uses OAuth 2 with the implicit grant flow
Filter by organizations owned by the user or not.