Skip to main content
Version: 1.3.0

Gardin API

Our API is built around RESTful principles. It has predictable resource-oriented URLs, accepts JSON-encoded request bodies, returns JSON-encoded responses, and uses standard HTTP response codes, authentication, and verbs.

The API is organised into common functionality groups:

  1. Sensor management: The Sensor Management API facilitates the management of your Gardin sensors, offering endpoints to allow developers to list, describe, and group their sensors, as well as operate device schedules and measurement jobs.

  2. Alert notifications: The Alert Notification API delivers real-time plant health alert updates via a secure webhook or websocket connection.

  3. Data analysis: The Query API unlocks deep analysis and data sharing through user-submitted queries and bulk data downloads of chlorophyll fluorescence† and Gardin indices data.

† available on specific license plans only.

info

The base URL for the Gardin API is: https://api.gardin.ag/v1.

Getting started

To get started:

  1. Obtain your client ID and secret by contacting the Gardin Support team.
  2. Get a new access token.
  3. Make a call to any Gardin API endpoint, making sure to always provide your access token in the Authorization: Bearer {token} HTTP header.

Authentication

To access the Gardin API, users are required to authenticate using the OAuth2 Client Credentials flow. This authentication method is designed for applications that need to access resources on behalf of themselves, not on behalf of a user. It involves the application presenting its own credentials to obtain an access token, which then grants it permission to call the desired API endpoints.

The Client Credentials flow is particularly suitable for server-to-server interactions where the application needs to access resources without user intervention. Upon successful authentication, the application is issued an access token.

Access tokens are represented as JSON Web Tokens (JWTs), which are compact, URL-safe means of representing claims to be transferred between two parties. These tokens contain a set of claims that grant specific rights and are securely signed, allowing the recipient to verify their authenticity and integrity.

See POST /oauth2/token endpoint documentation for more information.

Security Scheme Type:oauth2
OAuth Flow (clientCredentials):

Token URL: https://login.gardin.ag/oauth2/token/

Scopes: