Allows plugins to register HTTP routes.
See the service documentation for more details.
Adds an auth policy to the router. This is used to allow unauthenticated or cookie based access to parts of a plugin's API.
The paths given follow the same pattern as the routers given to the use method, that is, they are relative to the plugin's base URL, and can contain placeholders.
use
http.addAuthPolicy({ path: '/static/:id', allow: 'user-cookie',}); Copy
http.addAuthPolicy({ path: '/static/:id', allow: 'user-cookie',});
This allows limited access tokens via cookies on the /api/<plugin-id>/static/* paths, but not unauthenticated access.
/api/<plugin-id>/static/*
Registers an Express request handler under the plugin's base router. This typically makes its base path /api/<plugin-id>.
/api/<plugin-id>
Allows plugins to register HTTP routes.
See the service documentation for more details.