curl --request PUT \
--url https://api.sumvin.com/v0/user/ipa/{ipa_id}/conditions \
--header 'Content-Type: application/json' \
--header 'x-juno-jwt: <api-key>' \
--data '
{
"conditions": [
{
"type": "price_target",
"target_price": 123,
"currency": "USD"
}
]
}
'import requests
url = "https://api.sumvin.com/v0/user/ipa/{ipa_id}/conditions"
payload = { "conditions": [
{
"type": "price_target",
"target_price": 123,
"currency": "USD"
}
] }
headers = {
"x-juno-jwt": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'x-juno-jwt': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({conditions: [{type: 'price_target', target_price: 123, currency: 'USD'}]})
};
fetch('https://api.sumvin.com/v0/user/ipa/{ipa_id}/conditions', 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.sumvin.com/v0/user/ipa/{ipa_id}/conditions",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'conditions' => [
[
'type' => 'price_target',
'target_price' => 123,
'currency' => 'USD'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-juno-jwt: <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.sumvin.com/v0/user/ipa/{ipa_id}/conditions"
payload := strings.NewReader("{\n \"conditions\": [\n {\n \"type\": \"price_target\",\n \"target_price\": 123,\n \"currency\": \"USD\"\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("x-juno-jwt", "<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.put("https://api.sumvin.com/v0/user/ipa/{ipa_id}/conditions")
.header("x-juno-jwt", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"conditions\": [\n {\n \"type\": \"price_target\",\n \"target_price\": 123,\n \"currency\": \"USD\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sumvin.com/v0/user/ipa/{ipa_id}/conditions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["x-juno-jwt"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"conditions\": [\n {\n \"type\": \"price_target\",\n \"target_price\": 123,\n \"currency\": \"USD\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"_links": {},
"intent": {
"id": "<string>",
"intent_type": "product",
"status": "qualifying",
"autonomy_level": "supervised",
"created_at": 123,
"raw_intent": "<string>",
"specification": "<string>",
"constraints": {
"max_price": 123,
"max_total": 123,
"currency": "<string>",
"deadline": 123,
"preferred_sellers": [
"<string>"
],
"excluded_sellers": [
"<string>"
],
"extra": {}
},
"conditions": [
{
"type": "price_target",
"operator": "lte",
"target_price": "<string>",
"currency": "USD"
}
],
"monitor_until": 123,
"clarification_questions": [
"<string>"
],
"failure_reason": "<string>",
"pint_uris": [
"<string>"
],
"updated_at": 123,
"completed_at": 123,
"capacity": {
"limit_status": "no_amount_authorized",
"consumed": "<string>",
"reserved": "<string>",
"enforcement_mode": "<string>",
"mandate_pint_uri": "<string>",
"max_amount": "<string>",
"remaining": "<string>",
"asset": "<string>"
},
"manifest_summary": {
"id": "<string>",
"status": "<string>",
"item_count": 123,
"total_amount": "<string>",
"total_asset": "<string>",
"approved_at": 123,
"purchased_at": 123
},
"preflight_workflow_id": "<string>",
"originating_agent_task": {
"id": "<string>",
"status": "<string>",
"trigger_type": "<string>",
"created_at": 123,
"workflow_run_id": "<string>",
"task": "<string>",
"title": "<string>",
"started_at": 123,
"completed_at": 123
},
"executing_agent_task": {
"id": "<string>",
"status": "<string>",
"trigger_type": "<string>",
"created_at": 123,
"workflow_run_id": "<string>",
"task": "<string>",
"title": "<string>",
"started_at": 123,
"completed_at": 123
},
"candidates": [
{
"id": "<string>",
"offer_id": "<string>",
"status": "<string>",
"created_at": 123,
"rank": 123,
"score": 123,
"rejection_reason": "<string>"
}
],
"manifests": [
{
"id": "<string>",
"status": "<string>",
"items": [
{
"offer_id": "<string>",
"quantity": 123,
"unit_price_amount": "<string>",
"unit_price_asset": "<string>"
}
],
"created_at": 123,
"total_amount": "<string>",
"total_asset": "<string>",
"approved_at": 123,
"purchased_at": 123
}
],
"events": [
{
"id": "<string>",
"event_type": "ipa.status_change",
"created_at": 123,
"payload": {}
}
],
"approval_payload": {
"types": {},
"primaryType": "<string>",
"domain": {
"name": "<string>",
"version": "<string>",
"chainId": 123,
"verifyingContract": "<string>"
},
"message": {
"wallet": "<string>",
"nonce": 123,
"statement": "<string>",
"scopes": [
"<string>"
],
"resources": [
"<string>"
],
"maxAmount": 123,
"maxAmountToken": "<string>",
"expiresAt": 123,
"conditions": [
"<string>"
]
}
}
}
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}Replace the conditions on an errand's approval
Sets the complete condition set on the payload waiting to be signed for this errand, replacing whatever it carried before — an empty list strips every condition. Returns the rewritten payload: it is the one to sign, and it supersedes any copy fetched earlier. Rejected once the approval has already been signed.
curl --request PUT \
--url https://api.sumvin.com/v0/user/ipa/{ipa_id}/conditions \
--header 'Content-Type: application/json' \
--header 'x-juno-jwt: <api-key>' \
--data '
{
"conditions": [
{
"type": "price_target",
"target_price": 123,
"currency": "USD"
}
]
}
'import requests
url = "https://api.sumvin.com/v0/user/ipa/{ipa_id}/conditions"
payload = { "conditions": [
{
"type": "price_target",
"target_price": 123,
"currency": "USD"
}
] }
headers = {
"x-juno-jwt": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'x-juno-jwt': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({conditions: [{type: 'price_target', target_price: 123, currency: 'USD'}]})
};
fetch('https://api.sumvin.com/v0/user/ipa/{ipa_id}/conditions', 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.sumvin.com/v0/user/ipa/{ipa_id}/conditions",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'conditions' => [
[
'type' => 'price_target',
'target_price' => 123,
'currency' => 'USD'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-juno-jwt: <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.sumvin.com/v0/user/ipa/{ipa_id}/conditions"
payload := strings.NewReader("{\n \"conditions\": [\n {\n \"type\": \"price_target\",\n \"target_price\": 123,\n \"currency\": \"USD\"\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("x-juno-jwt", "<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.put("https://api.sumvin.com/v0/user/ipa/{ipa_id}/conditions")
.header("x-juno-jwt", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"conditions\": [\n {\n \"type\": \"price_target\",\n \"target_price\": 123,\n \"currency\": \"USD\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sumvin.com/v0/user/ipa/{ipa_id}/conditions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["x-juno-jwt"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"conditions\": [\n {\n \"type\": \"price_target\",\n \"target_price\": 123,\n \"currency\": \"USD\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"_links": {},
"intent": {
"id": "<string>",
"intent_type": "product",
"status": "qualifying",
"autonomy_level": "supervised",
"created_at": 123,
"raw_intent": "<string>",
"specification": "<string>",
"constraints": {
"max_price": 123,
"max_total": 123,
"currency": "<string>",
"deadline": 123,
"preferred_sellers": [
"<string>"
],
"excluded_sellers": [
"<string>"
],
"extra": {}
},
"conditions": [
{
"type": "price_target",
"operator": "lte",
"target_price": "<string>",
"currency": "USD"
}
],
"monitor_until": 123,
"clarification_questions": [
"<string>"
],
"failure_reason": "<string>",
"pint_uris": [
"<string>"
],
"updated_at": 123,
"completed_at": 123,
"capacity": {
"limit_status": "no_amount_authorized",
"consumed": "<string>",
"reserved": "<string>",
"enforcement_mode": "<string>",
"mandate_pint_uri": "<string>",
"max_amount": "<string>",
"remaining": "<string>",
"asset": "<string>"
},
"manifest_summary": {
"id": "<string>",
"status": "<string>",
"item_count": 123,
"total_amount": "<string>",
"total_asset": "<string>",
"approved_at": 123,
"purchased_at": 123
},
"preflight_workflow_id": "<string>",
"originating_agent_task": {
"id": "<string>",
"status": "<string>",
"trigger_type": "<string>",
"created_at": 123,
"workflow_run_id": "<string>",
"task": "<string>",
"title": "<string>",
"started_at": 123,
"completed_at": 123
},
"executing_agent_task": {
"id": "<string>",
"status": "<string>",
"trigger_type": "<string>",
"created_at": 123,
"workflow_run_id": "<string>",
"task": "<string>",
"title": "<string>",
"started_at": 123,
"completed_at": 123
},
"candidates": [
{
"id": "<string>",
"offer_id": "<string>",
"status": "<string>",
"created_at": 123,
"rank": 123,
"score": 123,
"rejection_reason": "<string>"
}
],
"manifests": [
{
"id": "<string>",
"status": "<string>",
"items": [
{
"offer_id": "<string>",
"quantity": 123,
"unit_price_amount": "<string>",
"unit_price_asset": "<string>"
}
],
"created_at": 123,
"total_amount": "<string>",
"total_asset": "<string>",
"approved_at": 123,
"purchased_at": 123
}
],
"events": [
{
"id": "<string>",
"event_type": "ipa.status_change",
"created_at": 123,
"payload": {}
}
],
"approval_payload": {
"types": {},
"primaryType": "<string>",
"domain": {
"name": "<string>",
"version": "<string>",
"chainId": 123,
"verifyingContract": "<string>"
},
"message": {
"wallet": "<string>",
"nonce": 123,
"statement": "<string>",
"scopes": [
"<string>"
],
"resources": [
"<string>"
],
"maxAmount": 123,
"maxAmountToken": "<string>",
"expiresAt": 123,
"conditions": [
"<string>"
]
}
}
}
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}{
"detail": "No wallet found with ID 12345 for this user.",
"error_code": "WAL-404-001",
"instance": "/v0/wallets/12345",
"status": 404,
"title": "Wallet Not Found",
"trace_id": "abc123-def456-ghi789",
"type": "https://api.sumvin.com/errors/wal-404-001"
}Authorizations
Session JWT from the identity provider that signed the user in — Dynamic Labs, Privy, or Clerk (consumer sign-in). Send it in the x-juno-jwt header on every authenticated request. An Authorization: Bearer <jwt> header carrying the same JWT is also accepted, and takes precedence when both are present.
Headers
Tenant org ID for multi-tenant auth
Controls how timestamp fields are serialized in JSON response bodies.
Default (header omitted or any other value): epoch milliseconds as integers.
iso8601: UTC ISO 8601 strings of the form YYYY-MM-DDTHH:MM:SSZ.
Example: with X-Timestamp-Format: iso8601, the field value 1704067200000 becomes "2024-01-01T00:00:00Z".
Affected fields (recursively, in dicts and arrays): any field whose name ends in _at, plus the literal field names timestamp, period_start, and period_end. All other fields are passed through unchanged.
Only iso8601 is recognized. Any other value (or omitting the header) yields the default epoch-ms representation; the server does not reject unknown values, so this is documented as an example rather than an enum to keep generated clients permissive.
"iso8601"
Path Parameters
Body
The complete condition set for this errand's approval.
Replaces whatever conditions the unsigned payload carried before. An empty list strips every condition.
The complete set of conditions the purchase must satisfy to proceed. Replaces any previously supplied conditions; an empty list removes them all. Each condition is written into the payload you sign, and into its plain-language summary.
32Auto-execute when the lowest offer price satisfies a comparison against a target.
- PriceTargetCondition
- BudgetCapCondition
- AvailabilityCondition
- TimeWindowCondition
- FlightRouteCondition
- CoverageMinimumCondition
- JurisdictionCondition
Show child attributes
Show child attributes