Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.mileapp.dev/llms.txt

Use this file to discover all available pages before exploring further.

What is a Task?

A task is an item of work intended for completion by an assignee. It can embody activities like pickups, deliveries, planning, inspections, sales visits, or other work-related actions within your organization. Tasks encompass essential attributes, including IDs, flow, time, status indicators, assignee information, order index, and other pertinent data. The content of a task is configurable based on your specified flow settings. For instance, tasks can serve as visits during the route optimization process, functioning as pivotal elements. The task can also represent a visit in route optimization, please follow this link to read more detail. Task data and task history are stored with 1-year data retention. To see the details of task object, please follow this link.

Task Types

  • Pickups - Collecting items from a location
  • Deliveries - Delivering items to a destination
  • Inspections - Site or equipment inspections
  • Sales visits - Customer visits for sales activities
  • Planning - Route planning and optimization
  • Other work-related actions within your organization

Task Attributes

Tasks encompass essential attributes including:
AttributeDescription
_idUnique task identifier
flowThe flow template used for this task
statusCurrent task status
assigneeUser assigned to complete the task
hubIdHub where the task belongs
taskTimeScheduled time for the task
orderIndexOrder position for sequencing
attributesCustom fields defined by the flow
The content of a task is configurable based on your specified flow settings. Tasks can also serve as visits during the route optimization process.

Common Operations

List Tasks

Retrieve all tasks with filtering options

Create Task

Create a new task

Update Task

Update an existing task

Assign Task

Assign a task to a user

Bulk Operations

MileApp supports bulk operations for efficient task management:
  • Bulk Create - Create multiple tasks in a single request
  • Bulk Update - Update multiple tasks at once
  • Bulk Assign - Assign multiple tasks to users
  • Bulk Move - Move multiple tasks to different hubs
  • Bulk Delete - Delete multiple tasks

Integration with Route Optimization

Tasks can serve as visits in the route optimization module. When you create tasks with location data, they can be:
  1. Included in route optimization calculations
  2. Assigned to vehicles based on constraints
  3. Sequenced for optimal delivery routes
For more information about route optimization, see the Routing documentation.

Field Accessibility

If the requesting userโ€™s role has field accessibility configured (via permissionDetails with permissionName: view/task), certain task fields may be restricted based on the flow.
  • GET endpoints without fields parameter: Hidden fields are automatically excluded from the response. No error is returned โ€” the fields simply donโ€™t appear.
  • GET endpoints with fields parameter: If a requested field is restricted, the API returns a 403 Forbidden error listing the restricted field names.
  • POST/PUT/PATCH endpoints: Write operations are not affected โ€” restricted fields can still be submitted.
Field accessibility is configured per role in the Permission Settings. Refer to the Role API for details on permissionDetails.