Skip to content

Preview Detect fraud risk (dry-run)

POST
/v1/actions/hospitality.action.detect_fraud_risk/preview
curl --request POST \
--url https://api.aerandil.com/v1/actions/hospitality.action.detect_fraud_risk/preview \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "branch": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "params": { "band": "low", "confidence": "low", "confidence_score": "example", "coverage_guaranteed": true, "coverage_terms_uri": "example", "expires_at": "2026-04-15T12:00:00Z", "external_record_ref": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "factors_considered": [ "payment_signal" ], "feature_payload_hash": "example", "fire_point": "at_booking", "folio_charge_ref": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "fraud_network_signal_ref": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "person_ref": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "policy_outcomes": [ "psd2_sca_required" ], "prior_triage_ref": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "rationale_text": "example", "reason_codes": "example", "recommended_action": "approve", "reservation_ref": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "risk_context_snapshot": {}, "score": "example", "score_calibrated": "example", "subject_id": "example", "subject_kind": "reservation", "triggered_rules": "example", "vendor_id": "example", "vendor_model_version": "example" }, "return_modified": false, "target": { "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "object_type": "hospitality.property" } }'

Scenario preview of apply_hospitality_action_detect_fraud_risk — runs the action exactly as apply would (validation, handler dispatch, modified-object projection, commit-time cross-link validation) then rolls the transaction back. Returns the modified_objects / modified_links / warnings the apply would have produced without persisting anything or firing any outward effect. Requires the same actions:hospitality.action.detect_fraud_risk:apply scope as apply. No Idempotency-Key.

Media typeapplication/json
object
branch

Apply against an open branch’s overlay view instead of the canonical (main) plane. The action’s writes land in the branch’s copy-on-first-write overlay, its events in the branch’s own stream, and the invocation is journaled for merge-by-replay. Branch writes are action-only, so this is the write-side entry point to a branch (POST /v1/branches forks one).

string format: uuid
params
required
object
band
required
Risk band ordinal
string
Allowed values: low medium high block not_assessed
confidence
required
Operator-facing confidence ordinal
string
Allowed values: low medium high
confidence_score
Calibrated probability [0, 1] (optional)
string format: decimal
coverage_guaranteed
True when the vendor's chargeback-guarantee covers this decision
boolean
coverage_terms_uri
Pointer to the vendor's coverage terms
string
expires_at
Assessment expiry (default per fire-point — see proposal §3.1)
string format: date-time
external_record_ref
Optional pointer to vendor raw payload (external_record_reference)
string format: uuid
factors_considered
required
Signals the assessment conditioned on
Array<string>
Allowed values: payment_signal identity_signal behavioural_signal device_signal velocity_signal geo_signal lead_time loyalty_account_age prior_chargeback_history prior_recovery_history third_party_payer_flag vcn_detected injection_history network_outcome kyc_outcome three_ds_outcome watchlist_match graph_signal fraud_network_signal other
feature_payload_hash
SHA-256 of canonical input-feature JSON (chargeback-defence tamper-evidence)
string
fire_point
required
Lifecycle moment the assessment fired at
string
Allowed values: at_booking at_payment at_check_in at_folio_close on_chargeback_attempt
folio_charge_ref
Optional charge anchor
string format: uuid
fraud_network_signal_ref
The Watchtower answer this assessment was scored with; its band floor binds the band
string format: uuid
person_ref
Optional denormalised person anchor
string format: uuid
policy_outcomes
required
Compliance flags observed during scoring
Array<string>
Allowed values: psd2_sca_required psd2_sca_out_of_scope_moto psd2_sca_exempted_low_value psd2_sca_exempted_trusted_beneficiaries psd2_sca_exempted_tra psd2_sca_exempted_recurring psd2_sca_exempted_corporate_payment three_ds_y three_ds_a three_ds_u three_ds_n three_ds_r three_ds_not_attempted gdpr_art22_explanation_required pci_token_only pci_last4_only facta_red_flag_match fincen_8300_threshold_met eu_ai_act_high_risk_processing ccpa_admt_notice_required none
prior_triage_ref
Optional cross-surface link to a prior message_triage (e.g. injection.suspected)
string format: uuid
rationale_text
required
Human-readable explanation
string
reason_codes
required
Explanation array (JSON array of {code, severity, contribution})
recommended_action
required
Recommended action class
string
Allowed values: approve review step_up_3ds step_up_kyc decline escalate
reservation_ref
Optional denormalised reservation anchor
string format: uuid
risk_context_snapshot
required
Frozen context snapshot at issue time (JSON; host populates per recommended shape)
object
key
additional properties
any
score
required
Raw numeric score on the [0, 100] scale
string format: decimal
score_calibrated
Optional calibrated probability [0, 1]
string format: decimal
subject_id
required
Id of the typed object the assessment scored
string
subject_kind
required
What kind of object the assessment scored
string
Allowed values: reservation payment charge person loyalty_redemption folio
triggered_rules
Custom-rule provenance (JSON array of {rule_id, rule_version, action})
vendor_id
required
Vendor identity (denormalised from Principal::Agent.vendor)
string
vendor_model_version
Vendor model version when exposed
string
return_modified

When true, the response carries modified_objects and modified_links projections — the engine reads the event log inside the same transaction so the projection observes the handler’s own writes.

boolean
target
required
object
id
required
string format: uuid
object_type
required
Allowed value: hospitality.property

Preview computed and rolled back. modified_objects and modified_links carry the effect set the apply would produce; preview is always true.

Media typeapplication/json
ApplyActionResponse

Envelope returned by the Aerandil action engine. correlation_id ties every event emitted by this invocation; modified_objects and modified_links project the events the handler emitted (per the action’s declared effects); warnings carries any non-blocking soft-validator observations.

object
correlation_id
required

Per-invocation correlation id; matches events.correlation_id for every event this action appended.

string format: uuid
modified_links
required

Links established or removed by this invocation. Empty when the caller did not request return_modified.

Array<object>
object
from_id
required
string format: uuid
from_type
required
string
kind
required
Allowed values: linked
link_type
required
Allowed values: hospitality.link.fraud_assessment_for_reservation hospitality.link.fraud_assessment_for_person hospitality.link.fraud_assessment_for_charge hospitality.link.fraud_assessment_at_property hospitality.link.fraud_assessment_references_external_record hospitality.link.fraud_assessment_superseded_by hospitality.link.fraud_assessment_for_prior_triage hospitality.link.fraud_assessment_consulted_network
to_id
required
string format: uuid
to_type
required
string
modified_objects
required

Objects created, modified, or soft-deleted by this invocation. Empty when the caller did not request return_modified.

Array<object>
object
id
required
string format: uuid
kind
required
Allowed values: created modified
object_type
required
Allowed values: hospitality.fraud_risk_assessment
warnings

Non-blocking soft-validator observations emitted during this invocation (e.g. comp-authority over-limit, recipe pour-cost over sell-price). Absent when no warnings were emitted.

Array<object>
object
message
required

Human-readable summary, suitable for logging or operator-UI surfacing.

string
object_type
required

Object type the warning was raised against.

string
property

Property the warning anchors to, when a single field is the locus. Absent for multi-field rules.

string
rule
required

Stable kebab-case rule identifier (e.g. comp-authority-over-limit).

string
Example
{
"modified_links": [
{
"kind": "linked",
"link_type": "hospitality.link.fraud_assessment_for_reservation"
}
],
"modified_objects": [
{
"kind": "created",
"object_type": "hospitality.fraud_risk_assessment"
}
]
}
Cache-Control
string
Allowed value: no-store

Always no-store — uncommitted live data.

Conflict — concurrent modification or unique constraint violation the apply would hit.

Validation error — the apply would be rejected.