Update member
curl --request PUT \
--url https://apiweb.mile.app/api/v3/member/{userId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Rina Putri",
"hubId": [
"64d9932e2beb9037735ff022"
],
"roleId": "6449f8ef2c481b07d40ecfc5",
"phoneNumber": "+62 81234567890",
"status": "active"
}
'import requests
url = "https://apiweb.mile.app/api/v3/member/{userId}"
payload = {
"name": "Rina Putri",
"hubId": ["64d9932e2beb9037735ff022"],
"roleId": "6449f8ef2c481b07d40ecfc5",
"phoneNumber": "+62 81234567890",
"status": "active"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'Rina Putri',
hubId: ['64d9932e2beb9037735ff022'],
roleId: '6449f8ef2c481b07d40ecfc5',
phoneNumber: '+62 81234567890',
status: 'active'
})
};
fetch('https://apiweb.mile.app/api/v3/member/{userId}', 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://apiweb.mile.app/api/v3/member/{userId}",
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([
'name' => 'Rina Putri',
'hubId' => [
'64d9932e2beb9037735ff022'
],
'roleId' => '6449f8ef2c481b07d40ecfc5',
'phoneNumber' => '+62 81234567890',
'status' => 'active'
]),
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://apiweb.mile.app/api/v3/member/{userId}"
payload := strings.NewReader("{\n \"name\": \"Rina Putri\",\n \"hubId\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"roleId\": \"6449f8ef2c481b07d40ecfc5\",\n \"phoneNumber\": \"+62 81234567890\",\n \"status\": \"active\"\n}")
req, _ := http.NewRequest("PUT", 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.put("https://apiweb.mile.app/api/v3/member/{userId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Rina Putri\",\n \"hubId\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"roleId\": \"6449f8ef2c481b07d40ecfc5\",\n \"phoneNumber\": \"+62 81234567890\",\n \"status\": \"active\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://apiweb.mile.app/api/v3/member/{userId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Rina Putri\",\n \"hubId\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"roleId\": \"6449f8ef2c481b07d40ecfc5\",\n \"phoneNumber\": \"+62 81234567890\",\n \"status\": \"active\"\n}"
response = http.request(request)
puts response.read_body{
"status": true,
"data": {
"_id": "621dd813eb3ebf16b94d6969",
"name": "Rina Putri",
"email": "[email protected]",
"phoneNumber": "+62 81234567890",
"hubId": [
"64d9932e2beb9037735ff022"
],
"teamId": [],
"roleId": "6449f8ef2c481b07d40ecfc5",
"organizationId": "64d99303be0ad015c461c932",
"language": "en",
"status": "active",
"updatedTime": "2026-10-16T03:20:00.000000Z",
"createdTime": "2025-01-10T02:00:00.000000Z"
},
"message": "Data has been updated successfully.",
"statusCode": 200,
"billingUpdated": false,
"licenseDowngraded": false
}{
"status": false,
"message": "Bad request - invalid parameters provided."
}{
"status": false,
"message": "Bad request - invalid parameters provided."
}{
"status": false,
"message": "Data not found"
}{
"status": false,
"message": "Internal server error, please contact [email protected]."
}User
Update member
Updates another member of your organization: name, hubs, teams, role, phone number, language or status.
Requires permission edit/member.
Rules:
name: 4-30 characters, letters, numbers, spaces and- ' + _ .only.phoneNumber: country code with+, a space, then the number, 10-16 characters, e.g.+62 81234567890.status:activeordisable. You cannot disable yourself or an owner.- An organization always keeps at least one active owner, so the last owner’s role cannot be changed.
- Changing
hubIdremoves the member from teams of hubs they no longer belong to. - Setting
passwordsigns the member out of all sessions. You can only edit members who share a hub with you.
PUT
/
member
/
{userId}
Update member
curl --request PUT \
--url https://apiweb.mile.app/api/v3/member/{userId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Rina Putri",
"hubId": [
"64d9932e2beb9037735ff022"
],
"roleId": "6449f8ef2c481b07d40ecfc5",
"phoneNumber": "+62 81234567890",
"status": "active"
}
'import requests
url = "https://apiweb.mile.app/api/v3/member/{userId}"
payload = {
"name": "Rina Putri",
"hubId": ["64d9932e2beb9037735ff022"],
"roleId": "6449f8ef2c481b07d40ecfc5",
"phoneNumber": "+62 81234567890",
"status": "active"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'Rina Putri',
hubId: ['64d9932e2beb9037735ff022'],
roleId: '6449f8ef2c481b07d40ecfc5',
phoneNumber: '+62 81234567890',
status: 'active'
})
};
fetch('https://apiweb.mile.app/api/v3/member/{userId}', 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://apiweb.mile.app/api/v3/member/{userId}",
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([
'name' => 'Rina Putri',
'hubId' => [
'64d9932e2beb9037735ff022'
],
'roleId' => '6449f8ef2c481b07d40ecfc5',
'phoneNumber' => '+62 81234567890',
'status' => 'active'
]),
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://apiweb.mile.app/api/v3/member/{userId}"
payload := strings.NewReader("{\n \"name\": \"Rina Putri\",\n \"hubId\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"roleId\": \"6449f8ef2c481b07d40ecfc5\",\n \"phoneNumber\": \"+62 81234567890\",\n \"status\": \"active\"\n}")
req, _ := http.NewRequest("PUT", 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.put("https://apiweb.mile.app/api/v3/member/{userId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Rina Putri\",\n \"hubId\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"roleId\": \"6449f8ef2c481b07d40ecfc5\",\n \"phoneNumber\": \"+62 81234567890\",\n \"status\": \"active\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://apiweb.mile.app/api/v3/member/{userId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Rina Putri\",\n \"hubId\": [\n \"64d9932e2beb9037735ff022\"\n ],\n \"roleId\": \"6449f8ef2c481b07d40ecfc5\",\n \"phoneNumber\": \"+62 81234567890\",\n \"status\": \"active\"\n}"
response = http.request(request)
puts response.read_body{
"status": true,
"data": {
"_id": "621dd813eb3ebf16b94d6969",
"name": "Rina Putri",
"email": "[email protected]",
"phoneNumber": "+62 81234567890",
"hubId": [
"64d9932e2beb9037735ff022"
],
"teamId": [],
"roleId": "6449f8ef2c481b07d40ecfc5",
"organizationId": "64d99303be0ad015c461c932",
"language": "en",
"status": "active",
"updatedTime": "2026-10-16T03:20:00.000000Z",
"createdTime": "2025-01-10T02:00:00.000000Z"
},
"message": "Data has been updated successfully.",
"statusCode": 200,
"billingUpdated": false,
"licenseDowngraded": false
}{
"status": false,
"message": "Bad request - invalid parameters provided."
}{
"status": false,
"message": "Bad request - invalid parameters provided."
}{
"status": false,
"message": "Data not found"
}{
"status": false,
"message": "Internal server error, please contact [email protected]."
}Authorizations
Use a valid Bearer token to authenticate.
Path Parameters
The identifier of the member.
Example: 621dd813eb3ebf16b94d6969
Body
application/json
Member name.
Example: Rina Putri
Required string length:
4 - 30Hub IDs the member belongs to. At least one, no duplicates.
Example: ["64d9932e2beb9037735ff022"]
Minimum array length:
1Team IDs, no duplicates.
Example: ["650138dee2683e0e7c6b0ed2"]
Role ID from your organization.
Example: 6449f8ef2c481b07d40ecfc5
Phone number as + . Send null to clear it.
Example: +62 81234567890
Required string length:
10 - 16Member's app language.
Example: en
Available options:
en, id, jp, zh, vi, th, tl, ko Account status.
Example: active
Available options:
active, disable New password for the member. Setting it signs the member out of every session.