Asset resources

List Asset Resources

Everything filed on one paddock or one mob. resources lists them without a follow-up call: the property (type: farm), the paddock a mob is standing in (type: paddock), the live mobs standing in a paddock (type: mob), and the tasks and records (type: task).

A move is a task whose asset is the mob. On a paddock it is still listed, because the move names that paddock as where the mob left or arrived. Placement uses the newest completed record that names a destination, the same rule as current_paddock_id.

asset_type is paddock or mob (singular or plural). Omit it and asset_id is tried as a paddock, then as a mob. Tasks are one page (page, per_page, default 25) in board order; meta carries the page. The property, the current paddock and the mobs are always complete, not paged. Pass include for the full records.

The caller must be able to read the asset: an accepted member of the owning business, or the person who owns a personal property.

get/asset-resources

Request

  • Base URL: https://api.purplegrain.com/api/v1
  • URL: https://api.purplegrain.com/api/v1/asset-resources
  • Auth: one of:
    • none
    • HTTP bearer

Query parameters

asset_idstring required

The paddock or mob.

asset_typestring

paddock or mob, singular or plural. Omitted, asset_id is resolved as a paddock and then as a mob. Deliberately no enum: a schema stricter than the lookup rejects a plural the day request validation is enforced.

pageinteger

Page of tasks and records. The property, paddock and mobs are not paged.

per_pageinteger

Tasks and records per page. Defaults to 25.

includestring
Example:farm,tasks,mobs,paddock

Comma-separated snake_case relationship paths to embed (JSON:API included array, or inlined for application/json). Never embedded by default; unknown paths ignored; max 10 paths. Allowed paths: farm, tasks, mobs, paddock. The resources attribute lists the same company without this parameter.

Response

The asset and the resources filed on it.

Example response

{
  "data": {
    "type": "asset_resources"
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.