splash_page

Splash Page

A splash page is the landing page of the portal that guests see when they access your WiFi setup. A portal must have a splash page. Splash pages can be designed and managed through Mojo Canvas. Once created, the pages can be associated with a campaign defined in Mojo Canvas. To publish a campaign it must have a splash page. A published campaign can contain only one active splash page.

JSON Table

Parameter Data Type Description Default/Sample Value
success boolean Whether the API call was successful or not.  true
message String A message indicating the API success or failure.  Records Found
data application/json A JSON object for the response data.
data/totalCount int The total number of splash pages fetched.  1
data/splash application/json A JSON object containing the details of each splash page.
data/splash/id int A system-generated unique ID for the splash page bundle.  1
data/splash/pid int A system-generated unique ID of the portal from which the splash page bundle details are fetched.  50
data/splash/name String A unique name for the splash page bundle.  Default Splash Page
data/splash/type String The type of splash page. The applicable values are custom and brandbuilder. Splash page created using the BrandBuilder app and saved in Guest Manager have the type set to brandbuilder  custom
data/splash/active boolean Whether or not the splash page is active. Only one splash page is active at a time. 1 indicates the splash page is active and 0 indicates it is inactive.  1
data/splash/locked_by String Username of Guest Manager user who has locked the splash page for editing in Brand Builder. Only splash pages with type = brandbuilder can be locked for editing.  null
data/splash/locked_date Date Date and time when the splash page was locked.  null
data/splash/date_created Date Date and time when the splash page was created.  2014-05-15 08:04:10.712763
data/splash/date_modified Date Date and time when the splash page was last modified.  2014-08-01 11:15:27.526092
data/splash/preview_url String The URL to preview the splash page.  https://analyticsdemo.mojonetworks.com/api/portalb/Cust_1/da629962fc72849b10b85dfab6aa7c59/archive/d3d3d8073ab859661ba72295d79bab9b
data/splash/download_url String The URL to download the splash page bundle.  https://analyticsdemo.mojonetworks.com/api/v1.1/portals/50/splashpages/1?download=1
data/splash/upload_url String The URL to upload a new bundle for the splash page.  https://analyticsdemo.mojonetworks.com/api/v1.1/portals/50/splashpages/1?type=custom
data/splash/access_token application/json An access token can be shared with a third party tool which can call splash page APIs on behalf of the user. This access token can be used for authorisation for such calls. {“token_name”:”token_value”}. Must be appended to the splash manager API when being consumed as “?token_name=token_value”. This value will be NOT NULL only for splash pages of type = brandbuilder, for the rest it is NULL.  null

Copy Sample JSON
Sample JSON
{
   "success": true,
   "message": "Records Found",
   "data": {
      "totalCount": 1,
      "splash": [{
         "id": 1,
         "pid": 50,
         "name": "Default Splash Page",
         "type": "custom",
         "active": 1,
         "locked_by": null,
         "locked_date": null,
         "date_created": "2014-05-15 08:04:10.712763",
         "date_modified": "2014-08-01 11:15:27.526092",
         "preview_url": "https://analyticsdemo.mojonetworks.com/api/portalb/Cust_1/da629962fc72849b10b85dfab6aa7c59/archive/d3d3d8073ab859661ba72295d79bab9b",
         "download_url": "https://analyticsdemo.mojonetworks.com/api/v1.1/portals/50/splashpages/1?download=1",
         "upload_url": "https://analyticsdemo.mojonetworks.com/api/v1.1/portals/50/splashpages/1?type=custom",
         "access_token": null
      }
      {
         "id": 2,
         "pid": 50,
         "name": "Brand Splash Page",
         "type": "brandbuilder",
         "active": 0,
         "locked_by": "admin",
         "locked_date": "2014-08-10 17:45:39.817241",
         "date_created": "2014-05-15 08:04:10.712763",
         "date_modified": "2014-08-01 11:15:27.526092",
         "preview_url": "https://analyticsdemo.mojonetworks.com/api/portalb/Cust_1/da629962fc72849b10b85dfab6aa7c59/archive/6ce42cdfa600584973dd9226a6be3407",
         "download_url": "https://analyticsdemo.mojonetworks.com/api/v1.2/portals/50/splashpages/2?download=1",
         "upload_url": "https://analyticsdemo.mojonetworks.com/api/v1.2/portals/50/splashpages/2?type=custom",
         "access_token": { "ATN_GMS_ADMIN" : "ojuqnhlcjj0ip4qroki8sbkqi6" }
      }]
   }
}
API Calls

/v1.14/portals/{portal_id}/splashpages/{id}

/v1.14/portals/{portal_id}/splashpages

/v1.14/portals/{portal_id}/splashpages

/v1.14/portals/{portal_id}/splashpages/{id}

/v1.14/portals/{portal_id}/splashpages/{id}

/v1.14/portals/{portal_id}/splashpages/{id}

Get Splash Page

Description The API returns the details of a splash page defined in the portal in Guest Manager.
Guest Manager users with the Administrator role can access this API.
Syntax
GET <Base_URL>/portals/{portal_id}/splashpages/{id}

Here,

  • portal_id

    It is the unique system-generated ID of the portal from which the splash page details have to be fetched. It takes integer value.

  • id

    It is the unique system-generated ID of the splash page bundle. It takes integer value.

Sample code
GET https://analyticsdemo.mojonetworks.com/api/v1.14/portals/50/splashpages/1
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 returns the details of the specified splash page created in the portal.

Get Splash Pages

Description The API returns the details of all the splash pages defined in the portal in Guest Manager.
Guest Manager users with the Administrator role can access this API.
Syntax
GET <Base_URL>/portals/{portal_id}/splashpages
Sample code
GET https://analyticsdemo.mojonetworks.com/api/v1.14/portals/50/splashpages
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 returns the details of all the splash pages created in the portal.

Add Splash Page

Description The API creates a splash page bundle in the specified portal in Guest Manager.
Guest Manager users with the Administrator role can access this API.
Syntax
POST <Base_URL>/portals/{portal_id}/splashpages?name=<value>&active=<value>&type=<value>

Here,

  • portal_id

    It is the unique system-generated ID of the portal from which the splash page details have to be fetched. It takes integer value.

  • name

    A unique name for the splash page bundle. It takes String value.

  • active

    Whether the splash page has to be made active post creation. This parameter takes a boolean value, where 1 indicates active and 0 indicates inactive. If an existing splash page is already active, then it will be made inactive when this parameter is set to 1 in the API call.This is an optional parameter with the default value being 0.

  • type

    This specifies the splash page bundle type. This is string value with the applicable values being custom and brandbuilder. The brandbuilder value is used only for splash page bundles created using the BrandBuilder app. For all other splash page bundles, use the type value custom.

Sample code
POST https://analyticsdemo.mojonetworks.com/api/v1.14/portals/50/splashpages?name=”Custom Splash Page”&active=1&type=”custom”
Request Body  The API takes the spash page bundle zip file in the request body. For example,
“file”:”splashpage_bundle.zip” (enctype = “multipart/form/data”)
Response Body If the API call is successful, the HTTP response status is 200.
The response body returns the details of the splash page created in the portal.

Edit Splash Page

Description The API modifies the name and active status of a splash page bundle in the specified portal in Guest Manager.
Guest Manager users with the Administrator role can access this API.
Syntax
PUT <Base_URL>/portals/{portal_id}/splashpages/{id}

Here,

  • portal_id

    It is the unique system-generated ID of the portal in which the splash page exists. It takes integer value.

  • id

    It is the unique system-generated ID of the splash page bundle that has to be edited. It takes integer value.

Sample code
PUT https://analyticsdemo.mojonetworks.com/api/v1.14/portals/50/splashpages/3
Request Body This API requires the details of the splash page bundle to be edited, which is passed as parameters in the request body.
The parameters are passed in the application/json format. The below list describes the optional parameters and the applicable values:

  • name

    The name of the splash page bundle. It takes String value. Sample value, Guest Splash Page.

  • active

    Whether or not the splash page is active. Only one splash page is active at a time. 1 indicates the splash page is active and 0 indicates it is inactive.
    It takes a boolean value. Sample value, 1.

A sample request body is as follows:

{
   "name": "Guest Splash Page",
   "active": 1,
}
Response Body If the API call is successful, the HTTP response status is 200.
The response body returns the details of the edited splash page in the portal.

Edit Splash Page Bundle

Description The API updates the splash page bundle in the specified portal in Guest Manager.
Guest Manager users with the Administrator role can access this API.
Syntax
POST <Base_URL>/portals/{portal_id}/splashpages/{id}?type=<value>

Here,

  • portal_id

    It is the unique system-generated ID of the portal from which the splash page details have to be fetched. It takes an integer value.

  • id

    It is the unique system-generated ID of the splash page bundle. It takes an integer value.

  • value

    It specifies the splash page bundle type. It takes String value. Applicable values are custom and brandbuilder.
    The brandbuilder value is used only for splash page bundles created using the BrandBuilder app.
    For all other splash page bundles, use the type value custom.

Sample code
POST https://analyticsdemo.mojonetworks.com/api/v1.14/portals/50/splashpages/3?type=”custom”
Request Body The API takes the new spash page bundle zip file in the request body. For example,
“file”:”splashpage_bundle.zip” (enctype = “multipart/form/data”)
Response Body If the API call is successful, the HTTP response status is 200.
The response body returns the details of the splash page updated in the portal.

Delete Splash Page

Description The API deletes a splash pages bundle defined in the portal in Guest Manager.
Guest Manager users with the Administrator role can access this API.
Syntax
DELETE <Base_URL>/portals/{portal_id}/splashpages/{id}

Here,

  • portal_id

    It is the unique system-generated ID of the portal from which the splash page details have to be fetched. It takes an integer value.

  • id

    It is the unique system-generated ID of the splash page bundle. It takes an integer value.

Sample code
DELETE https://analyticsdemo.mojonetworks.com/api/v1.14/portals/50/splashpages/3
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 returns the details of the remaining splash pages.