Pipedrive · Capability

Pipedrive API v1 — Roles

Pipedrive API v1 — Roles. 12 operations. Lead operation: Get all roles. Self-contained Naftiko capability covering one Pipedrive business surface.

Run with Naftiko PipedriveRoles

What You Can Do

GET
Getroles — Get all roles
/v1/roles
POST
Addrole — Add a role
/v1/roles
DELETE
Deleterole — Delete a role
/v1/roles/{id}
GET
Getrole — Get one role
/v1/roles/{id}
PUT
Updaterole — Update role details
/v1/roles/{id}
DELETE
Deleteroleassignment — Delete a role assignment
/v1/roles/{id}/assignments
GET
Getroleassignments — List role assignments
/v1/roles/{id}/assignments
POST
Addroleassignment — Add role assignment
/v1/roles/{id}/assignments
GET
Getrolepipelines — List pipeline visibility for a role
/v1/roles/{id}/pipelines
PUT
Updaterolepipelines — Update pipeline visibility for a role
/v1/roles/{id}/pipelines
GET
Getrolesettings — List role settings
/v1/roles/{id}/settings
POST
Addorupdaterolesetting — Add or update role setting
/v1/roles/{id}/settings

MCP Tools

get-all-roles

Get all roles

read-only idempotent
add-role

Add a role

delete-role

Delete a role

idempotent
get-one-role

Get one role

read-only idempotent
update-role-details

Update role details

idempotent
delete-role-assignment

Delete a role assignment

idempotent
list-role-assignments

List role assignments

read-only idempotent
add-role-assignment

Add role assignment

list-pipeline-visibility-role

List pipeline visibility for a role

read-only idempotent
update-pipeline-visibility-role

Update pipeline visibility for a role

idempotent
list-role-settings

List role settings

read-only idempotent
add-update-role-setting

Add or update role setting

Capability Spec

v1-roles.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Pipedrive API v1 — Roles
  description: 'Pipedrive API v1 — Roles. 12 operations. Lead operation: Get all roles. Self-contained Naftiko capability
    covering one Pipedrive business surface.'
  tags:
  - Pipedrive
  - Roles
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    PIPEDRIVE_API_KEY: PIPEDRIVE_API_KEY
capability:
  consumes:
  - type: http
    namespace: v1-roles
    baseUri: https://api.pipedrive.com/v1
    description: Pipedrive API v1 — Roles business capability. Self-contained, no shared references.
    resources:
    - name: roles
      path: /roles
      operations:
      - name: getroles
        method: GET
        description: Get all roles
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: start
          in: query
          type: integer
          description: Pagination start
        - name: limit
          in: query
          type: integer
          description: Items shown per page
      - name: addrole
        method: POST
        description: Add a role
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
    - name: roles-id
      path: /roles/{id}
      operations:
      - name: deleterole
        method: DELETE
        description: Delete a role
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: The ID of the role
          required: true
      - name: getrole
        method: GET
        description: Get one role
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: The ID of the role
          required: true
      - name: updaterole
        method: PUT
        description: Update role details
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: The ID of the role
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
    - name: roles-id-assignments
      path: /roles/{id}/assignments
      operations:
      - name: deleteroleassignment
        method: DELETE
        description: Delete a role assignment
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: The ID of the role
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
      - name: getroleassignments
        method: GET
        description: List role assignments
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: The ID of the role
          required: true
        - name: start
          in: query
          type: integer
          description: Pagination start
        - name: limit
          in: query
          type: integer
          description: Items shown per page
      - name: addroleassignment
        method: POST
        description: Add role assignment
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: The ID of the role
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
    - name: roles-id-pipelines
      path: /roles/{id}/pipelines
      operations:
      - name: getrolepipelines
        method: GET
        description: List pipeline visibility for a role
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: The ID of the role
          required: true
        - name: visible
          in: query
          type: boolean
          description: Whether to return the visible or hidden pipelines for the role
      - name: updaterolepipelines
        method: PUT
        description: Update pipeline visibility for a role
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: The ID of the role
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
    - name: roles-id-settings
      path: /roles/{id}/settings
      operations:
      - name: getrolesettings
        method: GET
        description: List role settings
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: The ID of the role
          required: true
      - name: addorupdaterolesetting
        method: POST
        description: Add or update role setting
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: integer
          description: The ID of the role
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: false
    authentication:
      type: bearer
      token: '{{env.PIPEDRIVE_API_KEY}}'
  exposes:
  - type: rest
    namespace: v1-roles-rest
    port: 8080
    description: REST adapter for Pipedrive API v1 — Roles. One Spectral-compliant resource per consumed operation, prefixed
      with /v1.
    resources:
    - path: /v1/roles
      name: roles
      description: REST surface for roles.
      operations:
      - method: GET
        name: getroles
        description: Get all roles
        call: v1-roles.getroles
        with:
          start: rest.start
          limit: rest.limit
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: addrole
        description: Add a role
        call: v1-roles.addrole
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/roles/{id}
      name: roles-id
      description: REST surface for roles-id.
      operations:
      - method: DELETE
        name: deleterole
        description: Delete a role
        call: v1-roles.deleterole
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
      - method: GET
        name: getrole
        description: Get one role
        call: v1-roles.getrole
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
      - method: PUT
        name: updaterole
        description: Update role details
        call: v1-roles.updaterole
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/roles/{id}/assignments
      name: roles-id-assignments
      description: REST surface for roles-id-assignments.
      operations:
      - method: DELETE
        name: deleteroleassignment
        description: Delete a role assignment
        call: v1-roles.deleteroleassignment
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: GET
        name: getroleassignments
        description: List role assignments
        call: v1-roles.getroleassignments
        with:
          id: rest.id
          start: rest.start
          limit: rest.limit
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: addroleassignment
        description: Add role assignment
        call: v1-roles.addroleassignment
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/roles/{id}/pipelines
      name: roles-id-pipelines
      description: REST surface for roles-id-pipelines.
      operations:
      - method: GET
        name: getrolepipelines
        description: List pipeline visibility for a role
        call: v1-roles.getrolepipelines
        with:
          id: rest.id
          visible: rest.visible
        outputParameters:
        - type: object
          mapping: $.
      - method: PUT
        name: updaterolepipelines
        description: Update pipeline visibility for a role
        call: v1-roles.updaterolepipelines
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/roles/{id}/settings
      name: roles-id-settings
      description: REST surface for roles-id-settings.
      operations:
      - method: GET
        name: getrolesettings
        description: List role settings
        call: v1-roles.getrolesettings
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: addorupdaterolesetting
        description: Add or update role setting
        call: v1-roles.addorupdaterolesetting
        with:
          id: rest.id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: v1-roles-mcp
    port: 9090
    transport: http
    description: MCP adapter for Pipedrive API v1 — Roles. One tool per consumed operation, routed inline through this capability's
      consumes block.
    tools:
    - name: get-all-roles
      description: Get all roles
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: v1-roles.getroles
      with:
        start: tools.start
        limit: tools.limit
      outputParameters:
      - type: object
        mapping: $.
    - name: add-role
      description: Add a role
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: v1-roles.addrole
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-role
      description: Delete a role
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: v1-roles.deleterole
      with:
        id: tools.id
      outputParameters:
      - type: object
        mapping: $.
    - name: get-one-role
      description: Get one role
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: v1-roles.getrole
      with:
        id: tools.id
      outputParameters:
      - type: object
        mapping: $.
    - name: update-role-details
      description: Update role details
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: v1-roles.updaterole
      with:
        id: tools.id
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-role-assignment
      description: Delete a role assignment
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: v1-roles.deleteroleassignment
      with:
        id: tools.id
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: list-role-assignments
      description: List role assignments
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: v1-roles.getroleassignments
      with:
        id: tools.id
        start: tools.start
        limit: tools.limit
      outputParameters:
      - type: object
        mapping: $.
    - name: add-role-assignment
      description: Add role assignment
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: v1-roles.addroleassignment
      with:
        id: tools.id
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: list-pipeline-visibility-role
      description: List pipeline visibility for a role
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: v1-roles.getrolepipelines
      with:
        id: tools.id
        visible: tools.visible
      outputParameters:
      - type: object
        mapping: $.
    - name: update-pipeline-visibility-role
      description: Update pipeline visibility for a role
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: v1-roles.updaterolepipelines
      with:
        id: tools.id
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: list-role-settings
      description: List role settings
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: v1-roles.getrolesettings
      with:
        id: tools.id
      outputParameters:
      - type: object
        mapping: $.
    - name: add-update-role-setting
      description: Add or update role setting
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: v1-roles.addorupdaterolesetting
      with:
        id: tools.id
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.