naftiko: 1.0.0-alpha2 info: label: Stack Exchange API v2.3 — Answers description: 'Answers surface of the Stack Exchange API. 4 operations. Lead operation: List Answers. Self-contained Naftiko capability covering one Stack Exchange business surface.' tags: - Stack Exchange - Q And A - Answers created: '2026-05-29' modified: '2026-05-29' binds: - namespace: env keys: STACK_EXCHANGE_KEY: STACK_EXCHANGE_KEY STACK_EXCHANGE_ACCESS_TOKEN: STACK_EXCHANGE_ACCESS_TOKEN capability: consumes: - type: http namespace: stack-exchange-answers baseUri: https://api.stackexchange.com/2.3 description: Stack Exchange API v2.3 — Answers business capability. Self-contained, no shared references. authentication: type: apikey key: key value: '{{env.STACK_EXCHANGE_KEY}}' placement: query resources: - name: answers path: /answers operations: - name: listAnswers method: GET description: List Answers inputParameters: - name: site in: query type: string required: true description: Target Q&A community. Either the api_site_parameter from a `/sites` entry (e.g. `stackoverflow`, `serverfault`, `superuser`) or a full domain (`stackoverflow.com`). - name: key in: query type: string required: false description: App key from stackapps.com. Raises the daily quota to 10,000/IP. - name: filter in: query type: string required: false description: Custom response filter id created via /filters/create. - name: page in: query type: integer required: false description: 1-indexed page number. - name: pagesize in: query type: integer required: false description: Items per page (max 100). - name: order in: query type: string required: false description: Sort direction. - name: fromdate in: query type: integer required: false description: Unix epoch seconds — earliest creation_date. - name: todate in: query type: integer required: false description: Unix epoch seconds — latest creation_date. - name: sort in: query type: string required: false description: sort parameter outputRawFormat: json outputParameters: - name: result type: object value: $. - name: answers-ids path: /answers/{ids} operations: - name: getAnswersByIds method: GET description: Get Answers by Ids inputParameters: - name: ids in: path type: string required: true description: Up to 100 semicolon-delimited ids of the resource. - name: site in: query type: string required: true description: Target Q&A community. Either the api_site_parameter from a `/sites` entry (e.g. `stackoverflow`, `serverfault`, `superuser`) or a full domain (`stackoverflow.com`). - name: key in: query type: string required: false description: App key from stackapps.com. Raises the daily quota to 10,000/IP. - name: filter in: query type: string required: false description: Custom response filter id created via /filters/create. outputRawFormat: json outputParameters: - name: result type: object value: $. - name: answers-ids-comments path: /answers/{ids}/comments operations: - name: listCommentsOnAnswers method: GET description: List Comments on Answers inputParameters: - name: ids in: path type: string required: true description: Up to 100 semicolon-delimited ids of the resource. - name: site in: query type: string required: true description: Target Q&A community. Either the api_site_parameter from a `/sites` entry (e.g. `stackoverflow`, `serverfault`, `superuser`) or a full domain (`stackoverflow.com`). - name: key in: query type: string required: false description: App key from stackapps.com. Raises the daily quota to 10,000/IP. - name: filter in: query type: string required: false description: Custom response filter id created via /filters/create. - name: page in: query type: integer required: false description: 1-indexed page number. - name: pagesize in: query type: integer required: false description: Items per page (max 100). outputRawFormat: json outputParameters: - name: result type: object value: $. - name: answers-ids-questions path: /answers/{ids}/questions operations: - name: getQuestionsForAnswers method: GET description: Get Questions for Answers inputParameters: - name: ids in: path type: string required: true description: Up to 100 semicolon-delimited ids of the resource. - name: site in: query type: string required: true description: Target Q&A community. Either the api_site_parameter from a `/sites` entry (e.g. `stackoverflow`, `serverfault`, `superuser`) or a full domain (`stackoverflow.com`). - name: key in: query type: string required: false description: App key from stackapps.com. Raises the daily quota to 10,000/IP. - name: filter in: query type: string required: false description: Custom response filter id created via /filters/create. outputRawFormat: json outputParameters: - name: result type: object value: $. exposes: - type: rest namespace: stack-exchange-answers-rest port: 8080 description: REST adapter for Stack Exchange API v2.3 — Answers. One Spectral-compliant resource per consumed operation, prefixed with /v1. resources: - path: /v1/answers name: answers description: REST surface for answers. operations: - method: GET name: listAnswers description: List Answers call: stack-exchange-answers.listAnswers with: site: rest.site key: rest.key filter: rest.filter page: rest.page pagesize: rest.pagesize order: rest.order fromdate: rest.fromdate todate: rest.todate sort: rest.sort outputParameters: - type: object mapping: $. - path: /v1/answers/{ids} name: answers description: REST surface for answers. operations: - method: GET name: getAnswersByIds description: Get Answers by Ids call: stack-exchange-answers.getAnswersByIds with: ids: rest.ids site: rest.site key: rest.key filter: rest.filter outputParameters: - type: object mapping: $. - path: /v1/answers/{ids}/comments name: comments description: REST surface for answers. operations: - method: GET name: listCommentsOnAnswers description: List Comments on Answers call: stack-exchange-answers.listCommentsOnAnswers with: ids: rest.ids site: rest.site key: rest.key filter: rest.filter page: rest.page pagesize: rest.pagesize outputParameters: - type: object mapping: $. - path: /v1/answers/{ids}/questions name: questions description: REST surface for answers. operations: - method: GET name: getQuestionsForAnswers description: Get Questions for Answers call: stack-exchange-answers.getQuestionsForAnswers with: ids: rest.ids site: rest.site key: rest.key filter: rest.filter outputParameters: - type: object mapping: $. - type: mcp namespace: stack-exchange-answers-mcp port: 9090 transport: http description: MCP adapter for Stack Exchange API v2.3 — Answers. One tool per consumed operation, routed inline through this capability's consumes block. tools: - name: list-answers description: List Answers hints: readOnly: true destructive: false idempotent: true call: stack-exchange-answers.listAnswers with: site: tools.site key: tools.key filter: tools.filter page: tools.page pagesize: tools.pagesize order: tools.order fromdate: tools.fromdate todate: tools.todate sort: tools.sort outputParameters: - type: object mapping: $. - name: get-answers-ids description: Get Answers by Ids hints: readOnly: true destructive: false idempotent: true call: stack-exchange-answers.getAnswersByIds with: ids: tools.ids site: tools.site key: tools.key filter: tools.filter outputParameters: - type: object mapping: $. - name: list-comments-answers description: List Comments on Answers hints: readOnly: true destructive: false idempotent: true call: stack-exchange-answers.listCommentsOnAnswers with: ids: tools.ids site: tools.site key: tools.key filter: tools.filter page: tools.page pagesize: tools.pagesize outputParameters: - type: object mapping: $. - name: get-questions-answers description: Get Questions for Answers hints: readOnly: true destructive: false idempotent: true call: stack-exchange-answers.getQuestionsForAnswers with: ids: tools.ids site: tools.site key: tools.key filter: tools.filter outputParameters: - type: object mapping: $.