CockroachDB · Capability

CockroachDB Cloud API — Folders

CockroachDB Cloud API — Folders. 6 operations. Lead operation: List folders. Self-contained Naftiko capability covering one Cockroachdb business surface.

Run with Naftiko CockroachdbFolders

What You Can Do

GET
Listfolders — List folders
/v1/api/v1/folders
POST
Createfolder — Create a folder
/v1/api/v1/folders
GET
Getfolder — Get a folder
/v1/api/v1/folders/{folder-id}
PATCH
Updatefolder — Update a folder
/v1/api/v1/folders/{folder-id}
DELETE
Deletefolder — Delete a folder
/v1/api/v1/folders/{folder-id}
GET
Listfoldercontents — List folder contents
/v1/api/v1/folders/{folder-id}/contents

MCP Tools

list-folders

List folders

read-only idempotent
create-folder

Create a folder

get-folder

Get a folder

read-only idempotent
update-folder

Update a folder

idempotent
delete-folder

Delete a folder

idempotent
list-folder-contents

List folder contents

read-only idempotent

Capability Spec

cloud-folders.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: CockroachDB Cloud API — Folders
  description: 'CockroachDB Cloud API — Folders. 6 operations. Lead operation: List folders. Self-contained Naftiko capability
    covering one Cockroachdb business surface.'
  tags:
  - Cockroachdb
  - Folders
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    COCKROACHDB_API_KEY: COCKROACHDB_API_KEY
capability:
  consumes:
  - type: http
    namespace: cloud-folders
    baseUri: https://cockroachlabs.cloud
    description: CockroachDB Cloud API — Folders business capability. Self-contained, no shared references.
    resources:
    - name: api-v1-folders
      path: /api/v1/folders
      operations:
      - name: listfolders
        method: GET
        description: List folders
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: path
          in: query
          type: string
          description: Filter folders by path prefix.
      - name: createfolder
        method: POST
        description: Create a folder
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: api-v1-folders-folder_id
      path: /api/v1/folders/{folder_id}
      operations:
      - name: getfolder
        method: GET
        description: Get a folder
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: updatefolder
        method: PATCH
        description: Update a folder
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: deletefolder
        method: DELETE
        description: Delete a folder
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: api-v1-folders-folder_id-contents
      path: /api/v1/folders/{folder_id}/contents
      operations:
      - name: listfoldercontents
        method: GET
        description: List folder contents
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    authentication:
      type: bearer
      token: '{{env.COCKROACHDB_API_KEY}}'
  exposes:
  - type: rest
    namespace: cloud-folders-rest
    port: 8080
    description: REST adapter for CockroachDB Cloud API — Folders. One Spectral-compliant resource per consumed operation,
      prefixed with /v1.
    resources:
    - path: /v1/api/v1/folders
      name: api-v1-folders
      description: REST surface for api-v1-folders.
      operations:
      - method: GET
        name: listfolders
        description: List folders
        call: cloud-folders.listfolders
        with:
          path: rest.path
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: createfolder
        description: Create a folder
        call: cloud-folders.createfolder
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/api/v1/folders/{folder-id}
      name: api-v1-folders-folder-id
      description: REST surface for api-v1-folders-folder_id.
      operations:
      - method: GET
        name: getfolder
        description: Get a folder
        call: cloud-folders.getfolder
        outputParameters:
        - type: object
          mapping: $.
      - method: PATCH
        name: updatefolder
        description: Update a folder
        call: cloud-folders.updatefolder
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: deletefolder
        description: Delete a folder
        call: cloud-folders.deletefolder
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/api/v1/folders/{folder-id}/contents
      name: api-v1-folders-folder-id-contents
      description: REST surface for api-v1-folders-folder_id-contents.
      operations:
      - method: GET
        name: listfoldercontents
        description: List folder contents
        call: cloud-folders.listfoldercontents
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: cloud-folders-mcp
    port: 9090
    transport: http
    description: MCP adapter for CockroachDB Cloud API — Folders. One tool per consumed operation, routed inline through this
      capability's consumes block.
    tools:
    - name: list-folders
      description: List folders
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: cloud-folders.listfolders
      with:
        path: tools.path
      outputParameters:
      - type: object
        mapping: $.
    - name: create-folder
      description: Create a folder
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: cloud-folders.createfolder
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: get-folder
      description: Get a folder
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: cloud-folders.getfolder
      outputParameters:
      - type: object
        mapping: $.
    - name: update-folder
      description: Update a folder
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: cloud-folders.updatefolder
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-folder
      description: Delete a folder
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: cloud-folders.deletefolder
      outputParameters:
      - type: object
        mapping: $.
    - name: list-folder-contents
      description: List folder contents
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: cloud-folders.listfoldercontents
      outputParameters:
      - type: object
        mapping: $.