{"openapi":"3.0.0","info":{"title":"Sauna am Fluss — Agent API","description":"Read-only API für KI-Agenten und externe Integrationspartner. Verfügbarkeiten, Preise, Buchungs- und Gutscheinstatus in Echtzeit.","version":"1.0.0","contact":{"name":"Sauna am Fluss","url":"https://safbookings.lovable.app/agents"}},"servers":[{"url":"https://safbookings.lovable.app/api/public/agent"}],"paths":{"/info":{"get":{"operationId":"getInfo","summary":"Öffnungszeiten, Regeln und Links","responses":{"200":{"description":"Sauna-Informationen","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Info"}}}}}}},"/prices":{"get":{"operationId":"getPrices","summary":"Aktive Produkte und Preise","responses":{"200":{"description":"Preisliste","content":{"application/json":{"schema":{"type":"object","properties":{"prices":{"type":"array","items":{"$ref":"#/components/schemas/Product"}}}}}}}}}},"/availability":{"get":{"operationId":"getAvailability","summary":"Verfügbare Einstiegsslots","parameters":[{"name":"date","in":"query","required":true,"schema":{"type":"string","format":"date"},"example":"2025-12-24"},{"name":"days","in":"query","schema":{"type":"integer","minimum":1,"maximum":14,"default":1}},{"name":"people","in":"query","schema":{"type":"integer","minimum":1,"maximum":20,"default":1}}],"responses":{"200":{"description":"Verfügbarkeit pro Tag","content":{"application/json":{"schema":{"type":"object","properties":{"days":{"type":"array","items":{"$ref":"#/components/schemas/DayAvailability"}}}}}}}}}},"/booking-status":{"get":{"operationId":"getBookingStatus","summary":"Buchungsstatus anhand Buchungsreferenz","parameters":[{"name":"ref","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Z0-9]{6}$"},"example":"Y6A9PK"}],"responses":{"200":{"description":"Buchungsstatus","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BookingStatus"}}}},"404":{"description":"Buchung nicht gefunden"}}}},"/voucher":{"get":{"operationId":"getVoucherStatus","summary":"Gutschein- oder Abo-Status","parameters":[{"name":"code","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Z0-9]{5,16}$"},"example":"GS-29CHF-AB1CD2"}],"responses":{"200":{"description":"Gutschein-/Abo-Status","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VoucherStatus"}}}},"404":{"description":"Code nicht gefunden"}}}}},"components":{"schemas":{"Info":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string"},"url":{"type":"string","format":"uri"},"timezone":{"type":"string"},"currency":{"type":"string"},"locale":{"type":"string"},"location":{"type":"object","properties":{"name":{"type":"string"},"address":{"type":"string"},"city":{"type":"string"},"postal_code":{"type":"string"},"country":{"type":"string"}}},"booking":{"type":"object","properties":{"type":{"type":"string"},"booking_url":{"type":"string","format":"uri"},"stay_minutes":{"type":"integer"},"entry_interval_minutes":{"type":"integer"},"max_entries_per_slot":{"type":"integer"},"max_concurrent_guests":{"type":"integer"},"advance_booking_required":{"type":"boolean"},"availability_is_real_time":{"type":"boolean"}}},"opening_hours":{"type":"object","description":"Öffnungszeiten pro Wochentag","additionalProperties":{"type":"object","properties":{"open_time":{"type":"string"},"close_time":{"type":"string"},"last_entry_time":{"type":"string"}}}},"season":{"type":"object","properties":{"start_date":{"type":"string","nullable":true},"end_date":{"type":"string","nullable":true}}},"cancellation":{"type":"object","properties":{"cancellation_allowed":{"type":"boolean"},"rebooking_allowed":{"type":"boolean"},"deadline_hours_before_entry":{"type":"integer"},"refund_method":{"type":"string"},"refund_processing_time":{"type":"string"}}},"payment":{"type":"object","properties":{"provider":{"type":"string"},"methods":{"type":"array","items":{"type":"string"}},"currency":{"type":"string"}}},"links":{"type":"object","properties":{"book":{"type":"string","format":"uri"},"gift_cards_and_passes":{"type":"string","format":"uri"},"voucher_balance":{"type":"string","format":"uri"},"agent_api_docs":{"type":"string","format":"uri"}}}}},"Product":{"type":"object","properties":{"code":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"kind":{"type":"string","enum":["ticket","extension","extra","abo"]},"price_chf":{"type":"number"},"currency":{"type":"string"}}},"DayAvailability":{"type":"object","properties":{"date":{"type":"string","format":"date"},"slots":{"type":"array","items":{"$ref":"#/components/schemas/SlotInfo"}}}},"SlotInfo":{"type":"object","properties":{"iso":{"type":"string","format":"date-time"},"label":{"type":"string"},"entryRemaining":{"type":"integer"},"concurrentRemaining":{"type":"integer"},"bookable":{"type":"boolean"},"bookableForPeople":{"type":"boolean"}}},"BookingStatus":{"type":"object","properties":{"ref":{"type":"string"},"status":{"type":"string"},"payment_status":{"type":"string","nullable":true},"date":{"type":"string","format":"date"},"time":{"type":"string"},"people":{"type":"integer"},"total_chf":{"type":"number"},"can_cancel_or_rebook":{"type":"boolean"},"note":{"type":"string"}}},"VoucherStatus":{"type":"object","properties":{"code":{"type":"string"},"kind":{"type":"string","enum":["voucher","month_pass","season_pass","ten_pass"]},"kind_label":{"type":"string"},"status":{"type":"string"},"balance_chf":{"type":"number","nullable":true},"entries_used":{"type":"integer","nullable":true},"max_entries":{"type":"integer","nullable":true},"entries_remaining":{"type":"integer","nullable":true},"valid_until":{"type":"string","nullable":true},"check_url":{"type":"string","format":"uri"},"redeem_hint":{"type":"string"}}}}}}