guestbookuserbatch

Guestbook User Batch

Guestbook is a private list of guest users to whom we provide access to wifi setup. Clubbed together they form a batch of users. When a user wants to access the Internet through our WiFi setup, they can either login with their social media account or request for a guest user account. This guest user account information is stored in the guest book of the portal. You can obtain user-specific information and add it to the user profile when creating a user account. To manage the guest book, you must have either the Administrator role or the Operator role.

JSON Table

Parameter Data Type Description
success boolean Whether the API call was successful or not.
message String A message indicating the API success or failure.
data application/json A JSON object for the response data.
data/totalCount int The total number of batches fetched.
data/batch application/json A JSON for the guest user accounts batch.
data/batch/bid int The system-generated unique ID for the guest user accounts batch.
data/batch/pid int The system-generated unique ID for the portal.
data/batch/pbid int The system-generated ID for the batch unique to the portal.
data/batch/batch_type int The type of batch.
1 indicates random (system-generated) user names.
2 indicates incremental user names.
data/batch/username_prefix String A string value that is prefixed with each system-generated guest user account name created by the batch.
data/batch/username_length int This is a mandatory property if the batch_type is set to 1. This specifies the number of characters in the system-generated guest user account names.
data/batch/start_index int This is a mandatory property if the batch_type is set to 2. This specifies the index (incrementing) to be appended to the username_prefix in the guest user account names.
data/batch/password_length int The number of characters in the system-generated password for the guest user accounts.
data/batch/no_of_users int The total number of guest user accounts created by the batch
data/batch/batch_desc String A short description specifying the purpose of creating this batch of guest user accounts.
data/batch/date_created Date The date on which the guest user accounts batch is created.
data/batch/expiration_date Date The date till which the guest user accounts in the batch will be valid.
data/batch/session_timeout int The time period, in minutes, after which the guest user session expires. The user must re-authenticate with his login credentials if he wants to continue using the WiFi service. A value of zero indicates that the user session does not timeout and the user must explicitly log out from the portal. A non-zero timeout configured on the user account takes precedence over the timeout configured on the plug-in, portal, and the SSID profile in Wireless Manager.
data/batch/blackout_time int The time period in minutes for which a user cannot log in to the portal after his last successful login has timed out. A value of zero indicates no blackout time. The blackout time, including zero value, configured on the user account takes precedence over the blackout time configured on the plug-in, portal, and the SSID profile in Wireless Manager.
data/batch/date_modified Date The date and time when the guest user accounts batch was created.
data/batch/created_by String The user name of the Guest Manager user who created the batch.
data/batch/bandwidth_upload_limit int Maximum upload bandwidth, in Kbps, for the guest user accounts.
data/batch/bandwidth_download_limit int Maximum download bandwidth, in Kbps, for the guest user accounts.

Copy Sample JSON
Sample JSON
[{
 "success": true,
 "message": "Record Found",
 "data": {
 "totalCount": 1,
 "batch": {
 "bid": 1,
 "pid": 1,
 "pbid": 1,
 "batch_type": "1",
 "username_prefix": "test",
 "username_length": 1,
 "start_index": null,
 "password_length": 8,
 "no_of_users": 5,
 "batch_desc": null,
 "date_created": "2017-09-11 05:41:54.688163",
 "expiration_date": "2017-09-11 13:41:19",
 "session_timeout": null,
 "blackout_time": null,
 "date_modified": null,
 "created_by": "customer_009@customer.com",
 "bandwidth_upload_limit": null,
 "bandwidth_download_limit": null,
 "device_limit": null,
 "login_count_limit": null
 }
 }
}]
API Calls

/V1.14/portals/{pid}/guestbook/batches/{bid}

/V1.14/portals/{pid}/guestbook/batches

/V1.14/portals/{pid}/guestbook/batches/{bid}/users

/V1.14/portals/{pid}/guestbook/batches/exportcsv

/V1.14/portals/{pid}/guestbook/batches/{bid}

/V1.14/portals/{pid}/guestbook/batches

/V1.14/portals/{pid}/guestbook/batches/{bid}

/V1.14/portals/{pid}/guestbook/batches/delete/bulk

Get Guestbook User Batch

Description This API is used to fetch the details of a guest user accounts batch from a specified portal.
Guest Manager users with the Administrator role or the Guestbook
Operator role can access this API.
Users with the Guestbook Operator role must have access to the portal in which the batch of
guest user accounts for the Guestbook plug-in exists.
Syntax
GET <Base_URL>/portals/{pid}/guestbook/batches/{bid}

Here,

  • pid

    It is the unique ID of the portal in which the guest user accounts batch for the Guestbook plug-in exists.

  • bid

    It is the unique ID of the guest user accounts batch for the Guestbook plug-in.

Sample code
GET https://marketverticalanalytics.airtightnw.com/api/v1.14/portals/1/guestbook/
batches/1
Request Body This API call does not require any request body parameters.
Response Body The API returns the details of the guest user accounts batch in the response body.
The response is in the application/json format.

Get Guestbook User Batches

Description This API is used to fetch the details of a guest user accounts batches from a specified portal.
Guest Manager users with the Administrator role or the Guestbook Operator role can access this API.
Users with the Guestbook Operator role must have access to the portal in which the
batches of guest user accounts for the Guestbook plug-in exist.
Syntax
GET <Base_URL>/portals/{pid}/guestbook/batches

Here,

  • pid

    It is the unique ID of the portal in which the guest user accounts batch for the Guestbook plug-in exists.

Sample code
GET https://marketverticalanalytics.airtightnw.com/api/v1.14/portals/1/guestbook/batches
Request Body This API call does not require any request body parameters.
Response Body The API returns the details of the guest user accounts batch in the response body.
The response is in the application/json format.

Get Guestbook Users In A Batch

Description This API is used to fetch the IDs of the guest user accounts in a batch from a specified portal.
Guest Manager users with the Administrator role or the Guestbook Operator role can access this API.
Users with the Guestbook Operator role must have access to the portal in which the
batches of guest user accounts for the Guestbook plug-in exist.
Syntax
GET <Base_URL>/portals/{pid}/guestbook/batches/{bid}/users

Here,

  • pid

    It is the unique ID of the portal in which the guest user accounts batch for the Guestbook plug-in exists.

  • bid

    It is the unique ID of the guest user accounts batch for the Guestbook plug-in.

Sample code
GET https://marketverticalanalytics.airtightnw.com/api/v1.14/portals/1/guestbook/
batches/1/users
Request Body This API call does not require any request body parameters.
Response Body The API returns the details of the guest user accounts batch in the response body.
The response is in the application/json format.

Export Guestbook User Batch

Description This API exports the guest user accounts batches that match the specified
filter criteria to a CSV file and download the CSV file.
Guest Manager users with the Administrator role or the Guestbook Operator role can access this API.
Users with the Guestbook Operator role must have access to the portal in which the
batches of guest user accounts for the Guestbook plug-in exist.
Syntax
GET <Base_URL>/portals/{pid}/guestbook/batches/exportcsv

Here,

  • pid

    It is the unique ID of the portal from which the batches of guest user accounts in the Guestbook plug-in are exported.

Sample code
GET https://marketverticalanalytics.airtightnw.com/api/v1.14/portals/
1/guestbook/users/exportcsv?”&filter={“property”:”created_by”,”value”:”admin”,”operator”:”=”}
Request Body This API call does not require any request body parameters.
Response Body If successful, the API exports the batches of guest user accounts that meet the filter criteria to a
CSV file and starts downloading the file.

Add A Guestbook User Batch

Description This API is used to create a batch of guest user accounts.
Guest Manager users with the Administrator role or the Guestbook Operator role can access this API.
Users with the Guestbook Operator role must have access to the portal in
which the batch of guest user accounts for the Guestbook plug-in is being created.
Syntax
POST <Base_URL>/portals/{pid}/guestbook/batches

Here,

  • pid

    It is the unique ID of the portal in which the batch of guest user accounts for the Guestbook plug-in is being created.

Sample code
POST https://marketverticalanalytics.airtightnw.com/api/v1.14/portals/1/guestbook/batches
Request Body This API call does not require any request body parameters.
Response Body The API returns the details of the newly created guest user accounts batch in the response body.
The response is in the application/json format.

Edit A Guestbook User Batch

Description This API is used to edit a guest user accounts batch.
Guest Manager users with the Administrator role or the Guestbook Operator role can access this API.
Users with the Guestbook Operator role must have access to the portal in which the batch of
guest user accounts for the Guestbook plug-in exists.
Syntax
PUT <Base_URL>/portals/{pid}/guestbook/batches/{bid}

Here,

  • pid

    It is the unique ID of the portal in which the guest user account in the Guestbook plug-in is created.

  • bid

    It is the unique ID of the guest user accounts batch for the Guestbook plug-in that is being updated.

Sample code
PUT https://marketverticalanalytics.airtightnw.com/api/v1.14/portals/50/guestbook/
batches/1
Request Body The API takes the batch details to be updated as parameters in the request body.
The parameters are passed in the application/json format.
Response Body The API returns the details of the updated guest user accounts batch in the response body.
The response is in the application/json format.

Post APIs

Description This API is used to fetch the APs that match the specified filter criteria from the allowed locations for the logged-in user. If no filters are specified, all the APs from the allowed locations are fetched. However, this API is not supported in a server cluster environment.

Note: Do not use this API to fetch more than 100 devices. For fetching larger number of devices, consider using the Get Paged List of APs API.

User Privileges Users with the following roles can call this API: superuser, administrator, and operator.

Request Body Parameters
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 the APs that match the filter criteria. The response is in the application/json format. Click AP to view the complete detais of the JSON along with a sample output.

Error codes
If the API call is successful, the HTTP response status is 200.

Syntax
GET /devices/aps
Sample code
GET https://training.mojonetworks.com/new/webservice/v2/devices/aps
GET
https://training.mojonetworks.com/new/webservice/v2/devices/aps?macaddress=00:11:74:33:23:12&macaddress=00:11:74:45:12:21
GET
https://training.mojonetworks.com/new/webservice/v2/devices/aps?capability=49&locationid=10&locationid=12&sortcolumn=devicename&sortascending=false
URL Parameters This API call takes optional URL parameters to filter the list of APs to be fetched and the column on which the output must be sorted. AP Filter Parameters lists the parmeter names, datatypes, applicable values, and whether the results can be sorted based on the parameter.
Query Parameters This API call takes optional URL parameters to filter the list of APs to be fetched and the column on which the output must be sorted. AP Filter Parameters lists the parmeter names, datatypes, applicable values, and whether the results can be sorted based on the parameter.
Response Body If the API call is successful, the HTTP response status is 200. The response body contains the details of the APs that match the filter criteria. The response is in the application/json format. Click AP to view the complete detais of the JSON along with a sample output.

Delete Guestbook User Batch

Description This API is used to delete a batch of guest user accounts from a specified portal.
Guest Manager users with the Administrator role or the Guestbook Operator role can access this API.
Users with the Guestbook Operator role must have access to the portal in which the batch of guest
user accounts for the Guestbook plug-in exists.
Syntax
DELETE <Base_URL>/portals/{pid}/guestbook/batches/{bid}

Here,

  • pid

    It is the unique ID of the portal in which the guest user account in the Guestbook plug-in is created.

  • bid

    It is the unique ID of the guest user accounts batch for the Guestbook plug-in.

Sample code
DELETE https://marketverticalanalytics.airtightnw.com/api/v1.14/portals/50/
guestbook/batches/1
Request Body This API call does not require any request body parameters.
Response Body The API returns the guest user account and profile details in the response body.
The response is in the application/json format.

Delete Guestbook User Batches

Description This API deletes batches of guest user accounts from the Guestbook plug-in of the specified portal.
Guest Manager users with the Administrator role or the Guestbook Operator role can access this API.
Users with the Guestbook Operator role must have access to the portal from which the batches of
guest user accounts for the Guestbook plug-in are deleted.
Syntax
DELETE <Base_URL>/portals/{pid}/guestbook/batches/delete/bulk

Here,

  • pid

    It is the unique ID of the portal from which the batches of guest user accounts for the Guestbook
    plug-in are to be deleted.

Sample code
DELETE https://marketverticalanalytics.airtightnw.com/api/v1.14/portals/1/guestbook/
batches/delete/bulk
Request Body The API takes the IDs of batches as parameter in the request body.
The parameters are passed in the application/json format.
The following table describes the parameters and the applicable values.

Parameter Data Type Description Manadatory Default/Sample Value
bids application/json An array of ID of the batches of guest user accounts that have to be deleted. Yes [ 1, 2 ]
Response Body The API returns the details of the deleted batches of guest user accounts in the response body.
The response is in the application/json format.