Introduction

Welcome to the documentation for Tassker's REST API. This API provides various endpoints to interact with different features of the Tassker platform. Whether you are building integrations, automations, or accessing user data, this documentation will guide you through the available resources and best practices.

About Tassker

Tassker is a platform designed to streamline task management, collaboration, and communication. Our API allows developers to extend the functionality of Tassker and integrate it seamlessly into their applications and workflows.

Getting Started

To get started with the API, you'll need to understand the authentication process, handle potential errors, and explore the available endpoints. Refer to the links in the sidebar for more detailed information on each section.

Authentication

Authentication is to access protected resources in the Tassker API. Follow the steps below to authenticate your requests:

API Key Authentication ( coming soon!)

Tassker does not use API key authentication as of yet. With the new updates, you will need to include your API key in the headers of your HTTP requests. Obtain your API key by navigating to your Tassker account settings.

Example Request:

                    
                        https://task-manager-api-dun.vercel.app/api/auth/finduser/{email}
                    
                

Example Response:

                  
                    {
                       "message": "User found successfully!",
                        "status": "success",
                        "user": {
                            "age": "34",
                            "country": "Westeros",
                            "email": "jonstark@gmail.com",
                            "firstName": "Jon",
                            "lastName": "Stark",
                            "isAdmin": false,
                            "language": "old english",
                            "timestamp": "1678131594",
                            "tourTaken": "false",
                            "tourtaken": false,
                            "username": "jonstark",
                            "phone": "N/A",
                            "profileImage": "",
                            "password": "",
                            "id": "qEOE8JOtkTVmJ6GLjbPR"
                    }
                  
                

Additional Information

Note some endpoints require specific authentication methods and oher data to return a value. Refer to the documentation for each endpoint to learn more

Errors

Tassker API may return various HTTP status codes to indicate the result of a request. Below are some common error codes along with their meanings:

Error 200: OK

The request was successful. This status code generally indicates that the request was processed without any issues.

Error 201: Created

The resource was successfully created. This status code is often returned when creating a new resource.

Error 400: Bad Request

The request could not be understood or was missing required parameters. Check the request and try again.

Error 404: Not Found

The requested resource could not be found on the server. Verify the URL and try again.

Error 401: Unauthorized

Authentication is required, and the provided credentials are not valid. Make sure to include valid authentication details.

Error 500: Internal Server Error

An unexpected error occurred on the server. Please try again later or contact support if the issue persists.

Endpoints

The Tassker API provides various endpoints to interact with different features of the platform. Below is a list of the available endpoints:

- Users/Auth

The Users/Auth endpoint allows you to authenticate a user and return their information. This endpoint requires a valid email address and password or id to return a value.

endpoints

- Tasks

The Tasks endpoint allows you to create, update, and delete tasks. This endpoint requires a valid user id to return a value.

endpoints

- Boards

The Boards endpoint allows you to create, update, and delete boards. This endpoint requires a valid user id to return a value.

endpoints

Example

The following is an example of a several requests and responses using a test user.

Request

            
              POST /api/auth/login HTTP/1.1
              Host: task-manager-api-dun.vercel.app
              Content-Type: application/json
              Content-Length: 60

              {
                "email": "jonstark@gmail.com",
                "password": "password"
              }
            
          

Response

            
              HTTP/1.1 200 OK
              Content-Type: application/json
              Content-Length: 60

              {
                "message": "User found successfully!",
                "status": "success",
                "user": {
                  "age": "34",
                  "country": "Westeros",
                  "email": "jonstark@gmail.com",
                  "firstName": "Jon",
                  "lastName": "Stark",
                  "isAdmin": false,
                  "language": "old english",
                  "timestamp": "1678131594",
                  "tourtaken": false,
                  "username": "jonstark",
                  "phone": "N/A",
                  "profileImage": "",
                  "password": "",
                  "id": "qEOE8JOtkTVmJ6GLjbPR"
                }
              }
            
          

Request

            
              GET /api/boards/getuserboards/qEOE8JOtkTVmJ6GLjbPR HTTP/1.1
              Host: task-manager-api-dun.vercel.app
              Content-Type: application/json
              Content-Length: 60

              {
                "userid": "qEOE8JOtkTVmJ6GLjbPR"
              }
            
          

Response

            
              HTTP/1.1 200 OK
              Content-Type: application/json
              Content-Length: 60

              {
                "message": "User found successfully!",
                "status": "success",
                "boards":[
                  {
                    "name": "My Board",
                    "id": "qEOE8JOtkTVmJ6GLjbPR",
                    "status": "active",
                  },
                  {
                    "name": "My Board 2",
                    "id": "qEOE8JOtkTVmJ6GLjbPR",
                    "status": "active",
                  }
                ]
                "user": {
                  "age": "34",
                  "country": "Westeros",
                  "email": "jonstark@gmail.com",
                  ...,
                }
              }
            
          

Request

            
              POST /api/tasks/createtask HTTP/1.1
              Host: task-manager-api-dun.vercel.app
              Content-Type: application/json
              Content-Length: 60

              {
                "userid": "qEOE8JOtkTVmJ6GLjbPR",
                "boardid": "...",
                "taskname": "My Task",
                "description": "This is my task",
                "taskstatus": "active",
                "duedate": "2021-09-01",
                "labels": ["label1", "label2"]
              }
            
          

Response

            
              HTTP/1.1 200 OK
              Content-Type: application/json
              Content-Length: 60

              {
                "message": "Task created successfully!",
                "status": "success",
                "task": {
                  "userid": "qEOE8JOtkTVmJ6GLjbPR",
                  "boardid": "...",
                  "taskname": "My Task",
                  "taskdescription": "This is my task",
                  "taskstatus": "active",
                  "duedate": "2021-09-01",
                  "labels": ["label1", "label2"],
                  "taskid": "...",
                  "timestamp": "1678131594",
                }
              }