Releases: costs-to-expect/api
Releases · costs-to-expect/api
Added "Budget" support and fixed some validation issues
Added
- Added full support for the
budget
item type, all endpoints.
Changed
- Updated the landing page image for the 'Budget' App.
- Updated the descriptions for all
item
OPTIONS endpoint responses, the descriptions are now specific to the item type`. - Updated the README, added additional Apps and improved the content in general.
Fixed
- Corrected PATCH and POST validation for
items
, execution will stop and return immediately. - Corrected an indentation issue in the CHANGELOG.
Added support for Yatzy
Added
- Added the "Yatzy" item subtype to support the new Yatzy game scorer.
Changed
- Updated the landing page, added "Expense" and "Yatzy".
Fixed
- Corrected a return type in a model, possible to be NULL.
- Corrections to the landing page
Added logging for items and a new landing page
Added
- Added a new landing page, mirrors the new "Budget" and "Yahtzee" landing pages.
- Added "Logging" for items, log entries can only be added and will be deleted along with the relevant item, new routes below
- GET
v3/resource-types/{resource_type_id}/resources/{resource_id}/items/{item_id}/log
- OPTIONS
v3/resource-types/{resource_type_id}/resources/{resource_id}/items/{item_id}/log
- POST
v3/resource-types/{resource_type_id}/resources/{resource_id}/items/{item_id}/log
- GET
v3/resource-types/{resource_type_id}/resources/{resource_id}/items/{item_id}/log/{item_log_id}
- OPTIONS
v3/resource-types/{resource_type_id}/resources/{resource_id}/items/{item_id}/log/{item_log_id}
Changed
- Switched to Bootstrap 5.
- We have updated the README to detail other Apps which use the API.
Fixed
- Added a missing PATCH route to the README.
- Corrected the description in an OPTIONS request.
Removed
- JQuery removed from dependencies.
"Budget" `item-type`
Added
- We have added the "budget"
item-type
, required for the Budging app.
Changed
- Updated our tests to be aware of the new
item-type
. - Updated all out back-end dependencies.
Document X-Skip-Cache
Changed
- Updated the README to document the
X-Skip-Cache
header.
Fixed
- Corrected the case for the
X-Skip-Cache
header.
Adjust category assignment limit
Changed
- Updated the limit for category assignments for the
game
item type.
v3.00.0
Added
- We have added a keyed data endpoint, allows us to store arbitrary data for games, later, we will add support for keyed data below the
allocated-expense
item-type. - We have added an
include-players
parameter for the items collection and show requests when fetching games.
Changed
- The validation error for a non distinct category is not based on the resource type/item type combination. For expenses the message refers to categories, for the game item type the message refers to players.
Fixed
- The fallback route returns a 404 status code along with the existing message.
- Added a lang file for
parameters-show
for allocated expenses. - We have updated model calls in the manage controllers, using
$viewable_resource_types
when they should be using$permitted_resource_types
. - Minor refactoring and clean-up.
Removed
- We have removed the
simple-expense
andsimple-item
item types. Simple expense are covered by Allocated expenses and Simple items don't have a place inside the service at the present time.
Changes required for the Yahtzee app
Added
- We have added an
item-type
filter to the resource type collection, you can limit what resource types to return. - We have added an
item-subtype
filter to the resource collection, you can limit what resources to return. - We have added the 'Yahtzee' item subtype.
- We have updated our backend dependencies.
- Lots of refactoring
Fixed
- Renamed a lang file, the parameters-show config file should be using the parameters-show lang file.
v2.25.0 - Soft Release
Added
- We allow the
collection
parameter forsimple-item
item-type collections. - We have added tests for subcategory management, found another bug, whoopee!
- We have added tests for item type responses.
- We have added an option response tests for the resource types collection and a resource type.
- We have added additional resource type tests and created/updated the json-schema files as necessary.
- We have added a catch-all route for non-matching routes.
Changed
- We have renamed the tests directory and corrected the namespaces.
- We are continuing to update out routes to named routes.
- We have moved additional responses to the response class.
- We have updated more response, if a collection is included in a response a
uri
field will contain the relative URI to the relevant collection. - We have adjusted the layout of the test section in the README and added a note explaining the meaning of 'Non yet'.
- We have updated the response when attempting to delete an item with category assignments, rather than return a generic foreign key error, we specifically mention that there are category assignments that need to be removed first.
- We have cleaned up the response description lang file.
Fixed
- Removed an output in a test.
- Updated the route middleware, invalid decodes should return a 403 for the route.
- Added a unique validation rule for emails, don't leave the check to the database.
- Corrected the descriptions in the OPTIONS requests for
item
summaries. - The allowed values for
winner_id
should be a category assigned to the item, not all the categories assigned to the resource type.
Item type refactoring and more tests
Added
- We have added our first schema files for OPTIONS responses and started working on the tests.
- We have added tests for category management, found one bug when creating the tests.
Changed
- We have updated our response class for OPTIONS responses, we now allow parameters to be defined for POST requests. One example of where we need this is the create password POST request,
password
andpassword_confirmation
are required fields, however,token
andemail
are required parameters. Before this update, you had to parse the returned error of read the OPTIONS request description. - We have started splitting config files, a config file should be for one purpose.
- We have spent quite a bit of time reviewing the API structure and refactoring. We have removed unnecessary complexity, renamed classes and methods to describe intent more clearly and removed pointless base classes.
- We have reworked how allowed values are generated for the different item types, allowed values for fields and parameters have been split, and we have removed all abstraction.
- We have removed some route validation files which didn't do anything useful after all the item type work.
- We have reworked the responses class, removed exception parameters when not necessary, pass in an exception if thrown and now delegated responsibility to the responses class to decide if the exception should be returned in the response.
- We have upgraded the API to Laravel 9 and PHP 8.1.
Fixed
- Options request incorrect for the
auth.register
endpoint (Test added). - Options requests returning response twice.
- Type corrected in OPTIONS response, authentication status/requirements now a boolean, not a string.
- Minor correction to the description of two POST endpoints.
- Corrected a type in the OPTIONS response for the month parameter.
- Corrected the
partial-transfer
JSON schema file. - Allowed values not showing for
category
on GET endpoints. - Inconsistent usage of the responses helper.
- Category validator allowed duplicate names due to incorrect params, caught by model.
Removed
- We have removed the
ItemType
base class and all the child classes. - We have removed a redundant validation class and moved the response method into the main response class.