Sample - OpenAI API
POST/organization/projects/{project_id}/users/{user_id}

Modify a project user's role

Updates a user's role in a specific project. Supply role to set the membership to owner or member, or use a null value where the schema permits it.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

2 parameters · 1 body field
project_idstringrequired
The identifier of the project containing the user.
user_idstringrequired
The identifier of the user whose project role to update.

Project user update payload containing the role value to apply.

rolestringoptional
`owner` or `member`

2 status codes
200Returns the updated project user object with its identifier, name, email, role, and added timestamp.
objectstringrequired
The object type, which is always `organization.project.user`
Allowed:organization.project.user
idstringrequired
The identifier, which can be referenced in API endpoints
namestringoptional
The name of the user
emailstringoptional
The email address of the user
rolestringrequired
`owner` or `member`
added_atintegerrequired
The Unix timestamp (in seconds) of when the project was added.
400Returned when the request body or `role` value does not satisfy the update schema.
errorobjectrequired

Error handling

A 400 is returned when the request body or role value is invalid. role may be a string representing owner or member, or a null value; project_id and user_id must identify the project membership to update.