Skip to main content
Dispatch is part of the optional teams, dispatch and missions module, used by operational verticals that send people to the field. Use this endpoint when an operator has already chosen the team. To find the events still waiting for a team, list the dispatch queue with GET /v1/events?undispatched=true: it returns the events without an active mission (no mission, or only missions that ended FAILED). To let wede rank the candidate teams, see Dispatch score and Action dispatch.

Dispatch a team

Authentication

Session token (Authorization: Bearer <token>) with the dispatch:assign permission. Tenant roles with it: company_admin, operational_supervisor, corporate_client.
The integration API key (x-wede-api-key) authenticates as api_user, which has no dispatch:* permission. Calls with an API key return 403 forbidden.

Body

string
required
The event_id wede returned for the event. It must be an existing production event of your tenant, otherwise wede returns 404 event_not_found.
string
required
UUID of the team to dispatch.
string
Up to 500 characters. Stored on the dispatch record and on the mission.
number
Latitude of the incident. Stored on the mission.
number
Longitude of the incident. Stored on the mission.

Example

Response 201

The dispatch record.
string
Dispatch record UUID.
string
Your tenant.
string
The event you dispatched to.
string
The dispatched team.
string | null
UUID of the user who dispatched.
string
ISO 8601 timestamp.
string | null
Your notes.

What happens on dispatch

  1. wede records the dispatch and sets the team status to on_mission.
  2. wede creates a mission for the team with status CREATED and channel_used internet. If the team already has a mission for this event_id, wede keeps that mission and does not create a second one.
  3. wede sends the team.dispatched webhook with { team_id, event_id, notes }.
To send a second team to the same event, dispatch again with the same event_id and the other team_id. Each team gets its own mission. When the mission reaches COMPLETED or FAILED, wede sets the team back to available. The mission outcome never changes the status of the event, which stays its delivery status. If the team does not acknowledge within your acknowledgement timeout, wede substitutes it automatically. See Missions.

Errors


Dispatch log

Returns the 100 most recent dispatch records of your tenant, newest first.

Authentication

Session token with the dispatch:view permission. Tenant roles with it: company_admin, operational_supervisor, corporate_client. API keys get 403 forbidden.

Query parameters

string
Return only the dispatch records for this event.

Response 200

Each record has the dispatch fields above plus team_name.

Errors

SDKs

dispatch in JavaScript and Python.