Tookan MCP by usefulapi

v1.33.1
io.usefulapi/tookan Checked 2 days ago Published 1 day ago

Read Tookan tasks, agents, teams and customers; create delivery tasks and assign agents.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

tookan_get_account Get account

The connected Tookan account (admin user): user_id, email, name, company name and address. Good first call. POST /v2/get_user_details.

tookan_list_tasks List tasks

List tasks (Tookan calls them jobs) of one task type within a date range of the task date (at most 31 days, within the last 31 days). Paginated: one Tookan page per call (page, default 1). Filter by status, agent (fleet_id), team, customer, job ids or your order ids. Task status codes: 0 assigned, 1 started, 2 successful, 3 failed, 4 in progress/arrived, 6 unassigned, 7 accepted/acknowledged, 8 declined, 9 cancelled, 10 deleted. POST /v2/get_all_tasks.

ParameterTypeDescription
end_date *stringEnd of the task-date range, YYYY-MM-DD (at most 31 days after start_date).
job_type *Task type: 0 = pickup, 1 = delivery, 2 = appointment, 3 = field workforce (FOS).
start_date *stringStart of the task-date range, YYYY-MM-DD.
custom_fieldsbooleanInclude the tasks' custom-field data.
customer_idintegerOnly tasks of this customer (from tookan_list_customers).
fleet_idintegerOnly tasks of this agent (from tookan_list_agents).
job_idsarrayOnly these task (job) ids.
job_statusOnly tasks in this status. Task status codes: 0 assigned, 1 started, 2 successful, 3 failed, 4 in progress/arrived, 6 unassigned, 7 accepted/acknowledged, 8 declined, 9 cancelled, 10 deleted.
order_idsarrayOnly tasks with these order ids (your own reference).
pageintegerPage number (default 1). Tookan pages are a fixed size.
team_idintegerOnly tasks of this team (from tookan_list_teams).

tookan_get_tasks Get task details

Full details of up to 100 tasks by job id: customer, addresses, agent (fleet_id/fleet_name), status, timestamps (started/arrived/completed), tracking link, custom fields; optionally the status history. Task status codes: 0 assigned, 1 started, 2 successful, 3 failed, 4 in progress/arrived, 6 unassigned, 7 accepted/acknowledged, 8 declined, 9 cancelled, 10 deleted. POST /v2/get_job_details.

ParameterTypeDescription
job_ids *arrayTask (job) ids, e.g. [5145].
include_additional_infobooleanInclude the job's additional info.
include_task_historybooleanInclude each task's status history.

tookan_get_tasks_by_order_id Get tasks by order id

Full details of the tasks carrying the given order ids (the reference you set when creating a task). POST /v2/get_job_details_by_order_id.

ParameterTypeDescription
order_ids *arrayOrder ids, e.g. ["P000469"].
include_task_historybooleanInclude each task's status history.

tookan_get_task_stats Task statistics

Task counts per status (e.g. successful vs failed), optionally for one task type, one team and a date range. Task status codes: 0 assigned, 1 started, 2 successful, 3 failed, 4 in progress/arrived, 6 unassigned, 7 accepted/acknowledged, 8 declined, 9 cancelled, 10 deleted. POST /v2/user_task_stats.

ParameterTypeDescription
end_datestringEnd date, YYYY-MM-DD.
job_statusarrayOnly these statuses, e.g. [2, 3].
job_typeTask type: 0 = pickup, 1 = delivery, 2 = appointment, 3 = field workforce (FOS).
start_datestringStart date, YYYY-MM-DD.
team_idintegerOnly tasks of this team.

tookan_list_agents List agents

List agents (drivers / field workers; Tookan calls them fleets) with fleet_id, name, phone, tags, team and live status (0 available, 1 offline, 2 busy). Filter by name, tags, availability or fleet ids. The API returns the whole list; this tool returns a window (limit/offset, next_offset). POST /v2/get_all_fleets.

ParameterTypeDescription
fleet_idsarrayOnly these agent ids.
fleet_type1 = captive agents, 2 = freelancers.
include_team_idbooleanInclude each agent's team id.
limitintegerMax items to return (default 50, max 200).
match_any_tagbooleanWith tags: true = agents having ANY of the tags, false = ALL of them.
namestringOnly agents whose name matches this text.
offsetintegerItems to skip (use next_offset from the previous call).
status0 = only free agents, 1 = only busy agents.
tagsstringComma-separated agent tags, e.g. "mini,suv".

tookan_get_agent Get agent profile

One agent's profile (name, email, phone, tags, transport, location, rating, active state) and current tasks. Only profile fields are returned; app tokens and password hashes never are. POST /v2/view_fleet_profile.

ParameterTypeDescription
fleet_id *integerAgent id (fleet_id from tookan_list_agents).

tookan_get_agent_location Get agent location

An agent's last known coordinates (latitude/longitude). POST /v2/get_fleet_location.

ParameterTypeDescription
fleet_id *integerAgent id (fleet_id from tookan_list_agents).

tookan_list_teams List teams

List teams (team_id, name, address, tags). With include_agents, each team also lists its agents. Returns a window (limit/offset, next_offset). POST /v2/view_all_team_only (or /v2/view_teams with agents).

ParameterTypeDescription
include_agentsbooleanAlso return each team's agents (larger reply).
limitintegerMax items to return (default 50, max 200).
offsetintegerItems to skip (use next_offset from the previous call).

tookan_list_customers List customers

List customers (customer_id, name, phone, email, address), optionally searched by name or phone. Paginated: one Tookan page per call (page, default 1). POST /v2/get_all_customers.

ParameterTypeDescription
namestringSearch by customer name.
pageintegerPage number (default 1). Tookan pages are a fixed size.
phonestringSearch by customer phone number.

tookan_find_customer_by_phone Find customer by phone

Find customers by exact phone number. POST /v2/find_customer_with_phone.

ParameterTypeDescription
phone *stringPhone number, e.g. "9897416008" or "+19897416008".

tookan_get_customer Get customer profile

One customer's profile (contact details, address, coordinates). POST /v2/view_customer_profile.

ParameterTypeDescription
customer_id *integerCustomer id (from tookan_list_customers).

tookan_create_delivery_task Create a delivery task

WRITE: create a delivery task (job) for a customer address, due by job_delivery_datetime in the given timezone. Optionally assign it to an agent (fleet_id) or team, or let Tookan auto-assign it within the team. Returns job_id and tracking link. Always uses the address given here, not one saved for the customer's phone (ignore_customer_lat_long 1). POST /v2/create_task (has_pickup 0, has_delivery 1, layout_type 0).

ParameterTypeDescription
customer_address *stringDelivery address.
job_delivery_datetime *stringDeliver before this local time, YYYY-MM-DD HH:MM:SS.
timezone *integerMinutes to ADD to local time to get UTC (Tookan's convention): IST = -330, CET = -60, EST = 300, PST = 480.
auto_assignmentbooleanLet Tookan auto-assign the task to an agent of team_id.
customer_emailstringCustomer email.
customer_phonestringCustomer phone, e.g. "+12015555555".
customer_usernamestringCustomer name.
fleet_idintegerAgent to assign the task to (from tookan_list_agents).
job_descriptionstringWhat is to be delivered.
latitudestringDelivery latitude (else Tookan geocodes the address).
longitudestringDelivery longitude.
notifybooleanSend the customer/agent notifications.
order_idstringYour own reference for the task.
tagsstringComma-separated agent tags used by auto-assignment.
team_idintegerTeam to put the task in (from tookan_list_teams).

tookan_assign_agent_to_task Assign an agent to a task

WRITE: assign (or reassign) a task to an agent of a team; replaces any previous agent. Notifies the agent unless notify is false (so repeating the call notifies again). POST /v2/assign_fleet_to_task.

ParameterTypeDescription
fleet_id *integerAgent id (from tookan_list_agents).
job_id *integerTask (job) id.
team_id *integerThe agent's team id (from tookan_list_teams).
notifybooleanNotify the agent (default true).

tookan_update_task_status Update task status

WRITE (DESTRUCTIVE): force a task's status, overriding the agent app. Completing (2 successful, 3 failed) or cancelling (9) closes the task and notifies per the account's settings; confirm with the user first. Deleting (10) is not offered. Settable: 0 assigned, 1 started, 2 successful, 3 failed, 4 arrived, 6 unassigned, 7 accepted, 8 declined, 9 cancelled. POST /v2/update_task_status.

ParameterTypeDescription
job_id *integerTask (job) id.
job_status *New status code (0-4, 6-9; 10 deleted is not allowed).