curl --request PATCH \
--url https://api.wirespeed.co/v1/users/{id}/role \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'import requests
url = "https://api.wirespeed.co/v1/users/{id}/role"
payload = {}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({})
};
fetch('https://api.wirespeed.co/v1/users/{id}/role', 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.wirespeed.co/v1/users/{id}/role",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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.wirespeed.co/v1/users/{id}/role"
payload := strings.NewReader("{}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.patch("https://api.wirespeed.co/v1/users/{id}/role")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wirespeed.co/v1/users/{id}/role")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"intercomId": "<string>",
"createdAt": "<string>",
"displayName": "<string>",
"email": "<string>",
"locked": true,
"isServiceAccount": true,
"activeTeamId": "<string>",
"parentTeamId": "<string>",
"completedOnboarding": true,
"teamId": "<string>",
"autoSubscribeToNotifications": true,
"role": "ADMIN",
"internalRole": "ADMIN",
"firstName": "<string>",
"lastName": "<string>",
"phoneNumber": "<string>"
}{
"message": "<string>",
"statusCode": 123
}Update user role
curl --request PATCH \
--url https://api.wirespeed.co/v1/users/{id}/role \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'import requests
url = "https://api.wirespeed.co/v1/users/{id}/role"
payload = {}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({})
};
fetch('https://api.wirespeed.co/v1/users/{id}/role', 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.wirespeed.co/v1/users/{id}/role",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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.wirespeed.co/v1/users/{id}/role"
payload := strings.NewReader("{}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.patch("https://api.wirespeed.co/v1/users/{id}/role")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wirespeed.co/v1/users/{id}/role")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"intercomId": "<string>",
"createdAt": "<string>",
"displayName": "<string>",
"email": "<string>",
"locked": true,
"isServiceAccount": true,
"activeTeamId": "<string>",
"parentTeamId": "<string>",
"completedOnboarding": true,
"teamId": "<string>",
"autoSubscribeToNotifications": true,
"role": "ADMIN",
"internalRole": "ADMIN",
"firstName": "<string>",
"lastName": "<string>",
"phoneNumber": "<string>"
}{
"message": "<string>",
"statusCode": 123
}Authorizations
Team API key sent as a Bearer token. Create a key in Wirespeed under Settings → Team. See https://docs.wirespeed.co/api-reference/authentication.
Path Parameters
User ID
Body
New role to assign to the user
ADMIN, ANALYST, VIEWER Response
Unique identifier for the user
Intercom customer support identifier
Timestamp when the user was created
Display name: first (+ optional last) if set, otherwise email
Email address of the user
Whether the user account is locked
Whether this is a service account for team API keys
ID of the currently active team
ID of the parent team
Whether the user has completed onboarding
Team ID the user belongs to
Whether the user is auto subscribed to notifications
Role assigned to the user
ADMIN, ANALYST, VIEWER Internal role for Wirespeed staff (null for regular users)
ADMIN, ANALYST, VIEWER First name of the user
Last name of the user
Phone number of the user

