Skip to main content

SlingshotIndex

One of the three major response types.

The SlingshotIndex response is used to return any list of items. The header of the XML is included below:

<!--?xml version="1.0" encoding="utf-8"?-->
<slingshotindex xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.ravenslingshot.com/SlingshotIndex/2010">
<totalcount>4</totalcount>
<pagesize>20</pagesize>
<ispreviouspage>false</ispreviouspage>
<isnextpage>false</isnextpage>
<pageindex>0</pageindex>
<totalpages>1</totalpages>
</slingshotindex>

Data Description

Data in the header contains the following details:

  • TotalCount - The total number of records in the list being returned.
  • PageSize - The number of records returned in this request. This is controlled by the optional query string parameter pageSize.
  • IsPreviousPage - A Boolean value indicating if there are any pages prior to the current page in this list.
  • IsNextPage - A Boolean value indicating if there are any pages after the current page in this list.
  • PageIndex - The index of the current page. The page index is zero based and has a max value of TotalPages -1. This is controlled by the optional query string parameter page.
  • TotalPages - The total number of pages in this list given the TotalCount and PageSize.

Body

The rest of the SlingshotIndex response consists of summary items of the type being asked for (Field Computers, Prescription Maps, or Job Data). These entries are represented by the following XML fragment:

<!--?xml version="1.0" encoding="utf-8"?-->
<nameofitem>
<id>1449</id>
<name>Job from Field</name>
<uri>https://api.ravenslingshot.com/{nameofitem}/1449</uri>
<subtype>Subordinate type of object</subtype>
</nameofitem>

Data Description

Data in the body contains the following details:

  • NameOfItem - the value of this tag will be one of: FieldComputer, PrescriptionMap, JobData, or FieldHub.
  • ID - The internal ID of the item.
  • Name - The name of the item given to it by a Slingshot user.
  • URI - the URI that can be used to retrieve more details about the item.
  • SubType - only applicable to PrescriptionMap and JobData. Contains additional information about the item. For JobData items, this will contain either 'Planter', 'Sprayer', 'Yield' or Planter/Sprayer. For PrescriptionMap items, this will contain 'Prescription Map'.