Microsoft · Capability

Microsoft Graph API — Drive

Microsoft Graph API — Drive. 5 operations. Lead operation: Microsoft Get drive item. Self-contained Naftiko capability covering one Microsoft business surface.

Run with Naftiko MicrosoftDrive

What You Can Do

GET
Getdriveitem — Microsoft Get drive item
/v1/drives/{drive-id}/items/{item-id}
PATCH
Updatedriveitem — Microsoft Update drive item
/v1/drives/{drive-id}/items/{item-id}
DELETE
Deletedriveitem — Microsoft Delete drive item
/v1/drives/{drive-id}/items/{item-id}
GET
Getmydrive — Microsoft Get current user's OneDrive
/v1/me/drive
GET
Listdriverootchildren — Microsoft List items in drive root
/v1/me/drive/root/children

MCP Tools

microsoft-get-drive-item

Microsoft Get drive item

read-only idempotent
microsoft-update-drive-item

Microsoft Update drive item

idempotent
microsoft-delete-drive-item

Microsoft Delete drive item

idempotent
microsoft-get-current-user-s-onedrive

Microsoft Get current user's OneDrive

read-only idempotent
microsoft-list-items-drive-root

Microsoft List items in drive root

read-only idempotent

Capability Spec

graph-drive.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Microsoft Graph API — Drive
  description: 'Microsoft Graph API — Drive. 5 operations. Lead operation: Microsoft Get drive item. Self-contained Naftiko
    capability covering one Microsoft business surface.'
  tags:
  - Microsoft
  - Drive
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    MICROSOFT_API_KEY: MICROSOFT_API_KEY
capability:
  consumes:
  - type: http
    namespace: graph-drive
    baseUri: https://graph.microsoft.com/v1.0
    description: Microsoft Graph API — Drive business capability. Self-contained, no shared references.
    resources:
    - name: drives-drive-id-items-item-id
      path: /drives/{drive-id}/items/{item-id}
      operations:
      - name: getdriveitem
        method: GET
        description: Microsoft Get drive item
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: updatedriveitem
        method: PATCH
        description: Microsoft Update drive item
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: deletedriveitem
        method: DELETE
        description: Microsoft Delete drive item
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: me-drive
      path: /me/drive
      operations:
      - name: getmydrive
        method: GET
        description: Microsoft Get current user's OneDrive
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: me-drive-root-children
      path: /me/drive/root/children
      operations:
      - name: listdriverootchildren
        method: GET
        description: Microsoft List items in drive root
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    authentication:
      type: bearer
      token: '{{env.MICROSOFT_API_KEY}}'
  exposes:
  - type: rest
    namespace: graph-drive-rest
    port: 8080
    description: REST adapter for Microsoft Graph API — Drive. One Spectral-compliant resource per consumed operation, prefixed
      with /v1.
    resources:
    - path: /v1/drives/{drive-id}/items/{item-id}
      name: drives-drive-id-items-item-id
      description: REST surface for drives-drive-id-items-item-id.
      operations:
      - method: GET
        name: getdriveitem
        description: Microsoft Get drive item
        call: graph-drive.getdriveitem
        outputParameters:
        - type: object
          mapping: $.
      - method: PATCH
        name: updatedriveitem
        description: Microsoft Update drive item
        call: graph-drive.updatedriveitem
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: deletedriveitem
        description: Microsoft Delete drive item
        call: graph-drive.deletedriveitem
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/me/drive
      name: me-drive
      description: REST surface for me-drive.
      operations:
      - method: GET
        name: getmydrive
        description: Microsoft Get current user's OneDrive
        call: graph-drive.getmydrive
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/me/drive/root/children
      name: me-drive-root-children
      description: REST surface for me-drive-root-children.
      operations:
      - method: GET
        name: listdriverootchildren
        description: Microsoft List items in drive root
        call: graph-drive.listdriverootchildren
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: graph-drive-mcp
    port: 9090
    transport: http
    description: MCP adapter for Microsoft Graph API — Drive. One tool per consumed operation, routed inline through this
      capability's consumes block.
    tools:
    - name: microsoft-get-drive-item
      description: Microsoft Get drive item
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: graph-drive.getdriveitem
      outputParameters:
      - type: object
        mapping: $.
    - name: microsoft-update-drive-item
      description: Microsoft Update drive item
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: graph-drive.updatedriveitem
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: microsoft-delete-drive-item
      description: Microsoft Delete drive item
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: graph-drive.deletedriveitem
      outputParameters:
      - type: object
        mapping: $.
    - name: microsoft-get-current-user-s-onedrive
      description: Microsoft Get current user's OneDrive
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: graph-drive.getmydrive
      outputParameters:
      - type: object
        mapping: $.
    - name: microsoft-list-items-drive-root
      description: Microsoft List items in drive root
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: graph-drive.listdriverootchildren
      outputParameters:
      - type: object
        mapping: $.