Ok, so the very first version of the API is now live at https://api.taskml.com. In short, it lets you manage simple tasks and projects within workspaces.
Overview
The main items are workspaces (where your stuff lives), projects, and tasks. Note that everything must have a valid parent. i.e. All projects belong to a workspace, and all tasks belong to a project.
workspace
project
task
Users also exist, and must be added to a workspace to be able to edit any project/task within that workspace (more info below).
Authorization
All requests (except ones to create new users) must be made with an Authentication header. i.e.
curl -X "GET" "https://api.taskml.com/tasks" -H "Authorization: Bearer YOUR_API_KEY_HERE" -H "Content-Type: application/json"
Making requests
Endpoints are as follows:
/workspaces
/projects
/tasks
This is a regular RESTful API. i.e.
POST /tasks // Creates a task
GET /tasks // Lists tasks
GET /tasks/:id // Get a single task
PUT /tasks/:id // Update an existing task
DELETE /tasks/:id // Deletes a task
Hereās an example request:
curl --location 'https://api.taskml.com/projects' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"description": "Build a basic version of the API for early feedback and testing.",
"name": "MVP",
"status": "in progress",
"workspace_id": 1
}'
You can use query params to filter list results by any property of the type youāre querying: e.g.
GET /tasks/:id?status=done
Data types
// User
{
"email" => "elon@tesla.com",
"name" => "Elon Musk",
}
// Workspace
{
"name" => "Tesla",
"description" => "For all Tesla projects and tasks.",
}
// Project
{
"name" => "Model 3 refresh",
"description" => "Updating the model 3 to modernize design and streamline manufacturing process.",
"status" => "in progress",
"workspace_id" => 1
}
// Task
{
"name" => "Update design",
"description" => "Update model 3 design using latest design cues from Model S Plaid.",
"status" => "in progress",
"project_id" => 1
}
Task and project statuses must be set to one of the following: ātodoā, āin progressā, ācompleteā, āpausedā, ācanceledā.
Getting started
-
Create a user - POST https://api.taskml.com/users (no authorization header required for this)
-
Create a workspace (using the access key returned in stage 1)
-
Create a project (using the returned workspace id)
-
Create tasks (using the returned project id)
Bonus
You can also invite other users to your workspace, and assign users to tasks/projects by POSTING to /workspace_users, /project_users and /task_users, which have the following data types:
// Workspace user
{
"workspace_id" => 1,
"user_id" => 1,
}
// Project user
{
"project_id" => 1,
"user_id" => 1,
}
// Task user
{
"task_id" => 1,
"user_id" => 1,
}
Hope that helps! If you have any questions, please let me know. š
Ok, so the very first version of the API is now live at https://api.taskml.com. In short, it lets you manage simple tasks and projects within workspaces.
Overview
The main items are workspaces (where your stuff lives), projects, and tasks. Note that everything must have a valid parent. i.e. All projects belong to a workspace, and all tasks belong to a project.
Users also exist, and must be added to a workspace to be able to edit any project/task within that workspace (more info below).
Authorization
All requests (except ones to create new users) must be made with an Authentication header. i.e.
Making requests
Endpoints are as follows:
This is a regular RESTful API. i.e.
Hereās an example request:
You can use query params to filter list results by any property of the type youāre querying: e.g.
Data types
Task and project statuses must be set to one of the following: ātodoā, āin progressā, ācompleteā, āpausedā, ācanceledā.
Getting started
Bonus
You can also invite other users to your workspace, and assign users to tasks/projects by POSTING to /workspace_users, /project_users and /task_users, which have the following data types:
Hope that helps! If you have any questions, please let me know. š
Update. Iāve expanded the info a bit to clarify what data you should send. Hereās an example request:
All data fields are required for all requests, except for ādescriptionā fields.
Update, Iāve removed the need to wrap your params when creating items.
Before:
Now:
This is true when creating all resources (workspaces, projects, tasks, users etc).
canāt try it this week but will try next week
Ok, so slight update. š
Based on feedback, Iāve decided to remove workspaces as theyāre not that useful for personal tasks/projects.
So the new hierarchy is projects -> tasks. And getting started now looks like:
1. Create a user
with:
2. Create a project (using the access key returned in stage 1)
Using Authorization header, and JSON data like:
NB. There is no longer a
workspace_id
field.3. Create tasks (using the returned project id)
Using Authorization header, and JSON data like:
{
}
I will create real documentation in future, apologies if things are a bit confusing in the meantime.
Heads up, all api routes now live at taskml.com/api rather than api.taskml.com.
e.g. https://taskml.com/api/tasks
This is because Iām adding some web endpoints (for sign up/login etc) and donāt want to run multiple servers.
the first link doesnāt work
also there is no upload button on the comments WYSIWYG
not cool changing all the urls from api.taskml.com to taskml.com/api :(
nice
I donāt why the data has to be json but sure
creating projects works
Hey @dorianmariefr, thanks for trying it out. š Yep, sorry the URL was changed, everything is a bit in flux at the moment.
Btw, if you have dev plugin access on ChatGPT, you can also try it out there: Plugins -> Install unverified plugin.
I will try the plugin.
I just want to finish testing the API first.
It seems like it doesnāt return the created users
I canāt create tasks for my projects:
I asked ChatGPT to make ruby code for creating tasks
Certainly! Hereās an example of a Ruby script that creates tasks using the TaskML API:
Make sure to replace
'YOUR_API_KEY'
with your actual API key, and update theproject_id
field with the ID of the project to which you want to assign the task.When you run this script, it will send a POST request to the TaskML API to create a task. If the request is successful (status code 201), it will display the task ID. Otherwise, it will show an error message.
Note: This is a basic example to demonstrate the concept. In a real-world scenario, you may want to handle error cases more robustly and include error handling for network or connection issues.
(no Ctrl-Enter to submit comments?)
So looking good
Hey!
There may be an authorisation issue here. /users will only return users who have projects in common with you. This is similar to e.g. /tasks which returns all tasks in projects you are involved with.
Hmm. Iām not sure the issue here. Possible things that can go wrong:
Note that when you create a project, you are automatically added as a project user for that project, but for other users, they have to be added manually. i.e.