Changelog
Contents
This page tracks behaviour changes to the API plugin. Older changes that predate the introduction of this changelog are not listed.
Unreleased
Added
- Real HTTP status codes. Endpoints now return
200,201,400,401,404,500based on the outcome instead of always200. Thestatus: "0"|"1"body field is kept for back-compat. See Error responses. - Full page object on create and edit.
POST /api/pagesandPUT /api/pages/{key}now return the complete page object (title, content, uuid, etc.) underdata, not just{key}. Thekeyfield is still present. metablock on list responses.GET /api/pagesincludesmeta.total,meta.pageNumber,meta.pageSize, andmeta.hasMorefor pagination.scheduledfilter onGET /api/pagesto include scheduled pages in the listing.
Changed
POST /api/pagesreturns201 Createdon success.GET /api/pages/{key},PUT /api/pages/{key},DELETE /api/pages/{key}return404 Not Foundwhen the page does not exist.GET /api/tags/{key},GET /api/categories/{key},GET /api/users/{username}return404when not found.
Fixed
- Pagination crash past the end. Requests with a
pageNumberpast the last page (or with a non-positivepageNumber/numberOfItems) used to crash the API. They now return200with an emptydataarray andmeta.hasMore: false. - Double-encoding on form-encoded inputs. Submitting
title=Cats & Dogsvia form-encoding used to storeCats & Dogs(double-encoded). Values are now sanitised once, by core.
Security
- Generated API tokens are shorter (256 bits / 64 hex characters instead of 512 bits / 128 hex characters). Existing tokens continue to work; new installs get the shorter format.