Skip to main content
PUT
/
v2
/
environments
/
{environmentId}
/
members
/
{memberId}
Update Member
curl --request PUT \
  --url https://api.tusky.io/v2/environments/{environmentId}/members/{memberId} \
  --header 'Content-Type: application/json' \
  --data '
{
  "role": "<string>"
}
'
{
  "id": "<string>",
  "address": "<string>",
  "role": "<string>",
  "environmentId": "<string>",
  "createdAt": "<string>"
}
Update the role of an existing environment member.

Path Parameters

environmentId
string
required
The unique identifier of the environment.
memberId
string
required
The unique identifier of the member to update.

Request Body

role
string
required
The new role to assign. One of:
  • viewer — read-only access to environment files
  • manager — can upload, download, and delete files
  • owner — full access including member management

Response

id
string
Unique identifier for the membership.
address
string
The Sui wallet address of the member.
role
string
The updated role.
environmentId
string
The environment this membership belongs to.
createdAt
string
ISO 8601 timestamp of when the member was added.

Example

curl -X PUT https://api.tusky.io/v2/environments/env_abc123def456/members/member_stu901vwx234 \
  -H "Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "role": "admin"
  }'

Response

{
  "id": "member_stu901vwx234",
  "address": "0x1a2b3c4d5e6f7890abcdef1234567890abcdef12",
  "role": "admin",
  "environmentId": "env_abc123def456",
  "createdAt": "2025-07-02T10:00:00.000Z"
}
Only environment owners and admins can update member roles. You cannot change the role of the environment owner.