Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/davenaugler/assignment_10_spoonacular_rest_api
Using Spoonacular's API to Generate Meal Plan for the Day and Week, with Nutritional Information
https://github.com/davenaugler/assignment_10_spoonacular_rest_api
java maven spring-boot
Last synced: about 2 months ago
JSON representation
Using Spoonacular's API to Generate Meal Plan for the Day and Week, with Nutritional Information
- Host: GitHub
- URL: https://github.com/davenaugler/assignment_10_spoonacular_rest_api
- Owner: davenaugler
- Created: 2024-01-13T20:57:24.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-02-02T16:45:05.000Z (12 months ago)
- Last Synced: 2024-02-02T17:46:03.136Z (12 months ago)
- Topics: java, maven, spring-boot
- Language: Java
- Homepage:
- Size: 79.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Assignment_10_Spoonacular_Rest_API
## Get Spoonacular apiKey
1. Go to https://spoonacular.com/food-api/console#Dashboard
2. Create an account and grab a free apiKey
3. Within `src/main/resources/application.properties` replace `add_your_apiKey_here` with your apiKey
- Thank you **Z** for reaching out and brining this to my attention.
## Start App via
1. Clone repo
2. Run the app
3. Navigate to `http://localhost:8080/mealplanner/day` and `http://localhost:8080/mealplanner/week` to see the daily and weekly options via Spoonacular's Rest API.
- Refresh browser to view other options## Application Packages Contain
- **Config Package:** This package manages Spoonacular configurations for the project
- **Controller Package:** This package contains the controller for this application
- **DTOs (Data Transfer Objects):** DTO structures the data as well as POJO's for the app
- **Model Package:** This package contains the data models for `DayResponse` and `WeekResponse`
- **Service Package:** This package contains the business logic
- **Assignment10Application:** Contains the static void main for the application
- **application.properties:** Stores my Spoonacular API key and URL components here.
- **Unit Test:** Contains Spoonacular API Unit Tests
- A work in progress.## Structure for Spoonacular Rest API Application
```CSS
src
└── main
├── java
│ └── com.spoonacular
│ └── .Assignment_10
│ ├── config
│ │ └── RestTemplateConfig.java
│ │ └── SpoonacularProperties.java
│ ├── controller
│ │ └── MealPlannerController.java
│ ├── domain
│ │ └── Meals.java
│ │ └── Nutrients.java
│ ├── dto
│ │ └── Meals.java
│ │ └── Nutrients.java
│ │ └── Week.java
│ ├── model
│ │ └── DayResponse.java
│ │ └── WeekResponse.java
│ ├── service
│ │ ├── MealPlannerService.java
│ └── Assignment10Application.java
└── resources
└── application.properties```