All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- Generic error response and response body schema, named
ErrorandAppErrorrespectively
- [BREAKING CHANGE] All error responses were replaced in favor of the new generic error schema
- [BREAKING CHANGE] In newly-named
Order,CustomerandSalespersonnow reference aPersonelement instead - [BREAKING CHANGE] Rename all instances of
SelltoOrder- Tag
sales->orders - Endpoint
/data/sales->/data/orders- All methods GET, POST, PUT and PATCH
- All subroutes
/confirmation/rejection/completion
- Schemas
Sell->OrderSellProperties->OrderPropertiesSellDetail->OrderDetailSellDetailProperties->OrderDetailProperties
- All uses of the noun in literal descriptions
- Tag
- [BREAKING CHANGE] Standard status codes in replacement of vague
200- All
/data/POST endpoints will return201- Excepting the three subroutes within
/data/orderswhich will return204:/confirmation/rejection/completion
- Excepting the three subroutes within
- All
/data/PUT, PATCH, DELETE and OPTIONS endpoints will return204
- All
- [BREAKING CHANGE] Error response schemas
ForbiddenNotFoundBadRequestBody
- [BREAKING CHANGE] Elements that constitute the concepts of
CustomerandSalesperson- Endpoints
/data/customersand/data/salespeople - Schemas
CustomerandSalesperson - Tags
customersandsalespeople
- Endpoints
- [BREAKING CHANGE] Auth-related resources
- Paths
/public/guest/public/register/public/login/access/access/{resource}
- Unusedd tags
authorizationsession
- Paths
- The following schemas were merged into their original ones
ProductRequiredProperties->ProductSellRequiredProperties->SellUserRequiredProperties->UserUserRoleRequiredProperties->UserRoleImageRequiredProperties->ImagePersonRequiredProperties->PersonProductCategoryRequiredProperties->ProductCategoryProductListRequiredProperties->ProductListShipperRequiredProperties->Shipper
- Bad $ref
- Joined specification documents back into one
PATCHmethods, to partially update data- affected endpoints
/data/products/data/sales/data/users/data/images/data/product_categories/data/shippers/data/product_lists
- all of these are tagged with
partial-update
- affected endpoints
- To support
PATCHmethods, each and every CRUD-related schema was split into three- One schema only has the
propertiesarray from the original one, and is added the suffix-Properties - Another, with the
requiredarray, and is added the suffix-RequiredProperties - The last one extends from both the others, plus includes the rest of the metaproperties
name,description,example, and retains the original name - All of this is true for these following schemas, resulting in the following new ones:
Product->ProductProperties&ProductRequiredPropertiesSell->SellProperties&SellRequiredPropertiesUser->UserProperties&UserRequiredPropertiesImage->ImageProperties&ImageRequiredPropertiesProductCategory->ProductCategoryProperties&ProductCategoryRequiredPropertiesShipper->ShipperProperties&ShipperRequiredPropertiesProductList->ProductListProperties&ProductListRequiredProperties
- This way, each
PATCHmethod only needs a-Propertiesschema, and eachPUT/POSTstill makes use of the original schema.
- One schema only has the
- SuperLinter badge url
- SuperLinter GitHub Action
- Created a second API document
common.trebol-api.jsonfor common components- Moved schemas to this document
DataPageLoginCredentialsUserRegistrationAuthorizedAccessPerson
- Moved responses to this document
PaginatedCollectionForbiddenAuthorizedAccessToResourceAuthorizedAccessToRoutesNotFoundEmptyAllowMethodPOSTAllowMethodGETAllowAllMethodsAllowMethodGET-PUTBadRequestBody
- Rewritten References (
$ref) to load all these components from the second document file if it exists in the same directory
- Moved schemas to this document
- Clean up unused resources
- Refactor (inline) schemas only used once
- Incorrect types for
/data/product_lists(was usingProductCategory)
- Declare global tags
- Incongruent CRUD operations tags
deleteandremoveare now merged asdeletefetch-oneandfetch-manyare now calledread-oneandread-many
- Query parameters specification for
GET /data/product_listsProductListspecific query params arecode,name,codeLikeandnameLike
- Three resources to interact with processing of sales
POST /data/sales/confirmation- Should confirm a given sell that is in aPaidor similar statePOST /data/sales/rejection- Should reject a given sell that is in aPaidor similar statePOST /data/sales/completion- Should mark a sell asCompletedorDelivered, given that it is in aConfirmedor similar state
- New query parameters for
GET /data/sales-afterDate,beforeDateandstatusCode
- Removed some empty security schema specs
- Added missing data type ref to path parameter in
/access/{resource}path - Moved
datequery parameter for/data/salesto be used only in itsGETmethod
- Deprecated resource paths
/public/categories- Since v1.1.0/public/products- Since v1.2.1/public/products/{barcode}- Since v1.2.0
- Means to use
/data/product_list_contentsPOSTaccepts a singleProductentity at a time- Remove most query parameters from
PUTandPOST- Only keep
listCodeas globally supported GETandDELETEdo support them all
- Only keep
- Update descriptions
- Incorrect request body specifications for
/data/product_list_contents - Added a security schema to all methods
- Entity
ProductList- made property
nameoptional
- made property
- Methods in
/dataare now publicly availableGET /data/billing_typesGET /data/productsGET /data/product_listsGET /data/product_list_contentsGET /data/product_categoriesGET /data/shippers
- Path
/public/productswill be superseded by/data/products
- New entity
ProductList- with properties
code,nameandtotalCount
- with properties
- New path
/data/product_lists- supports methods
GET,POST,PUTandDELETE
- supports methods
- New path
/data/product_list_contents- supports methods
GET,POST,PUTandDELETE - requires
listCodein query parameters
- supports methods
- Outdated response refs in some
OPTIONSresources
- Replaced all
/accesssub-paths with wildcard/access/* - Renamed response
AuthorizedAccessToSingleRoutetoAuthorizedAccessToResource - Renamed category-related query parameters in
/data/productsproductCategorytocategoryCodeproductCategoryLiketocategoryCodeLike
- Paths marked for deprecation:
/data/customers/{idNumber}/data/images/{code}/data/product_categories/{parentCode}/data/products/{barcode}/data/sales/{buyOrder}/data/salespeople/{idNumber}/data/users/{name}/public/categories/{parentId}
- Path
/public/products/{barcode}should be superseded with query parameters
- Use ref to predefined response for
/public/register [200 OK] - Missing examples for some specifications of
sortas a query parameter
- Several parameter descriptions
- Entity
ProductCategoryand Path/data/product_categories- property & query parameter
codechanged from typeintegertostring - query parameter
parentCodechanged from typeintegertostring
- property & query parameter
- All GET resources within
/datainclude pagination parameterspageIndex,pageSize,sortBy,sortOrder
- Entity
Receipt- introduce properties
token,taxValue,transportValueandtotalItems
- introduce properties
- Entity
Receipt- rename
amountproperty tototalValue - require properties
tokenandtotalItemsin addition to base schema properties
- rename
- Entity
Sell- include missing property
transportValue- this was wrongly documented as an addition in v1.1.0; changelog was updated
- include missing property
- Path
/data/product_categories- include methods
GET,POST,PUTandDELETEto manage product categories
- include methods
- Path
/data/shippers- include method
GET,POST,PUTandDELETEto manage shippers
- include method
- Entity
Sell- introduce properties
token,taxValue,totalValueandtotalItems
- introduce properties
- Entity
SellDetail- introduce property
unitValue
- introduce property
- Entity
Person- [Breaking change] Property
namesplit into two,firstNameandlastName
- [Breaking change] Property
- Paths in
/datawithout path parameters- updated summary and description
- paging query parameters are now (aptly) named
pageSizeandpageIndex
The following will be removed in the minor version that follows this one. Please follow given advices and use corresponding replacements before that.
- Reduce redundant API resources
/public/categories- use/data/product_categoriesinstead/public/categories/{parentId}- use/data/product_categories?parentCode={}instead
- Replace parameterized paths with simpler paths and use of query parameters (for all available methods)
/data/customers/{idNumber}- use/data/customers?idNumber={}instead/data/images/{code}- use/data/images?code={}instead/data/products/{code}- use/data/products?barcode={}instead/data/sales/{buyOrder}- use/data/sales?buyOrder={}instead/data/salespeople/{idNumber}- use/data/salespeople?idNumber={}instead/data/users/{name}- use/data/users?name={}instead
- All
500 Internal Server Errorresponses, and theUnknownErrorpredefined response
- Tags
- add entity tags to entity-related resources, such as
products,customersandsales
- add entity tags to entity-related resources, such as
- Path
/data/people- change
operationId
- change
- Tags
- instead of
fetch,one,manyandexisting, only usefetch-oneandfetch-many
- instead of
- Entity
Product: include propertydescriptionasstring
- Entity
Address- require properties
firstLine,municipalityandcityas base schema information
- require properties
- Entity
BillingCompany- require property
idNumberas base schema information
- require property
- Entity
Image- require properties
filename,urlandcodeas base schema information - set
codedata type tostring
- require properties
- Entity
Product- require properties
barcodeas base schema information
- require properties
- Entity
ProductCategory- require property
nameas base schema information - fix example
- require property
- Entity
Receipt- require properties
amount,buyOrder,date, andstatusas base schema information - remove
formatmetadata frombuyOrderandamount
- require properties
- Entity
Sell- add description
- require property
detailsin addition to others as base schema information - update description of
billingCompanyproperty
- Entity
SellDetail- require properties
productandunitsas base schema information - add description to both properties
- remove
formatmetadata fromunitsproperty
- require properties
- Entity
SellStatus- add description
- require properties
codeandname - add description to both properties
- update data type of
codetointeger
- Entity
Shipper- add description
- add description to
nameproperty
- Entities
ShopOwnerDetails,UserandUserRole- update description
- Entities
CustomerandSalesperson- require property
personas base schema information - add a description to
personproperty
- require property
- Entities
PaymentTypeandBillingType- require property
nameas base schema information
- require property
- Entity
Sell- include required property
customerasPerson
- include required property
- Path
/data/product_categories/{parentId}- parameter
parentIdrenamed toparentCode
- parameter
- Entity
ProductCategory- property
idrenamed tocode
- property
- Entity
User- require property
nameas base schema information - include property
roleasstring
- require property
First public version.