On the endpoint list screen for each API, you can create and configure APIs as well as endpoints.
Accessing the screen
In the left sidebar menu, click [API] and select the API you want to look at.
The main menu buttons appear at the top of the endpoint list screen.
Opens the API editor.
|Title||Title of the API (required field).|
|Version||Version of the API (required field).|
|Description||Overview of the API (required field).|
|Add||Click to create the API.|
Redirects to the Swagger UI screen for the current API.
(See: Using Swagger UI to check the data structure of your content for details).
Clears the settings cache of the current API. Any changes to Kuroco's internal behavior clears the cache and applies/reflects the latest version.
Configures the security settings for the current API.
(See: API Security for details.)
To enable CORS, customize the information that the Kuroco server returns to the response header.
The origin configured for CORS is the one assigned in the Content-Security-Policy: frame-ancestors. For example, to access the Kuroco server from the local frontend
http://localhost:8080 as follows.
(See: MDN Web Docs for details.)
|Item||Corresponding response header||Sample |
Updates the settings of the current API. The input fields are the same as for Create new API.
Deletes the current API. Note: Deleted APIs cannot be recovered.
Exports the current API in JSON/YAML format.
The exported configuration file is in Kuroco's own format. To include pre-/post-processing settings, check the "Including pre/post processing blocks" box.
Imports the current API in JSON/YAML format.
Select "Import as new API" to create a new API. Selecting "Import to the current API" updates the current API.
[Add new endpoint]
Opens the "Add new endpoint" pop-up screen.
(See: Reference - API - Endpoint settings for more details.)
A list of endpoints for the current API is displayed below the main menu.
This list appears only after you have added endpoints to a new API. The endpoints are grouped by category.
|Enabled||Indicates whether the API is enabled or disabled.|
|Path||Path of the endpoint.|
|Model||The Kuroco model bound to the endpoint.|
|Operation||The operations associated with the model.|
|Summary||Value specified when creating the endpoint.|
|Authentication||Method of authentication.|
|[Update]||Opens the "Configure endpoint" pop-up screen.|
|[Pre-processing]||Displays the pre-processing settings editor.|
|[Post-processing]||Displays the post-processing settings editor.|
|[Delete]||Deletes the endpoint.|