Good news for everyone who connects an app, a front end or another system to ExpressionEngine: Webservice v10.0 is here, with more than a hundred changes. You now see and manage every endpoint in the control panel, send a call with Try it, describe your API with OpenAPI and protect it with rate limiting. Less guessing about your API, more control over it.

Every endpoint in one overview
The add-on now opens on the new Endpoints page. It lists every endpoint of your APIs with its status, calls, errors, average duration, cache hits and last call, for the period you choose. Select endpoints to enable, disable or make them public in one go.
Your API tools get the same overview: download the OpenAPI 3 specification or expose it on /webservice/openapi.json, then import it in Postman or generate a client.

Try a call before you write code
Every endpoint has its own Try it page, which replaces the old Testing tools page. Send a request as yourself, with the credentials of a member or without any, and see the status, the duration, the headers and the formatted response. Copy the request as a cURL command, or pick one of your last five requests to send it again.

Members, comments and categories in the box
The Member, Comment and Category API are now part of the module, so there are no separate packages to install or keep up to date. The Member API follows the registration rules of ExpressionEngine and protects Super Admins. The Comment API follows the rules of the comment form, including moderation, the spam service and the notifications. The Category API is read only and returns categories as a flat list or a tree.
Its own key for every app
Give every app a shortkey with a label, see when it was last used, and revoke it without touching the others. New secrets and shortkeys are generated for you and shown once, then stored as a hash. A member only reaches the APIs you selected for it.
Your credentials can now also travel in the request headers: Authorization: Bearer <shortkey>, Basic auth, X-Api-Key with X-Api-Secret, or X-Session-Id.

Protected against overload and guessing
With rate limiting you set the calls per minute for each member, and for public endpoints per IP address. A call over the limit gets a 429 and is not run, and the X-RateLimit headers tell a client how many calls it has left. These two limits are off until you set them. Failed authentications are limited from the start: after ten in a minute by default, an IP address is locked out for the rest of that minute.
This release also improves the security of the authentication, the sessions, the public endpoints, the Entry API, the API logs and the credentials of the members, so we strongly recommend updating.

See what every call did
The new Log requests setting is on by default and logs every call with its HTTP status and duration, which is also where the statistics on the Endpoints page come from. The Api Logs page now has filters, bulk delete and a CSV export. Need to know why a call is slow or fails? Turn on Debug to log the queries and the response data too.

A cache that does its job
We also found a bug we have to be honest about: the response cache was never used or cleared. That is fixed, and the cache now works per member and per request. The new Cache page shows the cache and hit rate of every endpoint that can be cached, and each endpoint can have its own cache setting and cache time. Responses carry an X-Cache header, and the cache is cleared when an entry is saved or deleted. The cache stays off until you enable it in the settings.

More highlights
- Related data on read_entry:
include=parentsandinclude=structurereplace the separate Parent Relationship and Structure extensions. - View counts:
POST /entry/view_countcounts a view of an entry, for sites that do not use the templates of ExpressionEngine. - Passwords in the Auth API: forgot password, reset password and resend activation are now available through the API.
- CORS: the output headers are added to every response, including errors, and preflight requests are answered.
- Your own API: your own endpoints show up in the overview, on the Try it page and in the OpenAPI specification. A route can have more HTTP methods, such as
PUT|PATCH. - A better members page: filter members by type, status and keyword, and enable, disable or delete them in bulk.
Breaking changes to check before you upgrade
- Webservice 10 requires ExpressionEngine 7.3+ and PHP 8.0+. Still on ExpressionEngine 6? Use the legacy package (
legacy/ee_webservice-v9.2.0.zip). Coming from the old Webservice module, before thereinos_prefix? Update to the legacy package first. - A member only has access to the APIs selected in its member settings, so check these before you update.
- Secrets, shortkeys and the super admin shortkey can no longer be viewed in the control panel. Existing credentials keep working, but shortkeys are now case sensitive and unique. When members shared a shortkey, only the oldest member keeps it.
- The Member and Comment API are off by default, so turn them on when your clients use them. The data and responses of the Member, Comment and Category API have changed.
- The separate Channel, Category Group, Member Group, Config, Template, Template Group and Template Router APIs are discontinued and do not work with this version. The same goes for the Parent Relationship and Structure extensions and the View Count API, which have the replacements listed above.
- HTTP statuses have changed. Errors of the Entry API give a
400,403,404or422instead of a200, alsoNo Entry found. A failed login gives a401. An inactive member, a member without access to the API and a blocked IP address give a403. read_entryreturns every key of an entry, also when the value is empty. In a search,not testnow means does not contain; usenot =testfor the exact not-equal.- A session expires after two hours without a call, or one hour for a member with access to the control panel, and only works with the
User-Agentof the login. - The Free Api(s) setting is replaced by public endpoints and existing free APIs are migrated. A guest only finds
openentries on a public endpoint, and credentials sent to a public endpoint get the same checks as on any other endpoint. - For developers: the
entry_submission_endhook, thecp_js_endhook, theact_routeaction and the undocumented{reinos_webservice_action_url}global have been removed.
Want the complete picture? Every change is listed in the Webservice v10.0.0 changelog. Be sure to read Upgrading to 10.0 before you update, make a backup first and check your API clients afterwards. Curious how it all works together? The video is on the Webservice page. As always, the documentation comes with copy-paste examples, so you can get up and running in no time.