request quote
curl --request POST \
--url https://api.example.com/quotes \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"pack_id": "<string>",
"pack_version": "<string>",
"answers": {},
"consent": {
"share_for_pricing_research": true,
"anonymize": true,
"captured_at": "2023-11-07T05:31:56Z"
},
"attribution": {
"referrer_id": "<string>",
"token": "<string>",
"campaign": "<string>",
"source": "<string>"
},
"quantity": 4503599627370496
}
'import requests
url = "https://api.example.com/quotes"
payload = {
"pack_id": "<string>",
"pack_version": "<string>",
"answers": {},
"consent": {
"share_for_pricing_research": True,
"anonymize": True,
"captured_at": "2023-11-07T05:31:56Z"
},
"attribution": {
"referrer_id": "<string>",
"token": "<string>",
"campaign": "<string>",
"source": "<string>"
},
"quantity": 4503599627370496
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Idempotency-Key': '<idempotency-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
pack_id: '<string>',
pack_version: '<string>',
answers: {},
consent: {
share_for_pricing_research: true,
anonymize: true,
captured_at: '2023-11-07T05:31:56Z'
},
attribution: {
referrer_id: '<string>',
token: '<string>',
campaign: '<string>',
source: '<string>'
},
quantity: 4503599627370496
})
};
fetch('https://api.example.com/quotes', 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/quotes",
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([
'pack_id' => '<string>',
'pack_version' => '<string>',
'answers' => [
],
'consent' => [
'share_for_pricing_research' => true,
'anonymize' => true,
'captured_at' => '2023-11-07T05:31:56Z'
],
'attribution' => [
'referrer_id' => '<string>',
'token' => '<string>',
'campaign' => '<string>',
'source' => '<string>'
],
'quantity' => 4503599627370496
]),
CURLOPT_HTTPHEADER => [
"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.example.com/quotes"
payload := strings.NewReader("{\n \"pack_id\": \"<string>\",\n \"pack_version\": \"<string>\",\n \"answers\": {},\n \"consent\": {\n \"share_for_pricing_research\": true,\n \"anonymize\": true,\n \"captured_at\": \"2023-11-07T05:31:56Z\"\n },\n \"attribution\": {\n \"referrer_id\": \"<string>\",\n \"token\": \"<string>\",\n \"campaign\": \"<string>\",\n \"source\": \"<string>\"\n },\n \"quantity\": 4503599627370496\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Idempotency-Key", "<idempotency-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/quotes")
.header("Idempotency-Key", "<idempotency-key>")
.header("Content-Type", "application/json")
.body("{\n \"pack_id\": \"<string>\",\n \"pack_version\": \"<string>\",\n \"answers\": {},\n \"consent\": {\n \"share_for_pricing_research\": true,\n \"anonymize\": true,\n \"captured_at\": \"2023-11-07T05:31:56Z\"\n },\n \"attribution\": {\n \"referrer_id\": \"<string>\",\n \"token\": \"<string>\",\n \"campaign\": \"<string>\",\n \"source\": \"<string>\"\n },\n \"quantity\": 4503599627370496\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/quotes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Idempotency-Key"] = '<idempotency-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"pack_id\": \"<string>\",\n \"pack_version\": \"<string>\",\n \"answers\": {},\n \"consent\": {\n \"share_for_pricing_research\": true,\n \"anonymize\": true,\n \"captured_at\": \"2023-11-07T05:31:56Z\"\n },\n \"attribution\": {\n \"referrer_id\": \"<string>\",\n \"token\": \"<string>\",\n \"campaign\": \"<string>\",\n \"source\": \"<string>\"\n },\n \"quantity\": 4503599627370496\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"state": "INITIATED",
"estimate": {
"pack_id": "<string>",
"pack_version": "<string>",
"answers": {},
"artist_review_mode": "pre_price",
"price_range": {
"min": 1,
"max": 1,
"currency": "<string>",
"basis": "hourly",
"method": "artist_stated",
"provenance": {
"who": "<string>",
"when": "2023-11-07T05:31:56Z"
},
"n": 6,
"min_minor": 4503599627370495,
"max_minor": 4503599627370495
},
"sessions": {
"count": 1,
"hours_per_session": 1
},
"deposit": {
"amount": 1,
"basis": "<string>",
"policies": [
"<string>"
],
"status": "unpaid",
"merchant_of_record": "provider",
"provenance": {
"who": "<string>",
"when": "2023-11-07T05:31:56Z"
},
"confirmation": {
"source": "payment_processor",
"reference": "<string>",
"confirmed_at": "2023-11-07T05:31:56Z"
},
"amount_minor": 4503599627370495,
"capture_on": "accept",
"refundable_until": "2023-11-07T05:31:56Z",
"policy_url": "<string>"
},
"assumptions": [
"<string>"
],
"intermediates": [
{
"step": "<string>",
"factor_id": "<string>",
"input": "<unknown>",
"value": "<unknown>",
"skipped": true,
"reason": "<string>"
}
],
"review_status": "VALIDATED_PENDING_REVIEW",
"consent": {
"share_for_pricing_research": true,
"anonymize": true,
"captured_at": "2023-11-07T05:31:56Z"
},
"anonymized": true,
"kind": "estimate",
"binding": false,
"confidence": "low",
"requires_in_person_consult": true
},
"quote": {
"pack_id": "<string>",
"pack_version": "<string>",
"answers": {},
"artist_review_mode": "pre_price",
"price_range": {
"min": 1,
"max": 1,
"currency": "<string>",
"basis": "hourly",
"method": "artist_stated",
"provenance": {
"who": "<string>",
"when": "2023-11-07T05:31:56Z"
},
"n": 6,
"min_minor": 4503599627370495,
"max_minor": 4503599627370495
},
"sessions": {
"count": 1,
"hours_per_session": 1
},
"deposit": {
"amount": 1,
"basis": "<string>",
"policies": [
"<string>"
],
"status": "unpaid",
"merchant_of_record": "provider",
"provenance": {
"who": "<string>",
"when": "2023-11-07T05:31:56Z"
},
"confirmation": {
"source": "payment_processor",
"reference": "<string>",
"confirmed_at": "2023-11-07T05:31:56Z"
},
"amount_minor": 4503599627370495,
"capture_on": "accept",
"refundable_until": "2023-11-07T05:31:56Z",
"policy_url": "<string>"
},
"assumptions": [
"<string>"
],
"intermediates": [
{
"step": "<string>",
"factor_id": "<string>",
"input": "<unknown>",
"value": "<unknown>",
"skipped": true,
"reason": "<string>"
}
],
"review_status": "QUOTED",
"consent": {
"share_for_pricing_research": true,
"anonymize": true,
"captured_at": "2023-11-07T05:31:56Z"
},
"anonymized": true,
"valid_until": "2023-11-07T05:31:56Z",
"kind": "quote",
"binding": true,
"confidence": "low",
"client_approval": {
"amount": 1,
"currency": "<string>",
"policies": [
"<string>"
],
"approved_amount": true,
"approved_policies": true,
"approved_at": "2023-11-07T05:31:56Z",
"amount_minor": 4503599627370495
},
"attribution": {
"referrer_id": "<string>",
"token": "<string>",
"campaign": "<string>",
"source": "<string>"
},
"quantity": 4503599627370496,
"quantity_unit": {
"unit": "C62",
"display_text": "<string>",
"scale": 0
},
"checkout_handoff": {
"protocol": "ucp",
"url": "<string>",
"ucp_quote_status": "pending",
"acp_quote_id": "<string>",
"quote_expires_at": "2023-11-07T05:31:56Z"
},
"id": "<string>",
"expires_at": "2023-11-07T05:31:56Z"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"current_state": "INITIATED"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"current_state": "INITIATED"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"current_state": "INITIATED"
}
}API Reference
request quote
POST
/
quotes
request quote
curl --request POST \
--url https://api.example.com/quotes \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"pack_id": "<string>",
"pack_version": "<string>",
"answers": {},
"consent": {
"share_for_pricing_research": true,
"anonymize": true,
"captured_at": "2023-11-07T05:31:56Z"
},
"attribution": {
"referrer_id": "<string>",
"token": "<string>",
"campaign": "<string>",
"source": "<string>"
},
"quantity": 4503599627370496
}
'import requests
url = "https://api.example.com/quotes"
payload = {
"pack_id": "<string>",
"pack_version": "<string>",
"answers": {},
"consent": {
"share_for_pricing_research": True,
"anonymize": True,
"captured_at": "2023-11-07T05:31:56Z"
},
"attribution": {
"referrer_id": "<string>",
"token": "<string>",
"campaign": "<string>",
"source": "<string>"
},
"quantity": 4503599627370496
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Idempotency-Key': '<idempotency-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
pack_id: '<string>',
pack_version: '<string>',
answers: {},
consent: {
share_for_pricing_research: true,
anonymize: true,
captured_at: '2023-11-07T05:31:56Z'
},
attribution: {
referrer_id: '<string>',
token: '<string>',
campaign: '<string>',
source: '<string>'
},
quantity: 4503599627370496
})
};
fetch('https://api.example.com/quotes', 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/quotes",
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([
'pack_id' => '<string>',
'pack_version' => '<string>',
'answers' => [
],
'consent' => [
'share_for_pricing_research' => true,
'anonymize' => true,
'captured_at' => '2023-11-07T05:31:56Z'
],
'attribution' => [
'referrer_id' => '<string>',
'token' => '<string>',
'campaign' => '<string>',
'source' => '<string>'
],
'quantity' => 4503599627370496
]),
CURLOPT_HTTPHEADER => [
"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.example.com/quotes"
payload := strings.NewReader("{\n \"pack_id\": \"<string>\",\n \"pack_version\": \"<string>\",\n \"answers\": {},\n \"consent\": {\n \"share_for_pricing_research\": true,\n \"anonymize\": true,\n \"captured_at\": \"2023-11-07T05:31:56Z\"\n },\n \"attribution\": {\n \"referrer_id\": \"<string>\",\n \"token\": \"<string>\",\n \"campaign\": \"<string>\",\n \"source\": \"<string>\"\n },\n \"quantity\": 4503599627370496\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Idempotency-Key", "<idempotency-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/quotes")
.header("Idempotency-Key", "<idempotency-key>")
.header("Content-Type", "application/json")
.body("{\n \"pack_id\": \"<string>\",\n \"pack_version\": \"<string>\",\n \"answers\": {},\n \"consent\": {\n \"share_for_pricing_research\": true,\n \"anonymize\": true,\n \"captured_at\": \"2023-11-07T05:31:56Z\"\n },\n \"attribution\": {\n \"referrer_id\": \"<string>\",\n \"token\": \"<string>\",\n \"campaign\": \"<string>\",\n \"source\": \"<string>\"\n },\n \"quantity\": 4503599627370496\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/quotes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Idempotency-Key"] = '<idempotency-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"pack_id\": \"<string>\",\n \"pack_version\": \"<string>\",\n \"answers\": {},\n \"consent\": {\n \"share_for_pricing_research\": true,\n \"anonymize\": true,\n \"captured_at\": \"2023-11-07T05:31:56Z\"\n },\n \"attribution\": {\n \"referrer_id\": \"<string>\",\n \"token\": \"<string>\",\n \"campaign\": \"<string>\",\n \"source\": \"<string>\"\n },\n \"quantity\": 4503599627370496\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"state": "INITIATED",
"estimate": {
"pack_id": "<string>",
"pack_version": "<string>",
"answers": {},
"artist_review_mode": "pre_price",
"price_range": {
"min": 1,
"max": 1,
"currency": "<string>",
"basis": "hourly",
"method": "artist_stated",
"provenance": {
"who": "<string>",
"when": "2023-11-07T05:31:56Z"
},
"n": 6,
"min_minor": 4503599627370495,
"max_minor": 4503599627370495
},
"sessions": {
"count": 1,
"hours_per_session": 1
},
"deposit": {
"amount": 1,
"basis": "<string>",
"policies": [
"<string>"
],
"status": "unpaid",
"merchant_of_record": "provider",
"provenance": {
"who": "<string>",
"when": "2023-11-07T05:31:56Z"
},
"confirmation": {
"source": "payment_processor",
"reference": "<string>",
"confirmed_at": "2023-11-07T05:31:56Z"
},
"amount_minor": 4503599627370495,
"capture_on": "accept",
"refundable_until": "2023-11-07T05:31:56Z",
"policy_url": "<string>"
},
"assumptions": [
"<string>"
],
"intermediates": [
{
"step": "<string>",
"factor_id": "<string>",
"input": "<unknown>",
"value": "<unknown>",
"skipped": true,
"reason": "<string>"
}
],
"review_status": "VALIDATED_PENDING_REVIEW",
"consent": {
"share_for_pricing_research": true,
"anonymize": true,
"captured_at": "2023-11-07T05:31:56Z"
},
"anonymized": true,
"kind": "estimate",
"binding": false,
"confidence": "low",
"requires_in_person_consult": true
},
"quote": {
"pack_id": "<string>",
"pack_version": "<string>",
"answers": {},
"artist_review_mode": "pre_price",
"price_range": {
"min": 1,
"max": 1,
"currency": "<string>",
"basis": "hourly",
"method": "artist_stated",
"provenance": {
"who": "<string>",
"when": "2023-11-07T05:31:56Z"
},
"n": 6,
"min_minor": 4503599627370495,
"max_minor": 4503599627370495
},
"sessions": {
"count": 1,
"hours_per_session": 1
},
"deposit": {
"amount": 1,
"basis": "<string>",
"policies": [
"<string>"
],
"status": "unpaid",
"merchant_of_record": "provider",
"provenance": {
"who": "<string>",
"when": "2023-11-07T05:31:56Z"
},
"confirmation": {
"source": "payment_processor",
"reference": "<string>",
"confirmed_at": "2023-11-07T05:31:56Z"
},
"amount_minor": 4503599627370495,
"capture_on": "accept",
"refundable_until": "2023-11-07T05:31:56Z",
"policy_url": "<string>"
},
"assumptions": [
"<string>"
],
"intermediates": [
{
"step": "<string>",
"factor_id": "<string>",
"input": "<unknown>",
"value": "<unknown>",
"skipped": true,
"reason": "<string>"
}
],
"review_status": "QUOTED",
"consent": {
"share_for_pricing_research": true,
"anonymize": true,
"captured_at": "2023-11-07T05:31:56Z"
},
"anonymized": true,
"valid_until": "2023-11-07T05:31:56Z",
"kind": "quote",
"binding": true,
"confidence": "low",
"client_approval": {
"amount": 1,
"currency": "<string>",
"policies": [
"<string>"
],
"approved_amount": true,
"approved_policies": true,
"approved_at": "2023-11-07T05:31:56Z",
"amount_minor": 4503599627370495
},
"attribution": {
"referrer_id": "<string>",
"token": "<string>",
"campaign": "<string>",
"source": "<string>"
},
"quantity": 4503599627370496,
"quantity_unit": {
"unit": "C62",
"display_text": "<string>",
"scale": 0
},
"checkout_handoff": {
"protocol": "ucp",
"url": "<string>",
"ucp_quote_status": "pending",
"acp_quote_id": "<string>",
"quote_expires_at": "2023-11-07T05:31:56Z"
},
"id": "<string>",
"expires_at": "2023-11-07T05:31:56Z"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"current_state": "INITIATED"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"current_state": "INITIATED"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"current_state": "INITIATED"
}
}Headers
Minimum string length:
1Body
application/json
Minimum string length:
1Minimum string length:
1Show child attributes
Show child attributes
Neutral routing attribution; not payment authorization or proof of consent.
Show child attributes
Show child attributes
Required range:
1 <= x <= 9007199254740991Rec 20 unit descriptor. Quantity counts steps of 10^-scale units; omitted scale means zero.
Show child attributes
Show child attributes
Response
Success
Minimum string length:
1Available options:
INITIATED, MANIFEST_ISSUED, PAYLOAD_SUBMITTED, MUTATION_REQUIRED, VALIDATED_PENDING_REVIEW, QUOTED, ACCEPTED, DECLINED, EXPIRED Non-binding PricingModel result returned on PAYLOAD_SUBMITTED; incomplete inputs require mutation, never omission of a price.
Show child attributes
Show child attributes
Show child attributes
Show child attributes