Skip to content

Getting Started with Webhooks

Webhooks tell your application when something changes in Crewsum, so you do not have to poll the API. When a record changes, Crewsum sends an HTTP POST request with a JSON body to a URL that you choose.

Use webhooks to keep another system in sync with Crewsum. For example, update your CRM when a client changes, or start payroll processing when a timesheet is submitted.

  1. An administrator creates a webhook in Crewsum. A webhook has a URL and a list of events to send to that URL.

  2. Someone makes a change, in the Crewsum app or through the API.

  3. Crewsum sends a signed POST request to the URL of every webhook that subscribes to that event. The body has two fields:

    {
    "event": "projects.created",
    "data": { "projects": [{ "id": "project-mno123pqr4567890", "name": "Warehouse Automation Rollout" }] }
    }

    The example is shortened. Each event page shows the full payload.

  4. Your endpoint checks the signature, responds with 200, and processes the event.

The event type is the event field of the body. Match it exactly. Most types are plural (clients.created), but the timesheet events are singular (timesheet.saved).

ResourceEvent types
Clientsclients.created, clients.updated, clients.deleted
End customersend-customers.created, end-customers.updated, end-customers.deleted
Projectsprojects.created, projects.updated, projects.deleted
Contactsproject-contacts.created, project-contacts.updated, project-contacts.deleted
Taskstasks.created, tasks.updated, tasks.deleted
Project-contact associationsassociations.created, associations.updated, associations.removed
Supplierssuppliers.created, suppliers.updated, suppliers.deleted
Supplier contactssupplier-contacts.created, supplier-contacts.updated, supplier-contacts.deleted
Usersusers.created, users.updated, users.archived, users.deleted
Time entrytimesheet.saved, timesheet.submitted, timecards.reviewed, timesheet.deleted

The Contacts endpoints send project-contacts.* events. User groups and user assignments do not send events.

See Webhook Events for what triggers each event and which API endpoint sends it.

  • You must be an administrator in Crewsum to manage webhooks.
  • Your endpoint must accept POST requests from the internet. Use an https:// URL.
  • Your endpoint must read the raw request body to check the signature. Crewsum sends JSON but does not set Content-Type: application/json.

Crewsum sends each event once and does not retry failed deliveries. Crewsum also waits for your response during the action that caused the event, so respond quickly. The webhook Enabled switch currently does not stop deliveries. Read Delivery before you go to production.