https://github.com/mrintern/flask-api-test
https://github.com/mrintern/flask-api-test
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/mrintern/flask-api-test
- Owner: mrintern
- Created: 2023-09-22T09:50:12.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2023-09-22T10:55:27.000Z (almost 3 years ago)
- Last Synced: 2025-02-10T13:43:50.465Z (over 1 year ago)
- Language: Python
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# flask-api-test
Just a simple repo I made to test out making an api using flask.
## API Usage
### Endpoint: /api/add (POST)
To use this endpoint to add some numbers together, make a POST request to the `/api/add` endpoint with a JSON payload containing a list of numbers. The API will add all the numbers together and return the result.
example using curl: ```curl -X POST -H "Content-Type: application/json" -d '{"numbers": [5, 2343, 2, 10]}' http://127.0.0.1:5000/api/add```