Prefect · Capability

Prefect Cloud API — Users

Prefect Cloud API — Users. 7 operations. Lead operation: Read User. Self-contained Naftiko capability covering one Prefect business surface.

Run with Naftiko PrefectUsers

What You Can Do

GET
Readuserapiusersidget — Read User
/v1/api/users/{id}
PATCH
Updateuserapiusersidpatch — Update User
/v1/api/users/{id}
DELETE
Deleteuserapiusersiddelete — Delete User
/v1/api/users/{id}
POST
Createuserapikeyapiusersidapikeyspost — Create User Api Key
/v1/api/users/{id}/api-keys
GET
Readuserapikeysapiusersidapikeysget — Read User Api Keys
/v1/api/users/{id}/api-keys
GET
Readuserapikeyapiusersidapikeysapikeyidget — Read User Api Key
/v1/api/users/{id}/api-keys/{api-key-id}
DELETE
Deleteuserapikeyapiusersidapikeysapikeyiddelete — Delete User Api Key
/v1/api/users/{id}/api-keys/{api-key-id}

MCP Tools

read-user

Read User

read-only idempotent
update-user

Update User

idempotent
delete-user

Delete User

idempotent
create-user-api-key

Create User Api Key

read-user-api-keys

Read User Api Keys

read-only idempotent
read-user-api-key

Read User Api Key

read-only idempotent
delete-user-api-key

Delete User Api Key

idempotent

Capability Spec

prefect-users.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Prefect Cloud API — Users
  description: 'Prefect Cloud API — Users. 7 operations. Lead operation: Read User. Self-contained Naftiko capability covering
    one Prefect business surface.'
  tags:
  - Prefect
  - Users
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    PREFECT_API_KEY: PREFECT_API_KEY
capability:
  consumes:
  - type: http
    namespace: prefect-users
    baseUri: ''
    description: Prefect Cloud API — Users business capability. Self-contained, no shared references.
    resources:
    - name: api-users-id
      path: /api/users/{id}
      operations:
      - name: readuserapiusersidget
        method: GET
        description: Read User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: string
          required: true
      - name: updateuserapiusersidpatch
        method: PATCH
        description: Update User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: string
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: deleteuserapiusersiddelete
        method: DELETE
        description: Delete User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: string
          required: true
    - name: api-users-id-api_keys
      path: /api/users/{id}/api_keys
      operations:
      - name: createuserapikeyapiusersidapikeyspost
        method: POST
        description: Create User Api Key
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: string
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: readuserapikeysapiusersidapikeysget
        method: GET
        description: Read User Api Keys
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: string
          required: true
        - name: name
          in: query
          type: string
    - name: api-users-id-api_keys-api_key_id
      path: /api/users/{id}/api_keys/{api_key_id}
      operations:
      - name: readuserapikeyapiusersidapikeysapikeyidget
        method: GET
        description: Read User Api Key
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: string
          required: true
        - name: api_key_id
          in: path
          type: string
          required: true
      - name: deleteuserapikeyapiusersidapikeysapikeyiddelete
        method: DELETE
        description: Delete User Api Key
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: string
          required: true
        - name: api_key_id
          in: path
          type: string
          required: true
  exposes:
  - type: rest
    namespace: prefect-users-rest
    port: 8080
    description: REST adapter for Prefect Cloud API — Users. One Spectral-compliant resource per consumed operation, prefixed
      with /v1.
    resources:
    - path: /v1/api/users/{id}
      name: api-users-id
      description: REST surface for api-users-id.
      operations:
      - method: GET
        name: readuserapiusersidget
        description: Read User
        call: prefect-users.readuserapiusersidget
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
      - method: PATCH
        name: updateuserapiusersidpatch
        description: Update User
        call: prefect-users.updateuserapiusersidpatch
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: deleteuserapiusersiddelete
        description: Delete User
        call: prefect-users.deleteuserapiusersiddelete
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/api/users/{id}/api-keys
      name: api-users-id-api-keys
      description: REST surface for api-users-id-api_keys.
      operations:
      - method: POST
        name: createuserapikeyapiusersidapikeyspost
        description: Create User Api Key
        call: prefect-users.createuserapikeyapiusersidapikeyspost
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: GET
        name: readuserapikeysapiusersidapikeysget
        description: Read User Api Keys
        call: prefect-users.readuserapikeysapiusersidapikeysget
        with:
          id: rest.id
          name: rest.name
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/api/users/{id}/api-keys/{api-key-id}
      name: api-users-id-api-keys-api-key-id
      description: REST surface for api-users-id-api_keys-api_key_id.
      operations:
      - method: GET
        name: readuserapikeyapiusersidapikeysapikeyidget
        description: Read User Api Key
        call: prefect-users.readuserapikeyapiusersidapikeysapikeyidget
        with:
          id: rest.id
          api_key_id: rest.api_key_id
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: deleteuserapikeyapiusersidapikeysapikeyiddelete
        description: Delete User Api Key
        call: prefect-users.deleteuserapikeyapiusersidapikeysapikeyiddelete
        with:
          id: rest.id
          api_key_id: rest.api_key_id
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: prefect-users-mcp
    port: 9090
    transport: http
    description: MCP adapter for Prefect Cloud API — Users. One tool per consumed operation, routed inline through this capability's
      consumes block.
    tools:
    - name: read-user
      description: Read User
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: prefect-users.readuserapiusersidget
      with:
        id: tools.id
      outputParameters:
      - type: object
        mapping: $.
    - name: update-user
      description: Update User
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: prefect-users.updateuserapiusersidpatch
      with:
        id: tools.id
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-user
      description: Delete User
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: prefect-users.deleteuserapiusersiddelete
      with:
        id: tools.id
      outputParameters:
      - type: object
        mapping: $.
    - name: create-user-api-key
      description: Create User Api Key
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: prefect-users.createuserapikeyapiusersidapikeyspost
      with:
        id: tools.id
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: read-user-api-keys
      description: Read User Api Keys
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: prefect-users.readuserapikeysapiusersidapikeysget
      with:
        id: tools.id
        name: tools.name
      outputParameters:
      - type: object
        mapping: $.
    - name: read-user-api-key
      description: Read User Api Key
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: prefect-users.readuserapikeyapiusersidapikeysapikeyidget
      with:
        id: tools.id
        api_key_id: tools.api_key_id
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-user-api-key
      description: Delete User Api Key
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: prefect-users.deleteuserapikeyapiusersidapikeysapikeyiddelete
      with:
        id: tools.id
        api_key_id: tools.api_key_id
      outputParameters:
      - type: object
        mapping: $.