Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save celeroncoder/608e3dad0b2e9851f615f3a13433fd2e to your computer and use it in GitHub Desktop.
Save celeroncoder/608e3dad0b2e9851f615f3a13433fd2e to your computer and use it in GitHub Desktop.
GDSC-Team-Recruitment-Web-Domain-Task-Round-GuideLines

Follow this guidelines for the TODO API:

Create the following routes:

  1. GET ALL Todos [GET /todo]
    • Response:
      {
        "data": [
          {
            "id": string;
            "title": string;
            "description": string;
            "completed": boolean;
          }
        ]
      }
  2. Get One Todo using ID [GET /todo/<id>]:
    • Request:
      • params
        {
          "id": "string|int"
        }
    • Response:
      {
        "data": {
          "id": "string";
          "title": "string";
          "description": "string";
          "completed": "boolean";
        }
      }
  3. Update Todo Item [PUT /todo/<id>]:
    • Request:
      • Body:
        {
          "title": "string"; // optional
          "description": "string"; // optional
          "completed": "boolean"; // optional
        }
    • Response:
      {
        "data": {
          "id": "string";
          "title": "string";
          "description": "string";
          "completed": "boolean";
        }
      }
  4. Create Todo Item [POST /todo/]:
    • Request:
      • Body:
        {
          "title": "string"; // optional
          "description": "string"; // optional
          "completed": "boolean"; // optional
        }
    • Response:
      {
        "data": {
          "id": "string";
          "title": "string";
          "description": "string";
          "completed": "boolean";
        }
      }
  5. Delete Todo Item [DELETE /todo/<id>]:
    • Request:
      • params:
        {
          "id": "string|int"
        }
    • Response: 200 OK
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment