List ranked visibility opportunities
curl --request GET \
--url https://www.getsurfaced.ai/api/v1/autopilot/opportunities \
--header 'Authorization: Bearer <token>' \
--header 'X-Workspace-Id: <x-workspace-id>'import requests
url = "https://www.getsurfaced.ai/api/v1/autopilot/opportunities"
headers = {
"X-Workspace-Id": "<x-workspace-id>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-Workspace-Id': '<x-workspace-id>', Authorization: 'Bearer <token>'}
};
fetch('https://www.getsurfaced.ai/api/v1/autopilot/opportunities', 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://www.getsurfaced.ai/api/v1/autopilot/opportunities",
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>",
"X-Workspace-Id: <x-workspace-id>"
],
]);
$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://www.getsurfaced.ai/api/v1/autopilot/opportunities"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Workspace-Id", "<x-workspace-id>")
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://www.getsurfaced.ai/api/v1/autopilot/opportunities")
.header("X-Workspace-Id", "<x-workspace-id>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.getsurfaced.ai/api/v1/autopilot/opportunities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Workspace-Id"] = '<x-workspace-id>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"opportunities": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"projectId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"policyId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"policyVersion": 123,
"type": "missing_answer",
"subjectRef": "<string>",
"marketRef": "<string>",
"priority": {
"expectedImpact": 123,
"confidence": 123,
"urgency": 123,
"effort": 123,
"risk": 123,
"total": 123
},
"recommendedIntervention": "create_article",
"state": "proposed",
"evidenceRevisionHash": "<string>",
"cooldownUntil": "2023-11-07T05:31:56Z",
"noActionReceipt": {
"decisionId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"decidedAt": "2023-11-07T05:31:56Z",
"proposalMode": "agent",
"sourceRecommendation": "create_article",
"noActionReason": "weak_evidence",
"reasonCodes": [
"<string>"
],
"selectorCostMillicents": 1,
"alternatives": [
{
"intervention": "create_article",
"rank": 123,
"score": 123,
"evidenceEligible": true,
"policyEligible": true,
"policyDecision": "allow",
"reasonCodes": [
"<string>"
]
}
]
},
"planningAttemptCount": 1,
"planningExhaustedAt": "2023-11-07T05:31:56Z",
"planningLastError": "<string>",
"observationCount": 123,
"firstObservedAt": "2023-11-07T05:31:56Z",
"lastObservedAt": "2023-11-07T05:31:56Z",
"expiresAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
]
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}Autopilot
List ranked visibility opportunities
deprecated
Returns bounded, customer-safe opportunity evidence and deterministic priority components for one workspace project. Agent logs and mutable analyzer payloads are not exposed.
GET
/
autopilot
/
opportunities
List ranked visibility opportunities
curl --request GET \
--url https://www.getsurfaced.ai/api/v1/autopilot/opportunities \
--header 'Authorization: Bearer <token>' \
--header 'X-Workspace-Id: <x-workspace-id>'import requests
url = "https://www.getsurfaced.ai/api/v1/autopilot/opportunities"
headers = {
"X-Workspace-Id": "<x-workspace-id>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-Workspace-Id': '<x-workspace-id>', Authorization: 'Bearer <token>'}
};
fetch('https://www.getsurfaced.ai/api/v1/autopilot/opportunities', 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://www.getsurfaced.ai/api/v1/autopilot/opportunities",
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>",
"X-Workspace-Id: <x-workspace-id>"
],
]);
$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://www.getsurfaced.ai/api/v1/autopilot/opportunities"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Workspace-Id", "<x-workspace-id>")
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://www.getsurfaced.ai/api/v1/autopilot/opportunities")
.header("X-Workspace-Id", "<x-workspace-id>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.getsurfaced.ai/api/v1/autopilot/opportunities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Workspace-Id"] = '<x-workspace-id>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"opportunities": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"projectId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"policyId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"policyVersion": 123,
"type": "missing_answer",
"subjectRef": "<string>",
"marketRef": "<string>",
"priority": {
"expectedImpact": 123,
"confidence": 123,
"urgency": 123,
"effort": 123,
"risk": 123,
"total": 123
},
"recommendedIntervention": "create_article",
"state": "proposed",
"evidenceRevisionHash": "<string>",
"cooldownUntil": "2023-11-07T05:31:56Z",
"noActionReceipt": {
"decisionId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"decidedAt": "2023-11-07T05:31:56Z",
"proposalMode": "agent",
"sourceRecommendation": "create_article",
"noActionReason": "weak_evidence",
"reasonCodes": [
"<string>"
],
"selectorCostMillicents": 1,
"alternatives": [
{
"intervention": "create_article",
"rank": 123,
"score": 123,
"evidenceEligible": true,
"policyEligible": true,
"policyDecision": "allow",
"reasonCodes": [
"<string>"
]
}
]
},
"planningAttemptCount": 1,
"planningExhaustedAt": "2023-11-07T05:31:56Z",
"planningLastError": "<string>",
"observationCount": 123,
"firstObservedAt": "2023-11-07T05:31:56Z",
"lastObservedAt": "2023-11-07T05:31:56Z",
"expiresAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
]
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": {}
}
}Authorizations
API key (sk_live_...) created at https://www.getsurfaced.ai/app/settings/account/api-keys