curl --request GET \
--url https://api.opal.dev/v1/campaigns/{campaign_id}/items \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.opal.dev/v1/campaigns/{campaign_id}/items"
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/campaigns/{campaign_id}/items', 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/campaigns/{campaign_id}/items",
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/campaigns/{campaign_id}/items"
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/campaigns/{campaign_id}/items")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.opal.dev/v1/campaigns/{campaign_id}/items")
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": [
{
"campaign_item_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"campaign_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"target_type": "ROLE_ASSIGNMENT",
"role_assignment_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "PENDING",
"created_at": "2023-11-07T05:31:56Z",
"is_target_deleted": true,
"reviews": [
{
"campaign_item_review_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"campaign_item_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"reviewer_user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"assignment_source": "MANUAL",
"decision": "APPROVED",
"note": "<string>",
"updated_access_level_remote_id": "<string>",
"decided_at": "2023-11-07T05:31:56Z"
}
],
"principal_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"principal_type": "GROUP",
"entity_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"entity_type": "GROUP",
"access_level": {
"access_level_name": "AdminRole",
"access_level_remote_id": "arn:aws:iam::590304332660:role/AdministratorAccess"
},
"access_level_name": "<string>",
"admin_override": {
"actor_user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"decision": "APPROVED",
"decided_at": "2023-11-07T05:31:56Z"
}
}
],
"total_count": 123,
"next": "<string>",
"previous": "<string>"
}Returns a paginated list of review items for a campaign — the same rows
shown on the admin Reviews tab. Status is derived using the same rules
as the UI Status column. Soft-deleted role assignments are still
returned with is_target_deleted: true.
curl --request GET \
--url https://api.opal.dev/v1/campaigns/{campaign_id}/items \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.opal.dev/v1/campaigns/{campaign_id}/items"
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/campaigns/{campaign_id}/items', 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/campaigns/{campaign_id}/items",
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/campaigns/{campaign_id}/items"
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/campaigns/{campaign_id}/items")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.opal.dev/v1/campaigns/{campaign_id}/items")
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": [
{
"campaign_item_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"campaign_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"target_type": "ROLE_ASSIGNMENT",
"role_assignment_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "PENDING",
"created_at": "2023-11-07T05:31:56Z",
"is_target_deleted": true,
"reviews": [
{
"campaign_item_review_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"campaign_item_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"reviewer_user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"assignment_source": "MANUAL",
"decision": "APPROVED",
"note": "<string>",
"updated_access_level_remote_id": "<string>",
"decided_at": "2023-11-07T05:31:56Z"
}
],
"principal_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"principal_type": "GROUP",
"entity_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"entity_type": "GROUP",
"access_level": {
"access_level_name": "AdminRole",
"access_level_remote_id": "arn:aws:iam::590304332660:role/AdministratorAccess"
},
"access_level_name": "<string>",
"admin_override": {
"actor_user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"decision": "APPROVED",
"decided_at": "2023-11-07T05:31:56Z"
}
}
],
"total_count": 123,
"next": "<string>",
"previous": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The ID of the campaign.
Query Parameters
The pagination cursor value.
Number of results to return per page. Default is 200; maximum is 500 (the campaign-items list cap).
x <= 500Filter by derived item status. When multiple values are provided, items matching any status are returned (OR).
Derived aggregate status for a campaign item. Matches the admin Reviews tab Status column labels (undecided items on a stopped campaign are PENDING, not a separate stopped status).
PENDING, COMPLETED, APPROVED, REVOKED, NO_ACTION, CHANGED_ROLE, ADMIN_REVOKED Restrict to items assigned to this reviewer user ID.
When true, restrict to items with no reviewer assigned.
Case-insensitive search over principal name, asset name, and reviewer name.
Response
A page of campaign items.
A paginated list of campaign items.
Show child attributes
Show child attributes
Total number of items matching the filter (across all pages).
The cursor with which to continue pagination if additional result pages exist.
The cursor used to obtain the current result page.
Was this page helpful?