This module provides a way of creating an managing API keys within SilverStripe. This can be useful for building RESTful
and other APIs.
composer require sminnee/silverstripe-apikey
SecurityAdminprovide interfaces for seeing API keys, and generating new ones. API keys are
RequestMiddlewarewill look for an API key header (default:
X-API-Key) and if it is present, authenticate the
ApiKeyAuthenticatorshould be configured for GraphQL
For regular module usage, use the
RequestMiddleware class. The configuration to apply it is in this module's
but is commented out.
Copy the configuration and add it to your
This will protect all of your frontend routes.
The GraphQL authenticator will work separately from the
RequestMiddleware. If using this module for GraphQL, you will
probably want to disable the
RequestMiddleware. If you run both at the same time you will find that:
This should be considered experimental for now, and used with care. It has not received a security audit.
Module rating system helping users find modules that are well supported. For more on how the rating system works visit Module standards
Score not correct? Let us know there is a problem