Management Zones - List By Farmer Id
Returns a paginated list of management zone resources under a particular farmer.
GET /farmers/{farmerId}/management-zones?api-version=2021-07-31-preview
GET /farmers/{farmerId}/management-zones?types={types}&cropIds={cropIds}&seasonIds={seasonIds}&fieldIds={fieldIds}&sources={sources}&ids={ids}&names={names}&propertyFilters={propertyFilters}&statuses={statuses}&minCreatedDateTime={minCreatedDateTime}&maxCreatedDateTime={maxCreatedDateTime}&minLastModifiedDateTime={minLastModifiedDateTime}&maxLastModifiedDateTime={maxLastModifiedDateTime}&$maxPageSize={$maxPageSize}&$skipToken={$skipToken}&api-version=2021-07-31-preview
URI Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
|
farmer
|
path | True |
string |
Id of the associated farmer. |
|
api-version
|
query | True |
string |
The requested API version |
|
$max
|
query |
integer (int32) minimum: 10maximum: 1000 |
Maximum number of items needed (inclusive). Minimum = 10, Maximum = 1000, Default value = 50. |
|
|
$skip
|
query |
string |
Skip token for getting next set of results. |
|
|
crop
|
query |
string[] |
CropIds of the ManagementZone. |
|
|
field
|
query |
string[] |
FieldIds of the ManagementZone. |
|
|
ids
|
query |
string[] |
Ids of the resource. |
|
|
max
|
query |
string (date-time) |
Maximum creation date of resource (inclusive). |
|
|
max
|
query |
string (date-time) |
Maximum last modified date of resource (inclusive). |
|
|
min
|
query |
string (date-time) |
Minimum creation date of resource (inclusive). |
|
|
min
|
query |
string (date-time) |
Minimum last modified date of resource (inclusive). |
|
|
names
|
query |
string[] |
Names of the resource. |
|
|
property
|
query |
string[] |
Filters on key-value pairs within the Properties object. eg. "{testKey} eq {testValue}". |
|
|
season
|
query |
string[] |
SeasonIds of the ManagementZone. |
|
|
sources
|
query |
string[] |
Sources of the ManagementZone. |
|
|
statuses
|
query |
string[] |
Statuses of the resource. |
|
|
types
|
query |
string[] |
Types of the ManagementZone. |
Request Header
| Name | Required | Type | Description |
|---|---|---|---|
| Authorization | True |
string |
Please provide a valid bearer token for authorized API calls. Note that you might need to clear your browser cache if you tried un-authenticated calls before. |
Responses
| Name | Type | Description |
|---|---|---|
| 200 OK |
Success |
|
| Other Status Codes |
Error Headers x-ms-error-code: string |
Security
Authorization
Please provide a valid bearer token for authorized API calls. Note that you might need to clear your browser cache if you tried un-authenticated calls before.
Type:
apiKey
In:
header
Examples
ManagementZones_ListByFarmerId
Sample request
GET /farmers/FARMER123/management-zones?api-version=2021-07-31-preview
Sample response
{
"value": [
{
"farmerId": "FARMER123",
"id": "ManagementZone123",
"type": "Nutrient rich",
"seasonId": "Season123",
"cropId": "Crop123",
"fieldId": "Field123",
"source": "Agronomist",
"name": "John Smith's ManagementZone",
"status": "Active",
"description": "Some description",
"properties": {
"Irrigated": "Yes"
},
"createdDateTime": "2021-04-21T06:49:30Z",
"modifiedDateTime": "2021-04-21T06:49:30Z",
"eTag": "0f8fad5b-d9cb-469f-a165-70867728950e"
}
],
"$skipToken": "string",
"nextLink": "https://{{resourceName}}.farmbeats.azure.net/farmers/{{farmerId}}/management-zones?api-version={{apiVersion}}&$skipToken=%5b%7b%22token%22%3a%22%2bRID%3a%7e23TRC%3a10%23ISA%3d%22%2c%22range%22%3a%7b%22min%22%3a%22%22%2c%22max%22%3a%22FF%22%7d%7d%5d"
}
Definitions
| Name | Description |
|---|---|
| Error |
An error from the Azure AgPlatform service. |
|
Error |
An error response from the Azure AgPlatform service. <see href="https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses">ErrorResponse reference document.</see>. |
|
Inner |
Inner error containing list of errors. <see href="https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object">InnerError reference document</see>. |
|
Management |
Api Model for ManagementZone object. |
|
Management |
Paged response contains list of requested objects and a URL link to get the next set of results. |
Error
An error from the Azure AgPlatform service.
| Name | Type | Description |
|---|---|---|
| code |
string |
Server-defined set of error codes. |
| details |
Error[] |
Array of details about specific errors that led to this reported error. |
| innererror |
Inner error containing list of errors. <see href="https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object">InnerError reference document</see>. |
|
| message |
string |
Human-readable representation of the error. |
| target |
string |
Target of the error. |
ErrorResponse
An error response from the Azure AgPlatform service. <see href="https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses">ErrorResponse reference document.</see>.
| Name | Type | Description |
|---|---|---|
| error |
An error from the Azure AgPlatform service. |
|
| traceId |
string |
Unique trace Id. |
InnerError
Inner error containing list of errors. <see href="https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object">InnerError reference document</see>.
| Name | Type | Description |
|---|---|---|
| code |
string |
Specific error code than was provided by the containing error. |
| innererror |
Inner error containing list of errors. <see href="https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object">InnerError reference document</see>. |
ManagementZone
Api Model for ManagementZone object.
| Name | Type | Description |
|---|---|---|
| createdDateTime |
string (date-time) |
Date-time when resource was created, sample format: yyyy-MM-ddTHH:mm:ssZ. |
| cropId |
string |
Crop Id associated with the ManagementZone. |
| description |
string minLength: 0maxLength: 500 |
Textual description of the resource. |
| eTag |
string |
The ETag value to implement optimistic concurrency. |
| farmerId |
string |
Farmer Id associated with the ManagementZone. |
| fieldId |
string |
Field Id associated with the ManagementZone. |
| id |
string |
Unique resource ID. |
| modifiedDateTime |
string (date-time) |
Date-time when resource was last modified, sample format: yyyy-MM-ddTHH:mm:ssZ. |
| name |
string minLength: 0maxLength: 100 |
Name to identify resource. |
| properties |
|
A collection of key value pairs that belongs to the resource. Each pair must not have a key greater than 50 characters and must not have a value greater than 150 characters. Note: A maximum of 25 key value pairs can be provided for a resource and only string, numeral and datetime (yyyy-MM-ddTHH:mm:ssZ) values are supported. |
| seasonId |
string |
Season Id associated with the ManagementZone. |
| source |
string minLength: 2maxLength: 100 |
Source of the resource. |
| status |
string minLength: 0maxLength: 100 |
Status of the resource. |
| type |
string minLength: 0maxLength: 100 |
Type of the ManagementZone. |
ManagementZoneListResponse
Paged response contains list of requested objects and a URL link to get the next set of results.
| Name | Type | Description |
|---|---|---|
| $skipToken |
string |
Token used in retrieving the next page. If null, there are no additional pages. |
| nextLink |
string |
Continuation link (absolute URI) to the next page of results in the list. |
| value |
List of requested objects. |