Skip to content

esdd1995/azure-functions-todo-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Todo API for Azure Functions (Node.js)

Deploy to Azure MIT License

This streamlined Todo API leverages Azure Functions and Node.js to manage tasks.

Note: Entries are stored in-memory, so restarting the server clears all data.

API Reference

Route Description
GET /api/ Retrieves server information
GET /api/users/:userId/tasks Fetches tasks for a user (creates user if needed)
POST /api/users/:userId/tasks Adds a new task for a user (creates user if needed). Payload: { "description": "<task_description>" }
PATCH /api/users/:userId/tasks/:taskId Updates a specific task. Payload: { "completed": <boolean> }
DELETE /api/users/:userId/tasks/:taskId Deletes a specific task

Run Locally

Prerequisites:

  1. Navigate to the project directory: cd api && npm install
  2. Start the API server: npm start (Accessible at http://localhost:7071/api/)

Deploy to Azure

Requirements:

Windows Users:

For script execution, consider using either Windows Subsystem for Linux (WSL) (https://learn.microsoft.com/en-us/windows/wsl/) or Git Bash (https://git-scm.com/downloads).

  1. Run .azure/setup.sh and follow the on-screen instructions. The initial deployment will start automatically.

Subsequent commits to the repository will trigger automatic redeployments using GitHub Actions (https://github.com/features/actions).

Cleanup:

To remove deployed resources, execute .azure/setup.sh --terminate.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published