{{-- brafa Systems — booking systems on the booking-sync API. Livewire backing: App\Http\Livewire\SuperAdmin\BookingSystemManagement. --}}
@if ($successMessage)
{{ $successMessage }}
@endif @if ($errorMessage)
{{ $errorMessage }}
@endif {{-- Add a booking system --}}

Booking systems

Request log

Systems that push bookings to brafa (docs/booking-sync-api.md). Name a system to get its secret, then send the secret separately from the doc.

@if ($shownSecret)
{{ $shownSecret['rotating'] ? 'New secret' : 'Secret' }} for {{ $shownSecret['name'] }}: copy it now, it isn't shown again. @if ($shownSecret['rotating']) The old one keeps working until you finish the rotation. @endif @foreach ([['Base URL', $shownSecret['baseUrl']], ['Secret', $shownSecret['secret']]] as [$label, $value])
{{ $label }}
{{ $value }}
@endforeach
@endif
@error('name')

{{ $message }}

@enderror
@error('slug')

{{ $message }}

@enderror
@if ($slug !== '')

https://app.brafasystems.com/api/booking-sync/{{ $slug }}/{tenant}

@endif
{{-- Systems --}}

Systems

@forelse ($providers as $provider) @empty @endforelse
System Base URL Venues Last push Feed New venues Status Actions
{{ $provider->name }}
{{ $provider->provider }}
{{ $provider->baseUrl() }} {{ $venueCounts[$provider->provider] ?? 0 }} {{ optional($lastPushes[$provider->provider] ?? null)->diffForHumans() ?? 'Never' }} @if ($provider->feed_url) Read every 10 min @if (empty($provider->feed_token))
no token
@endif @else None @endif
{{ $provider->auto_provision ? 'Set up on first push' : 'Link first' }} @if ($provider->is_active) Active @else Off @endif @if ($provider->previous_secret !== null)
Rotating: old secret still works
@endif
@if ($provider->previous_secret !== null) @else @endif
No booking systems yet.
@if ($providers->isNotEmpty())

Bookings feed: if a system has its own feed of bookings, brafa reads it every 10 minutes for venues that have pushed, to catch pushes that never arrived. Leave the address empty to remove it. The token is stored encrypted and never shown again.

@error('feedProvider')

{{ $message }}

@enderror
@error('feedUrl')

{{ $message }}

@enderror
@error('feedToken')

{{ $message }}

@enderror
@endif
{{-- Moving from older feeds (Bookly → Stundagátt) --}} @if (count($moving) > 0)

Moving from Bookly

Link each venue below to its new system before that system's first push. The property keeps its lock account and locks; Bookly keeps working until the first push, then stands down. A unit whose name matches none of the property's lock mapping gets the locks it had before.

@foreach ($moving as $row) @endforeach
Property Linked venue Status Lock account Locks
{{ $row['name'] }}
{{ $row['propertyId'] }}
{{ $row['venue'] ?? '—' }} @if (! $row['venue']) Not linked @elseif ($row['liveSince']) Moved {{ $row['liveSince']->format('Y-m-d') }} @else Linked: {{ $row['from'] }} runs until first push @endif @if ($row['inheritedUnits'] > 0)
{{ $row['inheritedUnits'] }} unit(s) got the earlier locks: check Assigned Locks
@endif
{{ $row['hasLockAccount'] ? 'Yes' : 'Missing' }} {{ $row['lockCount'] ?: 'None' }}
@endif {{-- Venues --}}

Venues

Link a venue to a property brafa already has before its first push, or that push sets up a new property. New venues appear here on their own.

@error('linkProvider')

{{ $message }}

@enderror
@error('linkTenant')

{{ $message }}

@enderror
@error('linkProperty')

{{ $message }}

@enderror
@forelse ($sources as $source) @empty @endforelse
System Venue id Property Units Last push Added Status Actions
{{ $providerNames[$source->provider] ?? $source->provider }} {{ $source->tenant }} {{ $propertyNames[$source->property_id] ?? 'Property ' . $source->property_id }} @if ($source->replaces_api)
{{ $source->live_since ? 'Replaced ' . $source->replaces_api . ' on ' . $source->live_since->format('Y-m-d') : 'Replaces ' . $source->replaces_api . ' at first push' }}
@endif
{{ $source->units_count }} @if ($source->inherited_units_count > 0)
{{ $source->inherited_units_count }} with earlier locks: check
@endif
{{ optional($source->last_push_at)->diffForHumans() ?? 'Never' }} @if ($source->last_poll_at)
feed read {{ $source->last_poll_at->diffForHumans() }}
@endif @if ($source->poll_error)
{{ $source->poll_error }}
@endif
{{ optional($source->created_at)->format('Y-m-d') }} @if ($source->is_active) Active @else Off @endif
No venues yet. They appear on their first push, or when you link one above.