The API should have the following functionality for the packer-plugins-hashicups. The packer-plugins-hashicups will be used to teach practitioners how to create new Packer plugins and hack existing providers.
The plugins' main idea is to create customized coffees with different ingredient quantities from the ones available in the "menu". For example a Packer Spiced Latte with 50ml of espresso instead of 40ml.
JWT Token
Any endpoint that needs auth must have this header: Authorization: Bearer <token>. It will be a JWT token containing the user_id, username, and the token expiration date.
The API should have the following functionality for the
packer-plugins-hashicups
. Thepacker-plugins-hashicups
will be used to teach practitioners how to create new Packer plugins and hack existing providers.The plugins' main idea is to create customized coffees with different ingredient quantities from the ones available in the "menu". For example a
Packer Spiced Latte
with 50ml ofespresso
instead of 40ml.JWT Token
Any endpoint that needs auth must have this header:
Authorization: Bearer <token>
. It will be a JWT token containing the user_id, username, and the token expiration date.Endpoints
POST
/coffees
- needs auth{'id': "", "name": "'', "teaser": "", "description": "" }
POST
/coffees/{id:[0-9]+}/ingredients
- needs auth{"coffee_id": "", "ingredient_id": '"", "quantity": "", "unit": "" }