In the examples on this page, you can use either the
apiKey
or x-api-key
query parameter.Replace
EXAMPLE_COMPANY
with the name provided by your Lucidworks representative.ImportantAPI keys require an apikey realm in Fusion to work. If your Fusion cluster was created prior to Fusion 5.6.0, it lacks the required realm for API keys. Upgrading to Fusion 5.6.0 through 5.10.0 does not create the realm automatically.For more information, see Create an apikey realm.
Manage API keys in the Managed Fusion UI
You can create, delete, and view the names of API keys in the UI:- Navigate to System > Access Control > API Keys.
- Select Add API Key.
- Give the API key a name.
- Assign the appropriate roles to give the API key the correct permissions for your search application.
- Select Generate Key.
- Copy the API key that appears. Save this key in a secure location.
CautionAPI keys are treated like an automatically generated password. They are only visible during the key creation and do not display again. You must copy and securely store the API key to see it again after creation.
Manage API keys with the API
You can useGET
, POST
, and DELETE
HTTP requests to manage your API keys. The following examples use an API key to authenticate. To use an API key in an API request, use the x-api-key
HTTP request header.
Create a new API key
Use aPOST
HTTP request to create a new API key. Assign the appropriate roles to give the API key the correct permissions for your search application.
CautionAPI keys are treated like an automatically generated password. They are only visible during the key creation and do not display again. You must copy and securely store the API key to see it again after creation.
The value of the
key
field is the API key.List all available API keys
Use aGET
HTTP request to view all API keys.
The API key values are not included in the response. You can only access API keys at the time of creation.
Get details about an API key
Use aGET
HTTP request to get the details of a specific API key. You must supply the ID of the API key as part of your request URL.
Delete an API key
Use aDELETE
HTTP request to delete a specific API key. You must supply the ID of the API key as part of your request.
The request returns an HTTP 200 OK
status code when the API key is successfully deleted.
Create an apikey realm
This section only applies to Managed Fusion clusters created prior to Managed Fusion 5.6.0, but have since been updated to 5.6.0 through 5.10.0.
401 Unauthorized
status code:
POST
HTTP request.
This cannot be done in the Managed Fusion UI.