cURL
curl --request GET \
--url https://api.opal.dev/v1/resources/{resource_id}/non-human-identities \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.opal.dev/v1/resources/{resource_id}/non-human-identities"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.opal.dev/v1/resources/{resource_id}/non-human-identities', 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.opal.dev/v1/resources/{resource_id}/non-human-identities",
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: Bearer <token>"
],
]);
$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://api.opal.dev/v1/resources/{resource_id}/non-human-identities"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.opal.dev/v1/resources/{resource_id}/non-human-identities")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.opal.dev/v1/resources/{resource_id}/non-human-identities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"results": [
{
"principal_id": "74908af0-9383-4feb-b7ea-8b305d737338",
"principal_type": "RESOURCE",
"entity_id": "db04925a-635d-4764-870e-500b9b035c8e",
"entity_type": "RESOURCE",
"expiration_date": "2022-01-23T04:56:07.000Z",
"has_direct_access": true,
"num_access_paths": 3
},
{
"principal_id": "d940df34-726a-4403-864e-16cb2a0d6793",
"principal_type": "RESOURCE",
"entity_id": "c26cd16c-a3fa-4b82-96b1-32177f8b8f59",
"entity_type": "RESOURCE",
"expiration_date": "2022-01-23T04:56:07.000Z",
"has_direct_access": true,
"num_access_paths": 3
}
]
}Gets the list of non-human identities with access to this resource.
GET
/
resources
/
{resource_id}
/
non-human-identities
cURL
curl --request GET \
--url https://api.opal.dev/v1/resources/{resource_id}/non-human-identities \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.opal.dev/v1/resources/{resource_id}/non-human-identities"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.opal.dev/v1/resources/{resource_id}/non-human-identities', 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.opal.dev/v1/resources/{resource_id}/non-human-identities",
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: Bearer <token>"
],
]);
$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://api.opal.dev/v1/resources/{resource_id}/non-human-identities"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.opal.dev/v1/resources/{resource_id}/non-human-identities")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.opal.dev/v1/resources/{resource_id}/non-human-identities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"results": [
{
"principal_id": "74908af0-9383-4feb-b7ea-8b305d737338",
"principal_type": "RESOURCE",
"entity_id": "db04925a-635d-4764-870e-500b9b035c8e",
"entity_type": "RESOURCE",
"expiration_date": "2022-01-23T04:56:07.000Z",
"has_direct_access": true,
"num_access_paths": 3
},
{
"principal_id": "d940df34-726a-4403-864e-16cb2a0d6793",
"principal_type": "RESOURCE",
"entity_id": "c26cd16c-a3fa-4b82-96b1-32177f8b8f59",
"entity_type": "RESOURCE",
"expiration_date": "2022-01-23T04:56:07.000Z",
"has_direct_access": true,
"num_access_paths": 3
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The ID of the resource.
Query Parameters
Limit the number of results returned.
Response
200 - application/json
List of non-human identities with access to this resource.
Show child attributes
Show child attributes
Last modified on July 23, 2026
Was this page helpful?
⌘I