Skip to content

Cookpit / Timbrage time tracking

If your campground uses Cookpit (Timbrage) for staff time-stamping, this adapter pulls those clock events into CampOne’s time-tracking module every 15 minutes. Payroll-ready totals, no double entry.

If you don’t use Cookpit, CampOne ships a built-in clock-in widget on the daily dashboard — staff hit “Clock in” when they arrive, “Clock out” when they leave, and the same downstream reports work.

  • Pulls clock events from Cookpit every 15 minutes (idempotent — re-runs don’t duplicate)
  • Stores them in CampOne’s TimeEntry table alongside manual entries
  • Tracks adjustments separately (every PATCH writes a TimeEntryAdjustment audit row)
  • Per-user time summaries with date filters
  • A staff-side Clock in / Clock out widget on the dashboard for any tenant

Cookpit doesn’t publish a public developer portal — you contact them directly:

What to ask for:

  1. The technical API contract (we currently assume GET /api/v1/clock-events with X-API-Key header)
  2. A sandbox tenant + API key for one pilot site
  3. Confirmation of the base URL (https://api-test.cookpit.ch is our current best guess)
  4. Their position on push: do they accept inbound shifts from us, or is this pull-only?

A ready-to-send email template lives at docs-internal/handoffs/integrations-outreach-emails.md.

Settings → Integrations → Vendor Adapters → Cookpit:

FieldDescription
EnvironmentTest / Production
Location IDCookpit’s identifier for your campground
API keyThe token Cookpit issues per tenant
User mappingA JSON object mapping Cookpit user IDs → CampOne user IDs, e.g. {"cookpit_42": 17, "cookpit_43": 22}

Click Save, then Test connection.

Every 15 minutes a Celery task asks Cookpit “any new clock events since last cursor?”. For each event it finds:

  1. Look up the Cookpit user ID in your user mapping to get the CampOne user.
  2. If the user isn’t mapped, skip and log (so you can map them and re-run).
  3. Create or update a TimeEntry keyed on (tenant, source='cookpit', external_ref). Re-imports are idempotent.
  4. Update the cursor so the next pull only fetches new events.

The integration log shows how many events were imported per pull.

The dashboard widget creates TimeEntry rows with source='manual'. Same data shape, same downstream reports. If a site adopts Cookpit later, you flip the toggle on this card and old manual entries stay intact.

Tenant admins can edit any TimeEntry (e.g. fix a missed clock-out). Every edit writes a TimeEntryAdjustment row with the before / after snapshot and the user who made the change — full audit trail for payroll disputes.

  • Push-shift to Cookpit is documented as a roadmap item — the adapter raises NotImplementedError until Cookpit confirms the inbound contract.
  • The Cookpit API contract is currently inferred from common time-tracking patterns; expect a small adjustment to services/client.py when the vendor confirms the exact response shape.
  • VCR-recorded tests against the real Cookpit sandbox will be added once credentials arrive.