Apache CouchDB · Capability

Apache CouchDB HTTP API — Mango

Apache CouchDB HTTP API — Mango. 3 operations. Lead operation: Apache CouchDB Find Documents (Mango Query). Self-contained Naftiko capability covering one Apache Couchdb business surface.

Run with Naftiko Apache CouchdbMango

What You Can Do

POST
Finddocuments — Apache CouchDB Find Documents (Mango Query)
/v1/{db}/find
GET
Getindexes — Apache CouchDB Get Mango Indexes
/v1/{db}/index
POST
Createindex — Apache CouchDB Create Mango Index
/v1/{db}/index

MCP Tools

apache-couchdb-find-documents-mango

Apache CouchDB Find Documents (Mango Query)

read-only
apache-couchdb-get-mango-indexes

Apache CouchDB Get Mango Indexes

read-only idempotent
apache-couchdb-create-mango-index

Apache CouchDB Create Mango Index

Capability Spec

http-mango.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Apache CouchDB HTTP API — Mango
  description: 'Apache CouchDB HTTP API — Mango. 3 operations. Lead operation: Apache CouchDB Find Documents (Mango Query).
    Self-contained Naftiko capability covering one Apache Couchdb business surface.'
  tags:
  - Apache Couchdb
  - Mango
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    APACHE_COUCHDB_API_KEY: APACHE_COUCHDB_API_KEY
capability:
  consumes:
  - type: http
    namespace: http-mango
    baseUri: http://localhost:5984
    description: Apache CouchDB HTTP API — Mango business capability. Self-contained, no shared references.
    resources:
    - name: db-_find
      path: /{db}/_find
      operations:
      - name: finddocuments
        method: POST
        description: Apache CouchDB Find Documents (Mango Query)
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: db-_index
      path: /{db}/_index
      operations:
      - name: getindexes
        method: GET
        description: Apache CouchDB Get Mango Indexes
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: createindex
        method: POST
        description: Apache CouchDB Create Mango Index
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    authentication:
      type: apikey
      key: AuthSession
      value: '{{env.APACHE_COUCHDB_API_KEY}}'
      placement: cookie
  exposes:
  - type: rest
    namespace: http-mango-rest
    port: 8080
    description: REST adapter for Apache CouchDB HTTP API — Mango. One Spectral-compliant resource per consumed operation,
      prefixed with /v1.
    resources:
    - path: /v1/{db}/find
      name: db-find
      description: REST surface for db-_find.
      operations:
      - method: POST
        name: finddocuments
        description: Apache CouchDB Find Documents (Mango Query)
        call: http-mango.finddocuments
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/{db}/index
      name: db-index
      description: REST surface for db-_index.
      operations:
      - method: GET
        name: getindexes
        description: Apache CouchDB Get Mango Indexes
        call: http-mango.getindexes
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: createindex
        description: Apache CouchDB Create Mango Index
        call: http-mango.createindex
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: http-mango-mcp
    port: 9090
    transport: http
    description: MCP adapter for Apache CouchDB HTTP API — Mango. One tool per consumed operation, routed inline through this
      capability's consumes block.
    tools:
    - name: apache-couchdb-find-documents-mango
      description: Apache CouchDB Find Documents (Mango Query)
      hints:
        readOnly: true
        destructive: false
        idempotent: false
      call: http-mango.finddocuments
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: apache-couchdb-get-mango-indexes
      description: Apache CouchDB Get Mango Indexes
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: http-mango.getindexes
      outputParameters:
      - type: object
        mapping: $.
    - name: apache-couchdb-create-mango-index
      description: Apache CouchDB Create Mango Index
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: http-mango.createindex
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.