curl --request POST \
--url https://api.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"paths": [
"<string>"
],
"facts": [
{
"fact": "<string>",
"row": "<string>",
"field": "<string>"
}
]
}
'import requests
url = "https://api.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen"
payload = {
"paths": ["<string>"],
"facts": [
{
"fact": "<string>",
"row": "<string>",
"field": "<string>"
}
]
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
paths: ['<string>'],
facts: [{fact: '<string>', row: '<string>', field: '<string>'}]
})
};
fetch('https://api.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen', 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.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen",
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([
'paths' => [
'<string>'
],
'facts' => [
[
'fact' => '<string>',
'row' => '<string>',
'field' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Idempotency-Key: <idempotency-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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen"
payload := strings.NewReader("{\n \"paths\": [\n \"<string>\"\n ],\n \"facts\": [\n {\n \"fact\": \"<string>\",\n \"row\": \"<string>\",\n \"field\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Idempotency-Key", "<idempotency-key>")
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.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen")
.header("Idempotency-Key", "<idempotency-key>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"paths\": [\n \"<string>\"\n ],\n \"facts\": [\n {\n \"fact\": \"<string>\",\n \"row\": \"<string>\",\n \"field\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Idempotency-Key"] = '<idempotency-key>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"paths\": [\n \"<string>\"\n ],\n \"facts\": [\n {\n \"fact\": \"<string>\",\n \"row\": \"<string>\",\n \"field\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"reopened": [
"<string>"
],
"skipped": [
{
"path": "<string>",
"reason": "<string>"
}
],
"facts": {
"reopened": [
{
"fact": "<string>",
"row": "<string>",
"field": "<string>"
}
],
"skipped": [
{
"fact": "<string>",
"reason": "<string>",
"row": "<string>",
"field": "<string>"
}
]
},
"outstanding": [
{
"key": "<string>",
"label": "<string>",
"kind": "conflict",
"awaiting": "broker",
"severity": "blocking",
"neededFor": "<string>",
"note": "<string>"
}
]
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"code": "<string>",
"error": "<string>",
"extractionId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"requestId": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}Reopen proposals of an underwriting submission’s extraction
Takes back the ruling on each proposal named in paths and each fact’s value named in facts as {fact, row?, field?} (at most 500 together; a row without field names each of its fields), so it is offered again: the undo of an accept, a conflict choice or a dismiss.
Reopening a path where the submission holds a value the extraction proposed retracts that value, and takes back every overridden ruling at the path: the path holds no value, and the values read there are offered again. A value the accepted one replaced is not put back; it is in the log’s history. Reopening a dismissed or overridden proposal takes that ruling back and leaves a value the extraction did not propose as it is. A ruling stays on record as taken back, with who did it and when.
Answers reopened, skipped (each path left as it was and why: no_ruling), facts (the same for the facts’ values) and outstanding. 422 unknown_proposal for a path or fact the extraction read nothing for, which refuses the whole request.
A value removed is retracted from the submission’s log. The values live in the submission’s log on its program (/v2/rsl/{id}/logs/{log}, the log’s id is the submission’s), opened on the release the desk names the first time one is written. Each is written as the caller, in the program role they hold (or the one that acts for every other they hold): 403 no_program_role for a caller who holds none. What the log refuses is 422 log_refused, its words naming the log’s code (a value a higher role gave is NOT_AUTHORIZED), and changes nothing; a value another writer changed since the read, or a ruling another request made meanwhile, is 409 conflict. A value citing a document whose bytes changed since the extraction read it is 409 document_changed: run the extraction again. The log write is made under the request’s key, so the key sent with another request is 409 idempotency_conflict and writes nothing.
Idempotency-Key is required. The same key and request answer what the first one did for 24 hours, with outstanding as it stands now; the same key with a different request is 409 idempotency_conflict. A request refused before it writes the submission’s log changes and binds nothing. A ruling made at its paths after it read them refuses it with 409 conflict after its log write: the value the log took stays, and a retry finds it held.
Whoever rules writes to the submission’s log as one of the program’s roles: the caller needs a role of the program, or is a workspace admin. Needs edit access to the submission (403 for a reader, 404 when it cannot be read). An extraction with no result is 409 extraction_not_finished. Only where the workspace has underwriting turned on (403 feature_not_enabled).
Alpha: this operation may change or be removed without notice.
curl --request POST \
--url https://api.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"paths": [
"<string>"
],
"facts": [
{
"fact": "<string>",
"row": "<string>",
"field": "<string>"
}
]
}
'import requests
url = "https://api.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen"
payload = {
"paths": ["<string>"],
"facts": [
{
"fact": "<string>",
"row": "<string>",
"field": "<string>"
}
]
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
paths: ['<string>'],
facts: [{fact: '<string>', row: '<string>', field: '<string>'}]
})
};
fetch('https://api.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen', 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.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen",
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([
'paths' => [
'<string>'
],
'facts' => [
[
'fact' => '<string>',
'row' => '<string>',
'field' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Idempotency-Key: <idempotency-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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen"
payload := strings.NewReader("{\n \"paths\": [\n \"<string>\"\n ],\n \"facts\": [\n {\n \"fact\": \"<string>\",\n \"row\": \"<string>\",\n \"field\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Idempotency-Key", "<idempotency-key>")
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.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen")
.header("Idempotency-Key", "<idempotency-key>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"paths\": [\n \"<string>\"\n ],\n \"facts\": [\n {\n \"fact\": \"<string>\",\n \"row\": \"<string>\",\n \"field\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.canary.effectiveai.app/api/v2/insurance/underwriting/submissions/{submissionId}/extractions/{extractionId}/reopen")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Idempotency-Key"] = '<idempotency-key>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"paths\": [\n \"<string>\"\n ],\n \"facts\": [\n {\n \"fact\": \"<string>\",\n \"row\": \"<string>\",\n \"field\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"reopened": [
"<string>"
],
"skipped": [
{
"path": "<string>",
"reason": "<string>"
}
],
"facts": {
"reopened": [
{
"fact": "<string>",
"row": "<string>",
"field": "<string>"
}
],
"skipped": [
{
"fact": "<string>",
"reason": "<string>",
"row": "<string>",
"field": "<string>"
}
]
},
"outstanding": [
{
"key": "<string>",
"label": "<string>",
"kind": "conflict",
"awaiting": "broker",
"severity": "blocking",
"neededFor": "<string>",
"note": "<string>"
}
]
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"code": "<string>",
"error": "<string>",
"extractionId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"requestId": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}{
"error": "<string>",
"code": "<string>",
"details": [
{
"location": "path",
"path": [
"<string>"
],
"code": "required",
"message": "<string>"
}
],
"requestId": "<string>",
"dataset": "naic",
"businessCode": "<string>",
"violations": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>",
"value": "<unknown>",
"constraint": "<string>",
"cite": "<string>"
}
],
"violationsTruncated": true,
"executionId": "<string>",
"accessUrl": "<string>"
}Authorizations
Headers
Path Parameters
Body
Response
What was reopened and skipped, and what the submission still waits on.