Skip to content

Commit 8094e70

Browse files
committed
updated docs
1 parent a05ab23 commit 8094e70

14 files changed

Lines changed: 193 additions & 265 deletions

api-reference/assistant_interaction/send_a_message_to_an_assistant_and_get_a_response.mdx

Lines changed: 0 additions & 77 deletions
This file was deleted.

api-reference/media/animate_photo.mdx

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -32,19 +32,7 @@ Starts a job to generate an animated video of the assistant using an input image
3232

3333
</ParamField>
3434

35-
<ParamField body="dynamic_scale" type="number | null" default="1.0">
36-
37-
</ParamField>
38-
39-
<ParamField body="min_resolution" type="integer | null" default="512">
40-
41-
</ParamField>
42-
43-
<ParamField body="inference_steps" type="integer | null" default="25">
44-
45-
</ParamField>
46-
47-
<ParamField body="keep_resolution" type="boolean | null" default="true">
35+
<ParamField body="duration" type="integer | null" >
4836

4937
</ParamField>
5038

api-reference/openapi.json

Lines changed: 90 additions & 150 deletions
Large diffs are not rendered by default.

api-reference/organizations/create_organization.mdx

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ api: 'POST /v0/organizations'
55
Create a new organization.
66

77
The authenticated user will be the owner of the organization.
8-
If billing_user_id is not provided, it defaults to the owner.
8+
billing_user_id is always set to the owner (billing follows ownership).
9+
Returns the organization details and the owner's organization API key.
910

1011
#### Authorizations
1112

@@ -19,10 +20,6 @@ If billing_user_id is not provided, it defaults to the owner.
1920

2021
</ParamField>
2122

22-
<ParamField body="billing_user_id" type="string | null" >
23-
24-
</ParamField>
25-
2623
<RequestExample>
2724

2825
```bash cURL
@@ -51,13 +48,7 @@ print(response.text)
5148
<ResponseExample>
5249

5350
```json 201
54-
{
55-
"id": "integer",
56-
"name": "string",
57-
"owner_id": "string",
58-
"billing_user_id": "string",
59-
"created_at": "string"
60-
}
51+
{}
6152
```
6253

6354
```json 422
Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
---
2+
title: "Transfer Organization Ownership"
3+
api: 'POST /v0/organizations/{organization_id}/transfer-ownership'
4+
---
5+
Transfer organization ownership to another member.
6+
7+
Only the current owner can transfer ownership.
8+
The new owner must already be a member of the organization.
9+
10+
Changes applied:
11+
- org.owner_id → new_owner_id
12+
- org.billing_user_id → new_owner_id (billing always follows owner)
13+
- new_owner's role → Owner
14+
- old_owner's role → Admin
15+
16+
#### Authorizations
17+
18+
<ParamField header="Authorization" type="string" required="true">
19+
Bearer authentication header of the form `Bearer <token>`, where `<token>` is your auth token.
20+
</ParamField>
21+
22+
#### Path Parameters
23+
24+
<ParamField query="organization_id" type="integer" required="true">
25+
26+
</ParamField>
27+
28+
#### Body
29+
30+
<ParamField body="new_owner_id" type="string" required="true">
31+
32+
</ParamField>
33+
34+
<RequestExample>
35+
36+
```bash cURL
37+
curl --request POST \
38+
--url 'https://api.unify.ai/v0/organizations/<organization_id>/transfer-ownership' \
39+
--header "Authorization: Bearer $UNIFY_KEY"
40+
--header 'Content-Type: application/json' \
41+
--data '{}'
42+
```
43+
44+
```python Python
45+
import requests
46+
47+
url = "https://api.unify.ai/v0/organizations/<organization_id>/transfer-ownership"
48+
49+
headers = {"Authorization": "Bearer <token>"}
50+
51+
json_input = {}
52+
53+
response = requests.request("POST", url, json=json_input, headers=headers)
54+
55+
print(response.text)
56+
```
57+
58+
</RequestExample>
59+
<ResponseExample>
60+
61+
```json 200
62+
{
63+
"id": "integer",
64+
"name": "string",
65+
"owner_id": "string",
66+
"billing_user_id": "string",
67+
"created_at": "string"
68+
}
69+
```
70+
71+
```json 422
72+
{
73+
"detail": [
74+
{
75+
"loc": [
76+
"string"
77+
],
78+
"msg": "string",
79+
"type": "string"
80+
}
81+
]
82+
}
83+
```
84+
85+
</ResponseExample>

api-reference/organizations/update_organization.mdx

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ api: 'PATCH /v0/organizations/{organization_id}'
55
Update an organization.
66

77
Requires org:write permission.
8+
Note: To change owner or billing_user_id, use the transfer-ownership endpoint.
89

910
#### Authorizations
1011

@@ -24,10 +25,6 @@ Requires org:write permission.
2425

2526
</ParamField>
2627

27-
<ParamField body="billing_user_id" type="string | null" >
28-
29-
</ParamField>
30-
3128
<RequestExample>
3229

3330
```bash cURL

api-reference/projects/create_project.mdx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,11 @@
22
title: "Create Project"
33
api: 'POST /v0/project'
44
---
5-
Creates a logging project and adds this to your account. This project will
6-
have a set of logs associated with it.
5+
Creates a logging project and adds this to your account.
6+
7+
If using an organization API key, the project will be created as an
8+
organizational project (requires project:write permission in the org).
9+
If using a personal API key, the project will be a personal project.
710

811
#### Authorizations
912

api-reference/projects/transfer_project_to_organization.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ Requirements:
1212
Process:
1313
- Sets project.organization_id = target org
1414
- Sets project.user_id = NULL (org-owned)
15-
- No ResourceAccess entries created (implicit membership handles access)
15+
- Creates explicit Owner ResourceAccess grant for the transferring user
1616

1717
#### Authorizations
1818

api-reference/teams_&_resource_access/add_team_members.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ api: 'POST /v0/organizations/{organization_id}/teams/{team_id}/members'
44
---
55
Add members to a team.
66

7-
Only organization owners can add members to teams.
7+
Requires org:write permission (Owner and Admin roles have this).
88

99
:param request_fastapi: FastAPI request object.
1010
:param organization_id: Organization ID.

api-reference/teams_&_resource_access/create_team.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ api: 'POST /v0/organizations/{organization_id}/teams'
44
---
55
Create a new team in an organization.
66

7-
Only organization owners can create teams.
7+
Requires org:write permission (Owner and Admin roles have this).
88

99
:param request_fastapi: FastAPI request object.
1010
:param organization_id: Organization ID.

0 commit comments

Comments
 (0)