Login API

This is the API of the Login page, that will start a session for your user, based on Cookie or SessionID field.
Use http post to pass the fields into the function. Response returned as json string.
In order to use the API, call the DOMAIN/Login_json url.
In order to Log-Out, call the DOMAIN/Logout_json url.

Function Input

The list of required login fields, is defined by "Website Login System" on hyper's fundamentals.
Field Name Description
Leading_ID According to "Login System" configuration:
This field can get the user Email address, or the Phone number, or the TP Login number, as defined in the client record of Hyper.
Password The website password of the user.
ID The user ID (string), as defined in the client record of Hyper.

Functions Error Messages

Response Code Message in English
3 API function does not exists.
4 Database Error on server side.
5 Technical Error on server side.
7 Please fill up all the required fields.
10 User is already connected on this session (Logged in).
11 Incorrect Login details. Please check it and try again.

Message Examples

Posted Http Form:
DOMAIN/Login_json?Leading_ID=user@gmail.com&password=1234567890

For successful login, the following message will be received:
{"Login":"OK","Cookie":"SessionString"}
{"Login":"OK","Cookie":"1400605290776E29A80E40FA","PrevSession":"Dismissed"}

If any error occurs, the following message format will be received:
{"ResponseCode":"010","ResponseMsgEng":"User is already connected on this session (Logged in)"}
{"ResponseCode":"011","ResponseMsgEng":"Incorrect Login details. Please check it and try again."}

How to redirect browser between API login, to Hyper's html pages

For some website design, you might want to switch from your website (like word-press / WIX), to hyper's portal pages (like reports etc).
In this case the flow is:
  1. From your website (WP / WIX etc), you open a Login widget. The credentials are posted to your server.
  2. Your web server is calling Hyper's Login_json function, and get the session id (cookie).
  3. Your web server will reply the browser with a new page (WP / WIX etc) but this time register a session cookie named "HyperSession".
    Another way is to redirect to hyper's portal page, and in the HTTP response, include the "HyperSession" cookie.
    e.g. Set-Cookie: HyperSession=1400605290776E29A80E40FA; HttpOnly; Secure
  4. From this point, every time the browser will call a page from hyper's web-app, it's request will contain the "HyperSession" cookie.