Skip to content

Integrations

Algolia

Connect Algolia to Alter Vault for secure API access

Use Algolia credentials to make authenticated API calls through Alter Vault without exposing API keys in code.

PropertyValue
Template IDalgolia
CategorySearch
Credential TypeAPI Key

Log in to the Algolia Dashboard

Log in to the Algolia Dashboard at dashboard.algolia.com.

Go to Settings → API Keys

Go to Settings → API Keys at dashboard.algolia.com/account/api-keys/all.

Copy the Admin API Key

Copy the Admin API Key (or create a new one with specific permissions).

Copy the Application ID

Copy the Application ID for the Application ID field.

Open the Developer Portal

Go to portal.alterauth.com and navigate to the application.

Add Algolia

Go to Managed Secrets > Add Provider > Algolia.

Enter credentials

Paste the Admin API Key into the credential field.

Enter the Application ID

Paste the Application ID (e.g. B1G2GM9NG0) into the Application ID field. Alter injects it as the X-Algolia-Application-ID header and derives this credential’s allowed hosts from it — the application’s write, DSN, and fallback search hosts (APPID.algolia.net, APPID-dsn.algolia.net, APPID-1.algolianet.com, APPID-2.algolianet.com, APPID-3.algolianet.com) — so proxied calls can only ever reach the application’s Search API. Algolia’s other APIs (such as Insights and Analytics) live on separate fixed hosts and are not covered by this template. The allowlist cannot be widened or edited separately; rotate the credential with a new Application ID to retarget it.

Save

Click Save. You’ll receive a grant_id to use with the SDK.

from alter_sdk import PendingApproval
response = await alter_app.proxy_request(
HttpMethod.POST,
"https://YOUR_APP_ID-dsn.algolia.net/1/indexes/YOUR_INDEX/query",
grant_id="YOUR_GRANT_ID",
json={"query": "search terms"},
)
if isinstance(response, PendingApproval):
for gate in response.gates:
print("Approval required:", gate.approval_url)
response = await alter_app.await_approval(response.approval_id)

For deleteBy, parameter conditions can target indexName. Current filter and geo-selector fields are accepted, but they are not projected as scalar policy parameters: filters contain case-sensitive expressions, and geo selectors can override each other. Selector conditions, including obsolete params conditions, fail closed. The obsolete params request field is rejected. Use operation, family, or index-level controls for this operation.

Alter policy rules can target these attested operations and families for operation-level and parameter-aware controls.

Operation IDFamiliesMethodProvider pathNotes
searchreadPOST/1/indexes/*/queries—
searchSingleIndexreadPOST/1/indexes/{indexName}/query—
searchForFacetValuesreadPOST/1/indexes/{indexName}/facets/{facetName}/query—
browsereadPOST/1/indexes/{indexName}/browse—
getObjectreadGET/1/indexes/{indexName}/{objectID}—
getObjectsreadPOST/1/indexes/*/objects—
saveObjectwritePOST/1/indexes/{indexName}—
addOrUpdateObjectwritePUT/1/indexes/{indexName}/{objectID}—
partialUpdateObjectwritePOST/1/indexes/{indexName}/{objectID}/partial—
batchdelete, writePOST/1/indexes/{indexName}/batch—
multipleBatchdelete, writePOST/1/indexes/*/batch—
deleteObjectdeleteDELETE/1/indexes/{indexName}/{objectID}—
deleteBydeletePOST/1/indexes/{indexName}/deleteByQuery—
clearObjectsdeletePOST/1/indexes/{indexName}/clear—
deleteIndexdeleteDELETE/1/indexes/{indexName}—
operationIndexdelete, writePOST/1/indexes/{indexName}/operation—
listIndicesreadGET/1/indexes—
getSettingsreadGET/1/indexes/{indexName}/settings—
setSettingsadminPUT/1/indexes/{indexName}/settings—
saveRulewritePUT/1/indexes/{indexName}/rules/{objectID}—
searchRulesreadPOST/1/indexes/{indexName}/rules/search—
saveSynonymwritePUT/1/indexes/{indexName}/synonyms/{objectID}—
searchSynonymsreadPOST/1/indexes/{indexName}/synonyms/search—
getTaskreadGET/1/indexes/{indexName}/task/{taskID}—
getLogsreadGET/1/logs—
addApiKeyadminPOST/1/keysrefused by default: hands the caller a provider credential, or revokes the connection’s own (a credential_minting rule can allow it)
listApiKeysreadGET/1/keysrefused by default: hands the caller a provider credential, or revokes the connection’s own (a credential_minting rule can allow it)
restoreApiKeyadminPOST/1/keys/{key}/restorerefused by default: hands the caller a provider credential, or revokes the connection’s own (a credential_minting rule can allow it)

These operations are in the provider’s published API specification, but Alter has not reviewed them yet, so their families are unknown. Every operation, family or content rule refuses one with operation_unreviewed unless a rule admits it by name, so a broad rule cannot be dodged by calling one. A rule names one by the provider-qualified name in the first column, never by the bare operation ID, which other providers may share. To use one under a rule, list that name in an operation allowlist to allow it, or in a require_approval rule whose every condition names it to hold it for approval; saving such a rule needs an organization admin. A family never admits one. Because an unreviewed operation may create credentials or change account security, admitting one also needs a scoped credential_minting allowance naming the provider and that name. See Unreviewed operations.

Name in a ruleMethodProvider path
algolia:accountCopyIndexGET/accountCopyIndex
algolia:appendSourcePOST/1/security/sources/append
algolia:assignUserIdPOST/1/clusters/mapping
algolia:batchAssignUserIdsPOST/1/clusters/mapping/batch
algolia:batchDictionaryEntriesPOST/1/dictionaries/{dictionaryName}/batch
algolia:browseObjectsGET/browseObjects
algolia:chunkedBatchGET/chunkedBatch
algolia:clearRulesPOST/1/indexes/{indexName}/rules/clear
algolia:clearSynonymsPOST/1/indexes/{indexName}/synonyms/clear
algolia:customDeleteDELETE/{path}
algolia:customGetGET/{path}
algolia:customPostPOST/{path}
algolia:customPutPUT/{path}
algolia:deleteApiKeyDELETE/1/keys/{key}
algolia:deleteObjectsPOST/deleteObjects
algolia:deleteRuleDELETE/1/indexes/{indexName}/rules/{objectID}
algolia:deleteSourceDELETE/1/security/sources/{source}
algolia:deleteSynonymDELETE/1/indexes/{indexName}/synonyms/{objectID}
algolia:generateSecuredApiKeyGET/generateSecuredApiKey
algolia:getApiKeyGET/1/keys/{key}
algolia:getAppTaskGET/1/task/{taskID}
algolia:getDictionaryLanguagesGET/1/dictionaries/*/languages
algolia:getDictionarySettingsGET/1/dictionaries/*/settings
algolia:getRuleGET/1/indexes/{indexName}/rules/{objectID}
algolia:getSourcesGET/1/security/sources
algolia:getSynonymGET/1/indexes/{indexName}/synonyms/{objectID}
algolia:getTopUserIdsGET/1/clusters/mapping/top
algolia:getUserIdGET/1/clusters/mapping/{userID}
algolia:hasPendingMappingsGET/1/clusters/mapping/pending
algolia:indexExistsGET/indexExists
algolia:listClustersGET/1/clusters
algolia:listUserIdsGET/1/clusters/mapping
algolia:partialUpdateObjectsPOST/partialUpdateObjects
algolia:partialUpdateObjectsWithTransformationPOST/partialUpdateObjectsWithTransformation
algolia:removeUserIdDELETE/1/clusters/mapping/{userID}
algolia:replaceAllObjectsGET/replaceAllObjects
algolia:replaceAllObjectsWithTransformationGET/replaceAllObjectsWithTransformation
algolia:replaceSourcesPUT/1/security/sources
algolia:saveObjectsGET/saveObjects
algolia:saveObjectsWithTransformationGET/saveObjectsWithTransformation
algolia:saveRulesPOST/1/indexes/{indexName}/rules/batch
algolia:saveSynonymsPOST/1/indexes/{indexName}/synonyms/batch
algolia:searchDictionaryEntriesPOST/1/dictionaries/{dictionaryName}/search
algolia:searchUserIdsPOST/1/clusters/mapping/search
algolia:setClientApiKeyGET/setClientApiKey
algolia:setDictionarySettingsPUT/1/dictionaries/*/settings
algolia:updateApiKeyPUT/1/keys/{key}
algolia:waitForApiKeyGET/waitForApiKey
algolia:waitForAppTaskGET/waitForAppTask
algolia:waitForTaskGET/waitForTask

Report an issue with this page

Necessary

Required for sign-in, security, authorization, and remembering your choices.

Always active

Analytics

Helps us understand how our website, product, and documentation are used.

Performance diagnostics

Uses performance tracing and privacy-masked session replay to diagnose problems.

Advertising

Shares visits and sign-ups with Meta, Reddit, and X so we can measure which of our ads work.

You can change these choices at any time from Cookie settings.