Business units

Business units can be queried using this API. slashQ API platform is expecting an api_key in the API request, which you can get from the slashQ.io business settings page. On a successful API query, you will get business units belonging to a particular location.


Endpoint

{warning} All requests are passed to the slashq.io host URL. You can append corresponding API endpoints to the host URL depending on your requirement.

Method URI Description
GET /api/business-units Get business units

URL Params

api_key=API_KEY&location_id=2543

Data Params

NULL

{info} The API_KEY is the token that the server needs in order to auth the request.


{success} Success Response

Code 200

Content

{
    "status": "success",
    "message": "Business units fetched successfully",
    "data": [
        {
            "id": 1,
            "name": "ABC Unit",
            "address": "8026 N. Heather St.Baltimore, MD 21206",
            "image": "http://path.to.image"
        }
    ]
}

{warning} Unauthorized request

Code 401

Content

{
  "status": "failure",
  "message": "Unauthorized request"
}

{danger} Not found

Code 404

Content

{
  "status": "failure",
  "message": "Not found"
}