Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Current »

4. Create a Floor

 

A floor is an object associated with a building containing a building ID, floor ID, zoom level and resource URL(s) (e.g. .svg, .pdf).

Level One

The example request below creates a floor called Level One. The example response returns the newly created floor's ID. 

Level One will live inside of the Hyrule Castle Tower building, its parent container. 

Example Request

POST /v1.1/floors HTTP/1.1 
Host: map-api.phunware.com
X-Auth: see MaaS Security Protocol v1.0
Content-Type: application/json
{    
	"venueGuid": "f0685279-7497-4d90-882e-12201e476b0e",
    "buildingId": 6891,
    "name": "Level One",
    "originalMapUrl": "http://image.com/level1.pdf",
    "level": 1,
    "isOutdoor": false,
    "width": 100,
    "height": 200,
    "offsetX": 0,
    "offsetY": 0,
    "locationMapHierarchy": "Hyrule Castle>Hyrule Castle Tower>Level One",
    "maxZoomLevel": 3,
    "referencePoints": 
    {
        "rotation": 214,
        "portal": 
        {
            "topRight": 
            {
                "latitude": 33.77403309960294,
                "longitude": -84.32867120304763
            },
            "bottomLeft": 
            {
                "latitude": 33.7740738782866,
                "longitude": -84.32673443277963
            }
        },
        "topLeft": 
        {
            "latitude": 33.773309,
            "longitude": -84.327331
        },
        "topRight": 
        {
            "latitude": 33.774033,
            "longitude": -84.328671
        },
        "bottomLeft": 
        {
            "latitude": 33.774073,
            "longitude": -84.326734
        },
        "bottomRight": 
        {
            "latitude": 33.774797,
            "longitude": -84.328074
        }
    }
} 

Example Response

HTTP/1.1 200 OK 
Vary: Accept-Encoding
Content-Type: application/json; charset=utf-8
Date: Tue, 20 May 2015 16:06:54 GMT
Connection: keep-alive
{    
	"data": 
    {
        "id": 17
    }
} 

ON THIS PAGE

  • No labels