Discord · Capability

Discord REST API — Members

Discord REST API — Members. 13 operations. Lead operation: Discord List guild bans. Self-contained Naftiko capability covering one Discord business surface.

Run with Naftiko DiscordMembers

What You Can Do

GET
Getguildbans — Discord List guild bans
/v1/guilds/{guild-id}/bans
GET
Getguildban — Discord Get guild ban
/v1/guilds/{guild-id}/bans/{user-id}
PUT
Createguildban — Discord Create guild ban
/v1/guilds/{guild-id}/bans/{user-id}
DELETE
Removeguildban — Discord Remove guild ban
/v1/guilds/{guild-id}/bans/{user-id}
POST
Bulkguildban — Discord Bulk guild ban
/v1/guilds/{guild-id}/bulk-ban
GET
Listguildmembers — Discord List guild members
/v1/guilds/{guild-id}/members
GET
Searchguildmembers — Discord Search guild members
/v1/guilds/{guild-id}/members/search
GET
Getguildmember — Discord Get guild member
/v1/guilds/{guild-id}/members/{user-id}
PUT
Addguildmember — Discord Add guild member
/v1/guilds/{guild-id}/members/{user-id}
PATCH
Modifyguildmember — Discord Modify guild member
/v1/guilds/{guild-id}/members/{user-id}
DELETE
Removeguildmember — Discord Remove guild member
/v1/guilds/{guild-id}/members/{user-id}
GET
Getguildprunecount — Discord Get guild prune count
/v1/guilds/{guild-id}/prune
POST
Beginguildprune — Discord Begin guild prune
/v1/guilds/{guild-id}/prune

MCP Tools

discord-list-guild-bans

Discord List guild bans

read-only idempotent
discord-get-guild-ban

Discord Get guild ban

read-only idempotent
discord-create-guild-ban

Discord Create guild ban

idempotent
discord-remove-guild-ban

Discord Remove guild ban

idempotent
discord-bulk-guild-ban

Discord Bulk guild ban

discord-list-guild-members

Discord List guild members

read-only idempotent
discord-search-guild-members

Discord Search guild members

read-only idempotent
discord-get-guild-member

Discord Get guild member

read-only idempotent
discord-add-guild-member

Discord Add guild member

idempotent
discord-modify-guild-member

Discord Modify guild member

idempotent
discord-remove-guild-member

Discord Remove guild member

idempotent
discord-get-guild-prune-count

Discord Get guild prune count

read-only idempotent
discord-begin-guild-prune

Discord Begin guild prune

Capability Spec

rest-members.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Discord REST API — Members
  description: 'Discord REST API — Members. 13 operations. Lead operation: Discord List guild bans. Self-contained Naftiko
    capability covering one Discord business surface.'
  tags:
  - Discord
  - Members
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    DISCORD_API_KEY: DISCORD_API_KEY
capability:
  consumes:
  - type: http
    namespace: rest-members
    baseUri: https://discord.com/api/v10
    description: Discord REST API — Members business capability. Self-contained, no shared references.
    resources:
    - name: guilds-guild_id-bans
      path: /guilds/{guild_id}/bans
      operations:
      - name: getguildbans
        method: GET
        description: Discord List guild bans
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: limit
          in: query
          type: integer
        - name: before
          in: query
          type: string
        - name: after
          in: query
          type: string
    - name: guilds-guild_id-bans-user_id
      path: /guilds/{guild_id}/bans/{user_id}
      operations:
      - name: getguildban
        method: GET
        description: Discord Get guild ban
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: createguildban
        method: PUT
        description: Discord Create guild ban
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
      - name: removeguildban
        method: DELETE
        description: Discord Remove guild ban
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: guilds-guild_id-bulk-ban
      path: /guilds/{guild_id}/bulk-ban
      operations:
      - name: bulkguildban
        method: POST
        description: Discord Bulk guild ban
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: guilds-guild_id-members
      path: /guilds/{guild_id}/members
      operations:
      - name: listguildmembers
        method: GET
        description: Discord List guild members
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: limit
          in: query
          type: integer
        - name: after
          in: query
          type: string
    - name: guilds-guild_id-members-search
      path: /guilds/{guild_id}/members/search
      operations:
      - name: searchguildmembers
        method: GET
        description: Discord Search guild members
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: query
          in: query
          type: string
          required: true
        - name: limit
          in: query
          type: integer
    - name: guilds-guild_id-members-user_id
      path: /guilds/{guild_id}/members/{user_id}
      operations:
      - name: getguildmember
        method: GET
        description: Discord Get guild member
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: addguildmember
        method: PUT
        description: Discord Add guild member
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: modifyguildmember
        method: PATCH
        description: Discord Modify guild member
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: removeguildmember
        method: DELETE
        description: Discord Remove guild member
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: guilds-guild_id-prune
      path: /guilds/{guild_id}/prune
      operations:
      - name: getguildprunecount
        method: GET
        description: Discord Get guild prune count
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: days
          in: query
          type: integer
        - name: include_roles
          in: query
          type: string
      - name: beginguildprune
        method: POST
        description: Discord Begin guild prune
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
    authentication:
      type: bearer
      token: '{{env.DISCORD_API_KEY}}'
  exposes:
  - type: rest
    namespace: rest-members-rest
    port: 8080
    description: REST adapter for Discord REST API — Members. One Spectral-compliant resource per consumed operation, prefixed
      with /v1.
    resources:
    - path: /v1/guilds/{guild-id}/bans
      name: guilds-guild-id-bans
      description: REST surface for guilds-guild_id-bans.
      operations:
      - method: GET
        name: getguildbans
        description: Discord List guild bans
        call: rest-members.getguildbans
        with:
          limit: rest.limit
          before: rest.before
          after: rest.after
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/guilds/{guild-id}/bans/{user-id}
      name: guilds-guild-id-bans-user-id
      description: REST surface for guilds-guild_id-bans-user_id.
      operations:
      - method: GET
        name: getguildban
        description: Discord Get guild ban
        call: rest-members.getguildban
        outputParameters:
        - type: object
          mapping: $.
      - method: PUT
        name: createguildban
        description: Discord Create guild ban
        call: rest-members.createguildban
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: removeguildban
        description: Discord Remove guild ban
        call: rest-members.removeguildban
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/guilds/{guild-id}/bulk-ban
      name: guilds-guild-id-bulk-ban
      description: REST surface for guilds-guild_id-bulk-ban.
      operations:
      - method: POST
        name: bulkguildban
        description: Discord Bulk guild ban
        call: rest-members.bulkguildban
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/guilds/{guild-id}/members
      name: guilds-guild-id-members
      description: REST surface for guilds-guild_id-members.
      operations:
      - method: GET
        name: listguildmembers
        description: Discord List guild members
        call: rest-members.listguildmembers
        with:
          limit: rest.limit
          after: rest.after
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/guilds/{guild-id}/members/search
      name: guilds-guild-id-members-search
      description: REST surface for guilds-guild_id-members-search.
      operations:
      - method: GET
        name: searchguildmembers
        description: Discord Search guild members
        call: rest-members.searchguildmembers
        with:
          query: rest.query
          limit: rest.limit
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/guilds/{guild-id}/members/{user-id}
      name: guilds-guild-id-members-user-id
      description: REST surface for guilds-guild_id-members-user_id.
      operations:
      - method: GET
        name: getguildmember
        description: Discord Get guild member
        call: rest-members.getguildmember
        outputParameters:
        - type: object
          mapping: $.
      - method: PUT
        name: addguildmember
        description: Discord Add guild member
        call: rest-members.addguildmember
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: PATCH
        name: modifyguildmember
        description: Discord Modify guild member
        call: rest-members.modifyguildmember
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: removeguildmember
        description: Discord Remove guild member
        call: rest-members.removeguildmember
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/guilds/{guild-id}/prune
      name: guilds-guild-id-prune
      description: REST surface for guilds-guild_id-prune.
      operations:
      - method: GET
        name: getguildprunecount
        description: Discord Get guild prune count
        call: rest-members.getguildprunecount
        with:
          days: rest.days
          include_roles: rest.include_roles
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: beginguildprune
        description: Discord Begin guild prune
        call: rest-members.beginguildprune
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: rest-members-mcp
    port: 9090
    transport: http
    description: MCP adapter for Discord REST API — Members. One tool per consumed operation, routed inline through this capability's
      consumes block.
    tools:
    - name: discord-list-guild-bans
      description: Discord List guild bans
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: rest-members.getguildbans
      with:
        limit: tools.limit
        before: tools.before
        after: tools.after
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-get-guild-ban
      description: Discord Get guild ban
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: rest-members.getguildban
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-create-guild-ban
      description: Discord Create guild ban
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: rest-members.createguildban
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-remove-guild-ban
      description: Discord Remove guild ban
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: rest-members.removeguildban
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-bulk-guild-ban
      description: Discord Bulk guild ban
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: rest-members.bulkguildban
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-list-guild-members
      description: Discord List guild members
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: rest-members.listguildmembers
      with:
        limit: tools.limit
        after: tools.after
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-search-guild-members
      description: Discord Search guild members
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: rest-members.searchguildmembers
      with:
        query: tools.query
        limit: tools.limit
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-get-guild-member
      description: Discord Get guild member
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: rest-members.getguildmember
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-add-guild-member
      description: Discord Add guild member
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: rest-members.addguildmember
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-modify-guild-member
      description: Discord Modify guild member
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: rest-members.modifyguildmember
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-remove-guild-member
      description: Discord Remove guild member
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: rest-members.removeguildmember
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-get-guild-prune-count
      description: Discord Get guild prune count
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: rest-members.getguildprunecount
      with:
        days: tools.days
        include_roles: tools.include_roles
      outputParameters:
      - type: object
        mapping: $.
    - name: discord-begin-guild-prune
      description: Discord Begin guild prune
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: rest-members.beginguildprune
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.