curl --request PATCH \
--url https://api.runflow.ai/api/v1/runtime/users/{id} \
--header 'Content-Type: application/json' \
--data '
{
"email": "john.doe@acme.com",
"phone": "+5511999999999",
"name": "John Doe",
"avatarUrl": "https://example.com/avatar.jpg",
"isActive": true,
"role": "USER"
}
'import requests
url = "https://api.runflow.ai/api/v1/runtime/users/{id}"
payload = {
"email": "john.doe@acme.com",
"phone": "+5511999999999",
"name": "John Doe",
"avatarUrl": "https://example.com/avatar.jpg",
"isActive": True,
"role": "USER"
}
headers = {"Content-Type": "application/json"}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
email: 'john.doe@acme.com',
phone: '+5511999999999',
name: 'John Doe',
avatarUrl: 'https://example.com/avatar.jpg',
isActive: true,
role: 'USER'
})
};
fetch('https://api.runflow.ai/api/v1/runtime/users/{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.runflow.ai/api/v1/runtime/users/{id}",
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([
'email' => 'john.doe@acme.com',
'phone' => '+5511999999999',
'name' => 'John Doe',
'avatarUrl' => 'https://example.com/avatar.jpg',
'isActive' => true,
'role' => 'USER'
]),
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.runflow.ai/api/v1/runtime/users/{id}"
payload := strings.NewReader("{\n \"email\": \"john.doe@acme.com\",\n \"phone\": \"+5511999999999\",\n \"name\": \"John Doe\",\n \"avatarUrl\": \"https://example.com/avatar.jpg\",\n \"isActive\": true,\n \"role\": \"USER\"\n}")
req, _ := http.NewRequest("PATCH", 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.patch("https://api.runflow.ai/api/v1/runtime/users/{id}")
.header("Content-Type", "application/json")
.body("{\n \"email\": \"john.doe@acme.com\",\n \"phone\": \"+5511999999999\",\n \"name\": \"John Doe\",\n \"avatarUrl\": \"https://example.com/avatar.jpg\",\n \"isActive\": true,\n \"role\": \"USER\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.runflow.ai/api/v1/runtime/users/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"email\": \"john.doe@acme.com\",\n \"phone\": \"+5511999999999\",\n \"name\": \"John Doe\",\n \"avatarUrl\": \"https://example.com/avatar.jpg\",\n \"isActive\": true,\n \"role\": \"USER\"\n}"
response = http.request(request)
puts response.read_body{
"id": "123e4567-e89b-12d3-a456-426614174000",
"email": "john.doe@acme.com",
"name": "John Doe",
"role": "USER",
"isActive": true,
"lastLoginAt": "2025-01-01T00:00:00.000Z",
"createdAt": "2025-01-01T00:00:00.000Z",
"updatedAt": "2025-01-01T00:00:00.000Z",
"tenantId": "123e4567-e89b-12d3-a456-426614174000",
"phone": "+5511999999999",
"avatarUrl": "https://example.com/avatar.jpg",
"metadata": {
"auth0_user_id": "auth0|1234567890",
"auth0_created": true,
"invite_sent": false
},
"_count": {
"agents": 3,
"credentials": 5,
"executions": 12
}
}Update user (CLI/SDK)
Updates an existing user via CLI/SDK.
curl --request PATCH \
--url https://api.runflow.ai/api/v1/runtime/users/{id} \
--header 'Content-Type: application/json' \
--data '
{
"email": "john.doe@acme.com",
"phone": "+5511999999999",
"name": "John Doe",
"avatarUrl": "https://example.com/avatar.jpg",
"isActive": true,
"role": "USER"
}
'import requests
url = "https://api.runflow.ai/api/v1/runtime/users/{id}"
payload = {
"email": "john.doe@acme.com",
"phone": "+5511999999999",
"name": "John Doe",
"avatarUrl": "https://example.com/avatar.jpg",
"isActive": True,
"role": "USER"
}
headers = {"Content-Type": "application/json"}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
email: 'john.doe@acme.com',
phone: '+5511999999999',
name: 'John Doe',
avatarUrl: 'https://example.com/avatar.jpg',
isActive: true,
role: 'USER'
})
};
fetch('https://api.runflow.ai/api/v1/runtime/users/{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.runflow.ai/api/v1/runtime/users/{id}",
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([
'email' => 'john.doe@acme.com',
'phone' => '+5511999999999',
'name' => 'John Doe',
'avatarUrl' => 'https://example.com/avatar.jpg',
'isActive' => true,
'role' => 'USER'
]),
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.runflow.ai/api/v1/runtime/users/{id}"
payload := strings.NewReader("{\n \"email\": \"john.doe@acme.com\",\n \"phone\": \"+5511999999999\",\n \"name\": \"John Doe\",\n \"avatarUrl\": \"https://example.com/avatar.jpg\",\n \"isActive\": true,\n \"role\": \"USER\"\n}")
req, _ := http.NewRequest("PATCH", 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.patch("https://api.runflow.ai/api/v1/runtime/users/{id}")
.header("Content-Type", "application/json")
.body("{\n \"email\": \"john.doe@acme.com\",\n \"phone\": \"+5511999999999\",\n \"name\": \"John Doe\",\n \"avatarUrl\": \"https://example.com/avatar.jpg\",\n \"isActive\": true,\n \"role\": \"USER\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.runflow.ai/api/v1/runtime/users/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"email\": \"john.doe@acme.com\",\n \"phone\": \"+5511999999999\",\n \"name\": \"John Doe\",\n \"avatarUrl\": \"https://example.com/avatar.jpg\",\n \"isActive\": true,\n \"role\": \"USER\"\n}"
response = http.request(request)
puts response.read_body{
"id": "123e4567-e89b-12d3-a456-426614174000",
"email": "john.doe@acme.com",
"name": "John Doe",
"role": "USER",
"isActive": true,
"lastLoginAt": "2025-01-01T00:00:00.000Z",
"createdAt": "2025-01-01T00:00:00.000Z",
"updatedAt": "2025-01-01T00:00:00.000Z",
"tenantId": "123e4567-e89b-12d3-a456-426614174000",
"phone": "+5511999999999",
"avatarUrl": "https://example.com/avatar.jpg",
"metadata": {
"auth0_user_id": "auth0|1234567890",
"auth0_created": true,
"invite_sent": false
},
"_count": {
"agents": 3,
"credentials": 5,
"executions": 12
}
}Path Parameters
User UUID
Body
User email address
"john.doe@acme.com"
User phone number
"+5511999999999"
User full name
2 - 100"John Doe"
User avatar URL
500"https://example.com/avatar.jpg"
Whether the user is active
true
User role within the tenant
ADMIN, USER, VIEWER, SUPER_ADMIN, HUB_USER "USER"
Response
User updated successfully.
User unique identifier
"123e4567-e89b-12d3-a456-426614174000"
User email address
"john.doe@acme.com"
User full name
"John Doe"
User role within the tenant
ADMIN, USER, VIEWER, SUPER_ADMIN, HUB_USER "USER"
Whether the user is active
true
User last login timestamp
"2025-01-01T00:00:00.000Z"
Creation timestamp
"2025-01-01T00:00:00.000Z"
Last update timestamp
"2025-01-01T00:00:00.000Z"
Tenant ID that the user belongs to
"123e4567-e89b-12d3-a456-426614174000"
User phone number
"+5511999999999"
User avatar URL
"https://example.com/avatar.jpg"
User metadata (Auth0 integration data)
{
"auth0_user_id": "auth0|1234567890",
"auth0_created": true,
"invite_sent": false
}
User related statistics
{
"agents": 3,
"credentials": 5,
"executions": 12
}