/
Get Map Object Data

Get Map Object Data

Overview

Request for the Map Object Data based on the Map Profile ID.

Details

Type

POST

Endpoint

{{url}}/api/Maps/Editor/GetObjects

Request

The request data has 2 values.

mapid required

The mapid is needed to return the data for the correct map profile.

childresources optional

The childresources option can be used to request an updated list of all available resources for the current locations children (see AvailableResource for more info).

This is only relevant to resources that are NOT already saved for this Map Profile.

Example

{ "mapid": 36, "childresources": false }

Response

Example

{ "d": { "Resources": [ // see below for more info on "Resources" { "uid": null, "Id": 1, "ResID": 1, "SpaceType": "Desk", "IconPath": null, "ResName": "Desk E0.01", "LocationID": 5, "AlternativeMaps": [#, #, #], "x": 520.05514, "y": 682.01028, "hide": false, "tooltip": true } ], "Hotspots": [ // see below for more info on "Hotspots" { "uid": 4107, "type": "URL", "url": "https://www.resourcexpress.com/", "newtab": true, "x": 99999.00000, "y": 99999.00000, "tooltip": true, "text": "RX", "color": "#ff00bb", "icon": "/ResourceFiles//icon=Link.svg", "hide": false } ], "LastUpdated": "02/10/2023 09:00" } }

Resources [Array]

The Resources array will include all Resource objects that are available for the current Map Profile.
This will include basic resource information along with the X & Y coordinates, hide and tooltip settings.

Below is an example of a “Resource” object.

{ "uid": 1234, "Id": 1, "ResID": 1, "SpaceType": "Desk", "IconPath": null, "ResName": "Desk E0.01", "LocationID": 5, "AlternativeMaps": [#, #, #], "PosX": 520.05514, "PosY": 682.01028, "Hide": 0, "Tooltip": true }

This is very similar to the standard MapResource object used in the GetMapResources and GetMapHotspots API requests.

However, this response does not require any live/active resource data.

These fields need to be added

  • uid - If the marker already exists on the current Map Profile, this is the unique ID value for this object.
    This will be used to update or remove the marker from the map.

  • LocationID - This is the location that the resource is assigned, used for resource that are assigned to a child location of the current map, such as a zone.

  • AlternativeMaps - This is an array of ID's for other Map Profiles that this resource has previously been assigned.

Hotspots [Array]

This array will include all the other markers that are currently saved for the map profile.
These markers include:

  • Maplinks

  • URLs

  • Non-Interactive

The Hotspots array will be the same as the Hotspots array found in the GetMapHotspots API.

LastUpdated [DateTime]

The date and time that this map profile was last updated.

Related content

Set Map Object Data
Set Map Object Data
More like this
Get Map Data
Get Map Data
More like this
Search for Resource
Search for Resource
More like this
Get Resource Space Types
Get Resource Space Types
More like this
Get User Settings
Get User Settings
More like this
Get Assigned Space
Get Assigned Space
More like this