<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>API Reference Archives - SearchStax Docs</title>
	<atom:link href="https://www.searchstax.com/docs/category/managed-solr/mloud-manager/searchstax-api/feed/" rel="self" type="application/rss+xml" />
	<link></link>
	<description>Documentation</description>
	<lastBuildDate>Wed, 15 Jul 2026 20:37:47 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.5</generator>

<image>
	<url>https://www.searchstax.com/docs/wp-content/uploads/2023/10/cropped-favicon-32x32.png</url>
	<title>API Reference Archives - SearchStax Docs</title>
	<link></link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Solr Package Manager API</title>
		<link>https://www.searchstax.com/docs/solr-package-manager-api/</link>
		
		<dc:creator><![CDATA[matt wallace]]></dc:creator>
		<pubDate>Thu, 09 Jul 2026 18:50:24 +0000</pubDate>
				<category><![CDATA[Extensions and Packages APIs]]></category>
		<category><![CDATA[Cloud]]></category>
		<guid isPermaLink="false">https://www.searchstax.com/docs/?p=23909</guid>

					<description><![CDATA[<p>Solr Package Manager API Use the SearchStax API to add custom Solr JAR files with Solr Package Manager. Use Package Manager as the preferred workflow for adding or upgrading custom&#8230; <a class="more-link" href="https://www.searchstax.com/docs/solr-package-manager-api/">Continue reading <span class="screen-reader-text">Solr Package Manager API</span></a></p>
<p>The post <a href="https://www.searchstax.com/docs/solr-package-manager-api/">Solr Package Manager API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h1 id="h-solr-package-manager-api" class="wp-block-heading">Solr Package Manager API</h1>



<hr class="wp-block-separator has-alpha-channel-opacity"/>



<p class="wp-block-paragraph">Use the SearchStax API to add custom Solr JAR files with Solr Package Manager.</p>



<p class="wp-block-paragraph">Use Package Manager as the preferred workflow for adding or upgrading custom JARs on Managed Search deployments where Package Manager is enabled. Instead of adding a custom JAR directory to <code>solrconfig.xml</code> and restarting Solr after each upload, you upload JAR files to Filestore, register package versions, and reference the package name from your configset.</p>



<p class="wp-block-paragraph">Solr Package Manager uses Solr Filestore. Filestore stores and distributes JAR files across Solr nodes in a deployment. Package Manager references those files, assigns package names and versions, and makes the classes in those files available to Solr.</p>



<p class="wp-block-paragraph">Package Manager helps when you upgrade custom JAR files over time. After your configset references a package-prefixed class name, you can upload a new JAR and register a package version without changing the configset, reloading collections, or restarting Solr.</p>



<p class="wp-block-paragraph">During migration, the Custom JARs mechanism and Package Manager can operate at the same time. This lets you move custom classes to Package Manager incrementally. The Custom JARs workflow remains available for legacy deployments and migration cases.</p>



<p class="wp-block-paragraph">For the legacy custom JAR upload and restart workflow, see <a href="https://www.searchstax.com/docs/searchstax-cloud-custom-jars-api/">Solr Custom JARs API</a>.</p>



<h2 id="h-prerequisites" class="wp-block-heading">Prerequisites</h2>



<p class="wp-block-paragraph">Before you start, you need:</p>



<ul class="wp-block-list">
<li>A SearchStax Managed Search deployment running Solr 9 or later</li>



<li>A Premium Managed Search plan, such as Core or higher</li>



<li>A SearchStax user with Technical Contact access or higher</li>



<li>Package Manager enabled on the deployment, or an eligible deployment where Package Manager can be enabled</li>



<li>A SearchStax API token</li>



<li>The SearchStax account name</li>



<li>The deployment UID</li>



<li>A JAR file to upload</li>



<li>Permission to update the relevant Solr configsets</li>



<li>Permission to reload affected Solr collections after configset changes</li>
</ul>



<h2 id="h-api-base-url" class="wp-block-heading">API Base URL</h2>



<p class="wp-block-paragraph">The examples in this article use the following base URL:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: xml; title: ; notranslate">
https://app.searchstax.com/api/rest/v2
</pre></div>


<p class="wp-block-paragraph">The examples use the following variables:</p>



<figure class="wp-block-table"><table class="has-fixed-layout"><thead><tr><th>Variable</th><th>Description</th></tr></thead><tbody><tr><td><code>&lt;account_name&gt;</code></td><td>Your SearchStax account name.</td></tr><tr><td><code>&lt;uid&gt;</code></td><td>The deployment UID.</td></tr><tr><td><code>&lt;token&gt;</code></td><td>Your SearchStax API token.</td></tr><tr><td><code>&lt;filename&gt;</code></td><td>The JAR filename in Filestore. The filename can&#8217;t contain <code>/</code>.</td></tr><tr><td><code>&lt;package_name&gt;</code></td><td>The Solr package name.</td></tr><tr><td><code>&lt;version_number&gt;</code></td><td>The package version.</td></tr></tbody></table></figure>



<h2 id="h-authenticate" class="wp-block-heading">Authenticate</h2>



<p class="wp-block-paragraph">Request an authentication token from the SearchStax API:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s -X POST \
  -H &quot;Content-Type: application/json&quot; \
  -d &#039;{
    &quot;username&quot;: &quot;&lt;username&gt;&quot;,
    &quot;password&quot;: &quot;&lt;password&gt;&quot;,
    &quot;tfa_token&quot;: &quot;&lt;tfa_token&gt;&quot;
  }&#039; \
  https://app.searchstax.com/api/rest/v2/obtain-auth-token/
</pre></div>


<p class="wp-block-paragraph">The <code>tfa_token</code> field is optional unless your SearchStax account requires two-factor authentication.</p>



<p class="wp-block-paragraph">The response includes a token:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;token&quot;: &quot;&lt;token&gt;&quot;
}
</pre></div>


<p class="wp-block-paragraph">For the remaining requests, include the token in the <code>Authorization</code> header:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
Authorization: Token &lt;token&gt;
</pre></div>


<h2 id="h-step-1-check-package-manager-availability" class="wp-block-heading">Step 1: Check Package Manager Availability</h2>



<p class="wp-block-paragraph">Package Manager is available for Solr 9 deployments on eligible Managed Search plans. New Solr 9 deployments created in July 2026 or later have Package Manager enabled by default. Existing Solr 9 deployments created before July 2026 may need Package Manager enabled before you use package-managed JAR files.</p>



<p class="wp-block-paragraph">List existing packages to review the packages registered with the deployment:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/
</pre></div>


<p class="wp-block-paragraph">Successful response: <code>200 OK</code>.</p>



<p class="wp-block-paragraph">Example response:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;result&quot;: {
    &quot;znodeVersion&quot;: 0,
    &quot;packages&quot;: {
      &quot;my-package&quot;: &#x5B;
        {
          &quot;package&quot;: &quot;my-package&quot;,
          &quot;version&quot;: &quot;1.0.0&quot;,
          &quot;files&quot;: &#x5B;
            &quot;/my-plugin-1.0.0.jar&quot;
          ]
        }
      ]
    }
  }
}
</pre></div>


<p class="wp-block-paragraph">If Package Manager isn&#8217;t enabled on your deployment, use the enable endpoint before uploading package-managed JAR files.</p>



<h2 id="h-step-2-enable-package-manager-if-needed" class="wp-block-heading">Step 2: Enable Package Manager, If Needed</h2>



<p class="wp-block-paragraph">If Package Manager isn&#8217;t enabled on an eligible deployment, use the enable endpoint before you use package-managed JAR files:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s -X POST \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/enable/
</pre></div>


<p class="wp-block-paragraph">Successful response: <code>200 OK</code>.</p>



<p class="wp-block-paragraph">Don&#8217;t include a request body unless SearchStax provides one for your deployment or workflow.</p>



<p class="wp-block-paragraph">Note: For deployments created before July 2026, contact SearchStax Support if you can&#8217;t enable Package Manager from your account.</p>



<p class="wp-block-paragraph">Enabling Package Manager may trigger a rolling restart of the deployment.</p>



<h2 id="h-step-3-upload-a-jar-file-to-filestore" class="wp-block-heading">Step 3: Upload a JAR File to Filestore</h2>



<p class="wp-block-paragraph">Upload the JAR file to Solr Filestore:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s -X POST \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  -F &quot;file=@./my-plugin-1.0.0.jar&quot; \
  -F &quot;checksum=&lt;sha512_checksum&gt;&quot; \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/files/
</pre></div>


<p class="wp-block-paragraph">The <code>checksum</code> field is optional. Use this field to provide the SHA-512 checksum of the JAR file.</p>



<p class="wp-block-paragraph">When you upload a JAR through the SearchStax API, SearchStax signs the JAR and uploads the signed JAR to Filestore. Solr validates the signature before accepting the file.</p>



<h3 id="h-request-fields" class="wp-block-heading">Request Fields</h3>



<figure class="wp-block-table"><table class="has-fixed-layout"><thead><tr><th>Field</th><th>Type</th><th>Required</th><th>Description</th></tr></thead><tbody><tr><td><code>file</code></td><td>file</td><td>Yes</td><td>The JAR file to upload.</td></tr><tr><td><code>checksum</code></td><td>string</td><td>No</td><td>The SHA-512 checksum of the JAR file.</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">Successful response: <code>201 Created</code>.</p>



<p class="wp-block-paragraph">Example response:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;file&quot;: &quot;/my-plugin-1.0.0.jar&quot;,
  &quot;responseHeader&quot;: {
    &quot;status&quot;: 0,
    &quot;QTime&quot;: 67
  }
}
</pre></div>


<p class="wp-block-paragraph">If the same file metadata already exists, the response can include a message similar to the following:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;file&quot;: &quot;/my-plugin-1.0.0.jar&quot;,
  &quot;message&quot;: &quot;File with same metadata exists &quot;,
  &quot;responseHeader&quot;: {
    &quot;status&quot;: 0,
    &quot;QTime&quot;: 13
  }
}
</pre></div>


<h2 id="h-step-4-create-a-package-version" class="wp-block-heading">Step 4: Create a Package Version</h2>



<p class="wp-block-paragraph">After the JAR is available in Filestore, register it as a Solr package version:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s -X POST \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  -H &quot;Content-Type: application/json&quot; \
  -d &#039;{
    &quot;add&quot;: {
      &quot;package&quot;: &quot;my-package&quot;,
      &quot;version&quot;: &quot;1.0.0&quot;,
      &quot;files&quot;: &#x5B;
        &quot;/my-plugin-1.0.0.jar&quot;
      ]
    }
  }&#039; \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/
</pre></div>


<h3 id="h-request-fields-0" class="wp-block-heading">Request Fields</h3>



<figure class="wp-block-table"><table class="has-fixed-layout"><thead><tr><th>Field</th><th>Type</th><th>Required</th><th>Description</th></tr></thead><tbody><tr><td><code>add.package</code></td><td>string</td><td>Yes</td><td>The package name.</td></tr><tr><td><code>add.version</code></td><td>string</td><td>Yes</td><td>The package version.</td></tr><tr><td><code>add.files</code></td><td>array</td><td>Yes</td><td>The JAR files to associate with this package version.</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">Successful response: <code>200 OK</code>.</p>



<p class="wp-block-paragraph">Example response:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;responseHeader&quot;: {
    &quot;status&quot;: 0,
    &quot;QTime&quot;: 59
  }
}
</pre></div>


<p class="wp-block-paragraph">If the package version already exists, the response can include a Solr <code>400</code> error:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;responseHeader&quot;: {
    &quot;status&quot;: 400,
    &quot;QTime&quot;: 8
  },
  &quot;error&quot;: {
    &quot;msg&quot;: &quot;Error executing command, errors: &#x5B;...]&quot;,
    &quot;code&quot;: 400
  }
}
</pre></div>


<p class="wp-block-paragraph"><strong>Note</strong>: Solr uses lexicographic ordering, not semantic version ordering, to determine the latest package version. For example, Solr considers <code>1.9.0</code> newer than <code>1.11.0</code>. Choose version labels carefully so the latest intended version sorts correctly.</p>



<h2 id="h-step-5-update-configset-class-references" class="wp-block-heading">Step 5: Update Configset Class References</h2>



<p class="wp-block-paragraph">Update the relevant Solr configset files so Solr references the package-prefixed class name.</p>



<p class="wp-block-paragraph">Before Package Manager, custom classes use a fully qualified class name.</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: xml; title: ; notranslate">
class=&quot;com.example.solr.MyClass&quot;
</pre></div>


<p class="wp-block-paragraph">With Package Manager, prefix the class name with the package name:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: xml; title: ; notranslate">
class=&quot;my-package:com.example.solr.MyClass&quot;
</pre></div>


<p class="wp-block-paragraph">For example, the following request handler:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: xml; title: ; notranslate">
&lt;requestHandler name=&quot;/example&quot; class=&quot;com.example.solr.MyClass&quot; /&gt;
</pre></div>


<p class="wp-block-paragraph">becomes the following:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: xml; title: ; notranslate">
&lt;requestHandler name=&quot;/example&quot; class=&quot;my-package:com.example.solr.MyClass&quot; /&gt;
</pre></div>


<p class="wp-block-paragraph">Upload the modified configset using your normal configset management workflow.</p>



<h2 id="h-step-6-reload-affected-collections" class="wp-block-heading">Step 6: Reload Affected Collections</h2>



<p class="wp-block-paragraph">Reload each Solr collection that uses the updated configset.</p>



<p class="wp-block-paragraph">The reload applies the initial configset changes without requiring a full deployment restart.</p>



<p class="wp-block-paragraph">Use your normal collection reload workflow. This might be a SearchStax workflow, a Solr API workflow, or a process that you coordinate with SearchStax Support.</p>



<h2 id="h-update-a-package-to-a-new-jar-version" class="wp-block-heading">Update a Package to a New JAR Version</h2>



<p class="wp-block-paragraph">To update a package, upload the new JAR file and create a package version with the same package name.</p>



<p class="wp-block-paragraph">For example, upload <code>my-plugin-1.1.0.jar</code>, and then register a new version of <code>my-package</code>:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s -X POST \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  -H &quot;Content-Type: application/json&quot; \
  -d &#039;{
    &quot;add&quot;: {
      &quot;package&quot;: &quot;my-package&quot;,
      &quot;version&quot;: &quot;1.1.0&quot;,
      &quot;files&quot;: &#x5B;
        &quot;/my-plugin-1.1.0.jar&quot;
      ]
    }
  }&#039; \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/
</pre></div>


<p class="wp-block-paragraph">After the configset uses the package-prefixed class name, future package version changes don&#8217;t require another configset class-name change, collection reload, or Solr restart. Solr uses the latest package version automatically.</p>



<p class="wp-block-paragraph"><strong>Note</strong>: Because Solr uses lexicographic ordering to determine the latest package version, confirm that the new version sorts after the previous version.</p>



<h2 id="h-manage-existing-files" class="wp-block-heading">Manage Existing Files</h2>



<h3 id="h-list-files" class="wp-block-heading">List Files</h3>



<p class="wp-block-paragraph">List files in Solr Filestore:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/files/
</pre></div>


<p class="wp-block-paragraph">Successful response: <code>200 OK</code>.</p>



<p class="wp-block-paragraph">Example response:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;files&quot;: {
    &quot;/&quot;: &#x5B;
      {
        &quot;name&quot;: &quot;my-plugin-1.0.0.jar&quot;,
        &quot;size&quot;: 262,
        &quot;timestamp&quot;: 1712345678901,
        &quot;sig&quot;: &#x5B;
          &quot;&lt;signature&gt;&quot;
        ],
        &quot;sha512&quot;: &quot;&lt;sha512_checksum&gt;&quot;
      },
      {
        &quot;name&quot;: &quot;_trusted_&quot;,
        &quot;dir&quot;: true
      }
    ]
  },
  &quot;responseHeader&quot;: {
    &quot;status&quot;: 0,
    &quot;QTime&quot;: 5
  }
}
</pre></div>


<h3 id="h-get-file-metadata" class="wp-block-heading">Get File Metadata</h3>



<p class="wp-block-paragraph">Retrieve metadata for a specific file.</p>



<p class="wp-block-paragraph">The <code>&lt;filename&gt;</code> path parameter can&#8217;t contain <code>/</code>.</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/files/&lt;filename&gt;/
</pre></div>


<p class="wp-block-paragraph">Successful response: <code>200 OK</code>.</p>



<p class="wp-block-paragraph">Example response:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;files&quot;: {
    &quot;/my-plugin-1.0.0.jar&quot;: {
      &quot;name&quot;: &quot;my-plugin-1.0.0.jar&quot;,
      &quot;size&quot;: 262,
      &quot;timestamp&quot;: 1712345678901,
      &quot;sig&quot;: &#x5B;
        &quot;&lt;signature&gt;&quot;
      ],
      &quot;sha512&quot;: &quot;&lt;sha512_checksum&gt;&quot;
    }
  },
  &quot;responseHeader&quot;: {
    &quot;status&quot;: 0,
    &quot;QTime&quot;: 5
  }
}
</pre></div>


<h3 id="h-download-a-file" class="wp-block-heading">Download a File</h3>



<p class="wp-block-paragraph">Download a file from Solr Filestore.</p>



<p class="wp-block-paragraph">The <code>&lt;filename&gt;</code> path parameter can&#8217;t contain <code>/</code>.</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -L \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  -o my-plugin-1.0.0.jar \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/files/&lt;filename&gt;/download/
</pre></div>


<p class="wp-block-paragraph">Successful response: <code>200 OK</code>.</p>



<p class="wp-block-paragraph">Response body: Binary file content. The response is the file itself, not a JSON object.</p>



<h3 id="h-delete-a-file" class="wp-block-heading">Delete a File</h3>



<p class="wp-block-paragraph">Delete a file from Solr Filestore.</p>



<p class="wp-block-paragraph">The <code>&lt;filename&gt;</code> path parameter can&#8217;t contain <code>/</code>.</p>



<p class="wp-block-paragraph">A file can&#8217;t be part of any package when you delete it. Delete the package version that references the file before deleting the file.</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s -X DELETE \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/files/&lt;filename&gt;/
</pre></div>


<p class="wp-block-paragraph">Successful response: <code>200 OK</code>.</p>



<p class="wp-block-paragraph">The response body can include a Solr response header.</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;responseHeader&quot;: {
    &quot;status&quot;: 0,
    &quot;QTime&quot;: 18
  }
}
</pre></div>


<p class="wp-block-paragraph">If the file is still referenced by a package, the response can include a Solr <code>400</code> error:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;responseHeader&quot;: {
    &quot;status&quot;: 400,
    &quot;QTime&quot;: 11
  },
  &quot;error&quot;: {
    &quot;msg&quot;: &quot;jar in use, can&#039;t delete&quot;,
    &quot;code&quot;: 400
  }
}
</pre></div>


<h2 id="h-manage-existing-packages" class="wp-block-heading">Manage Existing Packages</h2>



<h3 id="h-list-packages" class="wp-block-heading">List Packages</h3>



<p class="wp-block-paragraph">List packages registered with Solr Package Manager:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/
</pre></div>


<p class="wp-block-paragraph">Successful response: <code>200 OK</code>.</p>



<p class="wp-block-paragraph">Example response:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;result&quot;: {
    &quot;znodeVersion&quot;: 2,
    &quot;packages&quot;: {
      &quot;my-package&quot;: &#x5B;
        {
          &quot;package&quot;: &quot;my-package&quot;,
          &quot;version&quot;: &quot;1.0.0&quot;,
          &quot;files&quot;: &#x5B;
            &quot;/my-plugin-1.0.0.jar&quot;
          ]
        },
        {
          &quot;package&quot;: &quot;my-package&quot;,
          &quot;version&quot;: &quot;1.1.0&quot;,
          &quot;files&quot;: &#x5B;
            &quot;/my-plugin-1.1.0.jar&quot;
          ]
        }
      ]
    }
  }
}
</pre></div>


<h3 id="h-delete-a-package-version" class="wp-block-heading">Delete a Package Version</h3>



<p class="wp-block-paragraph">Use the <code>delete</code> package command to delete a package version:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
curl -s -X POST \
  -H &quot;Authorization: Token &lt;token&gt;&quot; \
  -H &quot;Content-Type: application/json&quot; \
  -d &#039;{
    &quot;delete&quot;: {
      &quot;package&quot;: &quot;my-package&quot;,
      &quot;version&quot;: &quot;1.0.0&quot;
    }
  }&#039; \
  https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/package-manager/
</pre></div>


<h4 id="h-request-fields-1" class="wp-block-heading">Request Fields</h4>



<figure class="wp-block-table"><table class="has-fixed-layout"><thead><tr><th>Field</th><th>Type</th><th>Required</th><th>Description</th></tr></thead><tbody><tr><td><code>delete.package</code></td><td>string</td><td>Yes</td><td>The package name.</td></tr><tr><td><code>delete.version</code></td><td>string</td><td>Yes</td><td>The package version to delete.</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">Successful response: <code>200 OK</code>.</p>



<p class="wp-block-paragraph">Example response:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;responseHeader&quot;: {
    &quot;status&quot;: 0,
    &quot;QTime&quot;: 10
  }
}
</pre></div>


<p class="wp-block-paragraph">Note: The package delete command uses the same <code>POST /package-manager/</code> endpoint as package creation.</p>



<h2 id="h-endpoint-reference" class="wp-block-heading">Endpoint Reference</h2>



<h3 id="h-package-manager-endpoints" class="wp-block-heading">Package Manager Endpoints</h3>



<figure class="wp-block-table"><table class="has-fixed-layout"><thead><tr><th>Method</th><th>Endpoint</th><th>Description</th><th>Success Status</th></tr></thead><tbody><tr><td><code>GET</code></td><td><code>/account/{account_name}/deployment/{uid}/solr/package-manager/</code></td><td>List packages.</td><td><code>200 OK</code></td></tr><tr><td><code>POST</code></td><td><code>/account/{account_name}/deployment/{uid}/solr/package-manager/</code></td><td>Create a package version or delete a package version.</td><td><code>200 OK</code></td></tr><tr><td><code>POST</code></td><td><code>/account/{account_name}/deployment/{uid}/solr/package-manager/enable/</code></td><td>Enable Package Manager for a deployment.</td><td><code>200 OK</code></td></tr></tbody></table></figure>



<h3 id="h-file-endpoints" class="wp-block-heading">File Endpoints</h3>



<figure class="wp-block-table"><table class="has-fixed-layout"><thead><tr><th>Method</th><th>Endpoint</th><th>Description</th><th>Success Status</th></tr></thead><tbody><tr><td><code>GET</code></td><td><code>/account/{account_name}/deployment/{uid}/solr/package-manager/files/</code></td><td>List files in Filestore.</td><td><code>200 OK</code></td></tr><tr><td><code>POST</code></td><td><code>/account/{account_name}/deployment/{uid}/solr/package-manager/files/</code></td><td>Upload a file to Filestore.</td><td><code>201 Created</code></td></tr><tr><td><code>GET</code></td><td><code>/account/{account_name}/deployment/{uid}/solr/package-manager/files/{filename}/</code></td><td>Get metadata for a file.</td><td><code>200 OK</code></td></tr><tr><td><code>DELETE</code></td><td><code>/account/{account_name}/deployment/{uid}/solr/package-manager/files/{filename}/</code></td><td>Delete a file from Filestore.</td><td><code>200 OK</code></td></tr><tr><td><code>GET</code></td><td><code>/account/{account_name}/deployment/{uid}/solr/package-manager/files/{filename}/download/</code></td><td>Download a file from Filestore.</td><td><code>200 OK</code></td></tr></tbody></table></figure>



<h2 id="h-request-body-reference" class="wp-block-heading">Request Body Reference</h2>



<h3 id="h-upload-file-request" class="wp-block-heading">Upload File Request</h3>



<figure class="wp-block-table"><table class="has-fixed-layout"><thead><tr><th>Field</th><th>Type</th><th>Required</th><th>Description</th></tr></thead><tbody><tr><td><code>file</code></td><td>file</td><td>Yes</td><td>The JAR file to upload.</td></tr><tr><td><code>checksum</code></td><td>string</td><td>No</td><td>The SHA-512 checksum of the JAR file.</td></tr></tbody></table></figure>



<h3 id="h-add-package-version-request" class="wp-block-heading">Add Package Version Request</h3>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;add&quot;: {
    &quot;package&quot;: &quot;my-package&quot;,
    &quot;version&quot;: &quot;1.0.0&quot;,
    &quot;files&quot;: &#x5B;
      &quot;/my-plugin-1.0.0.jar&quot;
    ]
  }
}
</pre></div>


<h3 id="h-delete-package-version-request" class="wp-block-heading">Delete Package Version Request</h3>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
{
  &quot;delete&quot;: {
    &quot;package&quot;: &quot;my-package&quot;,
    &quot;version&quot;: &quot;1.0.0&quot;
  }
}
</pre></div>


<p class="wp-block-paragraph"></p>
<p>The post <a href="https://www.searchstax.com/docs/solr-package-manager-api/">Solr Package Manager API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Managed Search APIs Overview</title>
		<link>https://www.searchstax.com/docs/searchstax-cloud-apis-overview/</link>
					<comments>https://www.searchstax.com/docs/searchstax-cloud-apis-overview/#respond</comments>
		
		<dc:creator><![CDATA[Tom Humbarger]]></dc:creator>
		<pubDate>Wed, 10 May 2023 17:50:08 +0000</pubDate>
				<category><![CDATA[API Reference]]></category>
		<category><![CDATA[Cloud]]></category>
		<guid isPermaLink="false">https://www.searchstax.com/docs/?p=15203</guid>

					<description><![CDATA[<p>Managed Search APIs Overview Overview The SearchStax Managed Search service provides various APIs for supporting the creation, deletion, and management of Solr deployments. Learn more about SearchStax Managed Search Solr&#8230; <a class="more-link" href="https://www.searchstax.com/docs/searchstax-cloud-apis-overview/">Continue reading <span class="screen-reader-text">Managed Search APIs Overview</span></a></p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-apis-overview/">Managed Search APIs Overview</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h1 id="searchstax-managed-solr-provisioning-api-authentication" class="wp-block-heading">Managed Search APIs Overview</h1>



<hr class="wp-block-separator has-css-opacity"/>



<h2 id="overview" class="wp-block-heading">Overview</h2>



<p class="wp-block-paragraph">The SearchStax Managed Search service provides various APIs for supporting the creation, deletion, and management of Solr deployments.</p>



<p class="wp-block-paragraph">Learn more about SearchStax Managed Search Solr APIs:</p>



<ul class="wp-block-list">
<li><a href="https://www.searchstax.com/docs/searchstax-cloud-authentication-api/">Authentication API</a></li>



<li><a href="/docs/searchstax-cloud-users-api/">Users API</a></li>



<li><a href="/docs/searchstax-cloud-basic-auth-api/">Basic Auth API</a></li>



<li><a href="/docs/searchstax-cloud-users-api/">IP Filtering API</a></li>



<li><a href="/docs/searchstax-cloud-deployment-api/">Deployment API</a></li>



<li><a href="/docs/searchstax-cloud-private-vpc-api/">Private VPC API</a></li>



<li><a href="/docs/searchstax-cloud-dns-alias-api/">DNS Alias API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Backup/Restore API</a></li>



<li><a href="/docs/searchstax-cloud-custom-jars-api/">Custom JARs API</a></li>



<li><a href="/docs/searchstax-cloud-tags-api/">Tags API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Alerts API</a></li>



<li><a href="/docs/searchstax-cloud-webhooks-api/">Webhooks API</a></li>



<li><a href="/docs/searchstax-cloud-zookeeper-api/">Zookeeper API</a></li>



<li><a href="https://www.searchstax.com/docs/solr-package-manager-api/">Package Manager API</a></li>
</ul>



<p class="wp-block-paragraph">SearchStax Managed Search deployments also support custom JAR files to add custom analyzers, tokenizers, query parsers and other plugins for Solr deployments. Learn more about using <a href="https://www.searchstax.com/docs/solr-package-manager-api/">Package Manager</a> to manage custom JAR files for SearchStax Managed Search.</p>



<h2 id="questions" class="wp-block-heading">Questions?</h2>



<p class="wp-block-paragraph">Do not hesitate to contact the&nbsp;<a href="mailto:support@searchstax.com?subject=SearchStax%20Cloud%20Provisioning%20API%20–%20Authentication" target="_blank" rel="noreferrer noopener">SearchStax Support Desk</a>.</p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-apis-overview/">Managed Search APIs Overview</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.searchstax.com/docs/searchstax-cloud-apis-overview/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Provisioning API &#8211; Authentication</title>
		<link>https://www.searchstax.com/docs/searchstax-cloud-authentication-api/</link>
					<comments>https://www.searchstax.com/docs/searchstax-cloud-authentication-api/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Thu, 04 Mar 2021 10:27:07 +0000</pubDate>
				<category><![CDATA[Access and Security APIs]]></category>
		<category><![CDATA[Cloud]]></category>
		<guid isPermaLink="false">https://www.searchstax.com/docs/?p=7676</guid>

					<description><![CDATA[<p>Provisioning API &#8211; Authentication Overview The SearchStax Managed Search service provides an API supporting the creation, deletion, and management of Solr deployments. Core and Enterprise Clients Only! The SearchStax&#8230; <a class="more-link" href="https://www.searchstax.com/docs/searchstax-cloud-authentication-api/">Continue reading <span class="screen-reader-text">Provisioning API &#8211; Authentication</span></a></p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-authentication-api/">Provisioning API &#8211; Authentication</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h1 class="wp-block-heading" id="searchstax-managed-solr-provisioning-api-authentication">Provisioning API &#8211; Authentication</h1>



<hr class="wp-block-separator has-css-opacity"/>



<h2 class="wp-block-heading" id="overview">Overview</h2>



<p class="wp-block-paragraph">The SearchStax Managed Search service provides an API supporting the creation, deletion, and management of Solr deployments.</p>



<div class="alert alert-info">
<h3>Core and Enterprise Clients Only!</h3>
<p>The SearchStax API suite is available to our Core and Enterprise
clients only, as noted on our <a href="https://www.searchstax.com/pricing/cloud/">Pricing</a> page. </p>
</div>



<p class="wp-block-paragraph">The Provisioning API uses two methods of authentication appropriate to two levels of security:</p>



<ul class="wp-block-list">
<li><strong>Token Authentication:</strong>&nbsp;Use the username and password of an authorized user to obtain an&nbsp;<em>authentication token</em>. The token authorizes API calls within the normal scope of the user&#8217;s permissions. A token expires after 24 hours.</li>



<li><strong>API Key Authentication:</strong>&nbsp;The API Key authenticates a narrow set of API functions for managing Solr Basic Auth users and Zookeeper configurations in a deployment. The API Key does not expire, but it can be revoked.</li>
</ul>



<p class="wp-block-paragraph">The API can be accessed through any tool that assembles HTTP requests and dispatches them to a server. Among these would be the Python&nbsp;<a href="https://pypi.org/project/coreapi/" target="_blank" rel="noreferrer noopener">coreapi</a>&nbsp;package, the&nbsp;<a href="https://www.postman.com/" target="_blank" rel="noreferrer noopener">Postman</a>&nbsp;tool, and&nbsp;<a href="https://curl.se" target="_blank" rel="noreferrer noopener">cURL</a>. For Windows, use&nbsp;<a href="https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1" target="_blank" rel="noreferrer noopener">PowerShell 7+</a>.</p>



<div class="alert alert-warning">
<h3>Account Owner, Admin, or Technical Contact</h3>
<p>To run the SearchStax Provisioning API, you must be the account Owner,
an account Admin, or a Technical Contact. See <a href="/docs/searchstax-cloud-user-roles/#userroles">SearchStax User Roles</a>.</p>
</div>



<p class="wp-block-paragraph">Symbols enclosed in carets (&lt; and &gt;) such as&nbsp;<strong>&lt;username&gt;</strong>&nbsp;are metavariables. Substitute your local values when you encounter them in the examples.</p>



<p class="wp-block-paragraph">Contents:</p>



<ul class="wp-block-list">
<li><a href="#token">Token Authentication</a>
<ul class="wp-block-list">
<li><a href="#create-auth-token">obtain-auth-token &gt; create</a></li>



<li><a href="#verify-auth-token">verify-auth-token</a></li>
</ul>
</li>



<li><a href="#apikey">API Key Authentication</a>
<ul class="wp-block-list">
<li><a href="#createapikey">account &gt; apikey &gt; create</a></li>



<li><a href="#addkeytodeployment">account &gt; apikey &gt; associate_apikey_to_deployment</a></li>



<li><a href="#keydeployments">account &gt; apikey &gt; apikey_deployments</a></li>



<li><a href="#keydeployments">account &gt; apikey &gt; deployment_apikeys</a></li>



<li><a href="#dissociate" type="internal" id="#dissociate">account > apikey > disassociate_apikey_from_deployment</a></li>



<li><a href="#revokeapikey">account &gt; apikey &gt; revoke</a></li>
</ul>
</li>
</ul>



<p class="wp-block-paragraph">Related Pages:</p>



<ul class="wp-block-list">
<li><a href="/docs/searchstax-cloud-users-api/">Users API</a></li>



<li><a href="/docs/searchstax-cloud-basic-auth-api/">Basic Auth API</a></li>



<li><a href="/docs/searchstax-cloud-users-api/">IP Filtering API</a></li>



<li><a href="/docs/searchstax-cloud-deployment-api/">Deployment API</a></li>



<li><a href="/docs/searchstax-cloud-private-vpc-api/">Private VPC API</a></li>



<li><a href="/docs/searchstax-cloud-dns-alias-api/">DNS Alias API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Backup/Restore API</a></li>



<li><a href="/docs/searchstax-cloud-custom-jars-api/">Custom JARs API</a></li>



<li><a href="/docs/searchstax-cloud-tags-api/">Tags API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Alerts API</a></li>



<li><a href="/docs/searchstax-cloud-webhooks-api/">Webhooks API</a></li>



<li><a href="/docs/searchstax-cloud-zookeeper-api/">Zookeeper API</a></li>
</ul>



<h2 class="wp-block-heading" id="token">Token Authentication</h2>



<p class="wp-block-paragraph">The first step in using the SearchStax API is to obtain an authentication token by logging in to the SearchStax server. The token authorizes subsequent API requests.</p>



<h3 class="wp-block-heading" id="create-auth-token">obtain-auth-token &gt; create</h3>



<p class="wp-block-paragraph">Generates an authentication token for the user of a tenant account. This token expires after 24 hours. If obtain-auth-token API is called within its 24-hour validity window, the token expiration gets extended by another 24 hours.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/obtain-auth-token/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/obtain-auth-token/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The request body should be an &#8220;application/x-www-form-urlencoded&#8221; object to accommodate the non-alphanumeric characters that sometimes appear in usernames and passwords.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>"username=&lt;username>&amp;password=&lt;password>"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">&quot;username=&lt;username&gt;&amp;password=&lt;password&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">&nbsp;</p>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>username</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the email address used when you log into the SearchStax server.</td><td>&#8220;user@company.com&#8221;</td></tr><tr><td><strong>password</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the password associated with that username.</td><td>&#8220;4r36%74m&#8221;</td></tr><tr><td><strong>tfa_token</strong><br><span style="color:#32cd32" class="has-inline-color">optional</span><br>string</td><td>This is a six-digit code supplied by the Google Authenticator to enable <a href="/docs/searchstax-cloud-user-roles/#2FA">two-factor authentication.</a> Each code is good for one minute, so move fast.<br><br>The eight-character backup codes work with no time limit, but only once each.<br><br>If TFA is not enabled for this user account, this token is ignored.  </td><td>&#8220;123456&#8221;<br>or<br>&#8220;noho2x5n&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph"></p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>TOKEN=$(curl -s -H "Content-Type: application/json" -X POST \
       -d "{\"username\":\"$USER\",\"password\":\"$PASSWORD\",\"tfa_token\":\"$TWOFACTOR\"}" \
       https://app.searchstax.com/api/rest/v2/obtain-auth-token/)</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">TOKEN</span><span style="color: #D73A49">=</span><span style="color: #032F62">$(</span><span style="color: #6F42C1">curl</span><span style="color: #032F62"> </span><span style="color: #005CC5">-s</span><span style="color: #032F62"> </span><span style="color: #005CC5">-H</span><span style="color: #032F62"> &quot;Content-Type: application/json&quot; </span><span style="color: #005CC5">-X</span><span style="color: #032F62"> POST </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #032F62">       </span><span style="color: #005CC5">-d</span><span style="color: #032F62"> &quot;{</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">username</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">:</span><span style="color: #005CC5">\&quot;</span><span style="color: #24292E">$USER</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">password</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">:</span><span style="color: #005CC5">\&quot;</span><span style="color: #24292E">$PASSWORD</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">tfa_token</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">:</span><span style="color: #005CC5">\&quot;</span><span style="color: #24292E">$TWOFACTOR</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">}&quot; </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #032F62">       https://app.searchstax.com/api/rest/v2/obtain-auth-token/)</span></span></code></pre></div>



<p class="wp-block-paragraph"><em>If SearchStax will not accept your credentials from Bash, check your password for a $, !, or # character. Bash will try to interpret these characters, changing the text of the password.</em> If special characters in the password are a frequent problem, try the cURL command this way:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>TOKEN=$(curl -s -H "Content-Type: application/x-www-form-urlencoded" -X POST \
  --data-urlencode "username=$USER" \
  --data-urlencode "password=$PASSWORD" \
  --data-urlencode "tfa_token=$TWOFACTOR" \
  https://app.searchstax.com/api/rest/v1/obtain-auth-token/)</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">TOKEN</span><span style="color: #D73A49">=</span><span style="color: #032F62">$(</span><span style="color: #6F42C1">curl</span><span style="color: #032F62"> </span><span style="color: #005CC5">-s</span><span style="color: #032F62"> </span><span style="color: #005CC5">-H</span><span style="color: #032F62"> &quot;Content-Type: application/x-www-form-urlencoded&quot; </span><span style="color: #005CC5">-X</span><span style="color: #032F62"> POST </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #032F62">  </span><span style="color: #005CC5">--data-urlencode</span><span style="color: #032F62"> &quot;username=</span><span style="color: #24292E">$USER</span><span style="color: #032F62">&quot; </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #032F62">  </span><span style="color: #005CC5">--data-urlencode</span><span style="color: #032F62"> &quot;password=</span><span style="color: #24292E">$PASSWORD</span><span style="color: #032F62">&quot; </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #032F62">  </span><span style="color: #005CC5">--data-urlencode</span><span style="color: #032F62"> &quot;tfa_token=</span><span style="color: #24292E">$TWOFACTOR</span><span style="color: #032F62">&quot; </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #032F62">  https://app.searchstax.com/api/rest/v1/obtain-auth-token/)</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/obtainauthtokencreate.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$USER = "username"
$PASSWORD = "password"
$TFA = "123456"

$body = @{
    username=$USER
    password=$PASSWORD
    tfa_token=$TFA
}

$body = $body | ConvertTo-Json

$TOKEN = Invoke-RestMethod -Method Post -Body $body -ContentType 'application/json' `
        -uri "https://app.searchstax.com/api/rest/v2/obtain-auth-token/" 
$TOKEN = $TOKEN.token</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$USER </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;username&quot;</span></span>
<span class="line"><span style="color: #24292E">$PASSWORD </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;password&quot;</span></span>
<span class="line"><span style="color: #24292E">$TFA </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    username</span><span style="color: #D73A49">=</span><span style="color: #24292E">$USER</span></span>
<span class="line"><span style="color: #24292E">    password</span><span style="color: #D73A49">=</span><span style="color: #24292E">$PASSWORD</span></span>
<span class="line"><span style="color: #24292E">    tfa_token</span><span style="color: #D73A49">=</span><span style="color: #24292E">$TFA</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$TOKEN </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">Body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/obtain-auth-token/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$TOKEN </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $TOKEN.token</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing an authorization token.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "token": "aa70cb0a180a0532ae8855f7a1712eeceb81e080"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;token&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;aa70cb0a180a0532ae8855f7a1712eeceb81e080&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<div class="alert alert-info">
<h3>Using the token in Bash</h3>
<p>In the Bash scripts, the authorization token is incorporated directly in the header of the cURL call:</p>
<pre><code>    curl -s -H "Authorization: Token $TOKEN" etc.</code></pre>
</div>



<div class="alert alert-info">
<h3>Using the token in PowerShell</h3>
<p>In the PowerShell scripts, we use the token by assembling a header for the Invoke-RestMethod call. Note that <strong>$TOKEN.token</strong> extracts the actual token number from the Json response.</p>
<pre><code>
$TOKEN = $TOKEN.token

$headers = New-Object "System.Collections.Generic.Dictionary[[String],[String]]"
$headers.Add("Authorization", "Token $TOKEN")

$RESULTS = Invoke-RestMethod -Headers $headers etc. </code></pre>
</div>



<p class="wp-block-paragraph"></p>



<h3 class="wp-block-heading" id="verify-auth-token">verify-auth-token</h3>



<p class="wp-block-paragraph">Verifies if the auth token is valid, or needs to be regenerated.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/v2/verify-auth-token/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/verify-auth-token/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The Authorization header should be passed with the token to verify.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>Authorization "Token &lt;token>"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292e">Authorization &quot;Token &lt;token&gt;&quot;</span></span>
<span class="line"><span style="color: #24292e"></span></span></code></pre></div>



<p class="wp-block-paragraph">&nbsp;</p>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>token</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>The token to verify</td><td>&#8220;XyZ190189898njjhjhjhjhjhj&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph"></p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl -s -H "Content-Type: application/json" -X GET  \
   -H 'authorization: Token a34085b3f9138e35c38c5acc57cdbcf94f9ec6f2' \
   https://app.searchstax.com/api/rest/v2/verify-auth-token/</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">-s</span><span style="color: #24292E"> </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">-X</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E">  </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">   </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;authorization: Token a34085b3f9138e35c38c5acc57cdbcf94f9ec6f2&#39;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">   </span><span style="color: #032F62">https://app.searchstax.com/api/rest/v2/verify-auth-token/</span></span></code></pre></div>



<p class="wp-block-paragraph">When run from Windows (PowerShell):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$TOKEN = "a34085b3f9138e35c95338cc57cdbcf94f9ec6f2"

$headers = New-Object "System.Collections.Generic.Dictionary[&#91;String&#93;,&#91;String&#93;]"
$headers.Add("Authorization", "Token $TOKEN")

Write-Host "Verifying an authentication token..."
Write-Host

$RESULT = Invoke-RestMethod -uri "https://app.searchstax.com/api/rest/v2/verify-auth-token/" `
        -Method Get -Headers $headers #-ContentType 'application/json' 

$RESULT = $RESULT | ConvertTo-Json</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$TOKEN </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;a34085b3f9138e35c95338cc57cdbcf94f9ec6f2&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$headers </span><span style="color: #D73A49">=</span><span style="color: #24292E"> New</span><span style="color: #D73A49">-</span><span style="color: #24292E">Object </span><span style="color: #032F62">&quot;System.Collections.Generic.Dictionary[&#91;String&#93;,&#91;String&#93;]&quot;</span></span>
<span class="line"><span style="color: #24292E">$headers.</span><span style="color: #6F42C1">Add</span><span style="color: #24292E">(</span><span style="color: #032F62">&quot;Authorization&quot;</span><span style="color: #24292E">, </span><span style="color: #032F62">&quot;Token $TOKEN&quot;</span><span style="color: #24292E">)</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">Write</span><span style="color: #D73A49">-</span><span style="color: #24292E">Host </span><span style="color: #032F62">&quot;Verifying an authentication token...&quot;</span></span>
<span class="line"><span style="color: #24292E">Write</span><span style="color: #D73A49">-</span><span style="color: #24292E">Host</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> Invoke</span><span style="color: #D73A49">-</span><span style="color: #24292E">RestMethod </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/verify-auth-token/&quot;</span><span style="color: #24292E"> </span><span style="color: #032F62">`</span></span>
<span class="line"><span style="color: #032F62">        -Method Get -Headers $headers #-ContentType &#39;application/json&#39; </span></span>
<span class="line"></span>
<span class="line"><span style="color: #032F62">$RESULT = $RESULT | ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON with the expiry information of the token</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "token": {
        "key": "YXBwNDAtYXBpOmdUSG8xNyNrdXU4",
        "created": "2024-03-31T23:46:28Z",
        "duration_days":1,
        "expires": "2024-04-01T23:46:28Z"
    }
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;token&quot;</span><span style="color: #24292E">: {</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;key&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;YXBwNDAtYXBpOmdUSG8xNyNrdXU4&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;created&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2024-03-31T23:46:28Z&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;duration_days&quot;</span><span style="color: #24292E">:</span><span style="color: #005CC5">1</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;expires&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2024-04-01T23:46:28Z&quot;</span></span>
<span class="line"><span style="color: #24292E">    }</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph"></p>



<h2 class="wp-block-heading" id="apikey">API Key Authentication</h2>



<p class="wp-block-paragraph">An API Key is a non-expiring authorization allowing certain non-SearchStax users to perform a <em>specific set</em> of API operations on <em>specific deployments</em> of a <em>specific account</em>. If you step outside of that scope, you will see an <a href="https://www.searchstax.com/docs/hc/api-key-is-not-valid-for-required-scope/">Out of Scope</a> error. </p>



<p class="wp-block-paragraph">In a little more detail:</p>



<ul class="wp-block-list">
<li>You must be the Owner or an Admin of a Core or Enterprise account to generate an API Key. </li>



<li>You will need <a href="#token">Token Authentication</a> to create the API Key. </li>



<li>The API Key by itself is not good for anything. The account Owner or an Admin must <a href="#addkeytodeployment">associate the API Key</a> with a specific deployment before the key becomes active. </li>



<li>At this point, anyone who possesses the API Key (anyone at all) can use SearchStax Provisioning API methods to:
<ul class="wp-block-list">
<li>Manage <a href="https://www.searchstax.com/docs/searchstax-cloud-basic-auth-api/">Solr Basic Auth</a> users on that specific deployment. </li>



<li>Manage <a href="https://www.searchstax.com/docs/searchstax-cloud-zookeeper-api/">Solr configurations</a> on Zookeeper in that specific deployment.</li>
</ul>
</li>
</ul>



<p class="wp-block-paragraph">Note that the API Key is good for absolutely nothing else. </p>



<p class="wp-block-paragraph">Procedure for creating an APIkey:</p>



<ol class="wp-block-list">
<li><a href="#token">Obtain an authentication Token</a>.</li>



<li><a href="#createapikey">Generate an APIkey</a>.</li>



<li><a href="#addkeytodeployment">Associate the APIkey with a specific deployment</a>.</li>
</ol>



<p class="wp-block-paragraph">Once the APIkey has been associated with a deployment, you can view the APIkey under the&nbsp;<strong>Security</strong>&nbsp;menu for that deployment in the Managed Search dashboard.</p>



<figure class="wp-block-image size-large"><img fetchpriority="high" decoding="async" width="1024" height="541" src="https://www.searchstax.com/docs/wp-content/uploads/2024/06/APIkey-1-1024x541.png" alt="" class="wp-image-18968" srcset="https://www.searchstax.com/docs/wp-content/uploads/2024/06/APIkey-1-1024x541.png 1024w, https://www.searchstax.com/docs/wp-content/uploads/2024/06/APIkey-1-300x159.png 300w, https://www.searchstax.com/docs/wp-content/uploads/2024/06/APIkey-1-768x406.png 768w, https://www.searchstax.com/docs/wp-content/uploads/2024/06/APIkey-1.png 1200w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<h3 class="wp-block-heading" id="createapikey">account &gt; apikey &gt; create</h3>



<p class="wp-block-paragraph">This method creates an API Key based on a valid authentication token.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="#token">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    &#8220;scope&#8221;:[&#8220;deployment.dedicateddeployment&#8221;]
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;scope&quot;</span><span style="color: #24292E">:[</span><span style="color: #032F62">&quot;deployment.dedicateddeployment&quot;</span><span style="color: #24292E">]</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th>Parameter</th><th>Description</th></tr></thead><tbody><tr><td><strong>scope</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>list of strings</td><td>The scope in which this API key will be effective. Default value is&nbsp;<strong>deployment.dedicateddeployment</strong>.</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request POST "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/" \
  --header "Authorization: Token &lt;token>" \
  --header "Content-Type: application/json" \
  --data "{
    \"scope\":&#91;\"deployment.dedicateddeployment\"&#93;
}"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">scope</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">:&#91;</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">deployment.dedicateddeployment</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">&#93;</span></span>
<span class="line"><span style="color: #032F62">}&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountcreateapikey.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$body = @{
    scope=@(&#8216;deployment.dedicateddeployment&#8217;)   # Force single-value to be a list
}
$body = $body | ConvertTo-Json
$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/apikey/&#8221; 
$RESULT = $RESULT | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    scope</span><span style="color: #D73A49">=@</span><span style="color: #24292E">(</span><span style="color: #032F62">&#39;deployment.dedicateddeployment&#39;</span><span style="color: #24292E">)   </span><span style="color: #6A737D"># Force single-value to be a list</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/apikey/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{ &#8220;apikey&#8221;: &#8220;eyJhbGciOiJIUzVCJ9.eyJpYXQiOjE1NDMyNDc0ODMsImp0aSI6IjhmYTlkZThjNTIyNjRjZTc2Njg0NTkyMWQ4MTQ0MDY5ZThkMjc5NmMiLCJzY29wZSI6WyJkZXBsb3ltZW50LmRlZGljYXRlZGRlcGxveW1lbnQiXSwiQ1MrdThSZmlNTzMwNnZJM082QSJ9.r6X7bJi_ZWGR99XC0Ac&#8221; }</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{ </span><span style="color: #005CC5">&quot;apikey&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;eyJhbGciOiJIUzVCJ9.eyJpYXQiOjE1NDMyNDc0ODMsImp0aSI6IjhmYTlkZThjNTIyNjRjZTc2Njg0NTkyMWQ4MTQ0MDY5ZThkMjc5NmMiLCJzY29wZSI6WyJkZXBsb3ltZW50LmRlZGljYXRlZGRlcGxveW1lbnQiXSwiQ1MrdThSZmlNTzMwNnZJM082QSJ9.r6X7bJi_ZWGR99XC0Ac&quot;</span><span style="color: #24292E"> }</span></span></code></pre></div>



<div class="alert alert-info">
<h3>Using the API key in Bash</h3>
<p>In the Bash scripts, we use the API key directly in the header of the cURL call:</p>
<pre><code> curl -s -H "Authorization: APIkey $APIKEY" etc.</code></pre>
</div>



<div class="alert alert-info">
<h3>Using the API key in PowerShell</h3>
<p>In the PowerShell scripts, we use the API key by assembling a header and using it in the Invoke-RestMethod call:</p>
<pre><code> $headers = New-Object "System.Collections.Generic.Dictionary[[String],[String]]"
$headers.Add("Authorization", "APIkey $APIKEY")

$RESULTS = Invoke-RestMethod -Headers $headers etc. </code></pre>
</div>



<h3 class="wp-block-heading" id="addkeytodeployment">account &gt; apikey &gt; associate_apikey_to_deployment</h3>



<p class="wp-block-paragraph">This method associates an API key to a specific deployment. Note that an API key can be associated with multiple deployments, but each deployment can be associated with only one API key at a time.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/associate/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/associate/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method requires&nbsp;<a href="#token">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "apikey": "eyJhbGciOiJI6IkpXVCJ9...",
    "deployment": "ss123456"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;apikey&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;eyJhbGciOiJI6IkpXVCJ9...&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;deployment&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>apikey</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the API key that needs to be associated with the deployment.</td><td>&#8220;eyJhbGciOiJI6IkpXVCJ9&#8230;&#8221;</td></tr><tr><td><strong>deployment</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the UID of the deployment.</td><td>&#8220;ss123456&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl -s -H "Content-Type: application/json" \
     -H "Authorization: Token $TOKEN" -X POST \
     -d "{\"apikey\":\"$APIKEY\", \"deployment\":\"$uid\"}" \
     https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/apikey/associate/</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">-s</span><span style="color: #24292E"> </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">     </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token </span><span style="color: #24292E">$TOKEN</span><span style="color: #032F62">&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">-X</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">     </span><span style="color: #005CC5">-d</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">apikey</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">:</span><span style="color: #005CC5">\&quot;</span><span style="color: #24292E">$APIKEY</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">, </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">deployment</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">:</span><span style="color: #005CC5">\&quot;</span><span style="color: #24292E">$uid</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">}&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">     </span><span style="color: #032F62">https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/apikey/associate/</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountapikeyassociateapikeytodeployment.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"

$body = @{
    apikey=$APIKEY
    deployment=$uid
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod  -Method Post -body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/apikey/associate/"

$RESULT = $RESULT | ConvertTo-Json 
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    apikey</span><span style="color: #D73A49">=</span><span style="color: #24292E">$APIKEY</span></span>
<span class="line"><span style="color: #24292E">    deployment</span><span style="color: #D73A49">=</span><span style="color: #24292E">$uid</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E">  </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/apikey/associate/&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span><span style="color: #24292E"> </span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing a list of deployments associated with this key.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "deployments": &#91; "ssXXXXX1", "ssXXXXX2"&#93;
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;deployments&quot;</span><span style="color: #24292E">: &#91; </span><span style="color: #032F62">&quot;ssXXXXX1&quot;</span><span style="color: #24292E">, </span><span style="color: #032F62">&quot;ssXXXXX2&quot;</span><span style="color: #24292E">&#93;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">Note that a deployment may be associated with only one API key at a time. Attempting to associate a second API key results in an error message:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "detail": "Deployment is already associated to another API key."
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">&quot;detail&quot;</span><span style="color: #005CC5">:</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Deployment is already associated to another API key.&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<h3 class="wp-block-heading" id="keydeployments">account &gt; apikey &gt; apikey_deployments</h3>



<p class="wp-block-paragraph">This method lists the deployments associated with the given API key.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/deployments/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/deployments/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="#token">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "apikey" : "eyJhbGciOiJI6IkpXVCJ9..."
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;apikey&quot;</span><span style="color: #24292E"> : </span><span style="color: #032F62">&quot;eyJhbGciOiJI6IkpXVCJ9...&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th>Parameter</th><th>Description</th><th>Example</th></tr></thead><tbody><tr><td><strong>apikey</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the API key that is associated with the deployments.</td><td>&#8220;eyJhbGciOiJI6IkpXVCJ9&#8230;&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request POST "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/deployments/" \
  --header "Authorization: Token &lt;token>" \
  --header "Content-Type: application/json" \
  --data "{ \"apikey\" : \"eyJhbGciOiJI6IkpXVCJ9...\" }"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/deployments/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{ </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">apikey</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">eyJhbGciOiJI6IkpXVCJ9...</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> }&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountapikeyapikeydeployments.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$APIKEY = "eyJhbGciOiJI6IkpXVCJ9..."

$body = @{
    apikey=$APIKEY
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/apikey/deployments/" 
$RESULT = $RESULT | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$APIKEY </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;eyJhbGciOiJI6IkpXVCJ9...&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    apikey</span><span style="color: #D73A49">=</span><span style="color: #24292E">$APIKEY</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/apikey/deployments/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing a list of deployment UIDs.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "deployments": &#91; "ss123456" &#93;
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;deployments&quot;</span><span style="color: #24292E">: &#91; </span><span style="color: #032F62">&quot;ss123456&quot;</span><span style="color: #24292E"> &#93;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">If the <strong>username</strong> or <strong>account name</strong> is in error, the API returns this message:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "detail": "You do not have permission to perform this action."
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">&quot;detail&quot;</span><span style="color: #005CC5">:</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;You do not have permission to perform this action.&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<p class="wp-block-paragraph">If the lengthy API key string is in error (usually a line break), the API returns this error:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{"apikey":&#91;"Error decoding signature. Unknown API Key"&#93;}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span><span style="color: #6F42C1">&quot;apikey&quot;</span><span style="color: #005CC5">:</span><span style="color: #24292E">&#91;</span><span style="color: #6F42C1">&quot;Error decoding signature. Unknown API Key&quot;</span><span style="color: #6F42C1">&#93;}</span></span></code></pre></div>



<h3 class="wp-block-heading" id="removefromdeployment">account &gt; apikey &gt; deployment_apikeys</h3>



<p class="wp-block-paragraph">This method lists the API key that is associated with a deployment. Each deployment may be associated with only one API key at a time.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/list/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/list/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="#token">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "deployment" : "ss123456"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;deployment&quot;</span><span style="color: #24292E"> : </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>deployment</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the UID of the deployment.</td><td>&#8220;ss123456&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request POST "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/list/" \
  --header "Authorization: Token &lt;token>" \
  --header "Content-Type: application/json" \
  --data "{ \"deployment\" : \"ss123456\" }"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/list/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{ </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">deployment</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">ss123456</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> }&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountapikeydeploymentapikeys.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"

$body = @{
    deployment=$uid
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/apikey/list/" 
$RESULT = $RESULT | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    deployment</span><span style="color: #D73A49">=</span><span style="color: #24292E">$uid</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/apikey/list/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing the API key associated with the deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "apikey": &#91; "eyJhbGciOiJI6IkpXVCJ9..." &#93;
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;apikey&quot;</span><span style="color: #24292E">: &#91; </span><span style="color: #032F62">&quot;eyJhbGciOiJI6IkpXVCJ9...&quot;</span><span style="color: #24292E"> &#93;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="dissociate">account &gt; apikey &gt; disassociate_apikey_from_deployment</h3>



<p class="wp-block-paragraph">This method disassociates an API key from a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/disassociate/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/disassociate/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="#token">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "apikey" : "eyJhbGciOiJI6IkpXVCJ9...",
    "deployment": "ss123456"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;apikey&quot;</span><span style="color: #24292E"> : </span><span style="color: #032F62">&quot;eyJhbGciOiJI6IkpXVCJ9...&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;deployment&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>apikey</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the API key that needs to be disassociated from the deployment.</td><td>&#8220;eyJhbGciOiJI6IkpXVCJ9&#8230;&#8221;</td></tr><tr><td><strong>deployment</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the UID of the deployment.</td><td>&#8220;ss123456&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request POST "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/disassociate/" \
  --header "Authorization: Token &lt;token>" \
  --header "Content-Type: application/json" \
  --data "{
    \"apikey\" : \"eyJhbGciOiJI6IkpXVCJ9...\",
    \"deployment\": \"ss123456\"
}"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/disassociate/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">apikey</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">eyJhbGciOiJI6IkpXVCJ9...</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">deployment</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">ss123456</span><span style="color: #005CC5">\&quot;</span></span>
<span class="line"><span style="color: #032F62">}&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountapikeydisassociateapikeyfromdeployment.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"
$APIKEY = "eyJhbGciOiJI6IkpXVCJ9..."

$body = @{
    apikey=$APIKEY
    deployment=$uid
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/apikey/disassociate/" 
$RESULT = $RESULT | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"><span style="color: #24292E">$APIKEY </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;eyJhbGciOiJI6IkpXVCJ9...&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    apikey</span><span style="color: #D73A49">=</span><span style="color: #24292E">$APIKEY</span></span>
<span class="line"><span style="color: #24292E">    deployment</span><span style="color: #D73A49">=</span><span style="color: #24292E">$uid</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/apikey/disassociate/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing a list of deployments with which the API key is still associated.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "deployments": &#91;
    "ssXXXXX1",
    "ssXXXXX2",
    "ssXXXXX3"
  &#93;
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;deployments&quot;</span><span style="color: #24292E">: &#91;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #032F62">&quot;ssXXXXX1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #032F62">&quot;ssXXXXX2&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #032F62">&quot;ssXXXXX3&quot;</span></span>
<span class="line"><span style="color: #24292E">  &#93;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="revokeapikey">account &gt; apikey &gt; revoke</h3>



<p class="wp-block-paragraph">This method revokes an API key.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/revoke/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/revoke/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="#token">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    &#8220;apikey&#8221; : &#8220;eyJhbGciOiJI6IkpXVCJ9&#8230;&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;apikey&quot;</span><span style="color: #24292E"> : </span><span style="color: #032F62">&quot;eyJhbGciOiJI6IkpXVCJ9...&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>apikey</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the API key to revoke.</td><td>&#8220;eyJhbGciOiJI6IkpXVCJ9&#8230;&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request POST &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/apikey/revoke/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; \
  &#8211;header &#8220;Content-Type: application/json&#8221; \
  &#8211;data &#8220;{
    \&#8221;apikey\&#8221; : \&#8221;eyJhbGciOiJI6IkpXVCJ9&#8230;\&#8221;
}&#8221;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/apikey/revoke/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">apikey</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">eyJhbGciOiJI6IkpXVCJ9...</span><span style="color: #005CC5">\&quot;</span></span>
<span class="line"><span style="color: #032F62">}&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountapikeyrevoke.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$APIKEY = &#8220;eyJhbGciOiJI6IkpXVCJ9&#8230;&#8221;
$body = @{
    apikey=$APIKEY
}
$body = $body | ConvertTo-Json
$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/apikey/revoke/&#8221; 
$RESULT = $RESULT | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$APIKEY </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;eyJhbGciOiJI6IkpXVCJ9...&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    apikey</span><span style="color: #D73A49">=</span><span style="color: #24292E">$APIKEY</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/apikey/revoke/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing a success/failure message.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;success&#8221;: &#8220;API Key revoked successfully.&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;API Key revoked successfully.&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h2 class="wp-block-heading" id="questions">Questions?</h2>



<p class="wp-block-paragraph">Do not hesitate to contact the&nbsp;<a href="mailto:support@searchstax.com?subject=SearchStax%20Cloud%20Provisioning%20API%20–%20Authentication" target="_blank" rel="noreferrer noopener">SearchStax Support Desk</a>.</p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-authentication-api/">Provisioning API &#8211; Authentication</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.searchstax.com/docs/searchstax-cloud-authentication-api/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>SearchStax Users API</title>
		<link>https://www.searchstax.com/docs/searchstax-cloud-users-api/</link>
					<comments>https://www.searchstax.com/docs/searchstax-cloud-users-api/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Thu, 04 Mar 2021 10:23:05 +0000</pubDate>
				<category><![CDATA[Access and Security APIs]]></category>
		<guid isPermaLink="false">https://www.searchstax.com/docs/?p=7669</guid>

					<description><![CDATA[<p>Provisioning API &#8211; Users Overview The SearchStax Managed Search service provides an API supporting the creation, deletion and management of SearchStax Managed Search service deployments. Core and Enterprise Clients&#8230; <a class="more-link" href="https://www.searchstax.com/docs/searchstax-cloud-users-api/">Continue reading <span class="screen-reader-text">SearchStax Users API</span></a></p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-users-api/">SearchStax Users API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h1 class="wp-block-heading" id="searchstax-managed-solr-api-users">Provisioning API &#8211; Users</h1>



<hr class="wp-block-separator has-css-opacity"/>



<h2 class="wp-block-heading" id="overview">Overview</h2>



<p class="wp-block-paragraph">The SearchStax Managed Search service provides an API supporting the creation, deletion and management of SearchStax Managed Search service deployments.</p>



<div class="alert alert-info">
<h3>Core and Enterprise Clients Only!</h3>
<p>The SearchStax API suite is available to our Core and Enterprise
clients only, as noted on our <a href="https://www.searchstax.com/pricing/cloud/">Pricing</a> page. </p>
</div>



<p class="wp-block-paragraph">This page describes how to manage the users of a SearchStax account through the API.</p>



<p class="wp-block-paragraph">The API can be accessed through any tool that assembles HTTP requests and dispatch them to a server. Among these would be the Python&nbsp;<a href="https://pypi.org/project/coreapi/" target="_blank" rel="noreferrer noopener">coreapi</a>&nbsp;package, the&nbsp;<a href="https://www.postman.com/" target="_blank" rel="noreferrer noopener">Postman</a>&nbsp;tool, and&nbsp;<a href="https://curl.se" target="_blank" rel="noreferrer noopener">cURL</a>. For Windows, use&nbsp;<a href="https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1" target="_blank" rel="noreferrer noopener">PowerShell 7+</a>.</p>



<div class="alert alert-warning">
<h3>Account Owner, Admin, or Technical Contact</h3>
<p>To run the SearchStax Provisioning API, you must be the account Owner,
an account Admin, or a Technical Contact. See <a href="/docs/searchstax-cloud-user-roles/#userroles">SearchStax User Roles</a>.</p>
</div>



<p class="wp-block-paragraph">Symbols enclosed in carets (&lt; and &gt;) such as&nbsp;<strong>&lt;username&gt;</strong>&nbsp;are metavariables. Substitute your local values when you encounter them in the examples.</p>



<p class="wp-block-paragraph">Contents:</p>



<ul class="wp-block-list">
<li><a href="#users">Users</a>
<ul class="wp-block-list">
<li><a href="#listusers">users &gt; list</a></li>



<li><a href="#h-users-gt-add-user-gt-create" type="internal" id="#h-users-gt-add-user-gt-create">users &gt; add-user &gt; create</a></li>



<li><a href="#changepasswordcreate">users &gt; change-password &gt; create</a></li>



<li><a href="#setrolecreate">users &gt; set-role &gt; create</a></li>



<li><a href="#deleteusers">users &gt; delete</a></li>
</ul>
</li>
</ul>



<p class="wp-block-paragraph">Related Pages:</p>



<ul class="wp-block-list">
<li><a href="/docs/searchstax-cloud-authentication-api/">Authentication API</a></li>



<li><a href="/docs/searchstax-cloud-basic-auth-api/">Basic Auth API</a></li>



<li><a href="/docs/searchstax-cloud-ipfilter-api/">IP Filtering API</a></li>



<li><a href="/docs/searchstax-cloud-deployment-api/">Deployment API</a></li>



<li><a href="/docs/searchstax-cloud-private-vpc-api/">Private VPC API</a></li>



<li><a href="/docs/searchstax-cloud-dns-alias-api/">DNS Alias API</a></li>



<li><a href="/docs/searchstax-cloud-backup-restore-api/">Backup/Restore API</a></li>



<li><a href="/docs/searchstax-cloud-custom-jars-api/">Custom JARs API</a></li>



<li><a href="/docs/searchstax-cloud-tags-api/">Tags API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Alerts API</a></li>



<li><a href="/docs/searchstax-cloud-webhooks-api/">Webhooks API</a></li>



<li><a href="/docs/searchstax-cloud-zookeeper-api/">Zookeeper API</a></li>
</ul>



<h2 class="wp-block-heading" id="users">Users</h2>



<p class="wp-block-paragraph">The SearchStax Provisioning API provides methods for managing the users of a SearchStax Account from a remote application.</p>



<h3 class="wp-block-heading" id="listusers">users &gt; list</h3>



<p class="wp-block-paragraph">This method lists the SearchStax users for an account.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/users/?account=&lt;account_name></textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/users/?account=&lt;account_name&gt;</span></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>?account=&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET https://app.searchstax.com/api/rest/users/?account=$ACCOUNT 
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; </textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">https://app.searchstax.com/api/rest/users/?account=</span><span style="color: #24292E">$ACCOUNT </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/userslist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$RESULT = Invoke-RestMethod -Method Get -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/users/?account=$ACCOUNT&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/users/?account=</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing the SearchStax users of the account and their details:</p>



<div class="wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex">
<div class="wp-block-column is-layout-flow wp-block-column-is-layout-flow" style="flex-basis:100%">
<div class="wp-block-group"><div class="wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow">
<div class="wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex">
<div class="wp-block-column is-layout-flow wp-block-column-is-layout-flow" style="flex-basis:100%">
<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "success": true,
  "users": &#91;
    {
      "firstname": "FirstName",
      "lastname": "LastName",
      "email": "user@company.com",
      "role": "Team Member",
      "sitesearch_role": "Team Member",
      "tfa_enabled": false,
      "phone": "123-456-7890",
      "company": "Company",
      "id": 3201,
      "last_login": "2025-09-19T16:09:15Z",
      "created": "2021-01-06T19:51:28Z",
      "invitation_status": "Completed",
      "role_in_organization": "Engineer"
    }
  &#93;
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;users&quot;</span><span style="color: #24292E">: &#91;</span></span>
<span class="line"><span style="color: #24292E">    {</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;firstname&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;FirstName&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;lastname&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;LastName&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;email&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;user@company.com&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;role&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Team Member&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;sitesearch_role&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Team Member&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;tfa_enabled&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;phone&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;123-456-7890&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;company&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Company&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">3201</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;last_login&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2025-09-19T16:09:15Z&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;created&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2021-01-06T19:51:28Z&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;invitation_status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Completed&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;role_in_organization&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Engineer&quot;</span></span>
<span class="line"><span style="color: #24292E">    }</span></span>
<span class="line"><span style="color: #24292E">  &#93;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>
</div>
</div>
</div></div>
</div>
</div>



<h3 class="wp-block-heading" id="h-users-gt-add-user-gt-create">users &gt; add-user &gt; create</h3>



<p class="wp-block-paragraph">This method invites a new user to join an existing tenant account. </p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/users/add-user?account=&lt;account_name></textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/users/add-user?account=&lt;account_name&gt;</span></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>?account=&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    &#8220;email&#8221;: &#8220;user@company.com&#8221;,
    &#8220;role&#8221;: &#8220;Admin&#8221;,
    &#8220;first_name&#8221;: &#8220;First&#8221;,
    &#8220;last_name&#8221;: &#8220;Last&#8221;,    
    &#8220;phone_number&#8221;: &#8220;8005551212&#8221;
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;email&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;user@company.com&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;role&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Admin&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;first_name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;First&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;last_name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Last&quot;</span><span style="color: #24292E">,    </span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;phone_number&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;8005551212&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th></tr></thead><tbody><tr><td><strong>email</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark><br>string</td><td>The user&#8217;s email.</td></tr><tr><td><strong>role</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark><br>string</td><td>One of &#8216;Admin&#8217;, &#8216;Technical Contact&#8217;, &#8216;Billing Member&#8217;, &#8216;Team Member&#8217;.</td></tr><tr><td><strong>first_name</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark><br>string</td><td>User&#8217;s first name.</td></tr><tr><td><strong>last_name</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark><br>string</td><td>User&#8217;s last name.</td></tr><tr><td><strong>phone_number</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#32cd32" class="has-inline-color">optional</mark><br>string</td><td>User&#8217;s phone number.</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl -s -H &#8220;Authorization: Token $TOKEN&#8221; -H &#8220;Content-Type: application/json&#8221; -d &#8220;${BODY}&#8221; 
-X POST https://app.searchstax.com/api/rest/users/add-user?account=$ACCOUNT</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">-s</span><span style="color: #24292E"> </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token </span><span style="color: #24292E">$TOKEN</span><span style="color: #032F62">&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">-d</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;${</span><span style="color: #24292E">BODY</span><span style="color: #032F62">}&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #6F42C1">-X</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">https://app.searchstax.com/api/rest/users/add-user?account=</span><span style="color: #24292E">$ACCOUNT</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/usersadd-usercreate.ps1">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$body = @{
    email=&#8217;user@company.com&#8217;
    role=&#8217;Admin&#8217;
    first_name=&#8217;First&#8217;
    last_name=&#8217;Last&#8217;    
    phone_number=&#8217;8005551212&#8242;
}
$body = $body | ConvertTo-Json
$RESULTS = Invoke-RestMethod -Method Post -Body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
          -uri &#8220;https://app.searchstax.com/api/rest/users/add-user?account=$ACCOUNT&#8221; 
$RESULTS = $RESULTS | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    email</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;user@company.com&#39;</span></span>
<span class="line"><span style="color: #24292E">    role</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;Admin&#39;</span></span>
<span class="line"><span style="color: #24292E">    first_name</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;First&#39;</span></span>
<span class="line"><span style="color: #24292E">    last_name</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;Last&#39;</span><span style="color: #24292E">    </span></span>
<span class="line"><span style="color: #24292E">    phone_number</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;8005551212&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">Body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">          </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/users/add-user?account=</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULTS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">This method returns a JSON document containing a success message.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;success&#8221;: true,
  &#8220;message&#8221;: &#8220;User &#8216;user@company.com&#8217; invited successfully.&#8221;
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;User &#39;user@company.com&#39; invited successfully.&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<h3 class="wp-block-heading" id="changepasswordcreate">users &gt; change-password &gt; create</h3>



<p class="wp-block-paragraph">This method allows an authenticated user to change his own password. It is not possible to change someone else&#8217;s password.  </p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/users/change-password?account=&lt;account_name>&amp;id=&lt;id></textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/users/change-password?account=&lt;account_name&gt;&amp;id=&lt;id&gt;</span></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>?account=&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and <strong>id=&lt;id&gt;</strong> is the user identification number obtained from <a href="#listusers">users &gt; list</a>. </p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following item:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "password": "NewPasswordString"
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;password&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;NewPasswordString&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th></tr></thead><tbody><tr><td><strong>password</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark><br>string</td><td>The desired new password. The password should contain at least one upper-case letter, one lower-case letter, one number, one special character and be from 15 and 64 characters long.</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl -s -H "Authorization: Token $TOKEN" -H "Content-Type: application/json" -d '{"password": "NewPasswordString"}' /
-X POST "https://app.searchstax.com/api/rest/users/change-password?account=$ACCOUNT&amp;$ID"</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">-s</span><span style="color: #24292E"> </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token </span><span style="color: #24292E">$TOKEN</span><span style="color: #032F62">&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">-d</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;{&quot;password&quot;: &quot;NewPasswordString&quot;}&#39;</span><span style="color: #24292E"> </span><span style="color: #032F62">/</span></span>
<span class="line"><span style="color: #6F42C1">-X</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/users/change-password?account=</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">&amp;</span><span style="color: #24292E">$ID</span><span style="color: #032F62">&quot;</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/userschange-passwordcreate.ps1">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$body = @{
    password='NewPasswordString'
}

$body = $body | ConvertTo-Json

$RESULTS = Invoke-RestMethod -Method Post -Body $body -ContentType 'application/json' -Headers $headers `
          -uri "https://app.searchstax.com/api/rest/users/change-password?account=$ACCOUNT&amp;id=$ID" 
 
$RESULTS = $RESULTS | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    password</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;NewPasswordString&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">Body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">          </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/users/change-password?account=</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">&amp;id=</span><span style="color: #24292E">$ID</span><span style="color: #032F62">&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULTS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">This method returns a JSON document containing a success message.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "success":  true,
    "message":  "Password changed successfully."
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">:  </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;Password changed successfully.&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<p class="wp-block-paragraph">If you received an error saying, &#8220;<code>You can not change password for another user</code>,&#8221; check to be sure the URL is within double-quotes. If not, everything to the right of the ampersand (&amp;) will be truncated, usually resulting in the loss of the user ID. </p>



<h3 class="wp-block-heading" id="setrolecreate">users &gt; set-role &gt; create</h3>



<div class="alert alert-info">
<h3>Managed Search User Roles</h3>
<p>For background on user roles in Managed Search, see <a href="https://www.searchstax.com/blog/role-based-user-roles-for-your-searchstax-team/">Role-based User Roles for Your SearchStax Team</a> and <a href="https://www.searchstax.com/docs/searchstax-cloud-user-roles/#userroles">User Management</a>.</p>
</div>



<p class="wp-block-paragraph">This method allows an Author or Admin to change the role of one or more account users.  </p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/users/set-role/?account=&lt;account_name></textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/users/set-role/?account=&lt;account_name&gt;</span></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>?account=&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.. </p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following item:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    &#8220;id&#8221;: &#8220;2178,2067,3385&#8221;,
    &#8220;role&#8221;: &#8220;Team Member&#8221;
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2178,2067,3385&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;role&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Team Member&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th></tr></thead><tbody><tr><td><strong>id</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark><br>string</td><td>A comma-separated list of user ID numbers obtained from <a href="#listusers">users &gt; list</a>.  </td></tr><tr><td>role<br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark><br>string</td><td>One of Admin, Technical Contact, Billing Member, Team Member, Marketer. All users in the <strong>id</strong> list will be assigned to this role.</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl -s -H &#8220;Authorization: Token $TOKEN&#8221; -H &#8220;Content-Type: application/json&#8221; -d &#8220;${BODY}&#8221; 
-X POST &#8220;https://app.searchstax.com/api/rest/users/set-role?account=$ACCOUNT&#8221;</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">-s</span><span style="color: #24292E"> </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token </span><span style="color: #24292E">$TOKEN</span><span style="color: #032F62">&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">-d</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;${</span><span style="color: #24292E">BODY</span><span style="color: #032F62">}&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #6F42C1">-X</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/users/set-role?account=</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">&quot;</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/usersset-rolecreate.ps1">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$body = @{
    id=&#8217;2178,2067,3385&#8242;
    role=&#8217;Team Member&#8217;
}
$body = $body | ConvertTo-Json
$RESULTS = Invoke-RestMethod -Method Post -Body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
          -uri &#8220;https://app.searchstax.com/api/rest/users/set-role?account=$ACCOUNT&#8221; 
 
$RESULTS = $RESULTS | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    id</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;2178,2067,3385&#39;</span></span>
<span class="line"><span style="color: #24292E">    role</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;Team Member&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">Body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">          </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/users/set-role?account=</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULTS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">This method returns a JSON document containing a success/failure message for each user.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>&#91;
  {
    "id": 2178,
    "success": true,
    "message": "Role updated successfully."
  },
  {
    "id": 2067,
    "success": false,
    "message": "User id 2067 does not exist."
  },
  {
    "id": 3385,
    "success": true,
    "message": "Role updated successfully."
  }
&#93;
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">&#91;</span></span>
<span class="line"><span style="color: #24292E">  {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">2178</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Role updated successfully.&quot;</span></span>
<span class="line"><span style="color: #24292E">  },</span></span>
<span class="line"><span style="color: #24292E">  {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">2067</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;User id 2067 does not exist.&quot;</span></span>
<span class="line"><span style="color: #24292E">  },</span></span>
<span class="line"><span style="color: #24292E">  {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">3385</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Role updated successfully.&quot;</span></span>
<span class="line"><span style="color: #24292E">  }</span></span>
<span class="line"><span style="color: #24292E">&#93;</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="deleteusers">users &gt; delete</h3>



<p class="wp-block-paragraph">This method deletes a SearchStax user from an Account.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>DELETE https://app.searchstax.com/api/rest/users/?account=&lt;account_name>&amp;id=&lt;user_id></textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">DELETE</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/users/?account=&lt;account_name&gt;&amp;id=&lt;user_id&gt;</span></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>?account=&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&amp;id=&lt;user_id&gt;</strong>&nbsp;is the ID of the user.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl -H &#8220;Content-Type: application/json&#8221; -H &#8220;Authorization: Token $TOKEN&#8221; 
     -X DELETE &#8220;https://app.searchstax.com/api/rest/users/?account=$ACCOUNT&amp;id=$DELUSER&#8221;</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">-H</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token </span><span style="color: #24292E">$TOKEN</span><span style="color: #032F62">&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">     </span><span style="color: #6F42C1">-X</span><span style="color: #24292E"> </span><span style="color: #032F62">DELETE</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/users/?account=</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">&amp;id=</span><span style="color: #24292E">$DELUSER</span><span style="color: #032F62">&quot;</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/usersdelete.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$DELUSER = &#8220;1234&#8221;
$RESULT = Invoke-RestMethod -Method Delete -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/users/?account=$ACCOUNT&amp;id=$DELUSER&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$DELUSER </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;1234&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Delete </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/users/?account=</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">&amp;id=</span><span style="color: #24292E">$DELUSER</span><span style="color: #032F62">&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">This method returns a JSON document containing a success message.</p>



<div class="wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex">
<div class="wp-block-column is-layout-flow wp-block-column-is-layout-flow" style="flex-basis:100%">
<div class="wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex">
<div class="wp-block-column is-layout-flow wp-block-column-is-layout-flow" style="flex-basis:100%">
<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
   &#8220;id&#8221;:3204,
   &#8220;success&#8221;:true,
   &#8220;message&#8221;:&#8221;User deleted successfully.&#8221;
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">   </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">:</span><span style="color: #005CC5">3204</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">   </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">:</span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">   </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">:</span><span style="color: #032F62">&quot;User deleted successfully.&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>
</div>
</div>
</div>
</div>



<h2 class="wp-block-heading" id="questions">Questions?</h2>



<p class="wp-block-paragraph">Do not hesitate to contact the&nbsp;<a href="mailto:support@searchstax.com?subject=ASearchStax%20Cloud%20API%20–%20Users" target="_blank" rel="noreferrer noopener">SearchStax Support Desk</a>.</p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-users-api/">SearchStax Users API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.searchstax.com/docs/searchstax-cloud-users-api/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Solr Basic Auth API</title>
		<link>https://www.searchstax.com/docs/searchstax-cloud-basic-auth-api/</link>
					<comments>https://www.searchstax.com/docs/searchstax-cloud-basic-auth-api/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Thu, 04 Mar 2021 10:10:05 +0000</pubDate>
				<category><![CDATA[Access and Security APIs]]></category>
		<category><![CDATA[Cloud]]></category>
		<guid isPermaLink="false">https://www.searchstax.com/docs/?p=7660</guid>

					<description><![CDATA[<p>Provisioning API &#8211; Basic Auth Overview The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr deployments. Core and Enterprise Clients Only! The&#8230; <a class="more-link" href="https://www.searchstax.com/docs/searchstax-cloud-basic-auth-api/">Continue reading <span class="screen-reader-text">Solr Basic Auth API</span></a></p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-basic-auth-api/">Solr Basic Auth API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h1 class="wp-block-heading" id="h-provisioning-api-basic-auth">Provisioning API &#8211; Basic Auth</h1>



<hr class="wp-block-separator has-css-opacity"/>



<h2 class="wp-block-heading">Overview</h2>



<p class="wp-block-paragraph">The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr deployments.</p>



<div class="alert alert-info">
<h3>Core and Enterprise Clients Only!</h3>
<p>The SearchStax API suite is available to our Core and Enterprise
clients only, as noted on our <a href="https://www.searchstax.com/pricing/cloud/">Pricing</a> page. </p>
</div>



<p class="wp-block-paragraph">This page describes how to manage <a href="https://www.searchstax.com/docs/searchstax-cloud-deployment-security/">Solr Basic Auth</a> features through the API.</p>



<p class="wp-block-paragraph">The API can be accessed through any tool that assembles HTTP requests and dispatch them to a server. Among these would be the Python&nbsp;<a href="https://pypi.org/project/coreapi/" target="_blank" rel="noreferrer noopener">coreapi</a>&nbsp;package, the&nbsp;<a href="https://www.postman.com/" target="_blank" rel="noreferrer noopener">Postman</a>&nbsp;tool, and&nbsp;<a href="https://curl.se" target="_blank" rel="noreferrer noopener">cURL</a>. For Windows, use&nbsp;<a href="https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1" target="_blank" rel="noreferrer noopener">PowerShell 7+</a>.</p>



<div class="alert alert-warning">
<h3>Account Owner, Admin, or Technical Contact</h3>
<p>To run the SearchStax Provisioning API, you must be the account Owner,
an account Admin, or a Technical Contact. See <a href="https://www.searchstax.com/docs/userroles/#userroles">SearchStax User Roles</a>.</p>
</div>



<p class="wp-block-paragraph">Symbols enclosed in carets (&lt; and &gt;) such as&nbsp;<strong>&lt;username&gt;</strong>&nbsp;are metavariables. Substitute your local values when you encounter them in the examples.</p>



<p class="wp-block-paragraph">Contents:</p>



<ul class="wp-block-list">
<li><a href="#solr-basic-auth">Solr Basic Auth</a>
<ul class="wp-block-list">
<li><a href="#enablesolrauth">account &gt; deployment &gt; solr &gt; auth &gt; enable_basic_auth</a></li>



<li><a href="#disablesolrauth">account &gt; deployment &gt; solr &gt; auth &gt; disable_basic_auth</a></li>



<li><a href="#addsolruser">account &gt; deployment &gt; solr &gt; auth &gt; add_solr_user</a></li>



<li><a href="#deletesolruser">account &gt; deployment &gt; solr &gt; auth &gt; delete_solr_user</a></li>



<li><a href="#getsolrusers">account &gt; deployment &gt; solr &gt; auth &gt; get_solr_users</a></li>



<li><a href="#setsolrpassword">account &gt; deployment &gt; solr &gt; auth &gt; set_solr_user_password</a></li>



<li><a href="#setsolrrole">account &gt; deployment &gt; solr &gt; auth &gt; set_solr_user_role</a></li>
</ul>
</li>
</ul>



<p class="wp-block-paragraph">Related Pages:</p>



<ul class="wp-block-list">
<li><a href="/docs/searchstax-cloud-authentication-api/">Authentication API</a></li>



<li><a href="/docs/searchstax-cloud-users-api/">Users API</a></li>



<li><a href="/docs/searchstax-cloud-ipfilter-api/">IP Filtering API</a></li>



<li><a href="/docs/searchstax-cloud-deployment-api/">Deployment API</a></li>



<li><a href="/docs/searchstax-cloud-private-vpc-api/">Private VPC API</a></li>



<li><a href="/docs/searchstax-cloud-dns-alias-api/">DNS Alias API</a></li>



<li><a href="/docs/searchstax-cloud-backup-restore-api/">Backup/Restore API</a></li>



<li><a href="/docs/searchstax-cloud-custom-jars-api/">Custom JARs API</a></li>



<li><a href="/docs/searchstax-cloud-tags-api/">Tags API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Alerts A</a><a href="/docs/staxapi2alerts/">P</a><a href="https://www.searchstax.com/docs/staxapi2alerts/">I</a></li>



<li><a href="/docs/searchstax-cloud-webhooks-api/">Webhooks API</a></li>



<li><a href="/docs/searchstax-cloud-zookeeper-api/">Zookeeper API</a></li>
</ul>



<h2 class="wp-block-heading" id="solr-basic-auth">Solr Basic Auth</h2>



<p class="wp-block-paragraph">The SearchStax Provisioning API provides a selection of methods for managing Solr basic authentication from a remote application.</p>



<h3 class="wp-block-heading" id="enablesolrauth">account &gt; deployment &gt; solr &gt; auth &gt; enable_basic_auth</h3>



<p class="wp-block-paragraph">This method enables basic auth for a Solr deployment. Note that this process takes Solr offline for about 30 seconds to restart it. </p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/enable/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/enable/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/enable/&#8221; \
  &#8211;header &#8220;Authorization: APIkey &lt;apikey>&#8221; </textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/enable/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: APIkey &lt;apikey&gt;&quot;</span><span style="color: #24292E"> </span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentsolrauthenablebasicauth.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$RESULT = Invoke-RestMethod -Method Get -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/solr/auth/enable/&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/solr/auth/enable/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">This method returns a JSON document containing a success message.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;message&#8221;: &#8220;Basic authentication successfully Enabled for Solr&#8221;,
  &#8220;success&#8221;: &#8220;true&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Basic authentication successfully Enabled for Solr&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;true&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="disablesolrauth">account &gt; deployment &gt; solr &gt; auth &gt; disable_basic_auth</h3>



<p class="wp-block-paragraph">This method disables basic auth for a Solr deployment. Note that this process takes Solr offline for about 30 seconds to restart it.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/disable/</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/disable/</span></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/disable/&#8221; \
  &#8211;header &#8220;Authorization: APIkey &lt;apikey>&#8221; \</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/disable/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: APIkey &lt;apikey&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentsolrauthdisablebasicauth.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$RESULT = Invoke-RestMethod -Method Get -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/solr/auth/disable/&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/solr/auth/disable/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">This method returns a JSON document containing a success message.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;message&#8221;: &#8220;Basic authentication successfully Disabled for Solr&#8221;,
  &#8220;success&#8221;: &#8220;true&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Basic authentication successfully Disabled for Solr&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;true&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="addsolruser">account &gt; deployment &gt; solr &gt; auth &gt; add_solr_user</h3>



<p class="wp-block-paragraph">This method adds a Solr user to the deployment. Basic auth must be enabled.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/add-user/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/add-user/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    &#8220;username&#8221; : &#8220;demoSolrUser&#8221;,
    &#8220;password&#8221; : &#8220;test123&#8221;,
    &#8220;role&#8221; : &#8220;Admin&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;username&quot;</span><span style="color: #24292E"> : </span><span style="color: #032F62">&quot;demoSolrUser&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;password&quot;</span><span style="color: #24292E"> : </span><span style="color: #032F62">&quot;test123&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;role&quot;</span><span style="color: #24292E"> : </span><span style="color: #032F62">&quot;Admin&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>username</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the Solr user name.</td><td>&#8220;demoSolrUser&#8221;</td></tr><tr><td><strong>password</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the Solr user&#8217;s password.</td><td>&#8220;test123&#8221;</td></tr><tr><td><strong>role</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the Solr role: Admin, Read, Write, or ReadWrite.</td><td>&#8220;Admin&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">See&nbsp;<a href="/docs/searchstax-cloud-deployment-security/#solrauth/">Solr Basic Authentication</a>&nbsp;for an explanation of the Solr roles.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request POST &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/add-user/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; \
  &#8211;header &#8220;Content-Type: application/json&#8221; \
  &#8211;data &#8220;{
    \&#8221;username\&#8221; : \&#8221;demoSolrUser\&#8221;,
    \&#8221;password\&#8221; : \&#8221;test123\&#8221;,
    \&#8221;role\&#8221; : \&#8221;Admin\&#8221;
}&#8221;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/add-user/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">username</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">demoSolrUser</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">password</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">test123</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">role</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">Admin</span><span style="color: #005CC5">\&quot;</span></span>
<span class="line"><span style="color: #032F62">}&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentsolrauthaddsolruser.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$body = @{
    username=&#8217;demoSolrUser&#8217;
    password=&#8217;test123&#8242;
    role=&#8217;Admin&#8217;
}
$body = $body | ConvertTo-Json
$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/solr/auth/add-user/&#8221; 
$RESULT = $RESULT | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    username</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;demoSolrUser&#39;</span></span>
<span class="line"><span style="color: #24292E">    password</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;test123&#39;</span></span>
<span class="line"><span style="color: #24292E">    role</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;Admin&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/solr/auth/add-user/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">This method returns a JSON document containing a success message.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;message&#8221;: &#8220;User successfully added&#8221;,
  &#8220;success&#8221;: &#8220;true&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;User successfully added&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;true&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="deletesolruser">account &gt; deployment &gt; solr &gt; auth &gt; delete_solr_user</h3>



<p class="wp-block-paragraph">This method deletes a Solr user from a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/delete-user/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/delete-user/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: jscript; auto-links: false; title: ; notranslate">
{
    &quot;username&quot; : &quot;demoSolrUser&quot;
}

</pre></div>


<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>username</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the Solr user name.</td><td>&#8220;demoSolrUser&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request POST &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/delete-user/&#8221; \
  &#8211;header &#8220;Authorization: APIkey &lt;apikey>&#8221; \
  &#8211;header &#8220;Content-Type: application/json&#8221; \
  &#8211;data &#8220;{
    \&#8221;username\&#8221; : \&#8221;demoSolrUser\&#8221;
}&#8221;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/delete-user/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: APIkey &lt;apikey&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">username</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">demoSolrUser</span><span style="color: #005CC5">\&quot;</span></span>
<span class="line"><span style="color: #032F62">}&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentsolrauthdeletesolruser.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$body = @{
    username=&#8217;demoSolrUser&#8217;
}
$body = $body | ConvertTo-Json
$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/solr/auth/delete-user/&#8221; 
$RESULT = $RESULT | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    username</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;demoSolrUser&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/solr/auth/delete-user/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">This method returns a JSON document containing a success message.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;message&#8221;: &#8220;User successfully deleted!&#8221;,
  &#8220;success&#8221;: &#8220;true&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;User successfully deleted!&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;true&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="getsolrusers">account &gt; deployment &gt; solr &gt; auth &gt; get_solr_users</h3>



<p class="wp-block-paragraph">This method gets the Solr users for a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/get-users/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/get-users/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/get-users/&#8221; \
  &#8211;header &#8220;Authorization: APIkey &lt;apikey>&#8221; 
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/get-users/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: APIkey &lt;apikey&gt;&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentsolrauthgetsolrusers.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$RESULT = Invoke-RestMethod -Method Get -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/solr/auth/get-users/&#8221; 
$RESULT = $RESULT | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/solr/auth/get-users/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing the Solr users and the roles associated with them.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;success&#8221;: &#8220;true&#8221;,
  &#8220;users&#8221;: {
    &#8220;demoSolrUser&#8221;: {
      &#8220;roles&#8221;: [ &#8220;Read&#8221;, &#8220;Write&#8221;, &#8220;Admin&#8221; ]
    }
  }
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;true&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;users&quot;</span><span style="color: #24292E">: {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;demoSolrUser&quot;</span><span style="color: #24292E">: {</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;roles&quot;</span><span style="color: #24292E">: [ </span><span style="color: #032F62">&quot;Read&quot;</span><span style="color: #24292E">, </span><span style="color: #032F62">&quot;Write&quot;</span><span style="color: #24292E">, </span><span style="color: #032F62">&quot;Admin&quot;</span><span style="color: #24292E"> ]</span></span>
<span class="line"><span style="color: #24292E">    }</span></span>
<span class="line"><span style="color: #24292E">  }</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="setsolrpassword">account &gt; deployment &gt; solr &gt; auth &gt; set_solr_user_password</h3>



<p class="wp-block-paragraph">This method sets a password for a Solr user.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/set-password/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/set-password/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    &#8220;username&#8221; : &#8220;demoSolrUser&#8221;,
    &#8220;password&#8221;: &#8220;test456&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;username&quot;</span><span style="color: #24292E"> : </span><span style="color: #032F62">&quot;demoSolrUser&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;password&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;test456&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr>
            <th><strong>Parameter</strong></th>
            <th><strong>Description</strong></th>
            <th><strong>Example</strong></th>
         </tr></thead><tbody><tr><td><strong>username</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the Solr user name.</td><td>&#8220;demoSolrUser&#8221;</td></tr><tr><td><strong>password</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the Solr user&#8217;s password.</td><td>&#8220;test456&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request POST &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/set-password/&#8221; \
  &#8211;header &#8220;Authorization: APIkey &lt;apikey>&#8221; \
  &#8211;header &#8220;Content-Type: application/json&#8221; \
  &#8211;data &#8220;{
    \&#8221;username\&#8221; : \&#8221;demoSolrUser\&#8221;,
    \&#8221;password\&#8221;: \&#8221;test456\&#8221;
}&#8221;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/set-password/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: APIkey &lt;apikey&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">username</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">demoSolrUser</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">password</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">test456</span><span style="color: #005CC5">\&quot;</span></span>
<span class="line"><span style="color: #032F62">}&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentsolrauthsetsolruserpassword.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$body = @{
    username=&#8217;demoSolrUser&#8217;
    password=&#8217;test456&#8242;
}
$body = $body | ConvertTo-Json
$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/solr/auth/set-password/&#8221; 
$RESULT = $RESULT | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    username</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;demoSolrUser&#39;</span></span>
<span class="line"><span style="color: #24292E">    password</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;test456&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/solr/auth/set-password/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">This method returns a JSON document containing a success message.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;message&#8221;: &#8220;Password successfully updated!&#8221;,
  &#8220;success&#8221;: &#8220;true&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Password successfully updated!&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;true&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="setsolrrole">account &gt; deployment &gt; solr &gt; auth &gt; set_solr_user_role</h3>



<p class="wp-block-paragraph">This method sets the Solr user&#8217;s role. Available roles are Admin, Read, Write, and ReadWrite.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/set-role/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/set-role/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    &#8220;username&#8221; : &#8220;demoSolrUser&#8221;,
    &#8220;role&#8221; : &#8220;Read&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;username&quot;</span><span style="color: #24292E"> : </span><span style="color: #032F62">&quot;demoSolrUser&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;role&quot;</span><span style="color: #24292E"> : </span><span style="color: #032F62">&quot;Read&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr>
            <th><strong>Parameter</strong></th>
            <th><strong>Description</strong></th>
            <th><strong>Example</strong></th>
         </tr></thead><tbody><tr><td><strong>username</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the Solr user name.</td><td>&#8220;demoSolrUser&#8221;</td></tr><tr><td><strong>role</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>This is the Solr role: Admin, Read, Write, or ReadWrite.</td><td>&#8220;Read&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">See&nbsp;<a href="/docs/security/#solrauth/">Solr Basic Authentication</a>&nbsp;for an explanation of the Solr roles.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request POST &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/solr/auth/set-role/&#8221; \
  &#8211;header &#8220;Authorization: APIkey &lt;apikey>&#8221; \
  &#8211;header &#8220;Content-Type: application/json&#8221; \
  &#8211;data &#8220;{
    \&#8221;username\&#8221; : \&#8221;demoSolrUser\&#8221;,
    \&#8221;role\&#8221; : \&#8221;Read\&#8221;
}&#8221;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/solr/auth/set-role/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: APIkey &lt;apikey&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">username</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">demoSolrUser</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">role</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62"> : </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">Read</span><span style="color: #005CC5">\&quot;</span></span>
<span class="line"><span style="color: #032F62">}&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentsolrauthsetsolruserrole.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$body = @{
    username=&#8217;demoSolrUser&#8217;
    role=&#8217;Read&#8217;
}
$body = $body | ConvertTo-Json
$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/solr/auth/set-role/&#8221; 
$RESULT = $RESULT | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    username</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;demoSolrUser&#39;</span></span>
<span class="line"><span style="color: #24292E">    role</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;Read&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/solr/auth/set-role/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">This method returns a JSON document containing a success message.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;message&#8221;: &#8220;Successfully updated user role!&#8221;,
  &#8220;success&#8221;: &#8220;true&#8221;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Successfully updated user role!&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;true&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h2 class="wp-block-heading" id="questions">Questions?</h2>



<p class="wp-block-paragraph">Do not hesitate to contact the&nbsp;<a href="mailto:support@searchstax.com?subject=SearchStax%20Cloud%20API%20–%20Basic%20Auth" target="_blank" rel="noreferrer noopener">SearchStax Support Desk</a>.</p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-basic-auth-api/">Solr Basic Auth API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.searchstax.com/docs/searchstax-cloud-basic-auth-api/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Solr IP Filtering API</title>
		<link>https://www.searchstax.com/docs/searchstax-cloud-ipfilter-api/</link>
					<comments>https://www.searchstax.com/docs/searchstax-cloud-ipfilter-api/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Thu, 04 Mar 2021 09:57:52 +0000</pubDate>
				<category><![CDATA[Access and Security APIs]]></category>
		<category><![CDATA[Cloud]]></category>
		<guid isPermaLink="false">https://www.searchstax.com/docs/?p=7653</guid>

					<description><![CDATA[<p>Provisioning API &#8211; IP Filtering Overview The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr deployments. Core and Enterprise Clients Only! The&#8230; <a class="more-link" href="https://www.searchstax.com/docs/searchstax-cloud-ipfilter-api/">Continue reading <span class="screen-reader-text">Solr IP Filtering API</span></a></p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-ipfilter-api/">Solr IP Filtering API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h1 class="wp-block-heading" id="searchstax-managed-solr-api-ip-filtering">Provisioning API &#8211; IP Filtering</h1>



<hr class="wp-block-separator has-css-opacity"/>



<h2 class="wp-block-heading" id="overview">Overview</h2>



<p class="wp-block-paragraph">The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr deployments.</p>



<div class="alert alert-info">
<h3>Core and Enterprise Clients Only!</h3>
<p>The SearchStax API suite is available to our Core and Enterprise
clients only, as noted on our <a href="https://www.searchstax.com/pricing/cloud/">Pricing</a> page. </p>
</div>



<p class="wp-block-paragraph">This page describes how to set up IP Filtering using the API methods.</p>



<p class="wp-block-paragraph">The API can be accessed through any tool that assembles HTTP requests and dispatch them to a server. Among these would be the Python&nbsp;<a href="https://pypi.org/project/coreapi/" target="_blank" rel="noreferrer noopener">coreapi</a>&nbsp;package, the&nbsp;<a href="https://www.postman.com/" target="_blank" rel="noreferrer noopener">Postman</a>&nbsp;tool, and&nbsp;<a href="https://curl.se" target="_blank" rel="noreferrer noopener">cURL</a>. For Windows, use&nbsp;<a href="https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1" target="_blank" rel="noreferrer noopener">PowerShell 7+</a>.</p>



<div class="alert alert-warning">
<h3>Account Owner, Admin, or Technical Contact</h3>
<p>To run the SearchStax Provisioning API, you must be the account Owner,
an account Admin, or a Technical Contact. See <a href="/docs/searchstax-cloud-user-roles/#userroles">SearchStax User Roles</a>.</p>
</div>



<p class="wp-block-paragraph">Symbols enclosed in carets (&lt; and &gt;) such as&nbsp;<strong>&lt;username&gt;</strong>&nbsp;are metavariables. Substitute your local values when you encounter them in the examples.</p>



<p class="wp-block-paragraph">Contents:</p>



<ul class="wp-block-list">
<li><a href="#ipfiltering">IP Filtering</a>
<ul class="wp-block-list">
<li><a href="#ipfilterlist">account &gt; deployment &gt; ip-filter &gt; list</a></li>



<li><a href="#IPadd">account &gt; deployment &gt; ip-filter &gt; add_cidr_ip</a></li>



<li><a href="#IPdelete">account &gt; deployment &gt; ip-filter &gt; delete_cidr_ip</a></li>



<li><a href="#ipupdate">account &gt; deployment &gt; ip-filter &gt; update_cidr_ip</a></li>
</ul>
</li>
</ul>



<p class="wp-block-paragraph">Related Pages:</p>



<ul class="wp-block-list">
<li><a href="/docs/searchstax-cloud-authentication-api/">Authentication API</a></li>



<li><a href="/docs/searchstax-cloud-users-api/">Users API</a></li>



<li><a href="/docs/searchstax-cloud-basic-auth-api/">Basic Auth API</a></li>



<li><a href="/docs/searchstax-cloud-deployment-api/">Deployment API</a></li>



<li><a href="/docs/searchstax-cloud-private-vpc-api/">Private VPC API</a></li>



<li><a href="/docs/searchstax-cloud-dns-alias-api/">DNS Alias API</a></li>



<li><a href="/docs/searchstax-cloud-backup-restore-api/">Backup/Restore API</a></li>



<li><a href="/docs/searchstax-cloud-custom-jars-api/">Custom JARs API</a></li>



<li><a href="/docs/searchstax-cloud-tags-api/">Tags API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Alerts API</a></li>



<li><a href="/docs/searchstax-cloud-webhooks-api/">Webhooks API</a></li>



<li><a href="/docs/searchstax-cloud-zookeeper-api/">Zookeeper API</a></li>
</ul>



<h2 class="wp-block-heading" id="ipfiltering">IP Filtering</h2>



<p class="wp-block-paragraph">The SearchStax Provisioning API includes methods for applying IP Filters to deployments.</p>



<h3 class="wp-block-heading" id="ipfilterlist">account &gt; deployment &gt; ip-filter &gt; list</h3>



<p class="wp-block-paragraph">This method returns a list of IP Filters from a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET /api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/ip-filter/?page=&lt;n>
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/ip-filter/?page=&lt;n&gt;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment. The query parameter&nbsp;<strong>page</strong>&nbsp;is a number,&nbsp;<strong>&lt;n&gt;</strong>, that defaults to 1.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/ip-filter/?page=&lt;n>&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; 
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/ip-filter/?page=&lt;n&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentipfilterlist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;

$RESULTS = Invoke-RestMethod -Method Get -Headers $headers `
          -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/ip-filter/?page=1&#8221; 
$RESULTS = $RESULTS | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">          </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/ip-filter/?page=1&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULTS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing a list of IP Filters.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>[
  {
    &#8220;services&#8221;: [
      &#8220;solr&#8221;
    ],
    &#8220;cidr_ip&#8221;: &#8220;0.0.0.0/0&#8221;,
    &#8220;description&#8221;: &#8220;&#8221;
  }
]
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">[</span></span>
<span class="line"><span style="color: #24292E">  {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;services&quot;</span><span style="color: #24292E">: [</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;solr&quot;</span></span>
<span class="line"><span style="color: #24292E">    ],</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;cidr_ip&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;0.0.0.0/0&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;description&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;&quot;</span></span>
<span class="line"><span style="color: #24292E">  }</span></span>
<span class="line"><span style="color: #24292E">]</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="IPadd">account &gt; deployment &gt; ip-filter &gt; add-cidr-ip</h3>



<div class="alert alert-warning">
<h3>Setting IP Filters on Azure Deployments</h3>
<p>When using add-cidr-ip in an Azure environment, IP filters for Zookeeper and Solr must both be explicitly set.</p>
<p>SearchStax requires Zookeeper to be locked down by IP filters. To then leave Solr open to any connection (a common request), set the Solr IP filter to &#8216;0.0.0.0/0&#8217;.</p>
</div>



<p class="wp-block-paragraph">This method adds a new IP Filter to a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/ip-filter/add-cidr-ip/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/ip-filter/add-cidr-ip/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    services=@(&#8216;solr&#8217;,&#8217;zk&#8217;)
    cidr_ip=&#8217;100.100.100.100&#8242;
    description=&#8217;Added by API&#8217;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">services=@(&#39;solr&#39;,&#39;zk&#39;)</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">cidr_ip=&#39;100.100.100.100&#39;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">description=&#39;Added</span><span style="color: #24292E"> </span><span style="color: #B31D28; font-style: italic">by</span><span style="color: #24292E"> </span><span style="color: #B31D28; font-style: italic">API&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped">
<table>
<thead>
<tr>
<th><strong>Parameter</strong></th>
<th><strong>Description</strong></th>
<th><strong>Example</strong></th>
</tr>
</thead>
<tbody>
<tr>
<td><strong>services</strong><br><span class="has-inline-color" style="color: #ff0000;">required</span><br>list of strings</td>
<td>Which services to apply the filter to. Allowed values are &#8216;solr&#8217; and &#8216;zk&#8217;.</td>
<td>(&#8216;solr&#8217;,&#8217;zk&#8217;)</td>
</tr>
<tr>
<td><strong>cidr_ip</strong><br><span class="has-inline-color" style="color: #ff0000;">required</span><br>string</td>
<td>The IP address.</td>
<td>&#8220;100.100.100.100&#8221;</td>
</tr>
<tr>
<td><strong>description</strong><br><span class="has-inline-color" style="color: #32cd32;">optional</span><br>string</td>
<td>A very brief label.</td>
<td>&#8220;Added by API&#8221;</td>
</tr>
</tbody>
</table>
</figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request POST &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/ip-filter/add-cidr-ip/&#8221; \
  &#8211;header &#8220;Content-Type: application/json&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; \
  &#8211;data &#8216;{&#8220;services&#8221;:[&#8220;solr&#8221;,&#8221;zk&#8221;],&#8221;cidr_ip&#8221;:&#8221;100.100.100.100&#8243;,&#8221;description&#8221;:&#8221;Added by API&#8221;}&#8217;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/ip-filter/add-cidr-ip/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;{&quot;services&quot;:[&quot;solr&quot;,&quot;zk&quot;],&quot;cidr_ip&quot;:&quot;100.100.100.100&quot;,&quot;description&quot;:&quot;Added by API&quot;}&#39;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentipfilteraddcidrip.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;

$body = @{
    services=@(&#8216;solr&#8217;,&#8217;zk&#8217;)
    cidr_ip=&#8217;100.100.100.100&#8242;
    description=&#8217;Added by PowerShell&#8217;
}
$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/ip-filter/add-cidr-ip/&#8221; 
$RESULT = $RESULT | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    services</span><span style="color: #D73A49">=@</span><span style="color: #24292E">(</span><span style="color: #032F62">&#39;solr&#39;</span><span style="color: #D73A49">,</span><span style="color: #032F62">&#39;zk&#39;</span><span style="color: #24292E">)</span></span>
<span class="line"><span style="color: #24292E">    cidr_ip</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;100.100.100.100&#39;</span></span>
<span class="line"><span style="color: #24292E">    description</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;Added by PowerShell&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/ip-filter/add-cidr-ip/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document confirming success.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;detail&#8221;: null,
  &#8220;success&#8221;: true
}

</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;detail&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="IPdelete">account &gt; deployment &gt; ip-filter &gt; delete-cidr-ip</h3>



<p class="wp-block-paragraph">This method deletes an IP Filter from a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/ip-filter/delete-cidr-ip/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/ip-filter/delete-cidr-ip/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    cidr_ip=&#8217;100.100.100.100&#8242;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">cidr_ip=&#39;100.100.100.100&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>


<figure class="wp-block-table table table-bordered table-striped">
<table>
<thead>
<tr>
<th><strong>Parameter</strong></th>
<th><strong>Description</strong></th>
<th><strong>Example</strong></th>
</tr>
</thead>
<tbody>
<tr>
<td><strong>cidr_ip</strong><br /><span class="has-inline-color" style="color: #ff0000;">required</span><br />string</td>
<td>The IP address of the filter to delete.</td>
<td>&#8220;100.100.100.100&#8221;</td>
</tr>
</tbody>
</table>
</figure>


<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request POST &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/ip-filter/delete-cidr-ip/&#8221; \
  &#8211;header &#8220;Content-Type: application/json&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; \
  &#8211;data &#8216;{&#8220;cidr_ip&#8221;:&#8221;100.100.100.100&#8243;}&#8217;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/ip-filter/delete-cidr-ip/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;{&quot;cidr_ip&quot;:&quot;100.100.100.100&quot;}&#39;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentipfilterdeletecidrip.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;

$body = @{
    cidr_ip=&#8217;100.100.100.100&#8242;
}
$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/ip-filter/delete-cidr-ip/&#8221; 
$RESULT = $RESULT | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    cidr_ip</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;100.100.100.100&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/ip-filter/delete-cidr-ip/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document confirming success.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;detail&#8221;: null,
  &#8220;success&#8221;: true
}

</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;detail&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="ipupdate">account &gt; deployment &gt; ip-filter &gt; update-cidr-ip</h3>



<p class="wp-block-paragraph">This method updates an IP Filter in a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/ip-filter/update-cidr-ip/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/ip-filter/update-cidr-ip/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    services=@(&#8216;solr&#8217;,&#8217;zk&#8217;)
    cidr_ip=&#8217;100.100.100.100&#8242;
    description=&#8217;Updated by API&#8217;
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">services=@(&#39;solr&#39;,&#39;zk&#39;)</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">cidr_ip=&#39;100.100.100.100&#39;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">description=&#39;Updated</span><span style="color: #24292E"> </span><span style="color: #B31D28; font-style: italic">by</span><span style="color: #24292E"> </span><span style="color: #B31D28; font-style: italic">API&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>


<figure class="wp-block-table table table-bordered table-striped">
<table>
<thead>
<tr>
<th><strong>Parameter</strong></th>
<th><strong>Description</strong></th>
<th><strong>Example</strong></th>
</tr>
</thead>
<tbody>
<tr>
<td><strong>services</strong><br /><span class="has-inline-color" style="color: #ff0000;">required</span><br />list of strings</td>
<td>Which services to apply the filter to. Allowed values are &#8216;solr&#8217; and &#8216;zk&#8217;.</td>
<td>(&#8216;solr&#8217;,&#8217;zk&#8217;)</td>
</tr>
<tr>
<td><strong>cidr_ip</strong><br /><span class="has-inline-color" style="color: #ff0000;">required</span><br />string</td>
<td>The IP address.</td>
<td>&#8220;100.100.100.100&#8221;</td>
</tr>
<tr>
<td><strong>description</strong><br /><span class="has-inline-color" style="color: #32cd32;">optional</span><br />string</td>
<td>A very brief label.</td>
<td>&#8220;Added by API&#8221;</td>
</tr>
</tbody>
</table>
</figure>


<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request POST &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/ip-filter/add-cidr-ip/&#8221; \
  &#8211;header &#8220;Content-Type: application/json&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; \
  &#8211;data &#8216;{&#8220;services&#8221;:[&#8220;solr&#8221;,&#8221;zk&#8221;],&#8221;cidr_ip&#8221;:&#8221;100.100.100.100&#8243;,&#8221;description&#8221;:&#8221;Updated by API&#8221;}&#8217;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/ip-filter/add-cidr-ip/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;{&quot;services&quot;:[&quot;solr&quot;,&quot;zk&quot;],&quot;cidr_ip&quot;:&quot;100.100.100.100&quot;,&quot;description&quot;:&quot;Updated by API&quot;}&#39;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentipfilterupdatecidrip.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;

$body = @{
    services=@(&#8216;solr&#8217;,&#8217;zk&#8217;)
    cidr_ip=&#8217;100.100.100.100&#8242;
    description=&#8217;Updated by PowerShell&#8217;
}
$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/ip-filter/update-cidr-ip/&#8221; 
$RESULT = $RESULT | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    services</span><span style="color: #D73A49">=@</span><span style="color: #24292E">(</span><span style="color: #032F62">&#39;solr&#39;</span><span style="color: #D73A49">,</span><span style="color: #032F62">&#39;zk&#39;</span><span style="color: #24292E">)</span></span>
<span class="line"><span style="color: #24292E">    cidr_ip</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;100.100.100.100&#39;</span></span>
<span class="line"><span style="color: #24292E">    description</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;Updated by PowerShell&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/ip-filter/update-cidr-ip/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document confirming success.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;detail&#8221;: null,
  &#8220;success&#8221;: true
}

</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;detail&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"></span></code></pre></div>



<h2 class="wp-block-heading" id="questions">Questions?</h2>



<p class="wp-block-paragraph">Do not hesitate to contact the&nbsp;<a href="mailto:support@searchstax.com?subject=SearchStax%20Cloud%20API%20–%20IP%20Filtering" target="_blank" rel="noreferrer noopener">SearchStax Support Desk</a>.</p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-ipfilter-api/">Solr IP Filtering API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.searchstax.com/docs/searchstax-cloud-ipfilter-api/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Solr Deployment API</title>
		<link>https://www.searchstax.com/docs/searchstax-cloud-deployment-api/</link>
					<comments>https://www.searchstax.com/docs/searchstax-cloud-deployment-api/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Thu, 04 Mar 2021 09:15:08 +0000</pubDate>
				<category><![CDATA[Deployment and Networking APIs]]></category>
		<category><![CDATA[Cloud]]></category>
		<guid isPermaLink="false">https://www.searchstax.com/docs/?p=7637</guid>

					<description><![CDATA[<p>Provisioning API &#8211; Deployments Overview The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr deployments. Core and Enterprise Clients Only! The SearchStax&#8230; <a class="more-link" href="https://www.searchstax.com/docs/searchstax-cloud-deployment-api/">Continue reading <span class="screen-reader-text">Solr Deployment API</span></a></p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-deployment-api/">Solr Deployment API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h1 class="wp-block-heading" id="h-provisioning-api-deployments">Provisioning API &#8211; Deployments</h1>



<hr class="wp-block-separator has-css-opacity"/>



<h2 class="wp-block-heading">Overview</h2>



<p class="wp-block-paragraph">The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr deployments.</p>



<div class="alert alert-info">
<h3>Core and Enterprise Clients Only!</h3>
<p>The SearchStax API suite is available to our Core and Enterprise
clients only, as noted on our <a href="https://www.searchstax.com/pricing/cloud/">Pricing</a> page. </p>
</div>



<p class="wp-block-paragraph">This page describes how to create and manage deployments using API methods.</p>



<p class="wp-block-paragraph">The API can be accessed through any tool that assembles HTTP requests and dispatches them to a server. Among these would be the Python&nbsp;<a href="https://pypi.org/project/coreapi/" target="_blank" rel="noreferrer noopener">coreapi</a>&nbsp;package, the&nbsp;<a href="https://www.postman.com/" target="_blank" rel="noreferrer noopener">Postman</a>&nbsp;tool, and&nbsp;<a href="https://www.postman.com/" target="_blank" rel="noreferrer noopener">cURL</a>. For Windows, use&nbsp;<a href="https://learn.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.2&amp;viewFallbackFrom=powershell-7.1" target="_blank" rel="noreferrer noopener">PowerShell 7+</a>.</p>



<div class="alert alert-warning">
<h3>Account Owner, Admin, or Technical Contact</h3>
<p>To run the SearchStax Provisioning API, you must be the account Owner,
an account Admin, or a Technical Contact. See <a href="/docs/searchstax-cloud-user-roles/#userroles">SearchStax User Roles</a>.</p>
</div>



<p class="wp-block-paragraph">Symbols enclosed in carets (&lt; and &gt;) such as&nbsp;<strong>&lt;username&gt;</strong>&nbsp;are metavariables. Substitute your local values when you encounter them in the examples.</p>



<p class="wp-block-paragraph">Contents:</p>



<ul class="wp-block-list">
<li><a href="#deployment">Deployment</a>
<ul class="wp-block-list">
<li><a href="#createdeployment">account &gt; deployment &gt; create</a></li>



<li><a href="#deletedeployment">account &gt; deployment &gt; delete</a></li>



<li><a href="#listdeployment">account &gt; deployment &gt; list</a></li>



<li><a href="#accountdepdetail">account &gt; deployment &gt; read</a></li>



<li><a href="#deploymenthealth">account &gt; deployment &gt; get_deployment_health</a></li>



<li><a href="#collections">account &gt; deployment &gt; collections_health</a></li>



<li><a href="#rollingrestart">account &gt; deployment &gt; rolling_restart</a></li>



<li><a href="#start">account &gt; deployment &gt; server &gt; start_solr</a></li>



<li><a href="#stop">account &gt; deployment &gt; server &gt; stop_solr</a></li>



<li><a href="#status">account &gt; deployment &gt; server &gt; host_status</a></li>



<li><a href="#listnodes">account &gt; deployment &gt; server &gt; list</a></li>



<li><a href="#listplans">account &gt; plan &gt; list</a></li>



<li><a href="#usage">account &gt; usage &gt; list</a></li>



<li><a href="#usage-extended">account &gt; usage-extended &gt; list</a></li>
</ul>
</li>
</ul>



<p class="wp-block-paragraph">Related Pages:</p>



<ul class="wp-block-list">
<li><a href="/docs/searchstax-cloud-authentication-api/">Authentication API</a></li>



<li><a href="/docs/searchstax-cloud-users-api/">Users API</a></li>



<li><a href="/docs/searchstax-cloud-basic-auth-api/">Basic Auth API</a></li>



<li><a href="/docs/searchstax-cloud-ipfilter-api/">IP Filtering API</a></li>



<li><a href="/docs/searchstax-cloud-private-vpc-api/">Private VPC API</a></li>



<li><a href="/docs/searchstax-cloud-dns-alias-api/">DNS Alias API</a></li>



<li><a href="/docs/searchstax-cloud-backup-restore-api/">Backup/Restore API</a></li>



<li><a href="/docs/searchstax-cloud-custom-jars-api/">Custom JARs API</a></li>



<li><a href="/docs/searchstax-cloud-tags-api/">Tags API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Alerts API</a></li>



<li><a href="/docs/searchstax-cloud-webhooks-api/">Webhooks API</a></li>



<li><a href="/docs/searchstax-cloud-zookeeper-api/">Zookeeper API</a></li>
</ul>



<h2 class="wp-block-heading" id="deployment">Deployment</h2>



<h3 class="wp-block-heading" id="createdeployment">account &gt; deployment &gt; create</h3>



<p class="wp-block-paragraph">This method lets you create a new deployment. Note that a successful response indicates only that deployment creation was authorized and has begun. It can take up to an hour to bring a new deployment on line depending on the cloud provider.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "name": "SolrFromAPI",
    "application": "Solr",
    "application_version": "7.3.1",
    "termination_lock": false,
    "plan_type": "DedicatedDeployment",
    "plan": "NDN2-AWS-S",
    "region_id": "ap-northeast-1",
    "cloud_provider_id": "aws",
    "num_additional_app_nodes": 0
    "private_vpc": 2
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;SolrFromAPI&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;application&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Solr&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;application_version&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;7.3.1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;termination_lock&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;plan_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;DedicatedDeployment&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;plan&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;NDN2-AWS-S&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;region_id&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ap-northeast-1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;cloud_provider_id&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;aws&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;num_additional_app_nodes&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #032F62">&quot;private_vpc&quot;</span><span style="color: #B31D28; font-style: italic">:</span><span style="color: #24292E"> </span><span style="color: #005CC5">2</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>name</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>The name of the new deployment</td><td>&#8220;SolrFromAPI&#8221;</td></tr><tr><td><strong>application</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>The application for which this deployment is being created.</td><td>&#8220;Solr&#8221;</td></tr><tr><td><strong>application_version</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>The version of application being deployed. Detailed information regarding application versions is available from the <a href="#listplans">List Plans</a> method.</td><td>&#8220;7.3.1&#8221;</td></tr><tr><td><strong>termination_lock</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>boolean</td><td>Whether or not the deployment should be shielded from API deletion.</td><td>false</td></tr><tr><td><strong>plan_type</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>Available plan type could be SharedDeployment or DedicatedDeployment. Currently SearchStax only supports DedicatedDeployment (the default).</td><td>&#8220;DedicatedDeployment&#8221;</td></tr><tr><td><strong>plan</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>The plan of the selected plan type. Detailed information regarding plans available can be fetched using <a href="#listplans">List Plans</a> method.</td><td>&#8220;NDN2-AWS-S&#8221;</td></tr><tr><td><strong>region_id</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>The region ID of the region where deployment has to be created. Detailed information regarding regions available can be fetched using <a href="#listplans">List Plans</a> method.</td><td>&#8220;ap-northeast-1&#8221;</td></tr><tr><td><strong>cloud_provider_id</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>The cloud provider to be used to create this deployment. Detailed information regarding cloud providers available can be fetched using <a href="#listplans">List Plans</a> method.</td><td>&#8220;aws&#8221; &#8220;azure&#8221; &#8220;gcp&#8221;</td></tr><tr><td><strong>num_additional_app_nodes</strong><br><span style="color:#32cd32" class="has-inline-color">optional</span><br>number</td><td>The number of additional nodes to be added to the deployment beyond the default number of nodes.<br><br>If the deployment will grow to a large number of nodes, create it with 10 &#8220;additional&#8221; nodes. This allocates a large IP subnet that can scale up gracefully. You may then use the SearchStax Dashboard to manage the actual number of nodes up or down as needed.</td><td>&#8220;10&#8221;</td></tr><tr><td><strong>private_vpc</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#32cd32" class="has-inline-color">optional</mark><br>number</td><td>The ID of the Private VPC where the new deployment will appear. Private VPC IDs are available from the <a href="/docs/searchstax-cloud-private-vpc-api/#VPClist">account &gt; privatevpc &gt; list</a> method.</td><td>&#8220;2&#8221;</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request POST "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/" \
  --header "Content-Type: application/json" \
  --header "Authorization: Token &lt;token>" \
  --data "{
    \"name\": \"SolrFromAPI\",
    \"application\": \"Solr\",
    \"application_version\": \"7.3.1\",
    \"termination_lock\": false,
    \"plan_type\": \"DedicatedDeployment\",
    \"plan\": \"NDN2-AWS-S\",
    \"region_id\": \"ap-northeast-1\",
    \"cloud_provider_id\": \"aws\",
    \"num_additional_app_nodes\": \"0\"
    \"private_vpc\": \"2\"
    }"</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">name</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">SolrFromAPI</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">application</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">Solr</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">application_version</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">7.3.1</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">termination_lock</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: false,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">plan_type</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">DedicatedDeployment</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">plan</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">NDN2-AWS-S</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">region_id</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">ap-northeast-1</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">cloud_provider_id</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">aws</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">num_additional_app_nodes</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">0</span><span style="color: #005CC5">\&quot;</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">private_vpc</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">2</span><span style="color: #005CC5">\&quot;</span></span>
<span class="line"><span style="color: #032F62">    }&quot;</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentcreate.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"

$body = @{
    name='SolrFromAPI'
    application='Solr'
    application_version='7.5.0'
    termination_lock='false'
    plan_type='DedicatedDeployment'
    plan='NDN2-AWS-S'
    region_id='us-west-1'
    cloud_provider_id='aws'
    num_additional_app_nodes='0'
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -Body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/" 
$RESULT = $RESULT | ConvertTo-Json</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    name</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;SolrFromAPI&#39;</span></span>
<span class="line"><span style="color: #24292E">    application</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;Solr&#39;</span></span>
<span class="line"><span style="color: #24292E">    application_version</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;7.5.0&#39;</span></span>
<span class="line"><span style="color: #24292E">    termination_lock</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;false&#39;</span></span>
<span class="line"><span style="color: #24292E">    plan_type</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;DedicatedDeployment&#39;</span></span>
<span class="line"><span style="color: #24292E">    plan</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;NDN2-AWS-S&#39;</span></span>
<span class="line"><span style="color: #24292E">    region_id</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;us-west-1&#39;</span></span>
<span class="line"><span style="color: #24292E">    cloud_provider_id</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;aws&#39;</span></span>
<span class="line"><span style="color: #24292E">    num_additional_app_nodes</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;0&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">Body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing &#8230;</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "name": "SolrFromAPI",
  "uid": "ss123456",
  "application": "Solr",
  "application_version": "7.5.0",
  "tier": "Development",
  "http_endpoint": null,
  "status": "Pending",
  "provision_state": "Pending",
  "termination_lock": false,
  "plan_type": "DedicatedDeployment",
  "plan": "NDN2-AWS-S",
  "is_master_slave": false,
  "vpc_type": "Public",
  "vpc_name": "",
  "region_id": "us-west-1",
  "cloud_provider": "Amazon Web Services"
  "cloud_provider_id": "aws",
  "num_additional_app_nodes": 0,
  "deployment_type": "Dedicated Node",
  "num_nodes_default": 1,
  "num_zookeeper_nodes_default": 0,
  "num_additional_zookeeper_nodes": 0,
  "servers": [],
  "zookeeper_ensemble": null,
  "tag": [],
  "specifications": {
    "jvm_heap_memory": "536870912",
    "disk_space": "8589934592",
    "physical_memory": "1073741824"
  },
  "backups_enabled": false,
  "dr_enabled": false,
  "sla_active": false,
  "state_changed": null,
  "term_end": null,
  "date_created": "2023-01-25",
  "application_nodes_count": 1,
  "selected_node_count": 0,
  "savings": {
    "one_year_saving_perc": "52.38",
    "three_year_saving_perc": "59.52"
  },
  "dr_plan_type": null,
  "subscription": "monthly",
  "security_pack": false,
  "desired_tier": "development",
  "backup": null,
  "onboarding": false,
  "selected_plan_memory": 0.0,
  "selected_plan_storage": 0.0,
  "dr": null,
  "payment_method": null,
  "purchase_order": null
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;SolrFromAPI&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;uid&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;application&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Solr&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;application_version&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;7.5.0&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;tier&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Development&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;http_endpoint&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Pending&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;provision_state&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Pending&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;termination_lock&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;plan_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;DedicatedDeployment&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;plan&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;NDN2-AWS-S&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;is_master_slave&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;vpc_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Public&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;vpc_name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;region_id&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;us-west-1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;cloud_provider&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Amazon Web Services&quot;</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #032F62">&quot;cloud_provider_id&quot;</span><span style="color: #B31D28; font-style: italic">:</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;aws&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;num_additional_app_nodes&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;deployment_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Dedicated Node&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;num_nodes_default&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">1</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;num_zookeeper_nodes_default&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;num_additional_zookeeper_nodes&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;servers&quot;</span><span style="color: #24292E">: [],</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;zookeeper_ensemble&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;tag&quot;</span><span style="color: #24292E">: [],</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;specifications&quot;</span><span style="color: #24292E">: {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;jvm_heap_memory&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;536870912&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;disk_space&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;8589934592&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;physical_memory&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;1073741824&quot;</span></span>
<span class="line"><span style="color: #24292E">  },</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;backups_enabled&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;dr_enabled&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;sla_active&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;state_changed&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;term_end&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;date_created&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2023-01-25&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;application_nodes_count&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">1</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;selected_node_count&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;savings&quot;</span><span style="color: #24292E">: {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;one_year_saving_perc&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;52.38&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;three_year_saving_perc&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;59.52&quot;</span></span>
<span class="line"><span style="color: #24292E">  },</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;dr_plan_type&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;subscription&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;monthly&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;security_pack&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;desired_tier&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;development&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;backup&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;onboarding&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;selected_plan_memory&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0.0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;selected_plan_storage&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0.0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;dr&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;payment_method&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;purchase_order&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<p class="wp-block-paragraph">Note that the&nbsp;<strong>servers</strong>&nbsp;and the&nbsp;<strong>zookeeper_ensemble</strong>&nbsp;values are not initially available because those entities take time to create. Wait until the deployment is up and running, and then use the&nbsp;<a href="/docs/searchstax-cloud-deployment-api/#listdeployment/">account &gt; deployment &gt; list</a>&nbsp;method (below).</p>



<h3 class="wp-block-heading" id="deletedeployment">account &gt; deployment &gt; delete</h3>



<p class="wp-block-paragraph">This method deletes a deployment from the tenant account. Note that a successful response means only that the deletion process was authorized and has begun. It can take up to an hour to delete a deployment depending on the cloud provider.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>DELETE https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">DELETE</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "retain_backups": false
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;retain_backups&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>retain_backups</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color"><span style="color:#32cd32" class="has-inline-color">optional</span></mark> <br>boolean<br></td><td>If true, will not delete the scheduled backups. Default is false.</td><td>false</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request DELETE "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/" \
  --header "Authorization: Token &lt;token>" \
  --data "{
    \"retain_backups\": false
    }"</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">DELETE</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">retain_backups</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: false</span></span>
<span class="line"><span style="color: #032F62">    }&quot;</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentdelete.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"

$body = @{
    retain_backups='false'
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Delete -Body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/" 
$RESULT = $RESULT | ConvertTo-Json</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    retain_backups</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;false&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Delete </span><span style="color: #D73A49">-</span><span style="color: #24292E">Body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">A success response will identify the deleted deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "success": "true",
  "message": "Successfully deleted ss123456",
  "retain_backups": "false"
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;true&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Successfully deleted ss123456&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;retain_backups&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;false&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<p class="wp-block-paragraph">Invalid UID will throw a&nbsp;<strong>Not Found</strong>&nbsp;error.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "detail": "Not found."
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;detail&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Not found.&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<div class="alert alert-danger">
<h3>Subject to Termination Lock</h3>
<p>The <strong>Termination Lock</strong> button on the Deployment Details page in the SearchStax Dashboard protects the deployment from API deletion until the lock is released.</p>
</div>



<p class="wp-block-paragraph">If the Termination Lock is set, you&#8217;ll see a message like this one:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
   "detail":"This deployment has Termination Lock enabled. Please first remove the termination lock, and then retry deleting the deployment."
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">   </span><span style="color: #005CC5">&quot;detail&quot;</span><span style="color: #24292E">:</span><span style="color: #032F62">&quot;This deployment has Termination Lock enabled. Please first remove the termination lock, and then retry deleting the deployment.&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<h3 class="wp-block-heading" id="listdeployment">account &gt; deployment &gt; list</h3>



<p class="wp-block-paragraph">This method lists the deployments of an account along with their deployment details.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/?page=&lt;n>&amp;page_size=&lt;m>
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/?page=&lt;n&gt;&amp;page_size=&lt;m&gt;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account;&nbsp;<strong>page</strong>&nbsp;(optional) is the page number of a multi-page list; and&nbsp;<strong>page_size</strong>&nbsp;(optional) is the number of deployments to include on a page.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221;</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentlist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$DEPLOYMENTS = Invoke-RestMethod -Method Get -ContentType &#8216;application/json&#8217; -Headers $headers `
              -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/&#8221; 
$DEPLOYMENTS = $DEPLOYMENTS | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$DEPLOYMENTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$DEPLOYMENTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $DEPLOYMENTS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">A successful response contains a JSON object containing a list of deployment descriptions. Note that&nbsp;<strong>next</strong>&nbsp;and&nbsp;<strong>previous</strong>&nbsp;are literal URLs that fetch the next and previous pages of a multi-page list of deployments.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;count&#8221;: 3,
  &#8220;next&#8221;: null,
  &#8220;previous&#8221;: null,
  &#8220;results&#8221;: [
    {
      &#8220;name&#8221;: &#8220;ListByAPI&#8221;,
      &#8220;uid&#8221;: &#8220;ss123456&#8221;,
      &#8220;application&#8221;: &#8220;Solr&#8221;,
      &#8220;application_version&#8221;: &#8220;8.11.2&#8221;,
      &#8220;tier&#8221;: &#8220;Development&#8221;,
      &#8220;http_endpoint&#8221;: &#8220;https://ss123456-7hp6b4y0-us-west-1-aws.searchstax.com/solr/&#8221;,
      &#8220;status&#8221;: &#8220;Configuring Deployment&#8221;,
      &#8220;provision_state&#8221;: &#8220;Pending&#8221;,
      &#8220;termination_lock&#8221;: false,
      &#8220;plan_type&#8221;: &#8220;DedicatedDeployment&#8221;,
      &#8220;plan&#8221;: &#8220;NDC128-AWS-G&#8221;,
      &#8220;is_master_slave&#8221;: false,
      &#8220;vpc_type&#8221;: &#8220;Public&#8221;,
      &#8220;vpc_name&#8221;: &#8220;&#8221;,
      &#8220;region_id&#8221;: &#8220;us-west-1&#8221;,
      &#8220;cloud_provider&#8221;: &#8220;Amazon Web Services&#8221;,
      &#8220;cloud_provider_id&#8221;: &#8220;aws&#8221;,
      &#8220;num_additional_app_nodes&#8221;: 0,
      &#8220;deployment_type&#8221;: &#8220;Dedicated Cluster&#8221;,
      &#8220;num_nodes_default&#8221;: 2,
      &#8220;num_zookeeper_nodes_default&#8221;: 3,
      &#8220;num_additional_zookeeper_nodes&#8221;: 0,
      &#8220;servers&#8221;: &#8220;ss123456-5 ss123456-4 ss123456-3 ss123456-2 ss123456-1&#8221;,
      &#8220;zookeeper_ensemble&#8221;: &#8220;ss123456-7hp6b4y0-1-us-west-1-aws.searchstax.com:2181,ss123456-7hp6b4y0-2-us-west-1-aws.
rchstax.com:2181,ss123456-7hp6b4y0-3-us-west-1-aws.searchstax.com:2181&#8221;,
      &#8220;tag&#8221;: &#8220;&#8221;,
      &#8220;specifications&#8221;: &#8220;@{disk_space=; physical_memory=; jvm_heap_memory=}&#8221;,
      &#8220;backups_enabled&#8221;: false,
      &#8220;dr_enabled&#8221;: false,
      &#8220;sla_active&#8221;: false,
      &#8220;state_changed&#8221;: null,
      &#8220;term_end&#8221;: null,
      &#8220;date_created&#8221;: &#8220;2023-01-25&#8221;,
      &#8220;application_nodes_count&#8221;: 2,
      &#8220;selected_node_count&#8221;: 0,
      &#8220;savings&#8221;: &#8220;@{one_year_saving_perc=0.00; three_year_saving_perc=15.00}&#8221;,
      &#8220;dr_plan_type&#8221;: null,
      &#8220;subscription&#8221;: &#8220;yearly&#8221;,
      &#8220;security_pack&#8221;: false,
      &#8220;desired_tier&#8221;: &#8220;development&#8221;,
      &#8220;backup&#8221;: null,
      &#8220;onboarding&#8221;: false,
      &#8220;selected_plan_memory&#8221;: 0.0,
      &#8220;selected_plan_storage&#8221;: 0.0,
      &#8220;dr&#8221;: null,
      &#8220;payment_method&#8221;: null,
      &#8220;purchase_order&#8221;: null
    }, &lt;plus more deployments, if any&#8230;></textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;count&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">3</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;next&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;previous&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;results&quot;</span><span style="color: #24292E">: [</span></span>
<span class="line"><span style="color: #24292E">    {</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ListByAPI&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;uid&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;application&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Solr&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;application_version&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;8.11.2&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;tier&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Development&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;http_endpoint&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;https://ss123456-7hp6b4y0-us-west-1-aws.searchstax.com/solr/&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Configuring Deployment&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;provision_state&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Pending&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;termination_lock&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;plan_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;DedicatedDeployment&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;plan&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;NDC128-AWS-G&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;is_master_slave&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;vpc_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Public&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;vpc_name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;region_id&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;us-west-1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;cloud_provider&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Amazon Web Services&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;cloud_provider_id&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;aws&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;num_additional_app_nodes&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;deployment_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Dedicated Cluster&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;num_nodes_default&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">2</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;num_zookeeper_nodes_default&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">3</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;num_additional_zookeeper_nodes&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;servers&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-5 ss123456-4 ss123456-3 ss123456-2 ss123456-1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;zookeeper_ensemble&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-7hp6b4y0-1-us-west-1-aws.searchstax.com:2181,ss123456-7hp6b4y0-2-us-west-1-aws.</span></span>
<span class="line"><span style="color: #032F62">rchstax.com:2181,ss123456-7hp6b4y0-3-us-west-1-aws.searchstax.com:2181&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;tag&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;specifications&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;@{disk_space=; physical_memory=; jvm_heap_memory=}&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;backups_enabled&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;dr_enabled&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;sla_active&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;state_changed&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;term_end&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;date_created&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2023-01-25&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;application_nodes_count&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">2</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;selected_node_count&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;savings&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;@{one_year_saving_perc=0.00; three_year_saving_perc=15.00}&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;dr_plan_type&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;subscription&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;yearly&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;security_pack&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;desired_tier&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;development&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;backup&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;onboarding&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;selected_plan_memory&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0.0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;selected_plan_storage&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0.0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;dr&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;payment_method&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;purchase_order&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span></span>
<span class="line"><span style="color: #24292E">    }, </span><span style="color: #B31D28; font-style: italic">&lt;plus</span><span style="color: #24292E"> </span><span style="color: #B31D28; font-style: italic">more</span><span style="color: #24292E"> </span><span style="color: #B31D28; font-style: italic">deployments</span><span style="color: #24292E">, </span><span style="color: #B31D28; font-style: italic">if</span><span style="color: #24292E"> </span><span style="color: #B31D28; font-style: italic">any...&gt;</span></span></code></pre></div>



<h3 class="wp-block-heading" id="accountdepdetail">account &gt; deployment &gt; read</h3>



<p class="wp-block-paragraph">This method lists the properties of a specific deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET /api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; </textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentread.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$DETAILS = Invoke-RestMethod -Method Get -ContentType &#8216;application/json&#8217; -Headers $headers `
          -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/&#8221; 
$DETAILS1 = $DETAILS | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$DETAILS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">          </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$DETAILS1 </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $DETAILS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing the detailed properties of a deployment:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "name": "ReadByAPI",
  "uid": "ss123456",
  "application": "Solr",
  "application_version": "7.7.2",
  "tier": "Development",
  "http_endpoint": "https://ss123456-hjmll0ug-us-west-1-aws.searchstax.com/solr/",
  "status": "Running",
  "provision_state": "Done",
  "termination_lock": true,
  "plan_type": "DedicatedDeployment",
  "plan": "NDN2-AWS-S",
  "is_master_slave": false,
  "vpc_type": "Public",
  "vpc_name": "",
  "region_id": "us-west-1",
  "cloud_provider": "Amazon Web Services",
  "cloud_provider_id": "aws",
  "num_additional_app_nodes": 0,
  "deployment_type": "Dedicated Node",
  "num_nodes_default": 1,
  "num_zookeeper_nodes_default": 0,
  "num_additional_zookeeper_nodes": 0,
  "servers": &#91;
    "ss123456-1"
  &#93;,
  "zookeeper_ensemble": "ss123456-hjmll0ug-1-us-west-1-aws.searchstax.com:2181",
  "tag": &#91;
    "DoNotDelete"
  &#93;,
  "specifications": {
    "jvm_heap_memory": "536870912",
    "disk_space": "8589934592",
    "physical_memory": "1073741824"
  },
  "backups_enabled": false,
  "dr_enabled": false,
  "sla_active": false,
  "state_changed": "1571931445",
  "term_end": null,
  "date_created": "2019-10-24",
  "application_nodes_count": 1,
  "selected_node_count": 0,
  "savings": {
    "one_year_saving_perc": "52.50",
    "three_year_saving_perc": "64.38"
  },
  "dr_plan_type": null,
  "subscription": "monthly",
  "security_pack": false,
  "desired_tier": null,
  "backup": null,
  "onboarding": false,
  "selected_plan_memory": 0.0,
  "selected_plan_storage": 0.0,
  "dr": null,
  "payment_method": null,
  "purchase_order": null
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ReadByAPI&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;uid&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;application&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Solr&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;application_version&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;7.7.2&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;tier&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Development&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;http_endpoint&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;https://ss123456-hjmll0ug-us-west-1-aws.searchstax.com/solr/&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Running&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;provision_state&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Done&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;termination_lock&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;plan_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;DedicatedDeployment&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;plan&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;NDN2-AWS-S&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;is_master_slave&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;vpc_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Public&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;vpc_name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;region_id&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;us-west-1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;cloud_provider&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Amazon Web Services&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;cloud_provider_id&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;aws&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;num_additional_app_nodes&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;deployment_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Dedicated Node&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;num_nodes_default&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">1</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;num_zookeeper_nodes_default&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;num_additional_zookeeper_nodes&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;servers&quot;</span><span style="color: #24292E">: &#91;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #032F62">&quot;ss123456-1&quot;</span></span>
<span class="line"><span style="color: #24292E">  &#93;,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;zookeeper_ensemble&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-hjmll0ug-1-us-west-1-aws.searchstax.com:2181&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;tag&quot;</span><span style="color: #24292E">: &#91;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #032F62">&quot;DoNotDelete&quot;</span></span>
<span class="line"><span style="color: #24292E">  &#93;,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;specifications&quot;</span><span style="color: #24292E">: {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;jvm_heap_memory&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;536870912&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;disk_space&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;8589934592&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;physical_memory&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;1073741824&quot;</span></span>
<span class="line"><span style="color: #24292E">  },</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;backups_enabled&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;dr_enabled&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;sla_active&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;state_changed&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;1571931445&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;term_end&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;date_created&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2019-10-24&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;application_nodes_count&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">1</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;selected_node_count&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;savings&quot;</span><span style="color: #24292E">: {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;one_year_saving_perc&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;52.50&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;three_year_saving_perc&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;64.38&quot;</span></span>
<span class="line"><span style="color: #24292E">  },</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;dr_plan_type&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;subscription&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;monthly&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;security_pack&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;desired_tier&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;backup&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;onboarding&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;selected_plan_memory&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0.0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;selected_plan_storage&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0.0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;dr&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;payment_method&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;purchase_order&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<div class="alert alert-info">
<h3>Converting specifications to GB</h3>
<p>In a PowerShell script, we can convert the reported specification values to GB using the following lines. Do not convert the output to JSON before making these calculations:</p>
<pre><code>
$GB = [math]::pow( 1024, 3 )  # To convert raw memory to rounded GB like the UI uses.

$DISK = $DETAILS.specifications.disk_space / $GB
$JVM = $DETAILS.specifications.jvm_heap_memory / $GB
$MEMORY = $DETAILS.specifications.physical_memory / $GB


Write-Host "Disk space is $DISK GB"
Write-Host "JVM heap memory is $JVM GB"
Write-Host "Physical memory is $MEMORY GB"
</code></pre>
</div>



<h3 class="wp-block-heading" id="deploymenthealth">account &gt; deployment &gt; get_deployment_health</h3>



<p class="wp-block-paragraph">This method gets the deployment&#8217;s health using its UID.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/deployment-health/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/deployment-health/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/deployment-health/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; 
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/deployment-health/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentgetdeploymenthealth.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$RESULT = Invoke-RestMethod -Method Get -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/deployment-health/&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/deployment-health/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">Responses are JSON documents like those shown below. These examples are from a cluster:</p>



<ul class="wp-block-list">
<li>All nodes are running.</li>
</ul>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{ "status": "OK", "level": "success" }
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{ </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;OK&quot;</span><span style="color: #24292E">, </span><span style="color: #005CC5">&quot;level&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;success&quot;</span><span style="color: #24292E"> }</span></span>
<span class="line"></span></code></pre></div>



<ul class="wp-block-list">
<li>One or more servers is down, but not all of them.</li>
</ul>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{ &#8220;status&#8221;: &#8220;Warn&#8221;, &#8220;level&#8221;: &#8220;warning&#8221; }
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{ </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Warn&quot;</span><span style="color: #24292E">, </span><span style="color: #005CC5">&quot;level&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;warning&quot;</span><span style="color: #24292E"> }</span></span>
<span class="line"></span></code></pre></div>



<ul class="wp-block-list">
<li>All servers are down.</li>
</ul>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{ &#8220;status&#8221;: &#8220;Error&#8221;, &#8220;level&#8221;: &#8220;danger&#8221; }
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{ </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Error&quot;</span><span style="color: #24292E">, </span><span style="color: #005CC5">&quot;level&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;danger&quot;</span><span style="color: #24292E"> }</span></span>
<span class="line"></span></code></pre></div>



<ul class="wp-block-list">
<li>Invalid UID throws a&nbsp;<strong>Not Found</strong>&nbsp;error.</li>
</ul>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{ &#8220;detail&#8221;: &#8220;Not found.&#8221; }
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{ </span><span style="color: #005CC5">&quot;detail&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Not found.&quot;</span><span style="color: #24292E"> }</span></span>
<span class="line"></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="collections">account &gt; deployment &gt; collections_health</h3>



<p class="wp-block-paragraph">This method gets the health of a deployment&#8217;s collections.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/collection-health/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/collection-health/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/collections-health/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; </textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/collections-health/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentcollectionshealth.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$RESULT = Invoke-RestMethod -Method Get -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/collections-health/&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/collections-health/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">Responses are JSON documents like those shown below.</p>



<ul class="wp-block-list">
<li>All collections are running.</li>
</ul>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{ &#8220;success&#8221;: true, &#8220;healthy&#8221;: true}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{ </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">, </span><span style="color: #005CC5">&quot;healthy&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<ul class="wp-block-list">
<li>One or more collections are degraded.</li>
</ul>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{ &#8220;success&#8221;: true, &#8220;healthy&#8221;: false }
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{ </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">, </span><span style="color: #005CC5">&quot;healthy&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E"> }</span></span>
<span class="line"></span></code></pre></div>



<ul class="wp-block-list">
<li>API endpoint failure.</li>
</ul>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{ &#8220;success&#8221;: false, &#8220;error&#8221;: &#8220;some message&#8221; }
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{ </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">, </span><span style="color: #005CC5">&quot;error&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;some message&quot;</span><span style="color: #24292E"> }</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="rollingrestart">account &gt; deployment &gt; rolling_restart</h3>



<p class="wp-block-paragraph">This method lets you restart the Solr or Zookeeper nodes of a cluster in a rolling manner. </p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>PUT https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/rolling-restart/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">PUT</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/rolling-restart/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account and <strong>&lt;uid&gt;</strong> is the ID number of the deployment.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "solr": true,
    "zookeeper": false
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;solr&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;zookeeper&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>solr</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark> boolean<br></td><td>If true, will restart the Solr nodes. Default is true. </td><td>true</td></tr><tr><td><strong>zookeeper</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark> boolean<br></td><td>If true, will restart the Zookeeper nodes. Default is false.</td><td>false</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request PUT "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/rolling-restart/" \
  --header "Content-Type: application/json" \
  --header "Authorization: Token &lt;token>" \
  --data "{
    \"solr\": true,
    \"zookeeper\": false
    }"</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">PUT</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/rolling-restart/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;{</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">solr</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: true,</span></span>
<span class="line"><span style="color: #032F62">    </span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">zookeeper</span><span style="color: #005CC5">\&quot;</span><span style="color: #032F62">: false</span></span>
<span class="line"><span style="color: #032F62">    }&quot;</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentrollingrestart.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"

$body = @{
    solr='true'
    zookeeper='false'
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Put -Body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/rolling-restart/" 
$RESULT = $RESULT | ConvertTo-Json</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    solr</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;true&#39;</span></span>
<span class="line"><span style="color: #24292E">    zookeeper</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;false&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Put </span><span style="color: #D73A49">-</span><span style="color: #24292E">Body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/rolling-restart/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing &#8230;</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;detail&#8221;: &#8220;Rolling restart initiated&#8221;
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;detail&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Rolling restart initiated&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<p class="wp-block-paragraph">If the message says, &#8220;The specified deployment is not ready for a rolling restart,&#8221; it means that a rolling restart is already underway, or that one of the nodes is down. </p>



<h3 class="wp-block-heading" id="start">account &gt; deployment &gt; server &gt; start_solr</h3>



<p class="wp-block-paragraph">This method starts an individual Solr node using its UID.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/server/&lt;node>/start-solr/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/server/&lt;node&gt;/start-solr/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account,&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment, and&nbsp;<strong>&lt;node&gt;</strong>&nbsp;is the ID of the specific node.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request POST &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/server/&lt;node>/start-solr/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; </textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/server/&lt;node&gt;/start-solr/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentserverstart.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$NODE = &#8220;ss123456-4&#8221;
$RESULT = Invoke-RestMethod -Method Post -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/server/$NODE/start-solr/&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"><span style="color: #24292E">$NODE </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456-4&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/server/</span><span style="color: #24292E">$NODE</span><span style="color: #032F62">/start-solr/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document similar to this:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;success&#8221;: true
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<h3 class="wp-block-heading" id="stop">account &gt; deployment &gt; server &gt; stop_solr</h3>



<p class="wp-block-paragraph">This method stops an individual Solr node using its UID.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/server/&lt;node>/stop-solr/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/server/&lt;node&gt;/stop-solr/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account,&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment, and&nbsp;<strong>&lt;node&gt;</strong>&nbsp;is the ID of the specific node.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request POST &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/server/&lt;node>/stop-solr/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; </textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/server/&lt;node&gt;/stop-solr/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentserverstop.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$NODE = &#8220;ss123456-4&#8221;
$RESULT = Invoke-RestMethod -Method Post -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/server/$NODE/stop-solr/&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"><span style="color: #24292E">$NODE </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456-4&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/server/</span><span style="color: #24292E">$NODE</span><span style="color: #032F62">/stop-solr/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document similar to this:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;success&#8221;: true
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="status">account &gt; deployment &gt; server &gt; host_status</h3>



<p class="wp-block-paragraph">This method returns the status of an individual Solr node using its UID.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/server/&lt;node>/host-status/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/server/&lt;node&gt;/host-status/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account,&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment, and&nbsp;<strong>&lt;node&gt;</strong>&nbsp;is the number of the specific node.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/server/&lt;node>/host-status/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token></textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/server/&lt;node&gt;/host-status/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentserverstatus.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$uid = &#8220;ss123456&#8221;
$NODE = &#8220;4&#8221;
$RESULT = Invoke-RestMethod -Method Get -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/server/$NODE/host-status/&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"><span style="color: #24292E">$NODE </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;4&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/server/</span><span style="color: #24292E">$NODE</span><span style="color: #032F62">/host-status/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document similar to this:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;level&#8221;: &#8220;success&#8221;,
  &#8220;status&#8221;: &#8220;OK&#8221;
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;level&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;success&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;OK&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<h3 class="wp-block-heading" id="listnodes">account &gt; deployment &gt; server &gt; list</h3>



<p class="wp-block-paragraph">This method returns a list of nodes making up a Solr deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/server/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/server/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;uid&gt;</strong>&nbsp;is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses either&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication or&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#key/">API Key</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request GET "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/server/" \
  --header "Authorization: Token &lt;token>" </textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/server/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentserverlist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"

$RESULT = Invoke-RestMethod -Method Get -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/server/" 
$RESULT = $RESULT | ConvertTo-Json</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/server/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document similar to this:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>[
  {
    "sn": 1,
    "node": "ss123456-1",
    "private_address": "10.0.1.78",
    "dns_address": "ss123456-jkzg2pr0-1-ca-central-1-aws.searchstax.com",
    "status": "Running",
    "status_details":  "&#91;2026-03-25 17:12:53&#93; restart ended",
    "solr": false,
    "zookeeper": true,
    "silk": false,
    "availability_zone":  null
  },
  {
    "sn": 2,
    "node": "ss123456-2",
    "private_address": "10.0.1.74",
    "dns_address": "ss123456-jkzg2pr0-2-ca-central-1-aws.searchstax.com",
    "status": "Running",
    "status_details":  "&#91;2026-03-25 17:12:57&#93; restart ended",
    "solr": false,
    "zookeeper": true,
    "silk": false,
    "availability_zone":  null
  },
]</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">[</span></span>
<span class="line"><span style="color: #24292E">  {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;sn&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">1</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;node&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;private_address&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;10.0.1.78&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;dns_address&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-jkzg2pr0-1-ca-central-1-aws.searchstax.com&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Running&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;status_details&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;&#91;2026-03-25 17:12:53&#93; restart ended&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;solr&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;zookeeper&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;silk&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;availability_zone&quot;</span><span style="color: #24292E">:  </span><span style="color: #005CC5">null</span></span>
<span class="line"><span style="color: #24292E">  },</span></span>
<span class="line"><span style="color: #24292E">  {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;sn&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">2</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;node&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-2&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;private_address&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;10.0.1.74&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;dns_address&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-jkzg2pr0-2-ca-central-1-aws.searchstax.com&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Running&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;status_details&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;&#91;2026-03-25 17:12:57&#93; restart ended&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;solr&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;zookeeper&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;silk&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">false</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;availability_zone&quot;</span><span style="color: #24292E">:  </span><span style="color: #005CC5">null</span></span>
<span class="line"><span style="color: #24292E">  },</span></span>
<span class="line"><span style="color: #24292E">]</span></span></code></pre></div>



<h3 class="wp-block-heading" id="listplans">account &gt; plan &gt; list</h3>



<p class="wp-block-paragraph">This method lists the available deployment plans and the regions where those plans are available.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>GET https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/plan/?page=1&amp;application=Solr&amp;plan_type=DedicatedPlan
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/plan/?page=1&amp;application=Solr&amp;plan_type=DedicatedPlan</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account. There are three query parameters:&nbsp;<strong>page</strong>&nbsp;is the page number within the paginated result set;&nbsp;<strong>application</strong>&nbsp;requests plans for &#8220;Solr&#8221;; and&nbsp;<strong>plan_type</strong>&nbsp;is &#8220;DedicatedPlan&#8221;. (The API currently supports only one application and plan type.)</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>





<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/plan/?page=1&amp;application=Solr&amp;plan_type=DedicatedPlan&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; </textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/plan/?page=1&amp;application=Solr&amp;plan_type=DedicatedPlan&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountplanlist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$RESULT = Invoke-RestMethod -Method Get -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/plan/?page=1&amp;application=Solr&amp;plan_type=DedicatedPlan&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/plan/?page=1&amp;application=Solr&amp;plan_type=DedicatedPlan&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document with the following values &#8211;</p>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>name</strong><br>string</td><td>The name of the plan</td><td>&#8220;NDN4-AWS-S&#8221;</td></tr><tr><td><strong>description</strong><br>string</td><td>The description of the plan.</td><td>&#8220;Dedicated Node – 4GB/32GB&#8221;</td></tr><tr><td><strong>application</strong><br>object</td><td>JSON object with details of application selected</td><td>{<br>&#8220;name&#8221;: &#8220;Solr&#8221;,<br>&#8220;description&#8221;: &#8220;Apache Solr&#8221;,<br>&#8220;tag&#8221;: &#8220;solr&#8221;<br>}</td></tr><tr><td><strong>application_versions</strong><br>list of strings</td><td>List of available application versions</td><td>[<br>&#8220;8.11.2&#8221;,<br>&#8220;8.11.1&#8221;,<br>&#8220;8.8.2&#8221;,<br>&#8220;8.8.1&#8221;,<br>&#8220;8.6.3&#8221;,<br>and many more&#8230;<br>]</td></tr><tr><td><strong>plan_type</strong><br>string</td><td>The plan type selected</td><td>&#8220;DedicatedPlan&#8221;</td></tr><tr><td><strong>plan_regions</strong><br>list of objects</td><td>List of JSON objects containing information associated with each region.</td><td>{<br>&#8220;price&#8221;: 160,<br>&#8220;additional_application_node_price&#8221;: 0,<br>&#8220;additional_zookeeper_node_price&#8221;: 0,<br>&#8220;region_id&#8221;: &#8220;ap-northeast-1&#8221;,<br>&#8220;cloud_provider&#8221;: &#8220;Amazon Web Services&#8221;,<br>&#8220;cloud_provider_id&#8221;: &#8220;aws&#8221;<br>}</td></tr><tr><td><strong>trial_available</strong><br>boolean</td><td>Whether the plan is available in trial account</td><td>false</td></tr></tbody></table></figure>



<h3 class="wp-block-heading" id="usage">account &gt; usage &gt; list</h3>



<p class="wp-block-paragraph">This method produces a list of the billable usage events of <strong>dedicated deployments</strong> in an account during a specific year and month.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>GET /api/rest/v2/account/&lt;account_name>/usage/&lt;year>/&lt;month>/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/usage/&lt;year&gt;/&lt;month&gt;/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account,&nbsp;<strong>&lt;year&gt;</strong>&nbsp;is an integer (2023), and&nbsp;<strong>&lt;month&gt;</strong>&nbsp;is an integer (1-12).</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/usage/&lt;year>/&lt;month>/ \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; 
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/usage/&lt;year&gt;/&lt;month&gt;/ </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #032F62">  --header &quot;Authorization:</span><span style="color: #24292E"> </span><span style="color: #032F62">Token</span><span style="color: #24292E"> </span><span style="color: #D73A49">&lt;</span><span style="color: #032F62">toke</span><span style="color: #24292E">n</span><span style="color: #D73A49">&gt;</span><span style="color: #032F62">&quot; </span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountusagelist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$YEAR = &#8220;2023&#8221;
$MONTH = &#8220;3&#8221;
$RESULTS = Invoke-RestMethod -Method Get -Headers $headers `
          -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/usage/$YEAR/$MONTH/&#8221; 
$RESULTS = $RESULTS | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$YEAR </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;2023&quot;</span></span>
<span class="line"><span style="color: #24292E">$MONTH </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;3&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">          </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/usage/</span><span style="color: #24292E">$YEAR</span><span style="color: #032F62">/</span><span style="color: #24292E">$MONTH</span><span style="color: #032F62">/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULTS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing a list of usage events like this one:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>  {
    "startDate": "2022-04-01",
    "endDate": "2022-04-30",
    "objectID": "ss123456",
    "SKU": "NDN4-AWS-S",
    "currency": "USD",
    "amount": "192.00",
    "usage": 30,
    "tagCollection": []
  },
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">  {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;startDate&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2022-04-01&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;endDate&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2022-04-30&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;objectID&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;SKU&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;NDN4-AWS-S&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;currency&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;USD&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;amount&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;192.00&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;usage&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">30</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;tagCollection&quot;</span><span style="color: #24292E">: []</span></span>
<span class="line"><span style="color: #24292E">  },</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph"><strong>Usage</strong>&nbsp;is the number of billable days between <strong>startDate</strong> and <strong>endDate</strong>, inclusively. In the case of backup storage, it is the number of bytes stored.</p>



<h3 class="wp-block-heading" id="usage-extended">account &gt; usage-extended &gt; list</h3>





<p class="wp-block-paragraph">This method produces a list of billable usage events for <strong>serverless indexes</strong> of an account during a specific year and month.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>GET /api/rest/v2/account/&lt;account_name>/usage-extended/&lt;year>/&lt;month>/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/usage-extended/&lt;year&gt;/&lt;month&gt;/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account,&nbsp;<strong>&lt;year&gt;</strong>&nbsp;is an integer (2023), and&nbsp;<strong>&lt;month&gt;</strong>&nbsp;is an integer (1-12).</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/usage-extended/&lt;year>/&lt;month>/ \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; 
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/usage-extended/&lt;year&gt;/&lt;month&gt;/ </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #032F62">  --header &quot;Authorization:</span><span style="color: #24292E"> </span><span style="color: #032F62">Token</span><span style="color: #24292E"> </span><span style="color: #D73A49">&lt;</span><span style="color: #032F62">toke</span><span style="color: #24292E">n</span><span style="color: #D73A49">&gt;</span><span style="color: #032F62">&quot; </span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountusageextendedlist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$YEAR = &#8220;2023&#8221;
$MONTH = &#8220;3&#8221;
$RESULTS = Invoke-RestMethod -Method Get -Headers $headers `
          -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/usage-extended/$YEAR/$MONTH/&#8221; 
$RESULTS = $RESULTS | ConvertTo-Json
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$YEAR </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;2023&quot;</span></span>
<span class="line"><span style="color: #24292E">$MONTH </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;3&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">          </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/usage-extended/</span><span style="color: #24292E">$YEAR</span><span style="color: #032F62">/</span><span style="color: #24292E">$MONTH</span><span style="color: #032F62">/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULTS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing a list of usage events like this one:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>  {
    &#8220;startDate&#8221;: &#8220;2023-12-01&#8221;,
    &#8220;endDate&#8221;: &#8220;2023-12-31&#8221;,
    &#8220;objectID&#8221;: &#8220;4008_QuickStart&#8221;,
    &#8220;SKU&#8221;: &#8220;SH-STARTER&#8221;,
    &#8220;usage&#8221;: 31,
    &#8220;tagCollection&#8221;: [
      &#8220;Serverless_Index&#8221;,
      &#8220;type:index&#8221;
    ],
    &#8220;currency&#8221;: &#8220;USD&#8221;,
    &#8220;amount&#8221;: 9.15,
    &#8220;extendedAttributes&#8221;: [
      &#8220;createdDate:2023-10-06&#8221;,
      &#8220;totalRequests:0&#8221;,
      &#8220;indexID:4008&#8221;,
      &#8220;name:QuickStart&#8221;,
      &#8220;region:us-west-2&#8221;,
      &#8220;indexSize:0.002734375&#8221;,
      &#8220;indexSizeWUnit:2.8 KB&#8221;,
      &#8220;status:active&#8221;,
      &#8220;orderStatus:completed&#8221;,
      &#8220;subscription:yearly&#8221;
    ]
  }
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">  {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;startDate&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2023-12-01&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;endDate&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2023-12-31&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;objectID&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;4008_QuickStart&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;SKU&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;SH-STARTER&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;usage&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">31</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;tagCollection&quot;</span><span style="color: #24292E">: [</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;Serverless_Index&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;type:index&quot;</span></span>
<span class="line"><span style="color: #24292E">    ],</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;currency&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;USD&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;amount&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">9.15</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;extendedAttributes&quot;</span><span style="color: #24292E">: [</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;createdDate:2023-10-06&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;totalRequests:0&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;indexID:4008&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;name:QuickStart&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;region:us-west-2&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;indexSize:0.002734375&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;indexSizeWUnit:2.8 KB&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;status:active&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;orderStatus:completed&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;subscription:yearly&quot;</span></span>
<span class="line"><span style="color: #24292E">    ]</span></span>
<span class="line"><span style="color: #24292E">  }</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph"><strong>Usage</strong>&nbsp;is the number of billable days between <strong>startDate</strong> and <strong>endDate</strong>, inclusively. In the case of backup storage, it is the number of bytes stored. The list of <strong>extendedAttributes</strong> describes a single serverless index (collection).<strong> </strong></p>



<h2 class="wp-block-heading" id="questions">Questions?</h2>



<p class="wp-block-paragraph">Do not hesitate to contact the&nbsp;<a href="mailto:support@searchstax.com?subject=SearchStax%20Cloud%20API%20–%20Deployments" target="_blank" rel="noreferrer noopener">SearchStax Support Desk</a>.</p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-deployment-api/">Solr Deployment API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.searchstax.com/docs/searchstax-cloud-deployment-api/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Private VPC API</title>
		<link>https://www.searchstax.com/docs/searchstax-cloud-private-vpc-api/</link>
					<comments>https://www.searchstax.com/docs/searchstax-cloud-private-vpc-api/#respond</comments>
		
		<dc:creator><![CDATA[Bruce]]></dc:creator>
		<pubDate>Fri, 24 Jun 2022 01:18:46 +0000</pubDate>
				<category><![CDATA[Access and Security APIs]]></category>
		<category><![CDATA[Cloud]]></category>
		<guid isPermaLink="false">https://www.searchstax.com/docs/?p=11800</guid>

					<description><![CDATA[<p>Private VPC API The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr deployments. Core and Enterprise Clients Only! The SearchStax API suite is&#8230; <a class="more-link" href="https://www.searchstax.com/docs/searchstax-cloud-private-vpc-api/">Continue reading <span class="screen-reader-text">Private VPC API</span></a></p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-private-vpc-api/">Private VPC API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h1 class="wp-block-heading" id="h-private-vpc-api">Private VPC API</h1>



<hr class="wp-block-separator has-css-opacity"/>



<p class="wp-block-paragraph">The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr deployments.</p>



<div class="alert alert-info">
<h3>Core and Enterprise Clients Only!</h3>
<p>The SearchStax API suite is available to our Core and Enterprise
clients only, as noted on our <a href="https://www.searchstax.com/pricing/cloud/">Pricing</a> page. </p>
</div>



<p class="wp-block-paragraph">This page describes how to obtain the ID number of a Virtual Private Cloud (VPC) using the API. This ID is essential to creating a new deployment inside the VPC using the <a href="/docs/searchstax-cloud-deployment-api/#createdeployment">account &gt; deployment &gt; create</a> method. </p>



<p class="wp-block-paragraph">The API can be accessed through any tool that assembles HTTP requests and dispatch them to a server. Among these would be the Python&nbsp;<a href="https://pypi.org/project/coreapi/" target="_blank" rel="noreferrer noopener">coreapi</a>&nbsp;package, the&nbsp;<a href="https://www.postman.com/" target="_blank" rel="noreferrer noopener">Postman</a>&nbsp;tool, and&nbsp;<a href="https://curl.se" target="_blank" rel="noreferrer noopener">cURL</a>. For Windows, use&nbsp;<a href="https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1" target="_blank" rel="noreferrer noopener">PowerShell 7+</a>.</p>



<div class="alert alert-warning">
<h3>Account Owner, Admin, or Technical Contact</h3>
<p>To run the SearchStax Provisioning API, you must be the account Owner,
an account Admin, or a Technical Contact. See <a href="../userroles/#userroles">SearchStax User Roles</a>.</p>
</div>



<p class="wp-block-paragraph">Symbols enclosed in carets (&lt; and &gt;) such as&nbsp;<strong>&lt;username&gt;</strong>&nbsp;are metavariables. Substitute your local values when you encounter them in the examples.</p>



<p class="wp-block-paragraph">Contents:</p>



<ul class="wp-block-list">
<li><a href="#PrivateVPC">Private VPC API</a>
<ul class="wp-block-list">
<li><a href="#VPClist">account &gt; privatevpc &gt; list</a></li>
</ul>
</li>
</ul>



<p class="wp-block-paragraph">Related Pages:</p>



<ul class="wp-block-list">
<li><a href="/docs/searchstax-cloud-authentication-api/">Authentication API</a></li>



<li><a href="/docs/searchstax-cloud-users-api/">Users API</a></li>



<li><a href="/docs/searchstax-cloud-basic-auth-api/">Basic Auth API</a></li>



<li><a href="/docs/searchstax-cloud-ipfilter-api/">IP Filtering API</a></li>



<li><a href="/docs/searchstax-cloud-deployment-api/">Deployment API</a></li>



<li><a href="/docs/searchstax-cloud-backup-restore-api/">Backup/Restore API</a></li>



<li><a href="/docs/searchstax-cloud-custom-jars-api/">Custom JARs API</a></li>



<li><a href="/docs/searchstax-cloud-tags-api/">Tags API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Alerts API</a></li>



<li><a href="/docs/searchstax-cloud-webhooks-api/">Webhooks API</a></li>



<li><a href="/docs/searchstax-cloud-zookeeper-api/">Zookeeper API</a></li>
</ul>



<h2 class="wp-block-heading" id="PrivateVPC">Private VPC API</h2>



<p class="wp-block-paragraph">SearchStax provides the ability to create new Solr deployments within your VPC using the <a href="/docs/searchstax-cloud-deployment-api/#createdeployment">account &gt; deployment &gt; create</a> method. That method, in turn, requires the ID number of the VPC in your account. The following method lets you obtain this ID number. </p>



<h4 class="wp-block-heading" id="VPClist">account &gt; privatevpc &gt; list</h4>



<p class="wp-block-paragraph">This method lists VPCs associated with an account.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET /api/rest/v2/account/&lt;account_name>/privatevpc/?page=1
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/privatevpc/?page=1</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and <strong>&lt;page&gt;</strong> is an optional page number within the paginated result set.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/privatevpc&#8221; 
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/privatevpc&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountprivatevpclist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;

$RESULT = Invoke-RestMethod -Method Get -ContentType &#8216;application/json&#8217; -Headers $headers `
              -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/privatevpc/&#8221;
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/privatevpc/&quot;</span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">A successful response is a JSON object describing the VPCs of the account:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;count&#8221;: 1,
  &#8220;next&#8221;: null,
  &#8220;previous&#8221;: null,
  &#8220;results&#8221;: [
    {
      &#8220;id&#8221;: 2,
      &#8220;account&#8221;: &#8220;test&#8221;,
      &#8220;region&#8221;: &#8220;us-east1&#8221;,
      &#8220;status&#8221;: &#8220;Active&#8221;,
      &#8220;address_space&#8221;: &#8220;10.63.0.0/16&#8221;,
      &#8220;name&#8221;: &#8220;test-vpc&#8221;
    }
  ]
}
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;count&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">1</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;next&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;previous&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;results&quot;</span><span style="color: #24292E">: [</span></span>
<span class="line"><span style="color: #24292E">    {</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">2</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;account&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;test&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;region&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;us-east1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Active&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;address_space&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;10.63.0.0/16&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;test-vpc&quot;</span></span>
<span class="line"><span style="color: #24292E">    }</span></span>
<span class="line"><span style="color: #24292E">  ]</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<div class="wp-block-group"><div class="wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained">
<h2 class="wp-block-heading" id="questions">Questions?</h2>



<p class="wp-block-paragraph">Do not hesitate to contact the <a href="mailto:support@searchstax.com?subject=SearchStax%20Cloud%20Private%20VPC%20API" target="_blank" rel="noreferrer noopener">SearchStax Support Desk</a>.</p>
</div></div>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-private-vpc-api/">Private VPC API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.searchstax.com/docs/searchstax-cloud-private-vpc-api/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Solr DNS Alias API</title>
		<link>https://www.searchstax.com/docs/searchstax-cloud-dns-alias-api/</link>
					<comments>https://www.searchstax.com/docs/searchstax-cloud-dns-alias-api/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Thu, 04 Mar 2021 08:55:55 +0000</pubDate>
				<category><![CDATA[Deployment and Networking APIs]]></category>
		<category><![CDATA[Cloud]]></category>
		<guid isPermaLink="false">https://www.searchstax.com/docs/?p=7629</guid>

					<description><![CDATA[<p>Provisioning API &#8211; DNS Alias The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr deployments. Core and Enterprise Clients Only! The SearchStax&#8230; <a class="more-link" href="https://www.searchstax.com/docs/searchstax-cloud-dns-alias-api/">Continue reading <span class="screen-reader-text">Solr DNS Alias API</span></a></p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-dns-alias-api/">Solr DNS Alias API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h1 class="wp-block-heading" id="h-provisioning-api-dns-alias">Provisioning  API &#8211; DNS Alias</h1>



<hr class="wp-block-separator has-css-opacity"/>



<p class="wp-block-paragraph">The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr deployments.</p>



<div class="alert alert-info">
<h3>Core and Enterprise Clients Only!</h3>
<p>The SearchStax API suite is available to our Core and Enterprise
clients only, as noted on our <a href="https://www.searchstax.com/pricing/cloud/">Pricing</a> page. </p>
</div>



<p class="wp-block-paragraph">This page describes how to redirect a DNS alias from one deployment to another using the API.</p>



<p class="wp-block-paragraph">The API can be accessed through any tool that assembles HTTP requests and dispatch them to a server. Among these would be the Python&nbsp;<a href="https://pypi.org/project/coreapi/" target="_blank" rel="noreferrer noopener">coreapi</a>&nbsp;package, the&nbsp;<a href="https://www.postman.com/" target="_blank" rel="noreferrer noopener">Postman</a>&nbsp;tool, and&nbsp;<a href="https://curl.se" target="_blank" rel="noreferrer noopener">cURL</a>. For Windows, use&nbsp;<a href="https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1" target="_blank" rel="noreferrer noopener">PowerShell 7+</a>.</p>



<div class="alert alert-warning">
<h3>Account Owner, Admin, or Technical Contact</h3>
<p>To run the SearchStax Provisioning API, you must be the account Owner,
an account Admin, or a Technical Contact. See <a href="/docs/searchstax-cloud-user-roles/#userroles">SearchStax User Roles</a>.</p>
</div>



<p class="wp-block-paragraph">Symbols enclosed in carets (&lt; and &gt;) such as&nbsp;<strong>&lt;username&gt;</strong>&nbsp;are metavariables. Substitute your local values when you encounter them in the examples.</p>



<p class="wp-block-paragraph">Contents:</p>



<ul class="wp-block-list">
<li><a href="#DNSAlias">DNS Alias</a>
<ul class="wp-block-list">
<li><a href="#DNSlist">account &gt; dns-record &gt; list</a></li>



<li><a href="#DNSread">account &gt; dns-record &gt; read</a></li>



<li><a href="#DNSupdate">account &gt; dns-record &gt; associate</a></li>
</ul>
</li>
</ul>



<p class="wp-block-paragraph">Related Pages:</p>



<ul class="wp-block-list">
<li><a href="/docs/searchstax-cloud-authentication-api/">Authentication API</a></li>



<li><a href="/docs/searchstax-cloud-users-api/">Users API</a></li>



<li><a href="/docs/searchstax-cloud-basic-auth-api/">Basic Auth API</a></li>



<li><a href="/docs/searchstax-cloud-ipfilter-api/">IP Filtering API</a></li>



<li><a href="/docs/searchstax-cloud-deployment-api/">Deployment API</a></li>



<li><a href="/docs/searchstax-cloud-private-vpc-api/">Private VPC API</a></li>



<li><a href="/docs/searchstax-cloud-backup-restore-api/">Backup/Restore API</a></li>



<li><a href="/docs/searchstax-cloud-custom-jars-api/">Custom JARs API</a></li>



<li><a href="/docs/searchstax-cloud-tags-api/">Tags API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Alerts API</a></li>



<li><a href="/docs/searchstax-cloud-webhooks-api/">Webhooks API</a></li>



<li><a href="/docs/searchstax-cloud-zookeeper-api/">Zookeeper API</a></li>
</ul>



<h2 class="wp-block-heading" id="DNSAlias">DNS Alias</h2>



<p class="wp-block-paragraph">SearchStax provides the ability to set up a&nbsp;<a href="https://en.wikipedia.org/wiki/CNAME_record" target="_blank" rel="noreferrer noopener">DNS CNAME alias</a>&nbsp;for your deployment. This means that your search application can query a domain address of the form&nbsp;<em>myalias.searchstax.com</em>&nbsp;in place of a literal Solr HTTP Endpoint like&nbsp;<em>ss123456-hemxx0ug-us-west-1-aws.searchstax.com/solr/</em>.</p>



<p class="wp-block-paragraph">We also provide API methods that let you redirect this alias to a different deployment in the same account. This lets you switch search traffic from one deployment to another in an emergency. Note that multiple CNAME records can point to the same deployment.</p>



<p class="wp-block-paragraph">Searchstax controls the master list of CNAME records to prevent name collisions. If your system would benefit from a CNAME alias, please contact&nbsp;<a href="mailto:sales@searchstax.com?subject=Vanity%20DNS%20Request" target="_blank" rel="noreferrer noopener">sales@searchstax.com</a>.</p>



<h3 class="wp-block-heading" id="DNSlist">account &gt; dns-record &gt; list</h3>



<p class="wp-block-paragraph">This method lists the existing CNAME aliases of an account.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET /api/rest/v2/account/&lt;account_name>/dns-record/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/dns-record/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/dns-record/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/dns-record/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdnsrecordlist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;

$ALIASES = Invoke-RestMethod -Method Get -ContentType &#8216;application/json&#8217; -Headers $headers `
              -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/dns-record/&#8221;
$ALIASES = $ALIASES | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$ALIASES </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/dns-record/&quot;</span></span>
<span class="line"><span style="color: #24292E">$ALIASES </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $ALIASES </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">A successful response is a JSON object containing a list of CNAME records for this account:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;count&#8221;: 3,
  &#8220;next&#8221;: null,
  &#8220;previous&#8221;: null,
  &#8220;results&#8221;: [
    {
      &#8220;associated&#8221;: true,
      &#8220;name&#8221;: &#8220;alias1&#8221;,
      &#8220;value&#8221;: &#8220;ss123456-dbw2acz6-us-west-1-aws.searchstax.com&#8221;,
      &#8220;deployment&#8221;: &#8220;ss123456&#8221;,
      &#8220;ttl&#8221;: 300
    },
    {
      &#8220;associated&#8221;: true,
      &#8220;name&#8221;: &#8220;alias2&#8221;,
      &#8220;value&#8221;: &#8220;ss123456-jdwz6lb2-us-west-1-aws.searchstax.com&#8221;,
      &#8220;deployment&#8221;: &#8220;ss123456&#8221;,
      &#8220;ttl&#8221;: 300
    },
    {
      &#8220;associated&#8221;: true,
      &#8220;name&#8221;: &#8220;alias3&#8221;,
      &#8220;value&#8221;: &#8220;ss123456-jdwz6lb2-us-west-1-aws.searchstax.com&#8221;,
      &#8220;deployment&#8221;: &#8220;ss123456&#8221;,
      &#8220;ttl&#8221;: 300
    }
  ]
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;count&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">3</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;next&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;previous&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;results&quot;</span><span style="color: #24292E">: [</span></span>
<span class="line"><span style="color: #24292E">    {</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;associated&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;alias1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;value&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-dbw2acz6-us-west-1-aws.searchstax.com&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;deployment&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;ttl&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">300</span></span>
<span class="line"><span style="color: #24292E">    },</span></span>
<span class="line"><span style="color: #24292E">    {</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;associated&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;alias2&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;value&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-jdwz6lb2-us-west-1-aws.searchstax.com&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;deployment&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;ttl&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">300</span></span>
<span class="line"><span style="color: #24292E">    },</span></span>
<span class="line"><span style="color: #24292E">    {</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;associated&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;alias3&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;value&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-jdwz6lb2-us-west-1-aws.searchstax.com&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;deployment&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;ttl&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">300</span></span>
<span class="line"><span style="color: #24292E">    }</span></span>
<span class="line"><span style="color: #24292E">  ]</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<h3 class="wp-block-heading" id="DNSread">account &gt; dns-record &gt; read</h3>



<p class="wp-block-paragraph">This method reads a single CNAME record.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>GET /api/rest/v2/account/&lt;account_name>/dns-record/&lt;name>/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/dns-record/&lt;name&gt;/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;name&gt;</strong>&nbsp;is the name of the alias.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request GET &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/dns-record/&lt;name>/&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221;
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/dns-record/&lt;name&gt;/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdnsrecordread.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$NAME = &#8220;alias1&#8221;

$ALIASES = Invoke-RestMethod -Method Get -ContentType &#8216;application/json&#8217; -Headers $headers `
              -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/dns-record/$NAME/&#8221;
$ALIAS = $ALIAS | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$NAME </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;alias1&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$ALIASES </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/dns-record/</span><span style="color: #24292E">$NAME</span><span style="color: #032F62">/&quot;</span></span>
<span class="line"><span style="color: #24292E">$ALIAS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $ALIAS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">A successful response is a JSON object containing a single CNAME record from this account:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;associated&#8221;: true,
  &#8220;name&#8221;: &#8220;alias3&#8221;,
  &#8220;value&#8221;: &#8220;ss123456-jdwz6lb2-us-west-1-aws.searchstax.com&#8221;,
  &#8220;deployment&#8221;: &#8220;ss123456&#8221;,
  &#8220;ttl&#8221;: 300
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;associated&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;alias3&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;value&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-jdwz6lb2-us-west-1-aws.searchstax.com&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;deployment&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;ttl&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">300</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<h3 class="wp-block-heading" id="DNSupdate">account &gt; dns-record &gt; associate</h3>



<p class="wp-block-paragraph">This method updates a DNS CNAME record, associating the alias with a deployment&#8217;s Solr HTTP Endpoint. It can also set the DNS TTL (time to live) value for the record.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>PATCH https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/dns-record/&lt;name>/
</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">PATCH</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/dns-record/&lt;name&gt;/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where&nbsp;<strong>&lt;account_name&gt;</strong>&nbsp;is the name of the tenant account, and&nbsp;<strong>&lt;name&gt;</strong>&nbsp;is the name of the alias.</p>



<p class="wp-block-paragraph">This method uses&nbsp;<a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a>&nbsp;authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
    deployment=&#8217;ss123456&#8242;
    ttl=&#8217;300&#8242;
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">deployment=&#39;ss123456&#39;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">ttl=&#39;300&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>deployment</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string<br></td><td>The deployment ID number from the Solr HTTP Endpoint.<br></td><td>&#8220;ss123456&#8221;</td></tr><tr><td><strong>ttl</strong><br><span style="color:#ff0000" class="has-inline-color">required</span><br>string</td><td>The DNS&nbsp;<a href="https://en.wikipedia.org/wiki/Time_to_live#DNS_records">time-to-live</a>&nbsp;value (seconds), which must be one of 60, 300, 900, 1800, 3600, 21600, 43200, or 86400.</td><td>&#8220;300&#8221;<br></td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>curl &#8211;request PATCH &#8220;https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/dns-record/&lt;name>/&#8221; \
  &#8211;header &#8220;Content-Type: application/json&#8221; \
  &#8211;header &#8220;Authorization: Token &lt;token>&#8221; \
  &#8211;data &#8216;{&#8220;deployment&#8221;:&#8221;ss123456&#8243;,&#8221;ttl&#8221;:&#8221;300&#8243;}&#8217;</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">PATCH</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/dns-record/&lt;name&gt;/&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span><span style="color: #005CC5">\</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;{&quot;deployment&quot;:&quot;ss123456&quot;,&quot;ttl&quot;:&quot;300&quot;}&#39;</span></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdnsrecordassociate.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>$ACCOUNT = &#8220;AccountName&#8221;
$NAME = &#8220;alias1&#8221;

$body = @{
    deployment=&#8217;ss123456&#8242;
    ttl=&#8217;300&#8242;
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Patch -body $body -ContentType &#8216;application/json&#8217; -Headers $headers `
         -uri &#8220;https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/dns-record/$NAME/&#8221; 
$RESULT = $RESULT | ConvertTo-Json</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$NAME </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;alias1&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    deployment</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;ss123456&#39;</span></span>
<span class="line"><span style="color: #24292E">    ttl</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;300&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Patch </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/dns-record/</span><span style="color: #24292E">$NAME</span><span style="color: #032F62">/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing the updated CNAME record.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><textarea class="code-block-pro-copy-button-textarea" aria-hidden="true" readonly>{
  &#8220;associated&#8221;: true,
  &#8220;name&#8221;: &#8220;alias3&#8221;,
  &#8220;value&#8221;: &#8220;ss123456-jdwz6lb2-us-west-1-aws.searchstax.com&#8221;,
  &#8220;deployment&#8221;: &#8220;ss123456&#8221;,
  &#8220;ttl&#8221;: 300
}</textarea><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;associated&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">true</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;alias3&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;value&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456-jdwz6lb2-us-west-1-aws.searchstax.com&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;deployment&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss123456&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;ttl&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">300</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<h2 class="wp-block-heading">Questions?</h2>



<p class="wp-block-paragraph">Do not hesitate to contact the&nbsp;<a href="mailto:support@searchstax.com?subject=SearchStax%20Cloud%20API%20–%20DNS%20Alias" target="_blank" rel="noreferrer noopener">SearchStax Support Desk</a>.</p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-dns-alias-api/">Solr DNS Alias API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.searchstax.com/docs/searchstax-cloud-dns-alias-api/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Solr Backup/Restore API</title>
		<link>https://www.searchstax.com/docs/searchstax-cloud-backup-restore-api/</link>
					<comments>https://www.searchstax.com/docs/searchstax-cloud-backup-restore-api/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Thu, 04 Mar 2021 07:56:22 +0000</pubDate>
				<category><![CDATA[Operations and Recovery APIs]]></category>
		<category><![CDATA[Cloud]]></category>
		<guid isPermaLink="false">https://www.searchstax.com/docs/?p=7603</guid>

					<description><![CDATA[<p>Provisioning API &#8211; Backup/Restore Overview The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr Cloud deployments. Core and Enterprise Clients Only! The&#8230; <a class="more-link" href="https://www.searchstax.com/docs/searchstax-cloud-backup-restore-api/">Continue reading <span class="screen-reader-text">Solr Backup/Restore API</span></a></p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-backup-restore-api/">Solr Backup/Restore API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<h1 class="wp-block-heading" id="h-provisioning-api-backup-restore">Provisioning API &#8211; Backup/Restore</h1>



<hr class="wp-block-separator has-css-opacity"/>



<h2 class="wp-block-heading">Overview</h2>



<p class="wp-block-paragraph">The SearchStax Managed Search service provides an API supporting the creation, deletion and management of Solr Cloud deployments.</p>



<div class="alert alert-info">
<h3>Core and Enterprise Clients Only!</h3>
<p>The SearchStax API suite is available to our Core and Enterprise
clients only, as noted on our <a href="https://www.searchstax.com/pricing/cloud/">Pricing</a> page. </p>
</div>



<p class="wp-block-paragraph">This page describes how to perform backup and restore operations through API methods.</p>



<p class="wp-block-paragraph">The API can be accessed through any tool that assembles HTTP requests and dispatch them to a server. Among these would be the Python <a href="https://pypi.org/project/coreapi/" target="_blank" rel="noreferrer noopener">coreapi</a> package, the <a href="https://www.postman.com/" target="_blank" rel="noreferrer noopener">Postman</a> tool, and <a href="https://curl.se" target="_blank" rel="noreferrer noopener">cURL</a>. For Windows, use <a href="https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows?view=powershell-7.1" target="_blank" rel="noreferrer noopener">PowerShell 7+</a>.</p>



<div class="alert alert-warning">
<h4>Account Owner, Admin, or Technical Contact</h4>
<p>To run the SearchStax Provisioning API, you must be the account Owner,
an account Admin, or a Technical Contact. See <a href="/docs/searchstax-cloud-user-roles/#userroles">SearchStax User Roles</a>.</p>
</div>



<p class="wp-block-paragraph">Symbols enclosed in carets (&lt; and &gt;) such as <strong>&lt;username&gt;</strong> are metavariables. Substitute your local values when you encounter them in the examples.</p>



<p class="wp-block-paragraph">Contents:</p>



<ul class="wp-block-list">
<li><a href="#h-account-level-methods">Account-Level Methods</a>
<ul class="wp-block-list">
<li><a href="#accountbackuplist">account &gt; backup &gt; list</a></li>



<li><a href="#h-account-gt-backup-gt-delete">account &gt; backup &gt; delete</a></li>



<li><a href="#h-account-gt-restore-gt-create">account &gt; restore &gt; create</a></li>
</ul>
</li>



<li><a href="#deploymentmethods">Deployment-Level Methods</a>
<ul class="wp-block-list">
<li><a href="#backuplist">account &gt; deployment &gt; backup &gt; list</a></li>



<li><a href="#backupcreate">account &gt; deployment &gt; backup &gt; create</a></li>



<li><a href="#backupdelete">account &gt; deployment &gt; backup &gt; delete</a></li>



<li><a href="#schedulelist">account &gt; deployment &gt; backup &gt; schedule &gt; list</a></li>



<li><a href="#schedulecreate">account &gt; deployment &gt; backup &gt; schedule &gt; create</a></li>



<li><a href="#scheduledelete">account &gt; deployment &gt; backup &gt; schedule &gt; delete</a></li>



<li><a href="#restorecreate">account &gt; deployment &gt; restore &gt; create</a></li>



<li><a href="#restorestatus">account &gt; deployment &gt; restore &gt; status</a></li>
</ul>
</li>
</ul>



<p class="wp-block-paragraph">Related Pages:</p>



<ul class="wp-block-list">
<li><a href="/docs/searchstax-cloud-authentication-api/">Authentication API</a></li>



<li><a href="/docs/searchstax-cloud-users-api/">Users API</a></li>



<li><a href="/docs/searchstax-cloud-basic-auth-api/">Basic Auth API</a></li>



<li><a href="/docs/searchstax-cloud-ipfilter-api/">IP Filtering API</a></li>



<li><a href="/docs/searchstax-cloud-deployment-api/">Deployment API</a></li>



<li><a href="/docs/searchstax-cloud-private-vpc-api/">Private VPC API</a></li>



<li><a href="/docs/searchstax-cloud-dns-alias-api/">DNS Alias API</a></li>



<li><a href="/docs/searchstax-cloud-custom-jars-api/">Custom JARs API</a></li>



<li><a href="/docs/searchstax-cloud-tags-api/">Tags API</a></li>



<li><a href="/docs/searchstax-cloud-alerts-api/">Alerts API</a></li>



<li><a href="/docs/searchstax-cloud-webhooks-api/">Webhooks API</a></li>



<li><a href="/docs/searchstax-cloud-zookeeper-api/">Zookeeper API</a></li>
</ul>



<h2 class="wp-block-heading" id="h-account-level-methods">Account-Level Methods</h2>



<p class="wp-block-paragraph">Backup files do not disappear when you delete the associated  deployment. However, the deployment&#8217;s ssID (ss123456) becomes invalid, making it impossible to use the <a href="#deploymentmethods">deployment-level methods</a> to restore or delete the orphaned backup files. </p>



<p class="wp-block-paragraph">The following three methods let us list, restore, and delete orphaned backup files from the API.</p>



<h3 class="wp-block-heading" id="accountbackuplist">account &gt; backup &gt; list </h3>



<p class="wp-block-paragraph">This method lists all backups of an account, including deleted backup files.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>GET /api/rest/v2/account/&lt;account_name>/backup/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/backup/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request GET "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/backup/" 
  --header "Authorization: Token &lt;token>"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/backup/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountbackuplist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"

$BACKUPS = Invoke-RestMethod -Method Get -ContentType 'application/json' -Headers $headers `
              -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/backup/"
$BACKUPS = $BACKUPS | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/backup/&quot;</span></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $BACKUPS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">A successful response contains a JSON object containing a list of backups:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>[
    {
      "id": 57198,
      "backup_type": "One time",
      "created": "2020-06-19 04:49:42 PM (2020-06-19 16:49:42 UTC)",
      "status": "Done",
      "size": 223608,
      "region": "US West (N. California)",
      "collections": null,
      "deployment_uid": "ss305854",
      "deployment_name": "QuickStart",
      "version": "8.3.1",
      "cloud": "aws",
      "size_display": "223.61 KB",
      "replication_region": "-",
      "error_message": []
    }
]
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">[</span></span>
<span class="line"><span style="color: #24292E">    {</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">57198</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;backup_type&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;One time&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;created&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2020-06-19 04:49:42 PM (2020-06-19 16:49:42 UTC)&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Done&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;size&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">223608</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;region&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;US West (N. California)&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;collections&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">null</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;deployment_uid&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;ss305854&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;deployment_name&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;QuickStart&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;version&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;8.3.1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;cloud&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;aws&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;size_display&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;223.61 KB&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;replication_region&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;-&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #005CC5">&quot;error_message&quot;</span><span style="color: #24292E">: []</span></span>
<span class="line"><span style="color: #24292E">    }</span></span>
<span class="line"><span style="color: #24292E">]</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="h-account-gt-backup-gt-delete">account &gt; backup &gt; delete</h3>



<p class="wp-block-paragraph">This method deletes a backup from a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>DELETE /api/rest/v2/account/&lt;account_name>/backup/&lt;buid>/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">DELETE</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/backup/&lt;buid&gt;/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account, and <strong>&lt;buid&gt;</strong> is the ID of the backup.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request DELETE "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/backup/&lt;buid>/" 
  --header "Authorization: Token &lt;token>"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">DELETE</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/backup/&lt;buid&gt;/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountbackupdelete.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$BUID = "27004"

$BACKUPS = Invoke-RestMethod -Method Delete -ContentType 'application/json' -Headers $headers `
              -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/backup/$BUID/"
$BACKUPS = $BACKUPS | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$BUID </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;27004&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Delete </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/backup/</span><span style="color: #24292E">$BUID</span><span style="color: #032F62">/&quot;</span></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $BACKUPS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">A successful response returns a 204 code and an empty string. </p>





<h3 class="wp-block-heading" id="h-account-gt-restore-gt-create">account &gt; restore &gt; create</h3>



<p class="wp-block-paragraph">This method restores an orphaned backup file to a deployment. For more versatile restore options, see <a href="#restorecreate">account &gt; deployment &gt; restore &gt; create</a>.</p>



<div class="alert alert-warning">
<h4>Parallel Restoration</h4>
<p>Note that restoring a backup takes all collections offline until the restore is complete. </p>
<p>The <strong>parallel_restore</strong> parameter reduces restore time by rebuilding each collection in a separate thread.</p>
<p>Downtime due to a restore is difficult to estimate, ranging from minutes to hours for very large backup files. Experience must be your guide.</p>
</div>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/restore/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/restore/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    id="27004"
    target_deployment_id="ss123456"
    parallel_restore="true"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">id=</span><span style="color: #005CC5">&quot;27004&quot;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">target_deployment_id=</span><span style="color: #005CC5">&quot;ss123456&quot;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">parallel_restore=</span><span style="color: #005CC5">&quot;true&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped">
   <table>
      <thead>
         <tr>
            <th><strong>Parameter</strong></th>
            <th><strong>Description</strong></th>
            <th><strong>Example</strong></th>
         </tr>
      </thead>
       <tbody>
          <tr>
             <td><strong>id</strong><br>
                     <span style="color:#ff0000" class="has-inline-color">required</span><br>
                     string</td>
            <td>The backup id number, from the List Backups method.</td>
            <td>&#8220;27004&#8221;</td>
        </tr>
        <tr>
            <td><strong>target_deployment_uid</strong><br>
                    <span style="color:#32cd32" class="has-inline-color">optional</span><br>
                    string</td>
           <td>The target deployment ID number.</td>
           <td>&#8220;ss123456&#8221;</td>
        </tr>
        <tr>
            <td><strong>parallel_restore</strong><br>
                    <span style="color:#32cd32" class="has-inline-color">optional</span><br>
                    string</td>
           <td>Optional ability to restore collections in parallel (multiple threads). Default is &#8220;false.&#8221;</td>
           <td>&#8220;true&#8221;</td>
        </tr>        
     </tbody>
  </table>
</figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request POST "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/restore/" 
  --header "Content-Type: application/json" 
  --header "Authorization: Token &lt;token>" 
  --data '{"id":"27004","target_deployment_uid":"ss123456"}'
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/restore/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;{&quot;id&quot;:&quot;27004&quot;,&quot;target_deployment_uid&quot;:&quot;ss123456&quot;}&#39;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountrestorecreate.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"

$body = @{
    id='27004'
    target_deployment_uid='ss123456'
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/restore/" 
$RESULT = $RESULT | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    id</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;27004&#39;</span></span>
<span class="line"><span style="color: #24292E">    target_deployment_uid</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;ss123456&#39;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/restore/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document confirming that the restore has been scheduled.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "message": "restore begun"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;restore begun&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h2 class="wp-block-heading" id="deploymentmethods">Deployment-Level Methods</h2>



<p class="wp-block-paragraph">The SearchStax Provisioning API includes methods for performing backup and restore operations. If the backup file has been &#8220;orphaned&#8221; by deleting the source deployment, use the <a href="#h-account-level-methods">account-level methods</a> instead. </p>



<h3 class="wp-block-heading" id="backuplist">account &gt; deployment &gt; backup &gt; list</h3>



<p class="wp-block-paragraph">This method lists the existing backups of a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>GET /api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account, and <strong>&lt;uid&gt;</strong> is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request GET "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/" 
  --header "Authorization: Token &lt;token>"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentbackuplist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"

$BACKUPS = Invoke-RestMethod -Method Get -ContentType 'application/json' -Headers $headers `
              -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/backup/"
$BACKUPS = $BACKUPS | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/backup/&quot;</span></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $BACKUPS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">A successful response contains a JSON object containing a list of backups:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>[
    {
        "id":  2318045,
        "backup_type":  "scheduled",
        "created":  "2026-04-21T06:00:06Z",
        "status":  "done",
        "size":  2141854,
        "region":  "Amazon Web Services - us-west-2",
        "collections":  &#91;
                            "filmcollection"
                        &#93;
    },
        {
        "id":  2317534,
        "backup_type":  "onetime",
        "created":  "2026-04-20T17:05:01Z",
        "status":  "done",
        "size":  2141854,
        "region":  "Amazon Web Services - us-west-2",
        "collections":  &#91;

                        &#93;
    },
]
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">[</span></span>
<span class="line"><span style="color: #24292E">    {</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">:  </span><span style="color: #005CC5">2318045</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;backup_type&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;scheduled&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;created&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;2026-04-21T06:00:06Z&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;done&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;size&quot;</span><span style="color: #24292E">:  </span><span style="color: #005CC5">2141854</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;region&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;Amazon Web Services - us-west-2&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;collections&quot;</span><span style="color: #24292E">:  &#91;</span></span>
<span class="line"><span style="color: #24292E">                            </span><span style="color: #032F62">&quot;filmcollection&quot;</span></span>
<span class="line"><span style="color: #24292E">                        &#93;</span></span>
<span class="line"><span style="color: #24292E">    },</span></span>
<span class="line"><span style="color: #24292E">        {</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">:  </span><span style="color: #005CC5">2317534</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;backup_type&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;onetime&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;created&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;2026-04-20T17:05:01Z&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;done&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;size&quot;</span><span style="color: #24292E">:  </span><span style="color: #005CC5">2141854</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;region&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;Amazon Web Services - us-west-2&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">        </span><span style="color: #005CC5">&quot;collections&quot;</span><span style="color: #24292E">:  &#91;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">                        &#93;</span></span>
<span class="line"><span style="color: #24292E">    },</span></span>
<span class="line"><span style="color: #24292E">]</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">Note that the collections list is empty when all collections were backed up, but contains collection names when for a partial backup.</p>



<h3 class="wp-block-heading" id="backupcreate">account &gt; deployment &gt; backup &gt; create</h3>



<p class="wp-block-paragraph">This method makes a one-time backup of a deployment. </p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account, and <strong>&lt;uid&gt;</strong> is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    region: "us-west-1",
    collections: "&#91;filmcollection&#93;"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">region</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;us-west-1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">collections</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;&#91;filmcollection&#93;&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>region</strong><br><span style="color:#32cd32" class="has-inline-color">optional</span><br>string</td><td>The region ID of the region where the backup should be created. Defaults to the deployment&#8217;s region. Region codes can be obtained using the <a href="https://www.searchstax.com/docs/searchstax-cloud-deployment-api/#listplans">List Plans</a> method or from the deployment&#8217;s description in the SearchStax dashboard. </td><td>&#8220;us-west-2&#8221;</td></tr><tr><td><strong>collections</strong><br><span style="color:#34a300" class="has-inline-color"><meta charset="utf-8"><span style="color:#32cd32" class="has-inline-color">optional</span></span><br>list</td><td>List of collections to back up &#8211; [] to back up all collections</td><td>Bash: [&#8220;collection1&#8221;, &#8220;collection2&#8221;]<br><br>PowerShell: @(&#8216;collection1&#8217;, &#8216;collection2&#8217;)</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request POST "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/" 
  --header "Content-Type: application/json" 
  --header "Authorization: Token &lt;token>" 
  --data '{"region":"us-west-1","collection":"&#91;filmcollection&#93;"}'
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;{&quot;region&quot;:&quot;us-west-1&quot;,&quot;collection&quot;:&quot;&#91;filmcollection&#93;&quot;}&#39;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentbackupcreate.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"

$body = @{
    region='us-west-1'
    collections=@('filmcollection')
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/backup/" 
$RESULT = $RESULT | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    region</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;us-west-1&#39;</span></span>
<span class="line"><span style="color: #24292E">    collections</span><span style="color: #D73A49">=@</span><span style="color: #24292E">(</span><span style="color: #032F62">&#39;filmcollection&#39;</span><span style="color: #24292E">)</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/backup/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document containing the description of the new backup.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "id": 123456,
  "created": "2019-11-14T19:20:45.903037Z",
  "status": "pending",
  "size": 0,
  "region": "Amazon Web Services - us-west-1"
  "collections": &#91;
     "filmcollection"
     &#93;
}

</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">123456</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;created&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;2019-11-14T19:20:45.903037Z&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;status&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;pending&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;size&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">0</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;region&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Amazon Web Services - us-west-1&quot;</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #032F62">&quot;collections&quot;</span><span style="color: #B31D28; font-style: italic">:</span><span style="color: #24292E"> &#91;</span></span>
<span class="line"><span style="color: #24292E">     </span><span style="color: #032F62">&quot;filmcollection&quot;</span></span>
<span class="line"><span style="color: #24292E">     &#93;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="backupdelete">account &gt; deployment &gt; backup &gt; delete</h3>



<p class="wp-block-paragraph">This method deletes a backup from a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>DELETE /api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/&lt;buid>/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">DELETE</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/&lt;buid&gt;/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account, <strong>&lt;uid&gt;</strong> is the ID of the deployment, and <strong>&lt;buid&gt;</strong> is the ID of the backup.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request DELETE "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/&lt;buid>/" 
  --header "Authorization: Token &lt;token>"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">DELETE</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/&lt;buid&gt;/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentbackupdelete.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"
$BUID = "27004"

$BACKUPS = Invoke-RestMethod -Method Delete -ContentType 'application/json' -Headers $headers `
              -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/backup/$BUID/"
$BACKUPS = $BACKUPS | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"><span style="color: #24292E">$BUID </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;27004&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Delete </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/backup/</span><span style="color: #24292E">$BUID</span><span style="color: #032F62">/&quot;</span></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $BACKUPS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">A successful response is a JSON document containing a confirmation message:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "message": "Successfully deleted backup 27004",
  "success": "true"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Successfully deleted backup 27004&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;true&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h3 class="wp-block-heading" id="schedulelist">account &gt; deployment &gt; backup &gt; schedule &gt; list</h3>



<p class="wp-block-paragraph">This method lists the existing backup schedules of a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>GET /api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/schedule/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">GET</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/schedule/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account, and <strong>&lt;uid&gt;</strong> is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request GET "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/schedule/" 
  --header "Authorization: Token &lt;token>"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">GET</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/schedule/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentbackupschedulelist.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"

$BACKUPS = Invoke-RestMethod -Method Get -ContentType 'application/json' -Headers $headers `
              -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/backup/schedule/"

$BACKUPS = $BACKUPS | ConvertTo-Json</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Get </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/backup/schedule/&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $BACKUPS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span></code></pre></div>



<p class="wp-block-paragraph">A successful response contains a JSON object containing a list of backups:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>[
  {
    "id": 1234,
    "days": &#91;
      "mon",
      "tue",
      "wed",
      "thu",
      "fri",
      "sat",
      "sun"
    &#93;,
    "time": "00:00:00",
    "retention": 1,
    "collections": []
  }
]</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">[</span></span>
<span class="line"><span style="color: #24292E">  {</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;id&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">1234</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;days&quot;</span><span style="color: #24292E">: &#91;</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;mon&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;tue&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;wed&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;thu&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;fri&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;sat&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">      </span><span style="color: #032F62">&quot;sun&quot;</span></span>
<span class="line"><span style="color: #24292E">    &#93;,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;time&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;00:00:00&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;retention&quot;</span><span style="color: #24292E">: </span><span style="color: #005CC5">1</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;collections&quot;</span><span style="color: #24292E">: []</span></span>
<span class="line"><span style="color: #24292E">  }</span></span>
<span class="line"><span style="color: #24292E">]</span></span></code></pre></div>



<h3 class="wp-block-heading" id="schedulecreate">account &gt; deployment &gt; backup &gt; schedule &gt; create</h3>



<p class="wp-block-paragraph">This method creates a backup schedule for a deployment. </p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/schedule/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/schedule/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account, and <strong>&lt;uid&gt;</strong> is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    "retention":  7,
    "days":  &#91;
                 "mon",
                 "wed",
                 "fri"
             &#93;,
    "region_id":  "us-west-1",
    "frequency":  6,
    "collections":  &#91;
                        "filmcollection"
                    &#93;,
    "time":  "07:00"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;retention&quot;</span><span style="color: #24292E">:  </span><span style="color: #005CC5">7</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;days&quot;</span><span style="color: #24292E">:  &#91;</span></span>
<span class="line"><span style="color: #24292E">                 </span><span style="color: #032F62">&quot;mon&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">                 </span><span style="color: #032F62">&quot;wed&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">                 </span><span style="color: #032F62">&quot;fri&quot;</span></span>
<span class="line"><span style="color: #24292E">             &#93;,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;region_id&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;us-west-1&quot;</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;frequency&quot;</span><span style="color: #24292E">:  </span><span style="color: #005CC5">6</span><span style="color: #24292E">,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;collections&quot;</span><span style="color: #24292E">:  &#91;</span></span>
<span class="line"><span style="color: #24292E">                        </span><span style="color: #032F62">&quot;filmcollection&quot;</span></span>
<span class="line"><span style="color: #24292E">                    &#93;,</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #005CC5">&quot;time&quot;</span><span style="color: #24292E">:  </span><span style="color: #032F62">&quot;07:00&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped"><table><thead><tr><th><strong>Parameter</strong></th><th><strong>Description</strong></th><th><strong>Example</strong></th></tr></thead><tbody><tr><td><strong>time</strong><br><mark style="background-color:rgba(0, 0, 0, 0);color:#32cd32" class="has-inline-color">optional</mark><br>string</td><td>Time (UTC) the backup should run. (Format: HH:MM)<br>Either time or frequency must be provided. </td><td>&#8220;07:00&#8221;</td></tr><tr><td>days<br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark> list<br></td><td>List of days on which backup should run relative to UTC time. </td><td>[&#8220;mon&#8221;, &#8220;tue&#8221;, &#8220;wed&#8221;, &#8220;thu&#8221;, &#8220;fri&#8221;, &#8220;sat&#8221;, &#8220;sun&#8221;]<br><br>[&#8220;everyday&#8221;]</td></tr><tr><td>retention<br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark> number</td><td>Number of days to retain the backup.</td><td>7</td></tr><tr><td>frequency<br><mark style="background-color:rgba(0, 0, 0, 0);color:#32cd32" class="has-inline-color">optional</mark><br>number<br></td><td>At what interval (hours) the backups should run in the day.<br>Either time or frequency must be provided. </td><td>3</td></tr><tr><td><strong>region</strong>_id<br><mark style="background-color:rgba(0, 0, 0, 0);color:#ff0000" class="has-inline-color">required</mark> <br>string</td><td>The region ID of the region where the backup should be created. Defaults to the deployment&#8217;s region. <br>Region codes can be obtained using the <a href="https://www.searchstax.com/docs/searchstax-cloud-deployment-api/#listplans">List Plans</a> method or from the deployment&#8217;s description in the SearchStax dashboard. </td><td>&#8220;us-west-1&#8221;</td></tr><tr><td><strong>collections</strong><br><span style="color:#34a300" class="has-inline-color"><span style="color:#32cd32" class="has-inline-color">optional</span></span><br>list</td><td>List of collections to back up. Defaults to [] to back up all collections</td><td>Bash: [&#8220;collection1&#8221;, &#8220;collection2&#8221;]<br><br>PowerShell: @(&#8216;collection1&#8217;, &#8216;collection2&#8217;)</td></tr></tbody></table></figure>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request POST "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/schedule/" 
  --header "Content-Type: application/json" 
  --header "Authorization: Token &lt;token>" 
  --data '{"time":"08:30","collections":&#91;"filmcollection"&#93;,"days":&#91;"everyday"&#93;,"retention":"7","region_id":"us-west-1"}'
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/schedule/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;{&quot;time&quot;:&quot;08:30&quot;,&quot;collections&quot;:&#91;&quot;filmcollection&quot;&#93;,&quot;days&quot;:&#91;&quot;everyday&quot;&#93;,&quot;retention&quot;:&quot;7&quot;,&quot;region_id&quot;:&quot;us-west-1&quot;}&#39;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentbackupschedulecreate.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"

$body = @{
    days=@('mon', 'wed', 'fri')
    time='07:00'
    frequency=6
    retention=7
    region_id='us-west-1'
    collections=@('filmcollection')
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/backup/schedule/" 
$RESULT = $RESULT | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    days</span><span style="color: #D73A49">=@</span><span style="color: #24292E">(</span><span style="color: #032F62">&#39;mon&#39;</span><span style="color: #D73A49">,</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;wed&#39;</span><span style="color: #D73A49">,</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;fri&#39;</span><span style="color: #24292E">)</span></span>
<span class="line"><span style="color: #24292E">    time</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;07:00&#39;</span></span>
<span class="line"><span style="color: #24292E">    frequency</span><span style="color: #D73A49">=</span><span style="color: #005CC5">6</span></span>
<span class="line"><span style="color: #24292E">    retention</span><span style="color: #D73A49">=</span><span style="color: #005CC5">7</span></span>
<span class="line"><span style="color: #24292E">    region_id</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;us-west-1&#39;</span></span>
<span class="line"><span style="color: #24292E">    collections</span><span style="color: #D73A49">=@</span><span style="color: #24292E">(</span><span style="color: #032F62">&#39;filmcollection&#39;</span><span style="color: #24292E">)</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/backup/schedule/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document confirming success.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "message": "Backup Scheduled Successfully"
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Backup Scheduled Successfully&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span></code></pre></div>



<h3 class="wp-block-heading" id="scheduledelete">account &gt; deployment &gt; backup &gt; schedule &gt; delete</h3>



<p class="wp-block-paragraph">This method deletes a backup schedule from a deployment.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>DELETE /api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/schedule/&lt;buid>/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">DELETE</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/schedule/&lt;buid&gt;/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account, <strong>&lt;uid&gt;</strong> is the ID of the deployment, and <strong>&lt;buid&gt;</strong> is the ID of the backup.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request DELETE "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/backup/schedule/&lt;buid>/" 
  --header "Authorization: Token &lt;token>"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">DELETE</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/backup/schedule/&lt;buid&gt;/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentbackupscheduledelete.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"
$BUID = "27004"

$BACKUPS = Invoke-RestMethod -Method Delete -ContentType 'application/json' -Headers $headers `
              -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/backup/schedule/$BUID/"
$BACKUPS = $BACKUPS | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"><span style="color: #24292E">$BUID </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;27004&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Delete </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/backup/schedule/</span><span style="color: #24292E">$BUID</span><span style="color: #032F62">/&quot;</span></span>
<span class="line"><span style="color: #24292E">$BACKUPS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $BACKUPS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">A successful response is a JSON document containing a confirmation message:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "success": "The backup schedule has been deleted!"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;success&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;The backup schedule has been deleted!&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph"></p>



<h3 class="wp-block-heading" id="restorecreate">account &gt; deployment &gt; restore &gt; create</h3>



<p class="wp-block-paragraph">This method restores a backup to a deployment. Optionally, it can restore one or more individual collections from a multi-collection backup. </p>



<div class="alert alert-warning">
<h4>Restoring Individual Collections</h4>
<p>This method can be used to restore one or more individual collections from a multi-collection backup to a multi-collection deployment. Note that restoring individual collections takes all collections offline until the restore is complete. </p>
<p>The <strong>parallel_restore</strong> parameter reduces restore time by rebuilding each collection in a separate thread.</p>
<p>Downtime due to a restore is difficult to estimate, ranging from minutes to hours for very large backup files. Experience must be your guide.</p>
</div>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/restore/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/restore/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account, and <strong>&lt;uid&gt;</strong> is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">The request body should be a &#8220;application/json&#8221; encoded object, containing the following items:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
    backup_id="27004"
    replication_factor="3"
    collection_name="quickstart"
    collections=&#91;"Col1", "Col2", "Col3"&#93;
    parallel_restore="true"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">backup_id=</span><span style="color: #005CC5">&quot;27004&quot;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">replication_factor=</span><span style="color: #005CC5">&quot;3&quot;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">collection_name=</span><span style="color: #005CC5">&quot;quickstart&quot;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">collections=&#91;</span><span style="color: #005CC5">&quot;Col1&quot;</span><span style="color: #B31D28; font-style: italic">,</span><span style="color: #24292E"> </span><span style="color: #005CC5">&quot;Col2&quot;</span><span style="color: #B31D28; font-style: italic">,</span><span style="color: #24292E"> </span><span style="color: #005CC5">&quot;Col3&quot;</span><span style="color: #B31D28; font-style: italic">&#93;</span></span>
<span class="line"><span style="color: #24292E">    </span><span style="color: #B31D28; font-style: italic">parallel_restore=</span><span style="color: #005CC5">&quot;true&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<figure class="wp-block-table table table-bordered table-striped">
   <table>
      <thead>
         <tr>
            <th><strong>Parameter</strong></th>
            <th><strong>Description</strong></th>
            <th><strong>Example</strong></th>
         </tr>
      </thead>
       <tbody>
          <tr>
             <td><strong>backup_id</strong><br>
                     <span style="color:#ff0000" class="has-inline-color">required</span><br>
                     string</td>
            <td>The backup id number, from the List Backups method.</td>
            <td>&#8220;27004&#8221;</td>
        </tr>
        <tr>
            <td><strong>replication_factor</strong><br>
                    <span style="color:#32cd32" class="has-inline-color">optional</span><br>
                    string</td>
           <td>Defaults to the number of nodes in the target cluster. You may ask for fewer replicas, but not for more.</td>
           <td>&#8220;2&#8221;</td>
        </tr>
        <tr>
            <td><strong>collection_name</strong><br>
                    <span style="color:#32cd32" class="has-inline-color">optional</span><br>
                    string</td>
           <td>[Deprecated.] Optional name of a single collection to restore.</td>
           <td>&#8220;quickstart&#8221;</td>
        </tr>
        <tr>
            <td><strong>collections</strong><br>
                    <span style="color:#32cd32" class="has-inline-color">optional</span><br>
                    list</td>
           <td>[Preferred.] Optional list of collection names to restore.</td>
           <td>[&#8220;Col1&#8221;, &#8220;Col2&#8221;, &#8220;Col3&#8221;]</td>
        </tr>
        <tr>
            <td><strong>parallel_restore</strong><br>
                    <span style="color:#32cd32" class="has-inline-color">optional</span><br>
                    string</td>
           <td>Optional ability to restore collections in parallel (multiple threads). Default is &#8220;false.&#8221;</td>
           <td>&#8220;true&#8221;</td>
        </tr>
     </tbody>
  </table>
</figure>



<p class="wp-block-paragraph">If <strong>collection_name</strong> and <strong>collections</strong> are both present, the method will restore all of the listed collections. </p>



<p class="wp-block-paragraph">If <strong>collection_name</strong> and <strong>collections</strong> are both absent<strong>, </strong>the method will restore all the collections in the backup file, overwriting all previous data on the deployment.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request POST "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/restore/" 
  --header "Content-Type: application/json" 
  --header "Authorization: Token &lt;Token>" 
  --data '{"backup_id":"12345678","collections":&#91;"collection1","collection3"&#93;}'
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/restore/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Content-Type: application/json&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;Token&gt;&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--data</span><span style="color: #24292E"> </span><span style="color: #032F62">&#39;{&quot;backup_id&quot;:&quot;12345678&quot;,&quot;collections&quot;:&#91;&quot;collection1&quot;,&quot;collection3&quot;&#93;}&#39;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentrestorecreate.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"

$list = @("collection1","collection3")

$body = @{
    backup_id='12345678'
    collections=$list
}

$body = $body | ConvertTo-Json

$RESULT = Invoke-RestMethod -Method Post -body $body -ContentType 'application/json' -Headers $headers `
         -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/restore/" 
$RESULT = $RESULT | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$list </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">(</span><span style="color: #032F62">&quot;collection1&quot;</span><span style="color: #D73A49">,</span><span style="color: #032F62">&quot;collection3&quot;</span><span style="color: #24292E">)</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #D73A49">@</span><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">    backup_id</span><span style="color: #D73A49">=</span><span style="color: #032F62">&#39;12345678&#39;</span></span>
<span class="line"><span style="color: #24292E">    collections</span><span style="color: #D73A49">=</span><span style="color: #24292E">$list</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$body </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $body </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">body $body </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">         </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/restore/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">$RESULT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULT </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON document confirming that the restore has been scheduled.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "message": "The restore request has been successfully placed in the Task queue and will be initiated soon. You can check the status with the restore-status API"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;The restore request has been successfully placed in the Task queue and will be initiated soon. You can check the status with the restore-status API&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When performing a partial restore, SearchStax will overwrite the restored collections while preserving any others that are present.  </p>



<h3 class="wp-block-heading" id="restorestatus">account &gt; deployment &gt; restore &gt; status</h3>



<p class="wp-block-paragraph">This method reports on the status of a restore.</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>POST /api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/restore/status/
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #D73A49">POST</span><span style="color: #24292E"> /api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/restore/status/</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">where <strong>&lt;account_name&gt;</strong> is the name of the tenant account, <strong>&lt;uid&gt;</strong> is the ID of the deployment.</p>



<p class="wp-block-paragraph">This method uses <a href="/docs/searchstax-cloud-authentication-api/#token/">Token</a> authentication.</p>



<p class="wp-block-paragraph">There is no request body.</p>



<p class="wp-block-paragraph">When invoked from Linux (Bash script):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>curl --request POST "https://app.searchstax.com/api/rest/v2/account/&lt;account_name>/deployment/&lt;uid>/restore/status/" 
  --header "Authorization: Token &lt;token>"
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #6F42C1">curl</span><span style="color: #24292E"> </span><span style="color: #005CC5">--request</span><span style="color: #24292E"> </span><span style="color: #032F62">POST</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/&lt;account_name&gt;/deployment/&lt;uid&gt;/restore/status/&quot;</span><span style="color: #24292E"> </span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #6F42C1">--header</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;Authorization: Token &lt;token&gt;&quot;</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">When invoked from Windows (<a href="https://github.com/searchstax/searchstax-client-powershell/blob/master/restapi/accountdeploymentrestorestatus.ps1" target="_blank" rel="noreferrer noopener">PowerShell script</a>):</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>$ACCOUNT = "AccountName"
$uid = "ss123456"

$RESULTS = Invoke-RestMethod -Method Post -ContentType 'application/json' -Headers $headers `
              -uri "https://app.searchstax.com/api/rest/v2/account/$ACCOUNT/deployment/$uid/restore/status/"
$RESULTS = $RESULTS | ConvertTo-Json
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">$ACCOUNT </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;AccountName&quot;</span></span>
<span class="line"><span style="color: #24292E">$uid </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #032F62">&quot;ss123456&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> </span><span style="color: #005CC5">Invoke-RestMethod</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Method Post </span><span style="color: #D73A49">-</span><span style="color: #24292E">ContentType </span><span style="color: #032F62">&#39;application/json&#39;</span><span style="color: #24292E"> </span><span style="color: #D73A49">-</span><span style="color: #24292E">Headers $headers </span><span style="color: #D73A49">`</span></span>
<span class="line"><span style="color: #24292E">              </span><span style="color: #D73A49">-</span><span style="color: #24292E">uri </span><span style="color: #032F62">&quot;https://app.searchstax.com/api/rest/v2/account/</span><span style="color: #24292E">$ACCOUNT</span><span style="color: #032F62">/deployment/</span><span style="color: #24292E">$uid</span><span style="color: #032F62">/restore/status/&quot;</span></span>
<span class="line"><span style="color: #24292E">$RESULTS </span><span style="color: #D73A49">=</span><span style="color: #24292E"> $RESULTS </span><span style="color: #D73A49">|</span><span style="color: #24292E"> </span><span style="color: #005CC5">ConvertTo-Json</span></span>
<span class="line"></span></code></pre></div>



<p class="wp-block-paragraph">The response is a JSON object containing an appropriate message string:</p>



<div class="wp-block-kevinbatdorf-code-block-pro" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:1rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.5rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span role="button" tabindex="0" style="color:#24292e;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>{
  "message": "Backup Restore in Progress"
}

{
  "message": "No restore Running on this deployment"
}
</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg></span><pre class="shiki github-light" style="background-color: #fff" tabindex="0"><code><span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;Backup Restore in Progress&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #24292E">{</span></span>
<span class="line"><span style="color: #24292E">  </span><span style="color: #005CC5">&quot;message&quot;</span><span style="color: #24292E">: </span><span style="color: #032F62">&quot;No restore Running on this deployment&quot;</span></span>
<span class="line"><span style="color: #24292E">}</span></span>
<span class="line"></span></code></pre></div>



<h2 class="wp-block-heading" id="questions">Questions?</h2>



<p class="wp-block-paragraph">Do not hesitate to contact the <a href="mailto:support@searchstax.com?subject=SearchStax%20Cloud%20API%20–%20Backup%2FRestore" target="_blank" rel="noreferrer noopener">SearchStax Support Desk</a>.</p>
<p>The post <a href="https://www.searchstax.com/docs/searchstax-cloud-backup-restore-api/">Solr Backup/Restore API</a> appeared first on <a href="https://www.searchstax.com/docs">SearchStax Docs</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.searchstax.com/docs/searchstax-cloud-backup-restore-api/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
