Zones - Get

取得特定合作物件下指定的區域資源。

GET {endpoint}/parties/{partyId}/zones/{zoneId}?api-version=2023-11-01-preview

URI 參數

名稱 位於 必要 類型 Description
endpoint
path True

string (uri)

命名空間的主機名,例如 admaInstanceName.farmbeats.azure.net

partyId
path True

string

相關聯合作對象的標識碼。

zoneId
path True

string

區域的標識碼。

api-version
query True

string

要求的 API 版本

要求標頭

名稱 必要 類型 Description
Authorization True

string

請提供授權 API 呼叫的有效持有人令牌。 請注意,如果您之前嘗試未驗證的呼叫,您可能需要清除瀏覽器快取。

回應

名稱 類型 Description
200 OK

Zone

成功

Other Status Codes

ErrorResponse

錯誤

標題

x-ms-error-code: string

安全性

Authorization

請提供授權 API 呼叫的有效持有人令牌。 請注意,如果您之前嘗試未驗證的呼叫,您可能需要清除瀏覽器快取。

類型: apiKey
位於: header

範例

Zones_Get

範例要求

GET {endpoint}/parties/PARTY123/zones/Zone123?api-version=2023-11-01-preview

範例回覆

{
  "partyId": "PARTY123",
  "id": "Zone123",
  "managementZoneId": "ManagementZone123",
  "type": "Nutrient rich",
  "status": "Active",
  "name": "John Smith's Zone",
  "description": "Some description",
  "source": "source",
  "properties": {
    "Irrigated": "Yes"
  },
  "createdDateTime": "2021-04-21T06:49:30Z",
  "modifiedDateTime": "2021-04-21T06:49:30Z",
  "createdBy": "00000000-0000-0000-0000-000000000000",
  "modifiedBy": "00000000-0000-0000-0000-000000000000",
  "eTag": "0f8fad5b-d9cb-469f-a165-70867728950e"
}

定義

名稱 Description
Error

來自 Azure AgPlatform 服務的錯誤。

ErrorResponse

來自 Azure AgPlatform 服務的錯誤回應。 如需 ErrorResponse 參考檔,請參閱 https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses

GeoJsonObjectType

GeoJSON 物件類型。

InnerError

包含錯誤清單的內部錯誤。請參閱 innerError 參考檔 https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object

MultiPolygon

MultiPolygon 幾何。

Point

點幾何。

Polygon

多邊形幾何。

Zone

Zone 物件的 Api 模型。

Error

來自 Azure AgPlatform 服務的錯誤。

名稱 類型 Description
code

string

minLength: 1

伺服器定義的錯誤碼集。

details

Error[]

導致此錯誤之特定錯誤的詳細數據陣列。

innererror

InnerError

包含錯誤清單的內部錯誤。請參閱 innerError 參考檔 https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object

message

string

minLength: 1

人類可讀取的錯誤表示法。

target

string

錯誤的目標。

ErrorResponse

來自 Azure AgPlatform 服務的錯誤回應。 如需 ErrorResponse 參考檔,請參閱 https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses

名稱 類型 Description
error

Error

來自 Azure AgPlatform 服務的錯誤。

traceId

string

唯一追蹤標識碼。

GeoJsonObjectType

GeoJSON 物件類型。

Description
Point
Polygon
MultiPolygon

InnerError

包含錯誤清單的內部錯誤。請參閱 innerError 參考檔 https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object

名稱 類型 Description
code

string

包含錯誤所提供的特定錯誤碼。

innererror

InnerError

包含錯誤清單的內部錯誤。請參閱 innerError 參考檔 https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object

MultiPolygon

MultiPolygon 幾何。

名稱 類型 Description
coordinates

number[] (double)

取得或設定 GeoJSON 物件的座標。 它必須是多邊形陣列,每個多邊形都包含線性環形的清單。 對於有多個環形的多邊形,第一個必須是外部環形,而任何其他必須是內部環形。

type string:

MultiPolygon

GeoJSON 物件類型。

Point

點幾何。

名稱 類型 Description
coordinates

number[] (double)

取得或設定這個點的座標。 它必須是 2D 或 3D 系統的 2 或 3 個項目陣列。

type string:

Point

GeoJSON 物件類型。

Polygon

多邊形幾何。

名稱 類型 Description
coordinates

number[] (double)

取得或設定 GeoJSON 物件的類型。 它必須是線性環形座標數位的陣列。 對於有多個環形的多邊形,第一個必須是外部環形,而任何其他必須是內部環形。

type string:

Polygon

GeoJSON 物件類型。

Zone

Zone 物件的 Api 模型。

名稱 類型 Description
createdBy

string

由使用者/租使用者標識碼建立。

createdDateTime

string (date-time)

建立資源的日期時間,範例格式:yyyy-MM-ddTHH:mm:ssZ。

description

string

minLength: 0
maxLength: 500

資源的文字描述。

eTag

string

要實作開放式並行存取的ETag值。

geometry GeoJsonObject:

GeoJSON (如需詳細資訊:https://geojson.org/)。 注意:座標必須是 [經度, 緯度] 格式。

id

string

唯一的資源標識碼。

managementZoneId

string

與區域相關聯的管理區域標識符。

modifiedBy

string

由使用者/租使用者標識碼修改。

modifiedDateTime

string (date-time)

上次修改資源的日期時間,範例格式:yyyy-MM-ddTHH:mm:ssZ。

name

string

minLength: 0
maxLength: 100

用來識別資源的名稱。

partyId

string

與區域相關聯的合作對象標識碼。

properties

屬於資源的索引鍵值組集合。 每個配對不能有大於 50 個字元的索引鍵,而且不能有大於 150 個字元的值。 注意:最多可以針對資源提供 25 個索引鍵值組,而且只支援字串、數位和日期時間 (yyyy-MM-ddTHH:mm:ssZ) 值。

source

string

minLength: 2
maxLength: 100

資源的來源。

status

string

minLength: 0
maxLength: 100

資源的狀態。

type

string

minLength: 0
maxLength: 100

區域的類型。