Update Member
curl --request PUT \
--url https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id} \
--header 'Content-Type: application/json' \
--data '
{
"role_id": "<string>",
"expires_at": {}
}
'import requests
url = "https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}"
payload = {
"role_id": "<string>",
"expires_at": {}
}
headers = {"Content-Type": "application/json"}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({role_id: '<string>', expires_at: {}})
};
fetch('https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'role_id' => '<string>',
'expires_at' => [
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}"
payload := strings.NewReader("{\n \"role_id\": \"<string>\",\n \"expires_at\": {}\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}")
.header("Content-Type", "application/json")
.body("{\n \"role_id\": \"<string>\",\n \"expires_at\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"role_id\": \"<string>\",\n \"expires_at\": {}\n}"
response = http.request(request)
puts response.read_bodyMembers
Update Member
Changes a member’s role or access expiry. Requires members:manage.
PUT
/
v1
/
workspaces
/
{id}
/
members
/
{user_id}
Update Member
curl --request PUT \
--url https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id} \
--header 'Content-Type: application/json' \
--data '
{
"role_id": "<string>",
"expires_at": {}
}
'import requests
url = "https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}"
payload = {
"role_id": "<string>",
"expires_at": {}
}
headers = {"Content-Type": "application/json"}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({role_id: '<string>', expires_at: {}})
};
fetch('https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'role_id' => '<string>',
'expires_at' => [
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}"
payload := strings.NewReader("{\n \"role_id\": \"<string>\",\n \"expires_at\": {}\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}")
.header("Content-Type", "application/json")
.body("{\n \"role_id\": \"<string>\",\n \"expires_at\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.vertracloud.app/v1/workspaces/{id}/members/{user_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"role_id\": \"<string>\",\n \"expires_at\": {}\n}"
response = http.request(request)
puts response.read_bodyRequires the
members:manage permission. An API key needs the workspaces:write scope.
Nobody can edit their own membership row through this endpoint — not even to change their own
expires_at. Without that, members:manage would be able to remove its own expiry and become
permanent unilaterally.Path
string
required
Workspace ID.
string
required
Member’s user ID.
Body
At least one field required.string
New role ID, must belong to this workspace.
string | null
ISO datetime, or
null to clear the expiry.Response
Same shape as List Members row.Errors
| Status | Code | When |
|---|---|---|
| 400 | VALIDATION_ERROR | No field provided. |
| 403 | WORKSPACE_PERMISSION_DENIED | Caller lacks members:manage, or is editing their own row. |
| 404 | WORKSPACE_NOT_FOUND | Workspace doesn’t exist or you’re not a member. |
| 404 | WORKSPACE_ROLE_NOT_FOUND | role_id doesn’t belong to this workspace. |