Build a Safe Automated Pricing Workflow

Jun Zhou, Founder at AirROI
by Jun ZhouFounder at AirROI
Published: September 4, 2026
Updated: September 5, 2026

AirROI's recommendation endpoints calculate prices. Your application must store settings, refresh availability, decide which results to accept, and publish through a separate authorized channel integration.

Separate the stages

Calculation is one stage—not the whole publishing workflow

Keep the read-only recommendation steps separate from decisions and channel writes.

  1. 01 · Calculate

    Send property inputs, base price, settings, and current calendar. Read prices, explanations, and warnings.

  2. 02 · Review

    Check business limits, skipped rules, changed availability, and which dates are approved.

  3. 03 · Publish separately

    Send only approved updates through your channel integration. Reconcile per-date acknowledgments.

This is an integration pattern, not a set of additional AirROI API endpoints. Publishing requires your own authorized channel integration.
StageYour responsibilityOutput
1. PrepareLoad property facts, currency, base price, current calendar, and complete settingsVersioned request
2. CalculateCall Calendar Prices and capture status, warnings, and request IDRecommendation snapshot
3. ReviewEvaluate warnings, price changes, restrictions, and business limitsApproved dates and rates
4. PublishRecheck availability and send approved changes to your channel integrationPer-date publishing outcomes
5. ReconcileConfirm acknowledgments and record applied valuesAudit trail and retry queue

These are application-design recommendations, not extra AirROI API endpoints.

Persist configuration on your side

Every call is stateless. Resend rules, overrides, stay settings, and fresh calendar evidence each time. Store the request version, response currency, response prices, explanation lines, warnings, request ID, and your own calculation timestamp.

Decide deliberately when to refresh a base price; recalculating it on every schedule run is not required. You may use an existing base price and call Calendar Prices directly. Model updates and changing lead time mean repeated requests need not return identical prices.

Gate publishing on business policy

Start with preview-only mode and compare results to existing rates. Define acceptable price changes and which warning classes require manual review. Do not silently replace rejected recommendations with invented prices.

Recheck reservations and blocks before publishing: availability can change between calculation and publication. Apply your own non-negotiable publishing bounds if needed, because a fixed AirROI price override intentionally bypasses owner minimum and maximum settings.

Do not infer output stay restrictions that are absent. Calendar-row restrictions are not echoed, and length-of-stay discount settings currently produce no pricing effect. Channel minimum-stay and check-in/out capabilities must be handled by your integration.

Make failures recoverable

Retry transient network/server failures with bounded backoff and jitter. Do not retry invalid configuration indefinitely. Keep calculation retries separate from publishing retries: a rate calculation has no publishing side effect, but your channel operation may.

Use your channel provider's supported deduplication or idempotency mechanism where available. Record which dates were acknowledged so a partial failure does not become an untraceable full-calendar overwrite. Avoid overlapping publishing jobs for the same property.

Test before enabling writes

  • Currency handoff, including the Base Price USD fallback.
  • Property-local date boundaries and a shortened response horizon.
  • Missing/blocked calendar dates and occupancy evidence thresholds.
  • Large combined rule adjustments, minimums, and a fixed override outside owner limits.
  • A reservation arriving after calculation but before publishing.
  • Unknown warning codes, partial publishing failures, and unavailable dependencies.
Use the synthetic World Cup example to test explanation rendering, not as historical pricing data or a live forecast. See the quickstart for the calculation calls.