Get users in an organisation
curl --request GET \
--url https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users \
--header 'Authorization: <api-key>'import requests
url = "https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users', 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://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"meta": {
"start": 1,
"end": 1,
"total": 1,
"page": 1,
"totalPages": 1
},
"links": {
"self": "/v1/organisations/mgk7g/users?limit=20&page=1"
},
"users": [
{
"id": "9gd5l",
"username": "docs@example.com",
"avatarUrl": "https://s.gravatar.com/avatar/0dc7361faa5dcde8ee7789f06074bb30?s=480&r=pg&d=https%3A%2F%2Fcdn.auth0.com%2Favatars%2Fdo.png",
"emailAddress": "docs@example.com",
"links": {
"self": "/v1/users/9gd5l",
"features": "/v1/users/9gd5l/features",
"progress": "/v1/users/9gd5l/progress",
"teams": "/v1/users/9gd5l/teams",
"mockApis": "/v1/users/9gd5l/apis",
"apiTemplateCatalogues": "/v1/users/9gd5l/api-template-catalogues",
"apiTemplates": "/v1/users/9gd5l/api-templates",
"dataSources": "/v1/users/9gd5l/data-sources",
"keys": "/v1/users/9gd5l/jwks",
"organisation": "/v1/organisations/mgk7g",
"aclSubject": "/v1/acl/subjects/9gd5l",
"aclObject": "/v1/acl/objects/4kg32"
}
}
]
}"Credentials are required to access this resource."{
"errors": [
{
"title": "Forbidden",
"source": {}
}
]
}{
"code": 404,
"message": "HTTP 404 Not Found"
}Organisations
Get users in an organisation
Gets the users under a specific organisation, optionally filtered by username/email address.
GET
/
v1
/
organisations
/
{organisationId}
/
users
Get users in an organisation
curl --request GET \
--url https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users \
--header 'Authorization: <api-key>'import requests
url = "https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users', 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://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://wmc.wiremockapi.cloud/v1/organisations/{organisationId}/users")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"meta": {
"start": 1,
"end": 1,
"total": 1,
"page": 1,
"totalPages": 1
},
"links": {
"self": "/v1/organisations/mgk7g/users?limit=20&page=1"
},
"users": [
{
"id": "9gd5l",
"username": "docs@example.com",
"avatarUrl": "https://s.gravatar.com/avatar/0dc7361faa5dcde8ee7789f06074bb30?s=480&r=pg&d=https%3A%2F%2Fcdn.auth0.com%2Favatars%2Fdo.png",
"emailAddress": "docs@example.com",
"links": {
"self": "/v1/users/9gd5l",
"features": "/v1/users/9gd5l/features",
"progress": "/v1/users/9gd5l/progress",
"teams": "/v1/users/9gd5l/teams",
"mockApis": "/v1/users/9gd5l/apis",
"apiTemplateCatalogues": "/v1/users/9gd5l/api-template-catalogues",
"apiTemplates": "/v1/users/9gd5l/api-templates",
"dataSources": "/v1/users/9gd5l/data-sources",
"keys": "/v1/users/9gd5l/jwks",
"organisation": "/v1/organisations/mgk7g",
"aclSubject": "/v1/acl/subjects/9gd5l",
"aclObject": "/v1/acl/objects/4kg32"
}
}
]
}"Credentials are required to access this resource."{
"errors": [
{
"title": "Forbidden",
"source": {}
}
]
}{
"code": 404,
"message": "HTTP 404 Not Found"
}Path Parameters
The ID of the organisation
Required string length:
5 - 10Example:
"jjl8y"
Query Parameters
The search query to filter by. Partially matched against username and email address.
Example:
"docs@example.com"
Required range:
x >= 1Required range:
x >= 1⌘I