naftiko: 1.0.0-alpha2 info: label: Portkey API — Users description: 'Portkey API — Users. 4 operations. Lead operation: Get users. Self-contained Naftiko capability covering one Portkey business surface.' tags: - Portkey - Users created: '2026-05-19' modified: '2026-05-19' binds: - namespace: env keys: PORTKEY_API_KEY: PORTKEY_API_KEY capability: consumes: - type: http namespace: portkey-users baseUri: https://api.portkey.ai/v1 description: Portkey API — Users business capability. Self-contained, no shared references. resources: - name: admin-users path: /admin/users operations: - name: get method: GET description: Get users outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: x-portkey-api-key in: header type: string - name: pageSize in: query type: integer - name: currentPage in: query type: integer - name: role in: query type: string - name: email in: query type: string - name: admin-users-userId path: /admin/users/{userId} operations: - name: get method: GET description: Get user outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: userId in: path type: string required: true - name: delete method: DELETE description: Remove a user outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: userId in: path type: string required: true - name: put method: PUT description: Update user outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: userId in: path type: string required: true - name: body in: body type: object description: Request body (JSON). required: false authentication: type: bearer token: '{{env.PORTKEY_API_KEY}}' exposes: - type: rest namespace: portkey-users-rest port: 8080 description: REST adapter for Portkey API — Users. One Spectral-compliant resource per consumed operation, prefixed with /v1. resources: - path: /v1/admin/users name: admin-users description: REST surface for admin-users. operations: - method: GET name: get description: Get users call: portkey-users.get with: x-portkey-api-key: rest.x-portkey-api-key pageSize: rest.pageSize currentPage: rest.currentPage role: rest.role email: rest.email outputParameters: - type: object mapping: $. - path: /v1/admin/users/{userid} name: admin-users-userid description: REST surface for admin-users-userId. operations: - method: GET name: get description: Get user call: portkey-users.get with: userId: rest.userId outputParameters: - type: object mapping: $. - method: DELETE name: delete description: Remove a user call: portkey-users.delete with: userId: rest.userId outputParameters: - type: object mapping: $. - method: PUT name: put description: Update user call: portkey-users.put with: userId: rest.userId body: rest.body outputParameters: - type: object mapping: $. - type: mcp namespace: portkey-users-mcp port: 9090 transport: http description: MCP adapter for Portkey API — Users. One tool per consumed operation, routed inline through this capability's consumes block. tools: - name: get-users description: Get users hints: readOnly: true destructive: false idempotent: true call: portkey-users.get with: x-portkey-api-key: tools.x-portkey-api-key pageSize: tools.pageSize currentPage: tools.currentPage role: tools.role email: tools.email outputParameters: - type: object mapping: $. - name: get-user description: Get user hints: readOnly: true destructive: false idempotent: true call: portkey-users.get with: userId: tools.userId outputParameters: - type: object mapping: $. - name: remove-user description: Remove a user hints: readOnly: false destructive: true idempotent: true call: portkey-users.delete with: userId: tools.userId outputParameters: - type: object mapping: $. - name: update-user description: Update user hints: readOnly: false destructive: false idempotent: true call: portkey-users.put with: userId: tools.userId body: tools.body outputParameters: - type: object mapping: $.