api.hirepos.com/Availability

Edited

Welcome to the Availability Endpoint Documentation. This document provides detailed information on how developers can utilize the Availability endpoint to retrieve the Quantity Available for items within a specified date range.

Overview

The Availability endpoint is a crucial feature that enables developers to access real-time information on the Quantity Available for specific items. By submitting a date range along with an array of items, developers can retrieve accurate data on the availability of each item within the specified timeframe.

Usage

To utilize the Availability endpoint effectively, developers need to submit a request containing the following parameters:

  • Date Range: Specify the start and end dates for the desired timeframe.

  • Items Array: Provide an array of items for which the Quantity Available needs to be retrieved.

Response

Upon submitting a request to the Availability endpoint, developers will receive a response containing the Quantity Available for each item within the specified date range. The response will be structured in a format that is easy to parse and integrate into the developer's application.

Example

Below is an example of how a request to the Availability endpoint may look:

GET https://api.hirepos.com/Availability

Headers:
AuthKey={YourAPIKey}
AuthSecret={YourAPISecret}

// Example Request...

{
   "DateFrom":"8/07/2021 9:00 am",
   "DateTo":"10/07/2021 4:00 pm",
   "Items":[
      {         
         "WebsiteCode":"H1"
      }, 
      {         
         "WebsiteCode":"H2"
      }
   ]
}

// Example Response...

{
  "ErrorRaised": "False",
  "ErrorType": null,
  "ErrorMessage": null,
  "Items": [
    {
      "ItemID": "6877",
      "IsHireItem": null,
      "PackageID": "",
      "Code": "H1",
      "GroupCode": null,
      "WebsiteCode": "H",
      "QtyRequired": null,
      "QtyAvailable": "1",
      "ErrorRaised": "False",
      "ErrorType": null,
      "ErrorMessage": null
    },
    {
      "ItemID": "6878",
      "IsHireItem": null,
      "PackageID": "",
      "Code": "H2",
      "GroupCode": null,
      "WebsiteCode": "H",
      "QtyRequired": null,
      "QtyAvailable": "0",
      "ErrorRaised": "False",
      "ErrorType": null,
      "ErrorMessage": null
    }
  ]
}

Conclusion

The Availability endpoint is a powerful tool that empowers developers to access real-time information on the Quantity Available for items within a specified date range. By leveraging this endpoint effectively, developers can enhance the functionality of their applications and provide users with up-to-date availability information.