Codat · Capability

Lending — Manage data

Lending — Manage data. 5 operations. Lead operation: Refresh all data. Self-contained Naftiko capability covering one Codat business surface.

Run with Naftiko CodatManage data

What You Can Do

POST
Refreshalldatatypes — Refresh all data
/v1/companies/{companyid}/data/all
GET
Listpulloperations — List pull operations
/v1/companies/{companyid}/data/history
GET
Getpulloperation — Get pull operation
/v1/companies/{companyid}/data/history/{datasetid}
POST
Refreshdatatype — Refresh data type
/v1/companies/{companyid}/data/queue/{datatype}
GET
Getdatastatus — Get data status
/v1/companies/{companyid}/datastatus

MCP Tools

refresh-all-data

Refresh all data

list-pull-operations

List pull operations

read-only idempotent
get-pull-operation

Get pull operation

read-only idempotent
refresh-data-type

Refresh data type

get-data-status

Get data status

read-only idempotent

Capability Spec

lending-manage-data.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Lending — Manage data
  description: 'Lending — Manage data. 5 operations. Lead operation: Refresh all data. Self-contained Naftiko capability covering
    one Codat business surface.'
  tags:
  - Codat
  - Manage data
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    CODAT_API_KEY: CODAT_API_KEY
capability:
  consumes:
  - type: http
    namespace: lending-manage-data
    baseUri: https://api.codat.io
    description: Lending — Manage data business capability. Self-contained, no shared references.
    resources:
    - name: companies-companyId-data-all
      path: /companies/{companyId}/data/all
      operations:
      - name: refreshalldatatypes
        method: POST
        description: Refresh all data
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: companies-companyId-data-history
      path: /companies/{companyId}/data/history
      operations:
      - name: listpulloperations
        method: GET
        description: List pull operations
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: companies-companyId-data-history-datasetId
      path: /companies/{companyId}/data/history/{datasetId}
      operations:
      - name: getpulloperation
        method: GET
        description: Get pull operation
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: companies-companyId-data-queue-dataType
      path: /companies/{companyId}/data/queue/{dataType}
      operations:
      - name: refreshdatatype
        method: POST
        description: Refresh data type
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: connectionId
          in: query
          type: string
          description: Optionally, provide a data connection id to only queue pull operations on that connection.
    - name: companies-companyId-dataStatus
      path: /companies/{companyId}/dataStatus
      operations:
      - name: getdatastatus
        method: GET
        description: Get data status
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    authentication:
      type: apikey
      key: Authorization
      value: '{{env.CODAT_API_KEY}}'
      placement: header
  exposes:
  - type: rest
    namespace: lending-manage-data-rest
    port: 8080
    description: REST adapter for Lending — Manage data. One Spectral-compliant resource per consumed operation, prefixed
      with /v1.
    resources:
    - path: /v1/companies/{companyid}/data/all
      name: companies-companyid-data-all
      description: REST surface for companies-companyId-data-all.
      operations:
      - method: POST
        name: refreshalldatatypes
        description: Refresh all data
        call: lending-manage-data.refreshalldatatypes
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/companies/{companyid}/data/history
      name: companies-companyid-data-history
      description: REST surface for companies-companyId-data-history.
      operations:
      - method: GET
        name: listpulloperations
        description: List pull operations
        call: lending-manage-data.listpulloperations
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/companies/{companyid}/data/history/{datasetid}
      name: companies-companyid-data-history-datasetid
      description: REST surface for companies-companyId-data-history-datasetId.
      operations:
      - method: GET
        name: getpulloperation
        description: Get pull operation
        call: lending-manage-data.getpulloperation
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/companies/{companyid}/data/queue/{datatype}
      name: companies-companyid-data-queue-datatype
      description: REST surface for companies-companyId-data-queue-dataType.
      operations:
      - method: POST
        name: refreshdatatype
        description: Refresh data type
        call: lending-manage-data.refreshdatatype
        with:
          connectionId: rest.connectionId
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/companies/{companyid}/datastatus
      name: companies-companyid-datastatus
      description: REST surface for companies-companyId-dataStatus.
      operations:
      - method: GET
        name: getdatastatus
        description: Get data status
        call: lending-manage-data.getdatastatus
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: lending-manage-data-mcp
    port: 9090
    transport: http
    description: MCP adapter for Lending — Manage data. One tool per consumed operation, routed inline through this capability's
      consumes block.
    tools:
    - name: refresh-all-data
      description: Refresh all data
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: lending-manage-data.refreshalldatatypes
      outputParameters:
      - type: object
        mapping: $.
    - name: list-pull-operations
      description: List pull operations
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: lending-manage-data.listpulloperations
      outputParameters:
      - type: object
        mapping: $.
    - name: get-pull-operation
      description: Get pull operation
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: lending-manage-data.getpulloperation
      outputParameters:
      - type: object
        mapping: $.
    - name: refresh-data-type
      description: Refresh data type
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: lending-manage-data.refreshdatatype
      with:
        connectionId: tools.connectionId
      outputParameters:
      - type: object
        mapping: $.
    - name: get-data-status
      description: Get data status
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: lending-manage-data.getdatastatus
      outputParameters:
      - type: object
        mapping: $.