{"id":21205884,"url":"https://github.com/shiftkey-labs/api-workshop","last_synced_at":"2025-07-01T05:05:20.234Z","repository":{"id":263488645,"uuid":"890569142","full_name":"shiftkey-labs/api-workshop","owner":"shiftkey-labs","description":"Sample Flask and Node code files for explaining how APIs work. Includes docs and presentation.","archived":false,"fork":false,"pushed_at":"2024-11-18T19:59:19.000Z","size":4547,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-03-14T23:11:22.975Z","etag":null,"topics":["api","flask","javascript","nodejs","python","rest-api"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/shiftkey-labs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-18T19:54:54.000Z","updated_at":"2024-11-18T20:02:30.000Z","dependencies_parsed_at":"2024-11-18T21:07:38.047Z","dependency_job_id":null,"html_url":"https://github.com/shiftkey-labs/api-workshop","commit_stats":null,"previous_names":["shiftkey-labs/api-workshop"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/shiftkey-labs/api-workshop","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiftkey-labs%2Fapi-workshop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiftkey-labs%2Fapi-workshop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiftkey-labs%2Fapi-workshop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiftkey-labs%2Fapi-workshop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shiftkey-labs","download_url":"https://codeload.github.com/shiftkey-labs/api-workshop/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiftkey-labs%2Fapi-workshop/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262900186,"owners_count":23381662,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","flask","javascript","nodejs","python","rest-api"],"created_at":"2024-11-20T20:53:32.395Z","updated_at":"2025-07-01T05:05:20.208Z","avatar_url":"https://github.com/shiftkey-labs.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# APIs Workshop\n\nThis repository contains two implementations of a simple API for the \"Say Hello to APIs\" workshop. Both implementations demonstrate the same functionality, one using Python with Flask and the other using Node.js with Express.\n\n---\n\n## Project Structure\n\n```plaintext\n.\n├── js-api/\n│   ├── app.js        # Node.js Express API implementation\n│   ├── README.md     # Instructions for running the Node.js API\n├── py-api/\n│   ├── app.py        # Python Flask API implementation\n│   ├── README.md     # Instructions for running the Flask API\n└── README.md         # Root README file (this file)\n```\n\n---\n\n## API Features\n\n1. **Health Check Endpoint**\n\n   - Verifies if the server is running.\n\n2. **Get Drinks Endpoint**\n\n   - Retrieves a list of drinks or filters drinks based on a query parameter.\n\n3. **Add Drink Endpoint**\n\n   - Allows adding a new drink by sending JSON data in a `POST` request.\n\n4. **Restricted Access Endpoint**\n   - Simulates restricted access with a `403 Forbidden` response.\n\n---\n\n## Prerequisites\n\n- **For Python Flask**: Python 3.7 or higher\n- **For Node.js Express**: Node.js v14 or higher\n\n---\n\n## Quick Start Guide\n\n### Run the Python Flask API\n\n1. Navigate to the `py-api` directory:\n\n   ```bash\n   cd py-api\n   ```\n\n2. Follow the instructions in `py-api/README.md` to set up and run the Flask API.\n\n### Run the Node.js Express API\n\n1. Navigate to the `js-api` directory:\n\n   ```bash\n   cd js-api\n   ```\n\n2. Follow the instructions in `js-api/README.md` to set up and run the Express API.\n\n---\n\n## Testing the APIs\n\n- Use tools like `curl` or `Postman` to test the APIs.\n- Endpoints for both APIs are identical, ensuring consistent demonstration across platforms.\n\n---\n\n## Contributing\n\nFeel free to fork this repository and submit pull requests to enhance or modify the APIs.\n\n---\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshiftkey-labs%2Fapi-workshop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshiftkey-labs%2Fapi-workshop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshiftkey-labs%2Fapi-workshop/lists"}