Skip to main content
POST
/
projects
/
{project_id}
/
user-access
Grant user access to a project
curl --request POST \
  --url {schemes}://api.upsun.com/projects/{project_id}/user-access \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
[
  {
    "user_id": "<string>",
    "permissions": [
      "admin"
    ],
    "auto_add_member": true
  }
]
'
{
  "status": "<string>",
  "message": "<string>",
  "code": 123,
  "detail": {},
  "title": "<string>"
}

Authorizations

Authorization
string
header
required

Path Parameters

project_id
string
required

The ID of the project.

Body

application/json
user_id
string
required

ID of the user.

permissions
enum<string>[]
required

An array of project permissions.

Available options:
admin,
viewer,
development:admin,
development:contributor,
development:viewer,
staging:admin,
staging:contributor,
staging:viewer,
production:admin,
production:contributor,
production:viewer
auto_add_member
boolean

If the specified user is not a member of the project's organization, add it automatically.

Response

No Content