fix(api): update policies type and materialisation endpoint URL
continuous-integration/drone/push Build is passing Details

Per Backend Brooke messages:
- Made BookingDetail.policies required (commit 75c8edf deployed)
- Fixed materialisation endpoint: /materialisation-trigger → /slot-materialize
- CORS headers fix deploying on backend (X-Idempotency-Key, If-Match, If-None-Match)

Artifacts: src/types/bookings.ts:69-73, src/lib/api/materialisation.ts:91
master
Guillermo Pages 1 month ago
parent 9186b35649
commit 20971e53c0

@ -88,7 +88,7 @@ export async function triggerMaterialisation(
}
try {
const response = await fetch(`${API_BASE_URL}/admin/clubs/${clubId}/materialisation-trigger`, {
const response = await fetch(`${API_BASE_URL}/admin/clubs/${clubId}/slot-materialize`, {
method: 'POST',
credentials: 'include',
headers: {

@ -66,11 +66,10 @@ export interface BookingDetail {
updated_at: string; // ISO 8601
provider?: ProviderInfo;
etag?: string; // from ETag response header
// Optional policy fields (if backend adds them)
policies?: {
cancel_grace_minutes?: number;
cancel_grace_anchor?: 'start' | 'end';
move_window_days?: number;
policies: {
cancel_grace_minutes: number; // default: 15
cancel_grace_anchor: 'start' | 'end'; // current: 'start'
move_window_days: number; // default: 14, 0 = no limit
};
}

Loading…
Cancel
Save