TrackRecordPro API Documentation TrackRecordPro

locations endpoint

Summary

API Endpoint Address

https://api.trackrecordpro.co.uk/3.0/locations

Minimum Supported API Version3.0
Supported Methods

GET
POST
PUT
DELETE

Access LevelEveryone
DescriptionThis endpoint allows management of locations, to which assets can optionally be assigned.

GET locations

GET /3.0/locations HTTP/1.1

Details

Returns a list of locations associated with the current company

{
    "request": {
        "url": "\/3.0\/locations",
        "endpoint": "locations",
        "requested_version": "3.0",
        "api_version": 3,
        "request_method": "Get",
        "timestamp": 1507557789,
        "session": null
    },
    "pagination": {
        "total_pages": 24,
        "total_records": 692
    },
    "response": [
        {
            "id": 1,
            "company_id": 1,
            "description": "Location 1",
            "creationdate": "2017-10-04 00:00:00",
            "data": null,
            "company": {
                "id": 1,
                "name": "TrackRecordPro",
                "created": "2017-10-09 08:42:37",
                "logo": "trp.png",
                "subdomain": "trackrecordpro",
                "styles": {
                    "test": {
                        "foo": "bar",
                        "baz": 1
                    },
                    "test2": 666.7
                },
                "data": null
            }
        }
    ]
}

POST locations

POST /3.0/locations HTTP/1.1

Details

Update an entry in the locations table. You must include the fields and values to update as a JSON object in the POST data.

{
    "request": {
        "url": "\/3.0\/locations\/id=42",
        "endpoint": "locations",
        "requested_version": "3.0",
        "api_version": 3,
        "request_method": "Post",
        "timestamp": 1507622071,
        "session": null
    },
    "response": {
        "records_updated": 1,
        "records_found": 1
    }
}

 

 

PUT locations

PUT /3.0/locations HTTP/1.1

Details

Describe the PUT method

Example here

DELETE locations

DELETE /3.0/locations HTTP/1.1

Details

Describe the DELETE method

Example here

Field Definitions

Expand

Invalid license

Your evaluation license of PocketQuery expired. Please contact an administrator to purchase a new license.