Add Institution Members
curl --request POST \
--url https://api.paxos.com/v2/identity/institution-members \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"institution_id": "2908fa8b-427a-4089-b2cf-17654c604623",
"members": [
{
"identity_id": "31abdcbd-2801-4dbc-8986-adec3828391b",
"roles": [
"GRANTOR"
]
},
{
"identity_id": "58def33e-b68f-47d3-bc2b-62b1f68f21e5",
"roles": [
"TRUSTEE"
]
}
]
}
'import requests
url = "https://api.paxos.com/v2/identity/institution-members"
payload = {
"institution_id": "2908fa8b-427a-4089-b2cf-17654c604623",
"members": [
{
"identity_id": "31abdcbd-2801-4dbc-8986-adec3828391b",
"roles": ["GRANTOR"]
},
{
"identity_id": "58def33e-b68f-47d3-bc2b-62b1f68f21e5",
"roles": ["TRUSTEE"]
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
institution_id: '2908fa8b-427a-4089-b2cf-17654c604623',
members: [
{identity_id: '31abdcbd-2801-4dbc-8986-adec3828391b', roles: ['GRANTOR']},
{identity_id: '58def33e-b68f-47d3-bc2b-62b1f68f21e5', roles: ['TRUSTEE']}
]
})
};
fetch('https://api.paxos.com/v2/identity/institution-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://api.paxos.com/v2/identity/institution-members",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'institution_id' => '2908fa8b-427a-4089-b2cf-17654c604623',
'members' => [
[
'identity_id' => '31abdcbd-2801-4dbc-8986-adec3828391b',
'roles' => [
'GRANTOR'
]
],
[
'identity_id' => '58def33e-b68f-47d3-bc2b-62b1f68f21e5',
'roles' => [
'TRUSTEE'
]
]
]
]),
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.paxos.com/v2/identity/institution-members"
payload := strings.NewReader("{\n \"institution_id\": \"2908fa8b-427a-4089-b2cf-17654c604623\",\n \"members\": [\n {\n \"identity_id\": \"31abdcbd-2801-4dbc-8986-adec3828391b\",\n \"roles\": [\n \"GRANTOR\"\n ]\n },\n {\n \"identity_id\": \"58def33e-b68f-47d3-bc2b-62b1f68f21e5\",\n \"roles\": [\n \"TRUSTEE\"\n ]\n }\n ]\n}")
req, _ := http.NewRequest("POST", 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.post("https://api.paxos.com/v2/identity/institution-members")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"institution_id\": \"2908fa8b-427a-4089-b2cf-17654c604623\",\n \"members\": [\n {\n \"identity_id\": \"31abdcbd-2801-4dbc-8986-adec3828391b\",\n \"roles\": [\n \"GRANTOR\"\n ]\n },\n {\n \"identity_id\": \"58def33e-b68f-47d3-bc2b-62b1f68f21e5\",\n \"roles\": [\n \"TRUSTEE\"\n ]\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.paxos.com/v2/identity/institution-members")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"institution_id\": \"2908fa8b-427a-4089-b2cf-17654c604623\",\n \"members\": [\n {\n \"identity_id\": \"31abdcbd-2801-4dbc-8986-adec3828391b\",\n \"roles\": [\n \"GRANTOR\"\n ]\n },\n {\n \"identity_id\": \"58def33e-b68f-47d3-bc2b-62b1f68f21e5\",\n \"roles\": [\n \"TRUSTEE\"\n ]\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"institution_id": "2908fa8b-427a-4089-b2cf-17654c604623",
"members": [
{
"identity_id": "31abdcbd-2801-4dbc-8986-adec3828391b",
"roles": [
"GRANTOR"
],
"id": "23ebbcd3-0fe6-48c8-9a2c-a35572b0e8ba"
},
{
"identity_id": "58def33e-b68f-47d3-bc2b-62b1f68f21e5",
"roles": [
"TRUSTEE"
],
"id": "a0a0d270-0dd1-40b7-85ce-de713c47bcec"
}
]
}Institution Members
Add Institution Members
Add one or more institution members to a given institution.
Adding new members doesn’t affect existing members. For example, if an institution has three members, and adds two members using this API, then the institution would end up with five total members.
For details on the properties that can be specified when creating institution members, see Specifying Institution Members and Their Roles.
POST
/
identity
/
institution-members
Add Institution Members
curl --request POST \
--url https://api.paxos.com/v2/identity/institution-members \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"institution_id": "2908fa8b-427a-4089-b2cf-17654c604623",
"members": [
{
"identity_id": "31abdcbd-2801-4dbc-8986-adec3828391b",
"roles": [
"GRANTOR"
]
},
{
"identity_id": "58def33e-b68f-47d3-bc2b-62b1f68f21e5",
"roles": [
"TRUSTEE"
]
}
]
}
'import requests
url = "https://api.paxos.com/v2/identity/institution-members"
payload = {
"institution_id": "2908fa8b-427a-4089-b2cf-17654c604623",
"members": [
{
"identity_id": "31abdcbd-2801-4dbc-8986-adec3828391b",
"roles": ["GRANTOR"]
},
{
"identity_id": "58def33e-b68f-47d3-bc2b-62b1f68f21e5",
"roles": ["TRUSTEE"]
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
institution_id: '2908fa8b-427a-4089-b2cf-17654c604623',
members: [
{identity_id: '31abdcbd-2801-4dbc-8986-adec3828391b', roles: ['GRANTOR']},
{identity_id: '58def33e-b68f-47d3-bc2b-62b1f68f21e5', roles: ['TRUSTEE']}
]
})
};
fetch('https://api.paxos.com/v2/identity/institution-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://api.paxos.com/v2/identity/institution-members",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'institution_id' => '2908fa8b-427a-4089-b2cf-17654c604623',
'members' => [
[
'identity_id' => '31abdcbd-2801-4dbc-8986-adec3828391b',
'roles' => [
'GRANTOR'
]
],
[
'identity_id' => '58def33e-b68f-47d3-bc2b-62b1f68f21e5',
'roles' => [
'TRUSTEE'
]
]
]
]),
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.paxos.com/v2/identity/institution-members"
payload := strings.NewReader("{\n \"institution_id\": \"2908fa8b-427a-4089-b2cf-17654c604623\",\n \"members\": [\n {\n \"identity_id\": \"31abdcbd-2801-4dbc-8986-adec3828391b\",\n \"roles\": [\n \"GRANTOR\"\n ]\n },\n {\n \"identity_id\": \"58def33e-b68f-47d3-bc2b-62b1f68f21e5\",\n \"roles\": [\n \"TRUSTEE\"\n ]\n }\n ]\n}")
req, _ := http.NewRequest("POST", 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.post("https://api.paxos.com/v2/identity/institution-members")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"institution_id\": \"2908fa8b-427a-4089-b2cf-17654c604623\",\n \"members\": [\n {\n \"identity_id\": \"31abdcbd-2801-4dbc-8986-adec3828391b\",\n \"roles\": [\n \"GRANTOR\"\n ]\n },\n {\n \"identity_id\": \"58def33e-b68f-47d3-bc2b-62b1f68f21e5\",\n \"roles\": [\n \"TRUSTEE\"\n ]\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.paxos.com/v2/identity/institution-members")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"institution_id\": \"2908fa8b-427a-4089-b2cf-17654c604623\",\n \"members\": [\n {\n \"identity_id\": \"31abdcbd-2801-4dbc-8986-adec3828391b\",\n \"roles\": [\n \"GRANTOR\"\n ]\n },\n {\n \"identity_id\": \"58def33e-b68f-47d3-bc2b-62b1f68f21e5\",\n \"roles\": [\n \"TRUSTEE\"\n ]\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"institution_id": "2908fa8b-427a-4089-b2cf-17654c604623",
"members": [
{
"identity_id": "31abdcbd-2801-4dbc-8986-adec3828391b",
"roles": [
"GRANTOR"
],
"id": "23ebbcd3-0fe6-48c8-9a2c-a35572b0e8ba"
},
{
"identity_id": "58def33e-b68f-47d3-bc2b-62b1f68f21e5",
"roles": [
"TRUSTEE"
],
"id": "a0a0d270-0dd1-40b7-85ce-de713c47bcec"
}
]
}OAuth Scope
identity:write_identity
Authorizations
Paxos APIs use OAuth 2 with the client credentials grant flow.
Token URLs:
- Production: https://oauth.paxos.com/oauth2/token
- Sandbox: https://oauth.sandbox.paxos.com/oauth2/token
Learn more in the API credentials guide →
Body
application/json
Was this page helpful?
⌘I