farmOS Quantities API
Measurement quantities associated with logs
Operations 5
Documentation
Documentation
https://farmos.org/development/api/
Authentication
https://farmos.org/development/api/authentication/
Measurement quantities associated with logs
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/farmos-quantities-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: 'farmOS JSON: Assets Quantities API'
description: 'The farmOS JSON:API provides access to farm assets, logs, plans, and records.
It follows the JSON:API specification (https://jsonapi.org/) with UUID-based
resource identifiers. The root endpoint at /api returns server metadata and
available resource types. Resource endpoints follow the pattern
/api/[entity-type]/[bundle].
farmOS is an open-source farm management and record-keeping system built on
Drupal. It supports self-hosted deployments and managed hosting via Farmier.
'
version: 2.x
contact:
name: farmOS Community
url: https://farmos.org/community/
license:
name: GNU General Public License v2.0
url: https://github.com/farmOS/farmOS/blob/main/LICENSE.txt
termsOfService: https://farmos.org/
servers:
- url: https://{farmOS-host}/api
description: Self-hosted farmOS instance
variables:
farmOS-host:
default: example.farmos.net
description: The hostname of your farmOS instance (self-hosted or Farmier-managed)
security:
- oauth2AuthorizationCode:
- farm_manager
- oauth2ClientCredentials:
- farm_manager
tags:
- name: Quantities
description: Measurement quantities associated with logs
paths:
/quantity/standard:
get:
operationId: listStandardQuantities
summary: List standard quantities
description: Measurement quantities associated with logs.
tags:
- Quantities
parameters:
- $ref: '#/components/parameters/PageSize'
- $ref: '#/components/parameters/PageOffset'
- $ref: '#/components/parameters/FilterField'
- $ref: '#/components/parameters/SortField'
- $ref: '#/components/parameters/IncludeRelated'
responses:
'200':
description: A collection of standard quantities
content:
application/vnd.api+json:
schema:
$ref: '#/components/schemas/QuantityCollection'
'401':
$ref: '#/components/responses/Unauthorized'
post:
operationId: createStandardQuantity
summary: Create a standard quantity
tags:
- Quantities
requestBody:
required: true
content:
application/vnd.api+json:
schema:
$ref: '#/components/schemas/QuantityRequest'
responses:
'201':
description: Standard quantity created
content:
application/vnd.api+json:
schema:
$ref: '#/components/schemas/QuantityResponse'
'401':
$ref: '#/components/responses/Unauthorized'
'422':
$ref: '#/components/responses/UnprocessableEntity'
/quantity/standard/{id}:
parameters:
- $ref: '#/components/parameters/ResourceId'
get:
operationId: getStandardQuantity
summary: Get a standard quantity
tags:
- Quantities
responses:
'200':
description: A standard quantity
content:
application/vnd.api+json:
schema:
$ref: '#/components/schemas/QuantityResponse'
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
patch:
operationId: updateStandardQuantity
summary: Update a standard quantity
tags:
- Quantities
requestBody:
required: true
content:
application/vnd.api+json:
schema:
$ref: '#/components/schemas/QuantityRequest'
responses:
'200':
description: Updated standard quantity
content:
application/vnd.api+json:
schema:
$ref: '#/components/schemas/QuantityResponse'
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
delete:
operationId: deleteStandardQuantity
summary: Delete a standard quantity
tags:
- Quantities
responses:
'204':
description: Standard quantity deleted
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
components:
responses:
Unauthorized:
description: Authentication required or token expired
content:
application/vnd.api+json:
schema:
$ref: '#/components/schemas/JsonApiError'
NotFound:
description: Resource not found
content:
application/vnd.api+json:
schema:
$ref: '#/components/schemas/JsonApiError'
UnprocessableEntity:
description: Validation error
content:
application/vnd.api+json:
schema:
$ref: '#/components/schemas/JsonApiError'
schemas:
JsonApiRelationship:
type: object
properties:
data:
oneOf:
- $ref: '#/components/schemas/JsonApiRelationshipData'
- type: array
items:
$ref: '#/components/schemas/JsonApiRelationshipData'
- type:
- object
- 'null'
maxProperties: 0
links:
$ref: '#/components/schemas/JsonApiLinks'
QuantityAttributes:
type: object
properties:
measure:
type: string
description: Type of measurement (e.g., weight, volume, count, length, area, time, temperature, pressure, water_content, rating, ratio)
enum:
- weight
- volume
- count
- length
- area
- time
- temperature
- pressure
- water_content
- rating
- ratio
value:
type: object
description: Numeric value with decimal precision
properties:
numerator:
type: integer
denominator:
type: integer
decimal:
type: string
label:
type: string
description: Optional label for the quantity
inventory_adjustment:
type: string
description: How this quantity affects inventory (increment or decrement)
enum:
- increment
- decrement
- reset
JsonApiError:
type: object
properties:
errors:
type: array
items:
type: object
properties:
status:
type: string
title:
type: string
detail:
type: string
source:
type: object
properties:
pointer:
type: string
QuantityRequest:
type: object
required:
- data
properties:
data:
$ref: '#/components/schemas/QuantityData'
QuantityData:
type: object
required:
- type
- attributes
properties:
type:
type: string
example: quantity--standard
id:
type: string
format: uuid
readOnly: true
attributes:
$ref: '#/components/schemas/QuantityAttributes'
relationships:
$ref: '#/components/schemas/QuantityRelationships'
links:
$ref: '#/components/schemas/JsonApiLinks'
QuantityCollection:
type: object
properties:
data:
type: array
items:
$ref: '#/components/schemas/QuantityData'
links:
type: object
meta:
type: object
properties:
count:
type: integer
QuantityResponse:
type: object
properties:
data:
$ref: '#/components/schemas/QuantityData'
links:
$ref: '#/components/schemas/JsonApiLinks'
JsonApiLinks:
type: object
properties:
self:
type: string
format: uri
related:
type: string
format: uri
JsonApiRelationshipData:
type: object
properties:
type:
type: string
id:
type: string
format: uuid
QuantityRelationships:
type: object
properties:
units:
$ref: '#/components/schemas/JsonApiRelationship'
inventory_asset:
$ref: '#/components/schemas/JsonApiRelationship'
parameters:
SortField:
name: sort
in: query
description: 'Comma-separated list of fields to sort by. Prefix with - for descending.
Example: sort=-timestamp,name
'
schema:
type: string
IncludeRelated:
name: include
in: query
description: 'Comma-separated list of related resources to include in the response.
Example: include=asset,quantity
'
schema:
type: string
FilterField:
name: filter[field]
in: query
description: 'JSON:API filter parameter. Use dot notation for nested fields.
Example: filter[status]=pending or filter[timestamp][value]=1234567890&filter[timestamp][operator]=>=
'
schema:
type: string
PageOffset:
name: page[offset]
in: query
description: Offset for pagination
schema:
type: integer
minimum: 0
default: 0
ResourceId:
name: id
in: path
required: true
description: UUID of the resource
schema:
type: string
format: uuid
example: 3f1c2b4a-5d6e-7890-abcd-ef1234567890
PageSize:
name: page[limit]
in: query
description: Number of results per page
schema:
type: integer
minimum: 1
maximum: 50
default: 50
securitySchemes:
oauth2AuthorizationCode:
type: oauth2
description: 'OAuth2 Authorization Code grant for third-party integrations. Users
authorize the client application to access their farmOS data.
'
flows:
authorizationCode:
authorizationUrl: /oauth/authorize
tokenUrl: /oauth/token
scopes:
farm_manager: Full management access to the farm
farm_worker: Worker-level access to farm records
farm_viewer: Read-only access to farm records
oauth2ClientCredentials:
type: oauth2
description: 'OAuth2 Client Credentials grant for machine-to-machine authentication.
Used when no user account is required.
'
flows:
clientCredentials:
tokenUrl: /oauth/token
scopes:
farm_manager: Full management access to the farm
farm_worker: Worker-level access to farm records
farm_viewer: Read-only access to farm records
externalDocs:
description: farmOS API Documentation
url: https://farmos.org/development/api/