Guest Manager System Calls

Guest Manager System API calls comprise of the login, Logout, and all the system calls. These API calls help guest users log in to the GuestManager server and access its services. Using the system calls, one can retrieve the information like session data, timezone list, server config information, system capabilities, and server version.

API Calls

/v1.14/site/keyLogin

/v1.14/site/logout

/v1.14/site/sessiondata

/v1.14/site/timezonelist

/v1.14/site

/v1.14/site/version

Log Into Guest Manager

Description Logs in to the Guest Manager.
Who Can Execute? Any user can execute this API call.
Syntax
GET <Base_URL>/site/keyLogin?key_id=<value>&key_value=<value>
  • key_id

    The key ID and value is system-generated and can be created from Launchpad. The key must have privileges on the Guest Manager service.
    It takes String value and is a mandatory query parameter. Sample value, KEY-ATN59618-1.

  • key_value

    The corresponding key value. It takes String value and is a mandatory query parameter. Sample value, 42ff84734541cbd98f674b02555330ef.

Sample code
GET https://analyticsdemo.mojonetworks.com/api/v1.14/site/keyLogin?key_id=KEY-ATN165-19&key_value=8cc48dd84bcf1a70d4e187c1b6c5f2a8
Request Body  This API call does not require any request body parameters.
Response Body  If the API call is successful, the HTTP response status is 200.
The response body contains the success message and is in the application/json format.
The below list describes the contents of the response body.

  • success

    Specifies whether the API call is successful or not. It’s a boolean value.

  • message

    A message string indicating whether the API call is successful. It’s a String value.

  • data

    A JSON object for the API status message.

  • data/other

    A JSON object.

  • data/other/access_token

    A string value that must be passed as a parameter in the URL of the subsequent API calls.

A sample response is as follows:

{	
      "success": true,		
      "message": "Login Successfull",
      "data": {		
            "other": {
                  "access_token": "12otji6slt3bvame64rog416q7"
	       }
         }
}

Log Out of  Guest Manager

Description Logs out from the Guest Manager and end the corresponding session.
Who Can Execute? Any user can execute this API call.
Syntax
GET <Base_URL>/site/logout
Sample code
GET https://analyticsdemo.mojonetworks.com/api/v1.14/site/logout
Request Body  This API call does not require any request body parameters.
Response Body  If the API call is successful, the HTTP response status is 200. The response body contains the success message and is in the application/json format. The below list describes the contents of the response body:

  • success

    Specifies whether the API call is successful or not. It’s a boolean value.

  • message

    A message string indicating whether the API call is successful. It’s a String value.

  • data

    A JSON object for the API status message.

  • data/errorCode

    The error code. If the API call is successful the error code is 200. It’s an integer value.

  • data/message

    A message indicating the API success or failure. It’s a String value.

A sample response is as follows:

{
   "success": true,
   "message": "Logout Successfull",
   "data": {
      "errorCode": 200,
      "message": "Logout Successfull"
   }
}

Get Session Data

Description Returns the details of the current session for a logged in user.
Who Can Execute? Any user can execute this API call.
Syntax
GET <Base_URL>/site/sessiondata
Sample code
GET https://analyticsdemo.mojonetworks.com/api/v1.14/site/sessiondata
Request Body  This API call does not require any request body parameters.
Response Body If the API call is successful, the session details are returned in the response body.
The response is in the application/json format. The below list describes the contents of the response body:

  • success

    Specifies whether the API call is successful or not. It’s a boolean value.

  • message

    A message string indicating whether the API call is successful. It’s a String value.

  • data

    A JSON object including the session data.

  • data/session_data

    The session information in JSON.

  • data/session_data/username>

    The user account of the logged in user. It’s a String value.

  • data/session_data/rid

    The role ID of the role assigned to the user. It’s an integer value.

  • data/session_data/display_name

    The display name of the logged in user. It’s a String value.

  • data/session_data/email

    The email address of the logged in user. It’s a String value.

  • data/session_data/time_zone

    The timezone configured for the logged in user. It’s a String value.

  • data/session_data/lockout_policy

    This reserved for future use. It’s an integer value.

  • data/session_data/cas_login

    This is for internal use only. It’s a boolean value.

  • data/session_data/kvs_login

    A true or false value indicating whether the KVS Login is enabled or not. If the KVS Login is enabled then Analytics Engine Sync Operation will be performed with the KVS. If the KVS login is disabled then Analytics Engine Sync Operation will be performed with the SSO.

  • data/session_data/hide_pii_admin

    The true or false value indicating whether admin PII is visible or hidden. If set to true the admin PII will be hidden. If set to false then admin PII will be visible for that user.

  • data/session_data/hide_pii_wifi_users

    The true or false value indicating whether the WiFi users PII is visible or hidden. If set to true the WiFi users PII will be hidden. If set to false then the WiFi users PII will be visible to the user.

  • data/session_data/hide_credentials

    The true or false value indicating whether the credentials like username and password are visible or hidden. If set to true then credentials will be hidden. If set to false then credentials will be visible to the user.

  • data/session_data/cname

    The customer account to which the user belongs. It’s a String value.

  • data/session_data/analytics_last_sync_time

    Last sync time to help the data take caching related decisions.

A sample response is as follows:

{
    "success": true,
    "message": "Record Found",
    "data": {
        "session_data": {
            "username": "Doc team",
            "rid": 2,
            "display_name": " ",
            "email": null,
            "time_zone": "UTC",
            "lockout_policy": 0,
            "cas_login": false,
            "kvs_login": true,
            "hide_pii_admin": false,
            "hide_pii_wifi_users": false,
            "hide_credentials": false,
            "cname": "ATN165",
            "analytics_last_sync_time": 1516885248
        }
    }
}

Get Timezones

Description Returns the list of time zones supported by Guest Manager.
Who Can Execute? Any user can execute this API call.
Syntax
GET <Base_URL>/site/timezonelist
Sample code
GET https://analyticsdemo.mojonetworks.com/api/v1.14/site/timezonelist
Request Body  This API call does not require any request body parameters.
Response Body If the API call is successful, the session details are returned in the response body.
The response is in the application/json format. The below list describes the contents of the response body.

  • success

    Specifies whether the API call is successful or not. It’s a boolean value.

  • message

    A message string indicating whether the API call is successful. It’s a String value.

  • data

    A JSON object including the session data.

  • data/totalCount

    The total number of time zones available in Guest Manager. It’s an integer value.

  • data/timezones

    An array of JSON objects for the timezones.

  • data/timezones/timezone_name

    The timezone name. It’s a String value.

  • data/timezones/timezone_display_name

    The display name for the timezone. It’s a String value.

  • data/timezones/timezone_offset

    The offset from GMT for the timezone. It’s a String value.

A sample response is as follows:

{
    "success": true,
    "message": "Record Found",
    "data": {
        "totalCount": 593,
        "timezones": [
            {
                "timezone_name": "Etc/GMT+12",
                "timezone_display_name": "Etc/GMT+12",
                "timezone_offset": "-12:00"
            },
            {
                "timezone_name": "Pacific/Pago_Pago",
                "timezone_display_name": "Pacific/Pago_Pago",
                "timezone_offset": "-11:00"
            },
            {
                "timezone_name": "Etc/GMT+11",
                "timezone_display_name": "Etc/GMT+11",
                "timezone_offset": "-11:00"
            },    
			. . .
			. . .
			. . .
            {
                "timezone_name": "Pacific/Kiritimati",
                "timezone_display_name": "Pacific/Kiritimati",
                "timezone_offset": "+14:00"
            }
        ]
    }
}

Get Server Config Information

Description Provides the details of the configuration parameters for the Guest Manager.
Who Can Execute? Any user can execute this API call.
Syntax
GET <Base_URL>/site
Sample code
GET https://analyticsdemo.mojonetworks.com/api/v1.14/site
Request Body  This API call does not require any request body parameters.
Response Body If the API call is successful, the session details are returned in the response body.
The response is in the application/json format. The below list describes the contents of the response body.

  • success

    Specifies whether the API call is successful or not. It’s a boolean value.

  • message

    A message string indicating whether the API call is successful. It’s a String value.

  • data

    A JSON object including the session data.

  • data/site

    A JSON object for the configuration parameters.

  • data/site/is_sso_enabled

    A true or false value indicating whether the Guest Manager is SSO enabled or not. It’s boolean value.

  • data/site/is_kvs_enabled

    A true or false value indicating whether the GM server is SSO enabled or not. It’s boolean value.

  • data/site/canvas_url

    URL for the canvas. It’s a string value.

  • data/site/brand_config

    Brand config attributes.

  • data/site/brand_config /id

    32-bit unique character ID.

  • data/site/brand_config /short_name

    Short name for the brand config. It’s a String value.

  • data/site/brand_config /full_name

    The full name for brand config. It’s a String value.

  • data/site/brand_config /product_name

    The product name for the brand config. It’s a String value.

  • data/site/brand_config /wireless_manager_name

    Wireless Manager name for the brand config. It’s a String value.

  • data/site/brand_config /support_email

    Support email address for the brand config. It’s a String value.

  • data/site/brand_config /copyright_statement

    Copyright statement for the brand config. It’s a String value.

  • data/site/brand_config /license_url

    The license URL for the brand config. It’s a String value.

  • data/site/brand_config /patent_trademark_info

    Information regarding the trademark and patent. It’s a String value.

  • data/site/brand_config /report_footer

    Report footer to display in the footer of the report. It’s a String value.

  • data/site/brand_config /fb_url

    FaceBook URL for the brand. It’s a String value.

  • data/site/brand_config /twitter_url

    Twitter URL for the brand. It’s a String value.

  • data/site/brand_config /linkedin_url

    LinkedIn URL for the brand. It’s a String value.

A sample response is as follows:

{
    "success": true,
    "message": "Record Found",
    "data": {
        "site": {
            "is_sso_enabled": true,
            "is_kvs_enabled": true,
            "canvas_url": "https://canvasdemo.airtightnw.com",
            "brand_config": {
                "id": "61b12e30e5d51f9d185d0f99a0e8c850",
                "short_name": "Mojo",
                "full_name": "Mojo Networks, Inc.",
                "product_name": "Guest Manager",
                "wireless_manager_name": "Wireless Manager",
                "support_email": "support@mojonetworks.com",
                "copyright_statement": "\\u00a9 {0} Mojo Networks, Inc. All Rights Reserved.",
                "license_url": "http://www.mojonetworks.com/home/cloud-services-agreement.html",
                "patent_trademark_info": "Protected by one or more of U.S. patent Nos. 7,002,943; 
                 7,154,874; 7,216,365; 7,333,800; 7,333,481; 7,339,914; 7,406,320; 7,440,434; 7,447,184; 7,496,094;
                 7,536,723; 7,558,253; 7,710,933; 7,751,393; 7,764,648; 7,804,808; 7,856,209; 7,856,656; 7,970,894; 
                 7,971,253; 8,032,939; and international patents: AU 200429804; GB 2410154; JP 4639195; 
                 DE 60 2004 038 621.9; and GB/NL/FR/SE 1976227. More patents pending.
                 Mojo Networks, Mojo Networks logo, AirTight Networks and the AirTight Networks logo are trademarks 
                 and AirTight is a registered trademark of Mojo Networks, Inc.",
                "report_footer": "Mojo",
                "fb_url": "https://www.facebook.com/mojonetworks",
                "twitter_url": "https://twitter.com/mojonetworks_",
                "linkedin_url": "https://www.linkedin.com/company/mojo-networks"
            }
        }
    }
}

Get Server Version

Description Returns application and API versions.
Who Can Execute? Any user can execute this API call.
Syntax
GET <Base_URL>/site/version
Sample code
https://analyticsdemo.mojonetworks.com/api/v1.14/site/version
Request Body This API call does not require any request body parameters.
Response Body If the API call is successful, the HTTP response status is 200.
The response body contains the details of API and application version. The response is in the application/json format. The below list describes the contents of the response body:

  • success

    Specifies whether the API call is successful or not. It’s a boolean value.

  • message

    A message string indicating whether the API call is successful. It’s a String value.

  • data

    A JSON object including the system capability data.

  • version

    A JSON object including the version details.

  • application_build

    Latest application build. It’s an integer value. Sample value, 4.9.2-421.

  • application_version

    Latest application version. It’s an integer value. Sample value, 4.9.2.

  • api_version

    It’s the latest API version.

A sample response is as follows:

{
    "success": true,
    "message": "Record Found",
    "data": {
        "version": {
            "application_build": "4.9.2-421",
            "application_version": "4.9.2",
            "api_version": "v1.14"
        }
    }
}