Request a prior authorization from documents
curl --request POST \
--url https://api.example.com/v1/prior-authorization-requests \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"file_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"data": {
"patient_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"patient_data": {
"first_name": "<string>",
"last_name": "<string>",
"date_of_birth": "2023-12-25"
},
"payor_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"payor_data": {
"insurance_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"member_id": "<string>",
"insurance_display_name": "<string>"
},
"service": {
"specialty": "aba",
"service_type_codes": [
"mental_health_provider_outpatient"
],
"start_date": "2025-01-01",
"end_date": "2025-12-31",
"cpt_codes": [
{
"code": "97153",
"units": "160"
}
],
"requested_visits": 20,
"requested_weeks": 8,
"visits_last_90_days": 14,
"locations": [
"office",
"home"
]
},
"requesting_provider_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"servicing_provider_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"servicing_location_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"notes": "<string>",
"external_id": "<string>",
"scheduled_submission_date": "2023-12-25",
"copy_files_from_prior_authorization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}
'import requests
url = "https://api.example.com/v1/prior-authorization-requests"
payload = {
"file_ids": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"data": {
"patient_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"patient_data": {
"first_name": "<string>",
"last_name": "<string>",
"date_of_birth": "2023-12-25"
},
"payor_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"payor_data": {
"insurance_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"member_id": "<string>",
"insurance_display_name": "<string>"
},
"service": {
"specialty": "aba",
"service_type_codes": ["mental_health_provider_outpatient"],
"start_date": "2025-01-01",
"end_date": "2025-12-31",
"cpt_codes": [
{
"code": "97153",
"units": "160"
}
],
"requested_visits": 20,
"requested_weeks": 8,
"visits_last_90_days": 14,
"locations": ["office", "home"]
},
"requesting_provider_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"servicing_provider_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"servicing_location_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"notes": "<string>",
"external_id": "<string>",
"scheduled_submission_date": "2023-12-25",
"copy_files_from_prior_authorization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
file_ids: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
data: {
patient_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
patient_data: {first_name: '<string>', last_name: '<string>', date_of_birth: '2023-12-25'},
payor_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
payor_data: {
insurance_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
member_id: '<string>',
insurance_display_name: '<string>'
},
service: {
specialty: 'aba',
service_type_codes: ['mental_health_provider_outpatient'],
start_date: '2025-01-01',
end_date: '2025-12-31',
cpt_codes: [{code: '97153', units: '160'}],
requested_visits: 20,
requested_weeks: 8,
visits_last_90_days: 14,
locations: ['office', 'home']
},
requesting_provider_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
servicing_provider_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
servicing_location_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
organization_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
notes: '<string>',
external_id: '<string>',
scheduled_submission_date: '2023-12-25',
copy_files_from_prior_authorization_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a'
}
})
};
fetch('https://api.example.com/v1/prior-authorization-requests', 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.example.com/v1/prior-authorization-requests",
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([
'file_ids' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'data' => [
'patient_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'patient_data' => [
'first_name' => '<string>',
'last_name' => '<string>',
'date_of_birth' => '2023-12-25'
],
'payor_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'payor_data' => [
'insurance_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'member_id' => '<string>',
'insurance_display_name' => '<string>'
],
'service' => [
'specialty' => 'aba',
'service_type_codes' => [
'mental_health_provider_outpatient'
],
'start_date' => '2025-01-01',
'end_date' => '2025-12-31',
'cpt_codes' => [
[
'code' => '97153',
'units' => '160'
]
],
'requested_visits' => 20,
'requested_weeks' => 8,
'visits_last_90_days' => 14,
'locations' => [
'office',
'home'
]
],
'requesting_provider_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'servicing_provider_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'servicing_location_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'organization_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'notes' => '<string>',
'external_id' => '<string>',
'scheduled_submission_date' => '2023-12-25',
'copy_files_from_prior_authorization_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/prior-authorization-requests"
payload := strings.NewReader("{\n \"file_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"data\": {\n \"patient_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"patient_data\": {\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\"\n },\n \"payor_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"payor_data\": {\n \"insurance_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"member_id\": \"<string>\",\n \"insurance_display_name\": \"<string>\"\n },\n \"service\": {\n \"specialty\": \"aba\",\n \"service_type_codes\": [\n \"mental_health_provider_outpatient\"\n ],\n \"start_date\": \"2025-01-01\",\n \"end_date\": \"2025-12-31\",\n \"cpt_codes\": [\n {\n \"code\": \"97153\",\n \"units\": \"160\"\n }\n ],\n \"requested_visits\": 20,\n \"requested_weeks\": 8,\n \"visits_last_90_days\": 14,\n \"locations\": [\n \"office\",\n \"home\"\n ]\n },\n \"requesting_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_location_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"notes\": \"<string>\",\n \"external_id\": \"<string>\",\n \"scheduled_submission_date\": \"2023-12-25\",\n \"copy_files_from_prior_authorization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
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.example.com/v1/prior-authorization-requests")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"file_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"data\": {\n \"patient_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"patient_data\": {\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\"\n },\n \"payor_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"payor_data\": {\n \"insurance_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"member_id\": \"<string>\",\n \"insurance_display_name\": \"<string>\"\n },\n \"service\": {\n \"specialty\": \"aba\",\n \"service_type_codes\": [\n \"mental_health_provider_outpatient\"\n ],\n \"start_date\": \"2025-01-01\",\n \"end_date\": \"2025-12-31\",\n \"cpt_codes\": [\n {\n \"code\": \"97153\",\n \"units\": \"160\"\n }\n ],\n \"requested_visits\": 20,\n \"requested_weeks\": 8,\n \"visits_last_90_days\": 14,\n \"locations\": [\n \"office\",\n \"home\"\n ]\n },\n \"requesting_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_location_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"notes\": \"<string>\",\n \"external_id\": \"<string>\",\n \"scheduled_submission_date\": \"2023-12-25\",\n \"copy_files_from_prior_authorization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/prior-authorization-requests")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"file_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"data\": {\n \"patient_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"patient_data\": {\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\"\n },\n \"payor_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"payor_data\": {\n \"insurance_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"member_id\": \"<string>\",\n \"insurance_display_name\": \"<string>\"\n },\n \"service\": {\n \"specialty\": \"aba\",\n \"service_type_codes\": [\n \"mental_health_provider_outpatient\"\n ],\n \"start_date\": \"2025-01-01\",\n \"end_date\": \"2025-12-31\",\n \"cpt_codes\": [\n {\n \"code\": \"97153\",\n \"units\": \"160\"\n }\n ],\n \"requested_visits\": 20,\n \"requested_weeks\": 8,\n \"visits_last_90_days\": 14,\n \"locations\": [\n \"office\",\n \"home\"\n ]\n },\n \"requesting_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_location_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"notes\": \"<string>\",\n \"external_id\": \"<string>\",\n \"scheduled_submission_date\": \"2023-12-25\",\n \"copy_files_from_prior_authorization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n }\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "queued",
"prior_authorization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"fields": [
{
"path": "<string>",
"code": "<string>",
"message": "<string>"
}
]
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z"
}{
"type": "<string>",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"meta": {}
}{
"type": "<string>",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"meta": {}
}{
"type": "validation_error",
"code": "invalid_parameter",
"message": "Field validation failed",
"param": "phone_number"
}Prior Authorization Requests
Request a prior authorization from documents
Extract uploaded files, apply explicit data, and create a prior authorization asynchronously. Poll the Location URL until completed or failed.
POST
/
v1
/
prior-authorization-requests
Request a prior authorization from documents
curl --request POST \
--url https://api.example.com/v1/prior-authorization-requests \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"file_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"data": {
"patient_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"patient_data": {
"first_name": "<string>",
"last_name": "<string>",
"date_of_birth": "2023-12-25"
},
"payor_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"payor_data": {
"insurance_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"member_id": "<string>",
"insurance_display_name": "<string>"
},
"service": {
"specialty": "aba",
"service_type_codes": [
"mental_health_provider_outpatient"
],
"start_date": "2025-01-01",
"end_date": "2025-12-31",
"cpt_codes": [
{
"code": "97153",
"units": "160"
}
],
"requested_visits": 20,
"requested_weeks": 8,
"visits_last_90_days": 14,
"locations": [
"office",
"home"
]
},
"requesting_provider_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"servicing_provider_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"servicing_location_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"notes": "<string>",
"external_id": "<string>",
"scheduled_submission_date": "2023-12-25",
"copy_files_from_prior_authorization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}
'import requests
url = "https://api.example.com/v1/prior-authorization-requests"
payload = {
"file_ids": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"data": {
"patient_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"patient_data": {
"first_name": "<string>",
"last_name": "<string>",
"date_of_birth": "2023-12-25"
},
"payor_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"payor_data": {
"insurance_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"member_id": "<string>",
"insurance_display_name": "<string>"
},
"service": {
"specialty": "aba",
"service_type_codes": ["mental_health_provider_outpatient"],
"start_date": "2025-01-01",
"end_date": "2025-12-31",
"cpt_codes": [
{
"code": "97153",
"units": "160"
}
],
"requested_visits": 20,
"requested_weeks": 8,
"visits_last_90_days": 14,
"locations": ["office", "home"]
},
"requesting_provider_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"servicing_provider_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"servicing_location_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"notes": "<string>",
"external_id": "<string>",
"scheduled_submission_date": "2023-12-25",
"copy_files_from_prior_authorization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
file_ids: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
data: {
patient_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
patient_data: {first_name: '<string>', last_name: '<string>', date_of_birth: '2023-12-25'},
payor_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
payor_data: {
insurance_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
member_id: '<string>',
insurance_display_name: '<string>'
},
service: {
specialty: 'aba',
service_type_codes: ['mental_health_provider_outpatient'],
start_date: '2025-01-01',
end_date: '2025-12-31',
cpt_codes: [{code: '97153', units: '160'}],
requested_visits: 20,
requested_weeks: 8,
visits_last_90_days: 14,
locations: ['office', 'home']
},
requesting_provider_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
servicing_provider_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
servicing_location_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
organization_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
notes: '<string>',
external_id: '<string>',
scheduled_submission_date: '2023-12-25',
copy_files_from_prior_authorization_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a'
}
})
};
fetch('https://api.example.com/v1/prior-authorization-requests', 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.example.com/v1/prior-authorization-requests",
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([
'file_ids' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'data' => [
'patient_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'patient_data' => [
'first_name' => '<string>',
'last_name' => '<string>',
'date_of_birth' => '2023-12-25'
],
'payor_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'payor_data' => [
'insurance_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'member_id' => '<string>',
'insurance_display_name' => '<string>'
],
'service' => [
'specialty' => 'aba',
'service_type_codes' => [
'mental_health_provider_outpatient'
],
'start_date' => '2025-01-01',
'end_date' => '2025-12-31',
'cpt_codes' => [
[
'code' => '97153',
'units' => '160'
]
],
'requested_visits' => 20,
'requested_weeks' => 8,
'visits_last_90_days' => 14,
'locations' => [
'office',
'home'
]
],
'requesting_provider_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'servicing_provider_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'servicing_location_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'organization_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'notes' => '<string>',
'external_id' => '<string>',
'scheduled_submission_date' => '2023-12-25',
'copy_files_from_prior_authorization_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/prior-authorization-requests"
payload := strings.NewReader("{\n \"file_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"data\": {\n \"patient_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"patient_data\": {\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\"\n },\n \"payor_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"payor_data\": {\n \"insurance_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"member_id\": \"<string>\",\n \"insurance_display_name\": \"<string>\"\n },\n \"service\": {\n \"specialty\": \"aba\",\n \"service_type_codes\": [\n \"mental_health_provider_outpatient\"\n ],\n \"start_date\": \"2025-01-01\",\n \"end_date\": \"2025-12-31\",\n \"cpt_codes\": [\n {\n \"code\": \"97153\",\n \"units\": \"160\"\n }\n ],\n \"requested_visits\": 20,\n \"requested_weeks\": 8,\n \"visits_last_90_days\": 14,\n \"locations\": [\n \"office\",\n \"home\"\n ]\n },\n \"requesting_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_location_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"notes\": \"<string>\",\n \"external_id\": \"<string>\",\n \"scheduled_submission_date\": \"2023-12-25\",\n \"copy_files_from_prior_authorization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
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.example.com/v1/prior-authorization-requests")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"file_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"data\": {\n \"patient_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"patient_data\": {\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\"\n },\n \"payor_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"payor_data\": {\n \"insurance_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"member_id\": \"<string>\",\n \"insurance_display_name\": \"<string>\"\n },\n \"service\": {\n \"specialty\": \"aba\",\n \"service_type_codes\": [\n \"mental_health_provider_outpatient\"\n ],\n \"start_date\": \"2025-01-01\",\n \"end_date\": \"2025-12-31\",\n \"cpt_codes\": [\n {\n \"code\": \"97153\",\n \"units\": \"160\"\n }\n ],\n \"requested_visits\": 20,\n \"requested_weeks\": 8,\n \"visits_last_90_days\": 14,\n \"locations\": [\n \"office\",\n \"home\"\n ]\n },\n \"requesting_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_location_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"notes\": \"<string>\",\n \"external_id\": \"<string>\",\n \"scheduled_submission_date\": \"2023-12-25\",\n \"copy_files_from_prior_authorization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/prior-authorization-requests")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"file_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"data\": {\n \"patient_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"patient_data\": {\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"2023-12-25\"\n },\n \"payor_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"payor_data\": {\n \"insurance_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"member_id\": \"<string>\",\n \"insurance_display_name\": \"<string>\"\n },\n \"service\": {\n \"specialty\": \"aba\",\n \"service_type_codes\": [\n \"mental_health_provider_outpatient\"\n ],\n \"start_date\": \"2025-01-01\",\n \"end_date\": \"2025-12-31\",\n \"cpt_codes\": [\n {\n \"code\": \"97153\",\n \"units\": \"160\"\n }\n ],\n \"requested_visits\": 20,\n \"requested_weeks\": 8,\n \"visits_last_90_days\": 14,\n \"locations\": [\n \"office\",\n \"home\"\n ]\n },\n \"requesting_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_provider_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"servicing_location_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"notes\": \"<string>\",\n \"external_id\": \"<string>\",\n \"scheduled_submission_date\": \"2023-12-25\",\n \"copy_files_from_prior_authorization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n }\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "queued",
"prior_authorization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"fields": [
{
"path": "<string>",
"code": "<string>",
"message": "<string>"
}
]
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z"
}{
"type": "<string>",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"meta": {}
}{
"type": "<string>",
"code": "<string>",
"message": "<string>",
"param": "<string>",
"meta": {}
}{
"type": "validation_error",
"code": "invalid_parameter",
"message": "Field validation failed",
"param": "phone_number"
}Authorizations
APIKeyHeaderHTTPBearer
Headers
Optional durable submission key. Reuse with identical input to retrieve the same request; use a new key for corrected input.
Body
application/json
Response
Successful Response
Available options:
queued, processing, completed, failed Show child attributes
Show child attributes

