AgStack Foundation Field Retrieval & Queries API

The Field Retrieval & Queries API from AgStack Foundation β€” 4 operation(s) for field retrieval & queries.

Documentation

Specifications

Schemas & Data

📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-predictionout-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-weatherdataout-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-thidataout-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-sprayforecastresponse-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-flightstatusforecastresponse-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-geojsonout-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-jsonldgraph-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-authtoken-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-pointout-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-validationerror-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-httpvalidationerror-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-openagri-weather-service-body-token-auth-token-post-schema.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-predictionout-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-weatherdataout-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-thidataout-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-sprayforecastresponse-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-flightstatusforecastresponse-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-geojsonout-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-jsonldgraph-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-authtoken-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-pointout-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-validationerror-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-httpvalidationerror-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-openagri-weather-service-body-token-auth-token-post-structure.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-asset-registry-registerfieldwktrequest-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-asset-registry-geojsonfeaturecollection-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-schema/agstack-asset-registry-bulkpointresult-schema.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-asset-registry-registerfieldwktrequest-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-asset-registry-geojsonfeaturecollection-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/json-structure/agstack-asset-registry-bulkpointresult-structure.json

Other Resources

🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-predictionout-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-weatherdataout-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-thidataout-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-sprayforecastresponse-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-flightstatusforecastresponse-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-geojsonout-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-jsonldgraph-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-authtoken-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-pointout-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-validationerror-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-httpvalidationerror-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-openagri-weather-service-body-token-auth-token-post-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-asset-registry-registerfieldwktrequest-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-asset-registry-geojsonfeaturecollection-example.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/agstack/refs/heads/main/examples/agstack-asset-registry-bulkpointresult-example.json

OpenAPI Specification

agstack-field-retrieval-queries-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: AgStack Asset Registry api Field Retrieval & Queries API
  version: 1.0.0
  description: 'Welcome to the **AgStack Asset Registry** developer portal.


    ---


    ## πŸ” Authentication Guide


    | Service Zone | HTTP Method | Credential Type |

    | :--- | :---: | :--- |

    | **Authentication** | `GET/POST` | **Bearer Token** (where applicable) |

    | **Field Registration** | `POST` | **Bearer Token** |

    | **Field Retrieval** | `GET/POST`| **Bearer Token** (where applicable) |



    > πŸš€ **Quick Start Guide**

    > 1. Login via `/login` to get an `access_token` and `refresh_token`.

    > 2. Use `Bearer_Token` (Lock Icon) to authorize protected routes.

    '
servers:
- url: https://api-ar.agstack.org
  description: Production Server
tags:
- name: Field Retrieval & Queries
paths:
  /fetch-field/{geo_id}:
    get:
      tags:
      - Field Retrieval & Queries
      summary: πŸ—ΊοΈ Fetch Field Data
      parameters:
      - name: geo_id
        in: path
        required: true
        schema:
          type: string
      - name: s2_index
        in: query
        required: false
        schema:
          type: string
      responses:
        '200':
          description: Field fetched successfully
        '400':
          $ref: '#/components/responses/ErrorResponse'
        '404':
          description: Field not found
  /fetch-field-wkt/{geo_id}:
    get:
      tags:
      - Field Retrieval & Queries
      summary: πŸ“ Fetch Field WKT
      parameters:
      - name: geo_id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: WKT fetched successfully
        '400':
          $ref: '#/components/responses/ErrorResponse'
  /fetch-field-centroid/{geo_id}:
    get:
      tags:
      - Field Retrieval & Queries
      summary: πŸ“Œ Fetch Field Centroid
      parameters:
      - name: geo_id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Centroid fetched successfully
        '400':
          $ref: '#/components/responses/ErrorResponse'
  /get-percentage-overlap-two-fields:
    post:
      tags:
      - Field Retrieval & Queries
      summary: πŸ“Š Get Percentage Overlap
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
              - geo_id_field_1
              - geo_id_field_2
              properties:
                geo_id_field_1:
                  type: string
                geo_id_field_2:
                  type: string
      responses:
        '200':
          description: Overlap percentage calculated
        '400':
          $ref: '#/components/responses/ErrorResponse'
        '404':
          description: Field not found
components:
  responses:
    ErrorResponse:
      description: Generic Error Response
      content:
        application/json:
          schema:
            type: object
            properties:
              message:
                type: string
                example: Error description
              error:
                type: string
                example: Detailed exception message
  securitySchemes:
    Bearer_Token:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: '**Required for most operations.**

        1. Login via `/login` to get token.

        2. Paste access token here.

        '