USER PERMISSION API
Manage resources and operations related to user permission.
GET Edition - Self Role Check
GET https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/users/me/permission
Returns the authenticated user's role in a specific edition.
Parameters
| Name | Type | In | Required | Description |
|---|---|---|---|---|
| edition_id | string | path | Required | The unique ID of the edition. |
Responses
200
success
success - Response
{
"data": {
"user_permission_info": {
"current_user_id": "96384499",
"edition_id": "96499735",
"role": "SUPER_ADMIN"
}
},
"message": "User permissions fetched successfully",
"request_uri": "/vani/api/v1/editions/96499735/users/me/permission",
"status": "success"
}
Code Examples
cURL
Command line HTTP client
cURL
curl -X GET "https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/users/me/permission" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json"
GET Edition - Other Users
GET https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/users/{user_id}/permission
Retrieves the role of a specific user in an edition.
Parameters
| Name | Type | In | Required | Description |
|---|---|---|---|---|
| edition_id | string | path | Required | The unique ID of the edition. |
| user_id | string | path | Required | The unique ID of the user(zuid). |
Responses
200
success
404
user not found
401
unauthorized
success - Response
{
"data": {
"user_permission_info": {
"current_user_id": "96384499",
"edition_id": "96499735",
"role": "ORG_ADMIN",
"zuid": "80215739"
}
},
"message": "User permissions fetched successfully",
"request_uri": "/vani/api/v1/editions/96499735/users/80215739/permission",
"status": "success"
}
Code Examples
cURL
Command line HTTP client
cURL
curl -X GET "https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/users/{user_id}/permission" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json"
GET Teams
GET https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/teams/users/me/permission
Returns a list of teams in a specific edition, along with the authenticated user's roles in each team.
Parameters
| Name | Type | In | Required | Description |
|---|---|---|---|---|
| edition_id | string | path | Required | The unique ID of the edition. |
Responses
200
success - team admin
200
success - member
success - team admin - Response
{
"data": {
"user_permission_info": {
"teams": [
{
"role": "TEAM_ADMIN",
"team_id": 3009000000002003
}
],
"current_user_id": "96384499",
"edition_id": "96499735"
}
},
"message": "User permissions fetched successfully",
"request_uri": "/vani/api/v1/editions/96499735/teams/users/me/permission",
"status": "success"
}
Code Examples
cURL
Command line HTTP client
cURL
curl -X GET "https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/teams/users/me/permission" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json"
GET Team - Self Role Check
GET https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/teams/{team_id}/users/me/permission
Returns the role of the authenticated user in a team.
Parameters
| Name | Type | In | Required | Description |
|---|---|---|---|---|
| edition_id | string | path | Required | The unique ID of the edition. |
| team_id | string | path | Required | The unique ID of the team associated with the edition. |
Responses
200
success
404
team not found
403
user is not a member
success - Response
{
"data": {
"user_permission_info": {
"current_user_id": "96384499",
"edition_id": "96499735",
"role": "TEAM_ADMIN",
"team_id": "3009000000002003"
}
},
"message": "User permissions fetched successfully",
"request_uri": "/vani/api/v1/editions/96499735/teams/3009000000002003/users/me/permission",
"status": "success"
}
Code Examples
cURL
Command line HTTP client
cURL
curl -X GET "https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/teams/{team_id}/users/me/permission" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json"
GET Team - Other Users
GET https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/teams/{team_id}/users/{user_id}/permission
Returns the role assigned to a specified user in a team.
Parameters
| Name | Type | In | Required | Description |
|---|---|---|---|---|
| edition_id | string | path | Required | The unique ID of the edition. |
| team_id | string | path | Required | The unique ID of the team associated with the edition. |
| user_id | string | path | Required | The unique ID of the user(zuid). |
Responses
200
succcess
404
user is not a member
401
unauthorized
succcess - Response
{
"data": {
"user_permission_info": {
"current_user_id": "96384499",
"edition_id": "96499735",
"role": "TEAM_ADMIN",
"team_id": "3009000000002003",
"zuid": "80215739"
}
},
"message": "User permissions fetched successfully",
"request_uri": "/vani/api/v1/editions/96499735/teams/3009000000002003/users/80215739/permission",
"status": "success"
}
Code Examples
cURL
Command line HTTP client
cURL
curl -X GET "https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/teams/{team_id}/users/{user_id}/permission" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json"
GET Space - Self Role Check
GET https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/spaces/{space_id}/users/me/permission
Retrieves the authenticated user's role in a specified Space.
Parameters
| Name | Type | In | Required | Description |
|---|---|---|---|---|
| edition_id | string | path | Required | The unique ID of the edition. |
| space_id | string | path | Required | The unique ID of the Space. |
Responses
200
success
404
space not found
403
member is not part of the space
success - Response
{
"data": {
"user_permission_info": {
"current_user_id": "96384499",
"edition_id": "96499735",
"role": "CREATOR",
"space_id": "3009000000093003"
}
},
"message": "User permissions fetched successfully",
"request_uri": "/vani/api/v1/editions/96499735/spaces/3009000000093003/users/me/permission",
"status": "success"
}
Code Examples
cURL
Command line HTTP client
cURL
curl -X GET "https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/spaces/{space_id}/users/me/permission" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json"
GET Space - Other Users
GET https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/spaces/{space_id}/users/{user_id}/permission
Returns the role of a specified user in a given Space.
Parameters
| Name | Type | In | Required | Description |
|---|---|---|---|---|
| edition_id | string | path | Required | The unique ID of the edition. |
| space_id | string | path | Required | The unique ID of the Space. |
| user_id | string | path | Required | The unique ID of the user(zuid). |
Responses
200
success
404
member not part of the space
401
unauthorized
success - Response
{
"data": {
"user_permission_info": {
"current_user_id": "96384499",
"edition_id": "96499735",
"role": "EDITOR",
"space_id": "3009000000303003",
"zuid": "80215739"
}
},
"message": "User permissions fetched successfully",
"request_uri": "/vani/api/v1/editions/96499735/spaces/3009000000303003/users/80215739/permission",
"status": "success"
}
Code Examples
cURL
Command line HTTP client
cURL
curl -X GET "https://api.app.vanihq.com/vani/api/v1/editions/{edition_id}/spaces/{space_id}/users/{user_id}/permission" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json"