API - Remove HTTP Auth

Security
Security API

Remove HTTP Auth

The counterpart of update_http_auth: drops the HTTP Basic Auth requirement from an index so clients can query it without a username and password. Your IP access rules are not affected and keep protecting the endpoint.

Endpoint

GET https://opensolr.com/solr_manager/api/remove_http_auth

Parameters

ParameterStatusDescription
emailRequiredYour Opensolr registration email address
api_keyRequiredYour Opensolr API key (master key, or a scoped key that allows this endpoint)
core_nameRequiredThe index to open up

How It Works

After the ownership check, the server hosting the index removes the authentication block from the index’s endpoint configuration and reloads the web server, then the stored credentials are cleared from your account. For a resilient cluster the same is done on every replica, followed by a re-replication, so all endpoints behave identically. The change is live within seconds; a request that used to answer 401 answers 200.

Response

KeyTypeDescription
statusbooltrue on success
msgstringOK from the server; NOT_OWNER_ERROR or ERROR_INVALID_CORE_NAME on failure

Code Examples

$_ cURL

curl -s "https://opensolr.com/solr_manager/api/remove_http_auth?email=YOUR_EMAIL&api_key=YOUR_API_KEY&core_name=my_index"

PHP PHP

$q = http_build_query(['email' => 'YOUR_EMAIL', 'api_key' => 'YOUR_API_KEY', 'core_name' => 'my_index']);
$r = json_decode(file_get_contents("https://opensolr.com/solr_manager/api/remove_http_auth?{$q}"), true);
echo $r['status'] ? 'HTTP auth removed' : $r['msg'];

Py Python

import requests

r = requests.get("https://opensolr.com/solr_manager/api/remove_http_auth",
                 params={"email": "YOUR_EMAIL", "api_key": "YOUR_API_KEY", "core_name": "my_index"}, timeout=60)
print(r.json())

Example Response

{"status": true, "msg": "OK\n"}

Use Cases

  • Switch an index from credentials to IP allow-listing only
  • Open a demo or staging index for a browser-side search UI that cannot hold secrets
  • Rotate credentials cleanly: remove, then set new ones with update_http_auth

Related Documentation

Need help with the Opensolr API? We are here to help.

Contact Support