Actions52
- Advanced Actions
- Api Keys Actions
- Clusters Actions
- Dictionaries Actions
- Indices Actions
- Records Actions
- Rules Actions
- Search Actions
- Synonyms Actions
- Vaults Actions
Overview
This node operation restores a previously deleted API key in an Algolia application. When an API key is deleted, it can be restored to reactivate it with its original permissions and restrictions, except that the validity period is reset to zero (meaning it does not expire). This is useful for managing access control in your Algolia environment, especially if you accidentally delete a key or need to temporarily disable and then re-enable access.
Practical example:
If you have an API key that was deleted but you want to restore it to allow certain services or users to continue accessing your Algolia indices without creating a new key, this operation will help you do that efficiently.
Properties
| Name | Meaning |
|---|---|
| Key | The unique identifier string of the API key to restore (e.g., ALGOLIA_API_KEY). |
Output
The output JSON contains the response from the Algolia API after attempting to restore the API key. This typically includes details about the restored API key such as its ACLs, description, indexes it has access to, and other metadata. No binary data is involved in this operation.
Dependencies
- Requires an API authentication token credential configured in n8n to authenticate requests to the Algolia API.
- The node uses the Algolia REST API endpoint:
POST /1/keys/{key}/restore. - The base URL for requests is constructed using the Algolia Application ID credential.
Troubleshooting
- Invalid or missing API key: If the provided key string is incorrect or does not correspond to a deleted API key, the API may return an error indicating the key cannot be found or restored.
- Permission issues: The API key used for authentication must have sufficient privileges to restore keys; otherwise, the request will fail.
- API limits: Algolia stores up to 1,000 API keys per application. If you have exceeded this limit and the key was permanently deleted due to being the oldest, it cannot be restored.
- Network errors: Ensure that the network connection to Algolia's API endpoint is stable and accessible.