naftiko: 1.0.0-alpha2 info: label: LangWatch Annotations API description: 'Collaborative annotation and labeling workflows over traces. Self-contained Naftiko capability covering one LangWatch business surface.' tags: - LangWatch - Annotations - Labeling created: '2026-05-25' modified: '2026-05-25' binds: - namespace: env keys: LANGWATCH_API_KEY: LANGWATCH_API_KEY capability: consumes: - type: http namespace: annotations baseUri: https://app.langwatch.ai description: Collaborative annotation and labeling workflows over traces. resources: - name: api-annotations path: /api/annotations operations: - name: listAnnotations method: GET description: List annotations. outputRawFormat: json outputParameters: - name: result type: object value: $. - name: api-annotations-trace-id path: /api/annotations/trace/{id} operations: - name: listTraceAnnotations method: GET description: List annotations for a trace. outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string required: true - name: createTraceAnnotation method: POST description: Annotate a trace. outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string required: true - name: body in: body type: object description: Request body (JSON). required: false - name: api-annotations-id path: /api/annotations/{id} operations: - name: getAnnotation method: GET description: Retrieve an annotation. outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string required: true - name: updateAnnotation method: PATCH description: Update an annotation. outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string required: true - name: body in: body type: object description: Request body (JSON). required: false - name: deleteAnnotation method: DELETE description: Delete an annotation. outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string required: true authentication: type: bearer value: '{{env.LANGWATCH_API_KEY}}' placement: header exposes: - type: rest namespace: annotations-rest port: 8080 description: REST adapter for LangWatch Annotations API. resources: - path: /v1/api/annotations name: listannotations-resource description: REST surface for listAnnotations. operations: - method: GET name: listAnnotations description: List annotations. call: annotations.listAnnotations outputParameters: - type: object mapping: $. - path: /v1/api/annotations/trace/{id} name: listtraceannotations-resource description: REST surface for listTraceAnnotations. operations: - method: GET name: listTraceAnnotations description: List annotations for a trace. call: annotations.listTraceAnnotations with: id: rest.path.id outputParameters: - type: object mapping: $. - path: /v1/api/annotations/trace/{id} name: createtraceannotation-resource description: REST surface for createTraceAnnotation. operations: - method: POST name: createTraceAnnotation description: Annotate a trace. call: annotations.createTraceAnnotation with: id: rest.path.id body: rest.body outputParameters: - type: object mapping: $. - path: /v1/api/annotations/{id} name: getannotation-resource description: REST surface for getAnnotation. operations: - method: GET name: getAnnotation description: Retrieve an annotation. call: annotations.getAnnotation with: id: rest.path.id outputParameters: - type: object mapping: $. - path: /v1/api/annotations/{id} name: updateannotation-resource description: REST surface for updateAnnotation. operations: - method: PATCH name: updateAnnotation description: Update an annotation. call: annotations.updateAnnotation with: id: rest.path.id body: rest.body outputParameters: - type: object mapping: $. - path: /v1/api/annotations/{id} name: deleteannotation-resource description: REST surface for deleteAnnotation. operations: - method: DELETE name: deleteAnnotation description: Delete an annotation. call: annotations.deleteAnnotation with: id: rest.path.id outputParameters: - type: object mapping: $. - type: mcp namespace: annotations-mcp port: 9090 transport: http description: MCP adapter for LangWatch Annotations API. One tool per consumed operation. tools: - name: langwatch-listAnnotations description: List annotations. hints: readOnly: true destructive: false idempotent: true call: annotations.listAnnotations outputParameters: - type: object mapping: $. - name: langwatch-listTraceAnnotations description: List annotations for a trace. hints: readOnly: true destructive: false idempotent: true call: annotations.listTraceAnnotations with: id: tools.id outputParameters: - type: object mapping: $. - name: langwatch-createTraceAnnotation description: Annotate a trace. hints: readOnly: false destructive: false idempotent: false call: annotations.createTraceAnnotation with: id: tools.id body: tools.body outputParameters: - type: object mapping: $. - name: langwatch-getAnnotation description: Retrieve an annotation. hints: readOnly: true destructive: false idempotent: true call: annotations.getAnnotation with: id: tools.id outputParameters: - type: object mapping: $. - name: langwatch-updateAnnotation description: Update an annotation. hints: readOnly: false destructive: false idempotent: false call: annotations.updateAnnotation with: id: tools.id body: tools.body outputParameters: - type: object mapping: $. - name: langwatch-deleteAnnotation description: Delete an annotation. hints: readOnly: false destructive: true idempotent: true call: annotations.deleteAnnotation with: id: tools.id outputParameters: - type: object mapping: $.