Replace members of a customer organization
curl --request PUT \
--url https://eu.sequencehq.com/api/customer-organizations/{id}/members \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"customerIds": [
"e06f36e2-0a44-404d-bdbc-b66a292609b0"
]
}
'import requests
url = "https://eu.sequencehq.com/api/customer-organizations/{id}/members"
payload = { "customerIds": ["e06f36e2-0a44-404d-bdbc-b66a292609b0"] }
headers = {
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: '<authorization>', 'Content-Type': 'application/json'},
body: JSON.stringify({customerIds: ['e06f36e2-0a44-404d-bdbc-b66a292609b0']})
};
fetch('https://eu.sequencehq.com/api/customer-organizations/{id}/members', 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://eu.sequencehq.com/api/customer-organizations/{id}/members",
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([
'customerIds' => [
'e06f36e2-0a44-404d-bdbc-b66a292609b0'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"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://eu.sequencehq.com/api/customer-organizations/{id}/members"
payload := strings.NewReader("{\n \"customerIds\": [\n \"e06f36e2-0a44-404d-bdbc-b66a292609b0\"\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "<authorization>")
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://eu.sequencehq.com/api/customer-organizations/{id}/members")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{\n \"customerIds\": [\n \"e06f36e2-0a44-404d-bdbc-b66a292609b0\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://eu.sequencehq.com/api/customer-organizations/{id}/members")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"customerIds\": [\n \"e06f36e2-0a44-404d-bdbc-b66a292609b0\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": "c0dc4e79-ec52-4811-8cf5-addb2527915c",
"owner": {
"id": "50af5191-05a3-42a5-802a-6b59091157af",
"name": "FinTech Solutions Inc."
},
"members": [
{
"id": "e06f36e2-0a44-404d-bdbc-b66a292609b0",
"name": "FinTech Wealth Management"
}
]
}This response has no body data.This response has no body data.This response has no body data.Organizations
Replace members of a customer organization
Replace all customer in an existing customer organization. This action does not impact their membership in other organizations.
PUT
/
customer-organizations
/
{id}
/
members
Replace members of a customer organization
curl --request PUT \
--url https://eu.sequencehq.com/api/customer-organizations/{id}/members \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"customerIds": [
"e06f36e2-0a44-404d-bdbc-b66a292609b0"
]
}
'import requests
url = "https://eu.sequencehq.com/api/customer-organizations/{id}/members"
payload = { "customerIds": ["e06f36e2-0a44-404d-bdbc-b66a292609b0"] }
headers = {
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: '<authorization>', 'Content-Type': 'application/json'},
body: JSON.stringify({customerIds: ['e06f36e2-0a44-404d-bdbc-b66a292609b0']})
};
fetch('https://eu.sequencehq.com/api/customer-organizations/{id}/members', 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://eu.sequencehq.com/api/customer-organizations/{id}/members",
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([
'customerIds' => [
'e06f36e2-0a44-404d-bdbc-b66a292609b0'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"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://eu.sequencehq.com/api/customer-organizations/{id}/members"
payload := strings.NewReader("{\n \"customerIds\": [\n \"e06f36e2-0a44-404d-bdbc-b66a292609b0\"\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "<authorization>")
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://eu.sequencehq.com/api/customer-organizations/{id}/members")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{\n \"customerIds\": [\n \"e06f36e2-0a44-404d-bdbc-b66a292609b0\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://eu.sequencehq.com/api/customer-organizations/{id}/members")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"customerIds\": [\n \"e06f36e2-0a44-404d-bdbc-b66a292609b0\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": "c0dc4e79-ec52-4811-8cf5-addb2527915c",
"owner": {
"id": "50af5191-05a3-42a5-802a-6b59091157af",
"name": "FinTech Solutions Inc."
},
"members": [
{
"id": "e06f36e2-0a44-404d-bdbc-b66a292609b0",
"name": "FinTech Wealth Management"
}
]
}This response has no body data.This response has no body data.This response has no body data.Headers
Your API credentials. Eg. Basic {credentials}.
Use this header to select an API version
Available options:
2024-07-30 Path Parameters
Customer organisation ID
Body
application/json
IDs of customers to add to an existing organization.
Example:
["e06f36e2-0a44-404d-bdbc-b66a292609b0"]
Response
OK
Organization ID
Example:
"c0dc4e79-ec52-4811-8cf5-addb2527915c"
ID of the customer that will own the organization.
Show child attributes
Show child attributes
Example:
{ "id": "50af5191-05a3-42a5-802a-6b59091157af", "name": "FinTech Solutions Inc." }
Members of the customer organization, excluding the owner. These are the children in a parent-child relationship.
Show child attributes
Show child attributes
Example:
[ { "id": "e06f36e2-0a44-404d-bdbc-b66a292609b0", "name": "FinTech Wealth Management" } ]
⌘I