OpenFGA · Capability

OpenFGA — Stores

OpenFGA — Stores. 4 operations. Lead operation: List all stores. Self-contained Naftiko capability covering one Openfga business surface.

Run with Naftiko OpenfgaStores

What You Can Do

GET
Liststores — List all stores
/v1/stores
POST
Createstore — Create a store
/v1/stores
GET
Getstore — Get a store
/v1/stores/{store-id}
DELETE
Deletestore — Delete a store
/v1/stores/{store-id}

MCP Tools

list-all-stores

List all stores

read-only idempotent
create-store

Create a store

get-store

Get a store

read-only idempotent
delete-store

Delete a store

idempotent

Capability Spec

openfga-stores.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: OpenFGA — Stores
  description: 'OpenFGA — Stores. 4 operations. Lead operation: List all stores. Self-contained Naftiko capability covering
    one Openfga business surface.'
  tags:
  - Openfga
  - Stores
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    OPENFGA_API_KEY: OPENFGA_API_KEY
capability:
  consumes:
  - type: http
    namespace: openfga-stores
    baseUri: ''
    description: OpenFGA — Stores business capability. Self-contained, no shared references.
    resources:
    - name: stores
      path: /stores
      operations:
      - name: liststores
        method: GET
        description: List all stores
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: page_size
          in: query
          type: integer
        - name: continuation_token
          in: query
          type: string
        - name: name
          in: query
          type: string
          description: The name parameter instructs the API to only include results that match that name.Multiple results
            may be returned. Only exact matches will be returned; substri
      - name: createstore
        method: POST
        description: Create a store
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: string
          required: true
    - name: stores-store_id
      path: /stores/{store_id}
      operations:
      - name: getstore
        method: GET
        description: Get a store
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: store_id
          in: path
          type: string
          required: true
      - name: deletestore
        method: DELETE
        description: Delete a store
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: store_id
          in: path
          type: string
          required: true
  exposes:
  - type: rest
    namespace: openfga-stores-rest
    port: 8080
    description: REST adapter for OpenFGA — Stores. One Spectral-compliant resource per consumed operation, prefixed with
      /v1.
    resources:
    - path: /v1/stores
      name: stores
      description: REST surface for stores.
      operations:
      - method: GET
        name: liststores
        description: List all stores
        call: openfga-stores.liststores
        with:
          page_size: rest.page_size
          continuation_token: rest.continuation_token
          name: rest.name
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: createstore
        description: Create a store
        call: openfga-stores.createstore
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/stores/{store-id}
      name: stores-store-id
      description: REST surface for stores-store_id.
      operations:
      - method: GET
        name: getstore
        description: Get a store
        call: openfga-stores.getstore
        with:
          store_id: rest.store_id
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: deletestore
        description: Delete a store
        call: openfga-stores.deletestore
        with:
          store_id: rest.store_id
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: openfga-stores-mcp
    port: 9090
    transport: http
    description: MCP adapter for OpenFGA — Stores. One tool per consumed operation, routed inline through this capability's
      consumes block.
    tools:
    - name: list-all-stores
      description: List all stores
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: openfga-stores.liststores
      with:
        page_size: tools.page_size
        continuation_token: tools.continuation_token
        name: tools.name
      outputParameters:
      - type: object
        mapping: $.
    - name: create-store
      description: Create a store
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: openfga-stores.createstore
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: get-store
      description: Get a store
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: openfga-stores.getstore
      with:
        store_id: tools.store_id
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-store
      description: Delete a store
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: openfga-stores.deletestore
      with:
        store_id: tools.store_id
      outputParameters:
      - type: object
        mapping: $.