naftiko: 1.0.0-alpha2 info: label: Grafana — Sets description: 'Grafana — Sets. 11 operations. Lead operation: Grafana Set Role Assignments. Self-contained Naftiko capability covering one Grafana business surface.' tags: - Grafana - Sets created: '2026-05-19' modified: '2026-05-19' binds: - namespace: env keys: GRAFANA_API_KEY: GRAFANA_API_KEY capability: consumes: - type: http namespace: grafana-sets baseUri: http://{defaultHost} description: Grafana — Sets business capability. Self-contained, no shared references. resources: - name: access-control-roles-roleUID-assignments path: /access-control/roles/{roleUID}/assignments operations: - name: setroleassignments method: PUT description: Grafana Set Role Assignments outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: roleUID in: path type: string required: true - name: body in: body type: object description: Request body (JSON). required: true - name: access-control-teams-teamId-roles path: /access-control/teams/{teamId}/roles operations: - name: setteamroles method: PUT description: Grafana Set Team Roles outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: teamId in: path type: integer required: true - name: body in: body type: object description: Request body (JSON). required: true - name: access-control-users-userId-roles path: /access-control/users/{userId}/roles operations: - name: setuserroles method: PUT description: Grafana Set User Roles outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: userId in: path type: integer required: true - name: body in: body type: object description: Request body (JSON). required: true - name: access-control-resource-resourceID path: /access-control/{resource}/{resourceID} operations: - name: setresourcepermissions method: POST description: Grafana Set Resource Permissions outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: resource in: path type: string required: true - name: resourceID in: path type: string required: true - name: body in: body type: object description: Request body (JSON). required: true - name: access-control-resource-resourceID-builtInRoles-builtInRole path: /access-control/{resource}/{resourceID}/builtInRoles/{builtInRole} operations: - name: setresourcepermissionsforbuiltinrole method: POST description: Grafana Set Resource Permissions For Built In Role outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: resource in: path type: string required: true - name: resourceID in: path type: string required: true - name: builtInRole in: path type: string required: true - name: body in: body type: object description: Request body (JSON). required: true - name: access-control-resource-resourceID-teams-teamID path: /access-control/{resource}/{resourceID}/teams/{teamID} operations: - name: setresourcepermissionsforteam method: POST description: Grafana Set Resource Permissions For Team outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: resource in: path type: string required: true - name: resourceID in: path type: string required: true - name: teamID in: path type: integer required: true - name: body in: body type: object description: Request body (JSON). required: true - name: access-control-resource-resourceID-users-userID path: /access-control/{resource}/{resourceID}/users/{userID} operations: - name: setresourcepermissionsforuser method: POST description: Grafana Set Resource Permissions For User outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: resource in: path type: string required: true - name: resourceID in: path type: string required: true - name: userID in: path type: integer required: true - name: body in: body type: object description: Request body (JSON). required: true - name: datasources-dataSourceUID-cache path: /datasources/{dataSourceUID}/cache operations: - name: setdatasourcecacheconfig method: POST description: Grafana Set Data Source Cache Config outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: dataSourceUID in: path type: string required: true - name: body in: body type: object description: Request body (JSON). required: true - name: teams-team_id-members path: /teams/{team_id}/members operations: - name: setteammemberships method: PUT description: Grafana Set Team Memberships outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: team_id in: path type: string required: true - name: body in: body type: object description: Request body (JSON). required: true - name: user-helpflags-flag_id path: /user/helpflags/{flag_id} operations: - name: sethelpflag method: PUT description: Grafana Set Help Flag outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: flag_id in: path type: string required: true - name: user-using-org_id path: /user/using/{org_id} operations: - name: usersetusingorg method: POST description: Grafana User Set Using Org outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: org_id in: path type: integer required: true authentication: type: apikey key: Authorization value: '{{env.GRAFANA_API_KEY}}' placement: header exposes: - type: rest namespace: grafana-sets-rest port: 8080 description: REST adapter for Grafana — Sets. One Spectral-compliant resource per consumed operation, prefixed with /v1. resources: - path: /v1/access-control/roles/{roleuid}/assignments name: access-control-roles-roleuid-assignments description: REST surface for access-control-roles-roleUID-assignments. operations: - method: PUT name: setroleassignments description: Grafana Set Role Assignments call: grafana-sets.setroleassignments with: roleUID: rest.roleUID body: rest.body outputParameters: - type: object mapping: $. - path: /v1/access-control/teams/{teamid}/roles name: access-control-teams-teamid-roles description: REST surface for access-control-teams-teamId-roles. operations: - method: PUT name: setteamroles description: Grafana Set Team Roles call: grafana-sets.setteamroles with: teamId: rest.teamId body: rest.body outputParameters: - type: object mapping: $. - path: /v1/access-control/users/{userid}/roles name: access-control-users-userid-roles description: REST surface for access-control-users-userId-roles. operations: - method: PUT name: setuserroles description: Grafana Set User Roles call: grafana-sets.setuserroles with: userId: rest.userId body: rest.body outputParameters: - type: object mapping: $. - path: /v1/access-control/{resource}/{resourceid} name: access-control-resource-resourceid description: REST surface for access-control-resource-resourceID. operations: - method: POST name: setresourcepermissions description: Grafana Set Resource Permissions call: grafana-sets.setresourcepermissions with: resource: rest.resource resourceID: rest.resourceID body: rest.body outputParameters: - type: object mapping: $. - path: /v1/access-control/{resource}/{resourceid}/builtinroles/{builtinrole} name: access-control-resource-resourceid-builtinroles-builtinrole description: REST surface for access-control-resource-resourceID-builtInRoles-builtInRole. operations: - method: POST name: setresourcepermissionsforbuiltinrole description: Grafana Set Resource Permissions For Built In Role call: grafana-sets.setresourcepermissionsforbuiltinrole with: resource: rest.resource resourceID: rest.resourceID builtInRole: rest.builtInRole body: rest.body outputParameters: - type: object mapping: $. - path: /v1/access-control/{resource}/{resourceid}/teams/{teamid} name: access-control-resource-resourceid-teams-teamid description: REST surface for access-control-resource-resourceID-teams-teamID. operations: - method: POST name: setresourcepermissionsforteam description: Grafana Set Resource Permissions For Team call: grafana-sets.setresourcepermissionsforteam with: resource: rest.resource resourceID: rest.resourceID teamID: rest.teamID body: rest.body outputParameters: - type: object mapping: $. - path: /v1/access-control/{resource}/{resourceid}/users/{userid} name: access-control-resource-resourceid-users-userid description: REST surface for access-control-resource-resourceID-users-userID. operations: - method: POST name: setresourcepermissionsforuser description: Grafana Set Resource Permissions For User call: grafana-sets.setresourcepermissionsforuser with: resource: rest.resource resourceID: rest.resourceID userID: rest.userID body: rest.body outputParameters: - type: object mapping: $. - path: /v1/datasources/{datasourceuid}/cache name: datasources-datasourceuid-cache description: REST surface for datasources-dataSourceUID-cache. operations: - method: POST name: setdatasourcecacheconfig description: Grafana Set Data Source Cache Config call: grafana-sets.setdatasourcecacheconfig with: dataSourceUID: rest.dataSourceUID body: rest.body outputParameters: - type: object mapping: $. - path: /v1/teams/{team-id}/members name: teams-team-id-members description: REST surface for teams-team_id-members. operations: - method: PUT name: setteammemberships description: Grafana Set Team Memberships call: grafana-sets.setteammemberships with: team_id: rest.team_id body: rest.body outputParameters: - type: object mapping: $. - path: /v1/user/helpflags/{flag-id} name: user-helpflags-flag-id description: REST surface for user-helpflags-flag_id. operations: - method: PUT name: sethelpflag description: Grafana Set Help Flag call: grafana-sets.sethelpflag with: flag_id: rest.flag_id outputParameters: - type: object mapping: $. - path: /v1/user/using/{org-id} name: user-using-org-id description: REST surface for user-using-org_id. operations: - method: POST name: usersetusingorg description: Grafana User Set Using Org call: grafana-sets.usersetusingorg with: org_id: rest.org_id outputParameters: - type: object mapping: $. - type: mcp namespace: grafana-sets-mcp port: 9090 transport: http description: MCP adapter for Grafana — Sets. One tool per consumed operation, routed inline through this capability's consumes block. tools: - name: grafana-set-role-assignments description: Grafana Set Role Assignments hints: readOnly: false destructive: false idempotent: true call: grafana-sets.setroleassignments with: roleUID: tools.roleUID body: tools.body outputParameters: - type: object mapping: $. - name: grafana-set-team-roles description: Grafana Set Team Roles hints: readOnly: false destructive: false idempotent: true call: grafana-sets.setteamroles with: teamId: tools.teamId body: tools.body outputParameters: - type: object mapping: $. - name: grafana-set-user-roles description: Grafana Set User Roles hints: readOnly: false destructive: false idempotent: true call: grafana-sets.setuserroles with: userId: tools.userId body: tools.body outputParameters: - type: object mapping: $. - name: grafana-set-resource-permissions description: Grafana Set Resource Permissions hints: readOnly: false destructive: false idempotent: false call: grafana-sets.setresourcepermissions with: resource: tools.resource resourceID: tools.resourceID body: tools.body outputParameters: - type: object mapping: $. - name: grafana-set-resource-permissions-built description: Grafana Set Resource Permissions For Built In Role hints: readOnly: false destructive: false idempotent: false call: grafana-sets.setresourcepermissionsforbuiltinrole with: resource: tools.resource resourceID: tools.resourceID builtInRole: tools.builtInRole body: tools.body outputParameters: - type: object mapping: $. - name: grafana-set-resource-permissions-team description: Grafana Set Resource Permissions For Team hints: readOnly: false destructive: false idempotent: false call: grafana-sets.setresourcepermissionsforteam with: resource: tools.resource resourceID: tools.resourceID teamID: tools.teamID body: tools.body outputParameters: - type: object mapping: $. - name: grafana-set-resource-permissions-user description: Grafana Set Resource Permissions For User hints: readOnly: false destructive: false idempotent: false call: grafana-sets.setresourcepermissionsforuser with: resource: tools.resource resourceID: tools.resourceID userID: tools.userID body: tools.body outputParameters: - type: object mapping: $. - name: grafana-set-data-source-cache description: Grafana Set Data Source Cache Config hints: readOnly: false destructive: false idempotent: false call: grafana-sets.setdatasourcecacheconfig with: dataSourceUID: tools.dataSourceUID body: tools.body outputParameters: - type: object mapping: $. - name: grafana-set-team-memberships description: Grafana Set Team Memberships hints: readOnly: false destructive: false idempotent: true call: grafana-sets.setteammemberships with: team_id: tools.team_id body: tools.body outputParameters: - type: object mapping: $. - name: grafana-set-help-flag description: Grafana Set Help Flag hints: readOnly: false destructive: false idempotent: true call: grafana-sets.sethelpflag with: flag_id: tools.flag_id outputParameters: - type: object mapping: $. - name: grafana-user-set-using-org description: Grafana User Set Using Org hints: readOnly: false destructive: false idempotent: false call: grafana-sets.usersetusingorg with: org_id: tools.org_id outputParameters: - type: object mapping: $.