naftiko: 1.0.0-alpha2 info: label: Granular Farm Management API — Farms description: 'Granular Farm Management API — Farms. 2 operations. Lead operation: List farms. Self-contained Naftiko capability covering one Granular business surface.' tags: - Granular - Farms created: '2026-05-19' modified: '2026-05-19' binds: - namespace: env keys: GRANULAR_API_KEY: GRANULAR_API_KEY capability: consumes: - type: http namespace: farm-management-farms baseUri: https://api.granular.ag/v1 description: Granular Farm Management API — Farms business capability. Self-contained, no shared references. resources: - name: farms path: /farms operations: - name: listfarms method: GET description: List farms outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: page in: query type: integer - name: pageSize in: query type: integer - name: farms-farmId path: /farms/{farmId} operations: - name: getfarm method: GET description: Get farm details outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: farmId in: path type: string required: true authentication: type: bearer token: '{{env.GRANULAR_API_KEY}}' exposes: - type: rest namespace: farm-management-farms-rest port: 8080 description: REST adapter for Granular Farm Management API — Farms. One Spectral-compliant resource per consumed operation, prefixed with /v1. resources: - path: /v1/farms name: farms description: REST surface for farms. operations: - method: GET name: listfarms description: List farms call: farm-management-farms.listfarms with: page: rest.page pageSize: rest.pageSize outputParameters: - type: object mapping: $. - path: /v1/farms/{farmid} name: farms-farmid description: REST surface for farms-farmId. operations: - method: GET name: getfarm description: Get farm details call: farm-management-farms.getfarm with: farmId: rest.farmId outputParameters: - type: object mapping: $. - type: mcp namespace: farm-management-farms-mcp port: 9090 transport: http description: MCP adapter for Granular Farm Management API — Farms. One tool per consumed operation, routed inline through this capability's consumes block. tools: - name: list-farms description: List farms hints: readOnly: true destructive: false idempotent: true call: farm-management-farms.listfarms with: page: tools.page pageSize: tools.pageSize outputParameters: - type: object mapping: $. - name: get-farm-details description: Get farm details hints: readOnly: true destructive: false idempotent: true call: farm-management-farms.getfarm with: farmId: tools.farmId outputParameters: - type: object mapping: $.