Chainlens · Capability

Chainlens — Contract-Bytecode-Controller

Chainlens — Contract-Bytecode-Controller. 1 operations. Lead operation: Chainlens Retrieves bytecodes for a deployed contract.. Self-contained Naftiko capability covering one Chainlens business surface.

Run with Naftiko ChainlensContract-Bytecode-Controller

What You Can Do

GET
Getcontractbytecode — Chainlens Retrieves bytecodes for a deployed contract.
/v1/contracts/{addresshash}/bytecode

MCP Tools

chainlens-retrieves-bytecodes-deployed-contract

Chainlens Retrieves bytecodes for a deployed contract.

read-only idempotent

Capability Spec

chainlens-contract-bytecode-controller.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Chainlens — Contract-Bytecode-Controller
  description: 'Chainlens — Contract-Bytecode-Controller. 1 operations. Lead operation: Chainlens Retrieves bytecodes for
    a deployed contract.. Self-contained Naftiko capability covering one Chainlens business surface.'
  tags:
  - Chainlens
  - Contract-Bytecode-Controller
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    CHAINLENS_API_KEY: CHAINLENS_API_KEY
capability:
  consumes:
  - type: http
    namespace: chainlens-contract-bytecode-controller
    baseUri: ''
    description: Chainlens — Contract-Bytecode-Controller business capability. Self-contained, no shared references.
    resources:
    - name: contracts-addressHash-bytecode
      path: /contracts/{addressHash}/bytecode
      operations:
      - name: getcontractbytecode
        method: GET
        description: Chainlens Retrieves bytecodes for a deployed contract.
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: addressHash
          in: path
          type: string
          description: The address hash identifying the contract.
          required: true
  exposes:
  - type: rest
    namespace: chainlens-contract-bytecode-controller-rest
    port: 8080
    description: REST adapter for Chainlens — Contract-Bytecode-Controller. One Spectral-compliant resource per consumed operation,
      prefixed with /v1.
    resources:
    - path: /v1/contracts/{addresshash}/bytecode
      name: contracts-addresshash-bytecode
      description: REST surface for contracts-addressHash-bytecode.
      operations:
      - method: GET
        name: getcontractbytecode
        description: Chainlens Retrieves bytecodes for a deployed contract.
        call: chainlens-contract-bytecode-controller.getcontractbytecode
        with:
          addressHash: rest.addressHash
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: chainlens-contract-bytecode-controller-mcp
    port: 9090
    transport: http
    description: MCP adapter for Chainlens — Contract-Bytecode-Controller. One tool per consumed operation, routed inline
      through this capability's consumes block.
    tools:
    - name: chainlens-retrieves-bytecodes-deployed-contract
      description: Chainlens Retrieves bytecodes for a deployed contract.
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: chainlens-contract-bytecode-controller.getcontractbytecode
      with:
        addressHash: tools.addressHash
      outputParameters:
      - type: object
        mapping: $.