What are APIs and how to add API Endpoints?
What is an API Endpoint?
API endpoints are the points through which APIs (Application Programming Interface) communicate with the site visitors. These usually involve requests to and from the site visitors and can contain malicious content if not properly filtered.
This setting can be found under the API Security
tab in the settings section of your site. With it,
you will be able to add various API Endpoints to your site. This will allow Polaris to protect them
from malicious attackers.
Adding your API Endpoints
This setting can be found under the API Security tab in your website settings.
To access Settings
, click the drop-down menu on the selected site:
Under SITES
, select your domain and click on Settings
.
On the horizontal menu bar, click API Security
.
To add a new endpoint, click the blue Add Endpoint button. This will expand the interface and allow you to type in the relevant information. There are three fields:
- API Host: Your site name
- Prefix: Already filled in with "/", cannot be edited
- Specification: Please enter your API's OpenAPI 3.0 Specification. This would usually be found in your API's FAQ/knowledge base.
You are also allowed to import your specifications. This can only be done with YAML files.
Once you have filled in or imported all the fields, please click the Save button to add your API Endpoint.
Once the Endpoint has been added, incoming requests to the endpoint will be filtered to ensure that only those with correct query or response formats will be allowed through.
At any time you are able to enable or disable this protection via the slider on the Enabled column. You are also able to edit with the pen button on the Actions column and remove the Endpoint with the bin button.
It is recommended that you update this section whenever you add a new API to your site and enable protection for all APIs.