Chemical Products - List

Returns a paginated list of chemical product resources.

GET {endpoint}/chemical-products?api-version=2023-11-01-preview
GET {endpoint}/chemical-products?cropIds={cropIds}&brands={brands}&products={products}&types={types}&states={states}&activeIngredients={activeIngredients}&specificGravity={specificGravity}&formulation={formulation}&registrationNumber={registrationNumber}&minReEntryInterval={minReEntryInterval}&maxReEntryInterval={maxReEntryInterval}&locations={locations}&companyNames={companyNames}&datasetIds={datasetIds}&referenceRecordIds={referenceRecordIds}&ids={ids}&names={names}&propertyFilters={propertyFilters}&statuses={statuses}&minCreatedDateTime={minCreatedDateTime}&maxCreatedDateTime={maxCreatedDateTime}&minLastModifiedDateTime={minLastModifiedDateTime}&maxLastModifiedDateTime={maxLastModifiedDateTime}&maxPageSize={maxPageSize}&skipToken={skipToken}&api-version=2023-11-01-preview

URI Parameters

Name In Required Type Description
endpoint
path True

string

uri

The host name of the namespace, e.g. admaInstanceName.farmbeats.azure.net

api-version
query True

string

The requested API version

activeIngredients
query

string[]

ActiveIngredients of chemical product.

brands
query

string[]

Brands of chemical product.

companyNames
query

string[]

Company names of chemical product.

cropIds
query

string[]

CropIds of chemical product.

datasetIds
query

string[]

Reference dataset id of chemical product.

formulation
query

string[]

Formulation of chemical product.

ids
query

string[]

Ids of the resource.

locations
query

string[]

Locations of chemical product.

maxCreatedDateTime
query

string

date-time

Maximum creation date of resource (inclusive).

maxLastModifiedDateTime
query

string

date-time

Maximum last modified date of resource (inclusive).

maxPageSize
query

integer

int32

Maximum number of items needed (inclusive). Minimum = 10, Maximum = 1000, Default value = 50.

maxReEntryInterval
query

integer

int32

Max ReEntryInterval of chemical product.

minCreatedDateTime
query

string

date-time

Minimum creation date of resource (inclusive).

minLastModifiedDateTime
query

string

date-time

Minimum last modified date of resource (inclusive).

minReEntryInterval
query

integer

int32

Min ReEntryInterval of chemical product.

names
query

string[]

Names of the resource.

products
query

string[]

Products of chemical product.

propertyFilters
query

string[]

Filters on key-value pairs within the Properties object. eg. "{testKey} eq {testValue}".

referenceRecordIds
query

string[]

Reference record id of chemical product.

registrationNumber
query

string[]

RegistrationNumber of chemical product.

skipToken
query

string

Skip token for getting next set of results.

specificGravity
query

string[]

SpecificGravity of chemical product.

states
query

string[]

States of chemical product.

statuses
query

string[]

Statuses of the resource.

types
query

string[]

Types of chemical product.

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

ChemicalProductListResponse

Success

Other Status Codes

ErrorResponse

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

ChemicalProducts_List

Sample request

GET {endpoint}/chemical-products?api-version=2023-11-01-preview

Sample response

{
  "value": [
    {
      "id": "Chemical123",
      "cropIds": [
        "CropId"
      ],
      "reference": {
        "datasetId": "datasetId",
        "recordId": "recordId"
      },
      "brand": "Brand",
      "product": "AGTECH",
      "type": "Herbicide",
      "state": "Liquid",
      "activeIngredients": [
        "NO2"
      ],
      "specificGravity": "string",
      "formulation": "N, P, K",
      "company": {
        "name": "CompanyName",
        "description": "Agriculture Manufacturer",
        "registrationNumber": "1234"
      },
      "location": "US",
      "registrationNumber": "1234",
      "reEntryInterval": 5,
      "status": "Active",
      "source": "Manufacturer",
      "name": "Fertilizer1",
      "description": "string",
      "properties": {
        "key1": "value1",
        "key2": 123.45
      },
      "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"
    }
  ],
  "skipToken": "string",
  "nextLink": "https://{{resourceName}}.farmbeats.azure.net/parties/{{partyId}}/chemical-products/{{chemicalProductId}}?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
ChemicalProduct

Schema of ChemicalProduct resource.

ChemicalProductListResponse

Paged response contains list of requested objects and a skipToken to get the next set of results.

Company

Company/Manufacturer's details.

Error

An error from the Azure AgPlatform service.

ErrorResponse

An error response from the Azure AgPlatform service. See https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses for ErrorResponse reference document.

InnerError

Inner error containing list of errors.See https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object for InnerError reference document.

Reference

Reference to a dataset record.

ChemicalProduct

Schema of ChemicalProduct resource.

Name Type Description
activeIngredients

string[]

Active chemicals in the formulation.

brand

string

Commercial brand of the chemical product.

company

Company

Company/Manufacturer's details.

createdBy

string

Created by user/tenant id.

createdDateTime

string

Date-time when resource was created, sample format: yyyy-MM-ddTHH:mm:ssZ.

cropIds

string[]

The Ids of the crops associated with the Chemical product. Note: A maximum of 25 crops can be associated with a cropProduct.

description

string

Textual description of the resource.

eTag

string

The ETag value to implement optimistic concurrency.

formulation

string

Formulation description. Percentage or other unit of N, P, K, CA, MG, S, FE, MN, ZN, CU, B, MO, CL (based on the source, the available chemical elements can vary, but this is a typical list).

id

string

Unique resource ID.

location

string

Area where the chemical is used. This is important from a compliance perspective.

modifiedBy

string

Modified by user/tenant id.

modifiedDateTime

string

Date-time when resource was last modified, sample format: yyyy-MM-ddTHH:mm:ssZ.

name

string

Name to identify resource.

product

string

Commercial product name of the chemical product.

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.

reEntryInterval

integer

The number of days after which a person can visit the field after the chemical product is applied.

reference

Reference

Reference to a dataset record.

registrationNumber

string

Registration number of the chemical. This could vary by geography.

source

string

Source of the resource.

specificGravity

string

Specific gravity details.

state

string

Liquid/non Liquid.

status

string

Status of the resource.

type

string

Herbicide, Additive, Insecticides, Fertilizers.

ChemicalProductListResponse

Paged response contains list of requested objects and a skipToken to get the next set of results.

Name Type Description
nextLink

string

Continuation link (absolute URI) to the next page of results in the list.

skipToken

string

Token used in retrieving the next page. If null, there are no additional pages.

value

ChemicalProduct[]

List of requested objects.

Company

Company/Manufacturer's details.

Name Type Description
description

string

Manufacturing Company description.

name

string

Name of the manufacturing company.

registrationNumber

string

Registration number of the company.

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

InnerError

Inner error containing list of errors.See https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object for InnerError reference document.

message

string

Human-readable representation of the error.

target

string

Target of the error.

ErrorResponse

An error response from the Azure AgPlatform service. See https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses for ErrorResponse reference document.

Name Type Description
error

Error

An error from the Azure AgPlatform service.

traceId

string

Unique trace Id.

InnerError

Inner error containing list of errors.See https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object for InnerError reference document.

Name Type Description
code

string

Specific error code than was provided by the containing error.

innererror

InnerError

Inner error containing list of errors.See https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#innererror--object for InnerError reference document.

Reference

Reference to a dataset record.

Name Type Description
datasetId

string

Dataset id.

recordId

string

Record id.