Signup API

The registration process basically consists of getting a pair of public and private keys.

If your store can define the product descriptions in multiple languages, you’ll need to get a separate pair of keys for each language and connect all keys in a group of keys. This is necessary to manage settings and view statistics in the Searchanise (Smart Search & Filter) control panel.

Let’s look at this process more closely. 

To start the registration process, form an HTTP POST request with parameters (see the table below) for one of your languages. In response, you’ll get api_key and private_key. Save them.

Repeat this process as many times as there are languages in your store. Send the private key you received in the first request to the server and pass the private key in the parent_private_key parameter, that you received upon the first request to the server.

Upon completion, the first obtained private key will be both a private key when accessing update API, and the parent private key specified when connecting to the widget of the embedded control panel.

Registration request

A registration request is an HTTP POST request sent to http://searchserverapi.com/api/signup/json with the following parameters:

Parameter Description Value type
url Required parameter, full url to the homepage of your store, including get parameter, with which you can immediately go to the homepage of your store with the selected language (http://your_store/folder/?language=current) string (valid url)
email Required parameter, email of the store administrator for getting feedback string (valid email)
parent_private_key Parent private key, used for linking a group of keys for different languages within a single store string (private key)

Response to the request

Parameter Description
api Public API key
private Private API key
Note

The request for registration may take some time. We recommend setting at least 10 seconds for the timeout.

An example

curl -X POST "http://searchserverapi.com/api/signup/json" -d 'url=http://example.com/?language=english&email=test@example.com'
 > {"keys":{"api":"XXXXXXXXXX","private":"XXXXXXXXXXXXXXXXXXXX"}}

An example with an error

curl -X POST "http://searchserverapi.com/api/signup/json"
 > {"errors":{"error":"Invalid email or url"}}

Possible errors

  • {«errors»:{«error»:«Invalid email or url»}} – URL or email parameter is not specified
  • {«errors»:{«error»:«Note that the searchanise registration unavailable for the store …»}} – registration is not possible for the specified URL
  • {«errors»:{«error»:«Sorry, registration is not possible: the service is temporarily closed for maintenance. Please try again in a while.»}} – Registration is not possible at this moment. Try again later.

And other errors in the test format that describe the error that occurred at registration.

Updated on March 23, 2022

Was this article helpful?

Related Articles

Need Support?
Can't find the answer you're looking for?
Contact Support
Back to top