Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The following section describes the API methods of the WIFI platform referring to the WifiAreas Locations module, which let you to, for example, obtain all the information related to the WifiAreas Locations or WLANs.

Table of Contents

...

Locations

GET - Get

...

Location

Returns all the WifiAreas Locations to which the user has access. If the ID of a particular WifiArea Location is indicated in the request, this returns all the information related to that WifiAreaLocation.

Code Block
https://<server-domainname>/rest/<version>/wifiareaLocation/{wifiareaIdLocationId}

j

Parameters

TYPE

Parameter

Significance

Type

Required

Default

HEAD

Authorization

Bearer <API_KEY>

String

YES


GET

wifiareaIdLocationId

WifiArea Location identifier

String

NO

NULL


Response

HTTP Code

Result

Response data

200

Ok


Code Block
{
	"data": [{
    "deviceType": "mikrotik",
    "printFormat": "thermal",
    "cacPhone": null,
    "authServer": 1,
    "paypalAccountId": 1,
    "pmsInterfaceId": null,
    "pmsCharges": 0,
    "facebookConfigId": 1,
    "twitterConfigId": 0,
    "linkedinConfigId": 0,
    "instagramConfigId": 0,
    "smsConfigId": null,
    "ticketHeadline": null,
    "realmId": 66,
    "realm": "XXX",
    "coding": "base32pass",
    "id": "02XXX200",
    "name": "WIFI",
    "properties": {
      "usesPasscode": 0,
      "printTickets": 1
    },
    "grantedModules": null,
    "address": "Calle Valentin Beato 22, 28037 Madrid",
    "latLng": "40.4492616,-3.7114444",
    "timezone": "Europe\/Madrid",
    "woeid": null,
    "currency": "eur",
    "isEnabled": 1,
    "avatar": 480,
    "supportCode": null,
    "owner": "XXX",
    "groups": null
  }]
}


401

Unauthorized

Explanation of the error


WLANs

GET - Get WLANs of

...

Location

Returns all the WLANs of the WifiArea Location specified by the wifiareaId LocationId parameter.

Code Block
https://<server-domainname>/rest/<version>/wifiareaLocation/wlan/{wifiareaIdLocationId}


Parameters

TYPE

Parameter

Significance

Type

Required

Default

HEAD

Authorization

Bearer <API_KEY>

String

YES


QUERY

wifiareaIdLocationId

WifiArea Location identifier

String

YES


QUERY

offset


integer

NO


QUERY

limit


integer

NO


QUERY

rows


integer

NO


QUERY

page


integer

NO


QUERY

current_page


integer

NO


...

HTTP Code

Result

Response data

200

Ok


Code Block
[{
	"id": 115,
	"wifiareaIdLocationId": "28XXX01",
	"wifiareaNameLocationName": "PRUEBAS API",
	"name": "WL0008",
	"ssid": "WLAN_GUEST",
	"desc": "GUEST",
	"status": 1,
	"splashPortalId": 98,
	"avatar": 712,
	"disclaimerId": 2,
	"redirection": "http:\/\/example.com",
	"redirections": {
		"sponsor": null
	},
	"loginMethods": ["sponsor"]
}, {
	"id": 148,
	"wifiareaIdLocationId": "28XXX01",
	"wifiareaNameLocationName": "PRUEBAS API",
	"name": "WL0009",
	"ssid": "WLAN_STAFF",
	"desc": "STAFF",
	"status": 1,
	"splashPortalId": 67,
	"avatar": 712,
	"disclaimerId": 2,
	"redirection": null,
	"redirections": {
		"general": null
	},
	"loginMethods": ["general"]
}]


401

Unauthorized

Explanation of the error

...



Locations Groups

GET - Get

...

Location Groups

Returns all the WifiArea Location groups to which the user has access. If the ID of a specific group is indicated in the request, this returns all the WifiAreas Locations that belong to that group.

Code Block
https:/<server-domainname>/rest/<version>/wifiareaLocation/groups/{wifiareaGroupIdLocationGroupId}


Parameters

TYPE

Parameter

Significance

Type

Required

Default

HEAD

Authorization

Bearer <API_KEY>

String

YES


GET

wifiareaGroupIdLocationGroupId

WiFiArea Location identifier

String

NO

NULL


Response

...

If the ID of a particular WifiArea Location group is sent as parameter, all the WifiAreas Locations included in that group will be obtained.

...

HTTP Code

Result

Response data

200

Ok


Code Block
[
    {
        "deviceType": "aerohive",
        "printFormat": "thermal",
        "cacPhone": null,
        "authServer": 1,
        "paypalAccountId": 2,
        "pmsInterfaceId": "1",
        "pmsCharges": 0,
        "facebookConfigId": 2,
        "twitterConfigId": 0,
        "linkedinConfigId": 0,
        "instagramConfigId": 0,
        "smsConfigId": 1,
        "mailConfigId": 4,
        "ticketHeadline": null,
        "realmId": 21,
        "realm": "28XXX004",
        "coding": "passcode",
        "id": "28XXX004",
        "name": "Pruebas API",
        "properties": {
            "emailCredentials": 0,
            "printTickets": 1,
            "usesPasscode": 1,
            "sponsorNotificationChannel": "sms"
        },
        "grantedModules": null,
        "address": "Madrid",
        "latLng": "44.76221,-3.532",
        "timezone": "Europe/Madrid",
        "woeid": null,
        "currency": "eur",
        "isEnabled": 1,
        "avatar": 846,
        "supportCode": null,
        "owner": "XXX",
        "groups": [
              "XXX"
        ],
        "tenant": {
            "id": "1",
            "sitePrefix": "XXX"
        },
        "services": [
            {
                "id": 59219,
                "wifiareaIdLocationId": "28XXX004",
                "typeId": "ttf",
                "name": "Ticket - 1h",
                "price": 0,
                "status": 1,
                "onlineTime": 0,
                "expTime": 3600,
                "tpv": 0,
                "pms": 0,
                "showLogin": 1,
                "simDevices": 10,
                "maxUsers": 1,
                "loginMethod": "general",
                "download": 0,
                "upload": 0,
                "downrate": 0,
                "uprate": 0,
                "dailyLimit": 0,
                "validUntil": 15552000,
                "vip": 0,
                "validateEmail": 0,
                "deleted": 0,
                "withRegistration": 0,
                "macCaching": 0,
                "issueOrder": 0,
                "type": {
                    "id": "ttf",
                    "description": "Tiempo corrido",
                    "timetofinish": true,
                    "onlinetime": false,
                    "timetolimit": false,
                    "limittraffic": false
                }
            }
        ],
        "wlans": [
            {
                "id": 428,
                "wifiareaIdLocationId": "28XXX004",
                "wifiareaNameLocationName": "WIFIAREALocation NAME",
                "name": "WL0008",
                "ssid": "WIFI GUEST",
                "desc": "WIFI GUEST",
                "status": 1,
                "splashPortalId": 244,
                "avatar": 846,
                "disclaimerId": 1,
                "redirection": null,
                "redirections": {
                    "general": null
                },
                "loginMethods": [
                    "general"
                ]
            },
        }
        ],
        "devices": [
            {
                "id": 675,
                "deviceType": "aerohive",
                "mac": "4b-3e-01-50-6d-f6",
                "name": "Aerohive AP",
                "wifiareaIdLocationId": "28XXX004",
                "status": 1,
                "deleted": 0,
                "macAsCalled": 0,
                "nases": [
                    {
                        "id": 41659,
                        "called": "4b-3e-01-50-6d-f6:WIFI GUEST",
                        "status": 1,
                        "wlanId": 428,
                        "deviceId": 675
                    },
				]
		}]
    }
]


401

Unauthorized

Explanation of the error

...

Code Block
https://<server-domainname>/rest/<version>/wifiareaLocation/wlangroups/{wlangroupId}

...

HTTP Code

Result

Response data

200

Ok


Code Block
[
    {
        "id": 181,
        "wifiareaIdLocationId": "28XXX001",
        "wifiareaNameLocationName": "WIFIAREALocation NAME",
        "name": "WL001",
        "ssid": "WIFI GUEST",
        "desc": "WIFI GUEST",
        "status": 1,
        "splashPortalId": 62,
        "avatar": 340,
        "disclaimerId": null,
        "redirection": "https://www.example.com"
    },
    {
        "id": 182,
        "wifiareaIdLocationId": "28XXX0021",
        "wifiareaNameLocationName": "WIFIAREALocation NAME",
        "name": "WL002",
        "ssid": "WIFI STAFF",
        "desc": "WIFI STAFF",
        "status": 1,
        "splashPortalId": 62,
        "avatar": 340,
        "disclaimerId": null,
        "redirection": "https://www.example2.com"
    }
]


401

Unauthorized

Explanation of the error

...