naftiko: 1.0.0-alpha2 info: label: Escape Public API — CustomRules description: 'Escape Public API — CustomRules. 5 operations. Lead operation: List custom rules. Self-contained Naftiko capability covering one Escape business surface.' tags: - Escape - CustomRules created: '2026-05-19' modified: '2026-05-19' binds: - namespace: env keys: ESCAPE_API_KEY: ESCAPE_API_KEY capability: consumes: - type: http namespace: escape-customrules baseUri: https://public.escape.tech/v3 description: Escape Public API — CustomRules business capability. Self-contained, no shared references. resources: - name: custom-rules path: /custom-rules operations: - name: listcustomrules method: GET description: List custom rules outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: context in: query type: string description: Filter by custom rule context - name: createcustomrule method: POST description: Create a custom rule outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: body in: body type: object description: Request body (JSON). required: false - name: custom-rules-customRuleId path: /custom-rules/{customRuleId} operations: - name: getcustomrule method: GET description: Get a custom rule outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: customRuleId in: path type: string required: true - name: updatecustomrule method: PUT description: Update a custom rule outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: customRuleId in: path type: string description: The ID of the custom rule to update required: true - name: body in: body type: object description: Request body (JSON). required: false - name: deletecustomrule method: DELETE description: Delete a custom rule outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: customRuleId in: path type: string description: The ID of the custom rule to delete required: true authentication: type: apikey key: X-ESCAPE-API-KEY value: '{{env.ESCAPE_API_KEY}}' placement: header exposes: - type: rest namespace: escape-customrules-rest port: 8080 description: REST adapter for Escape Public API — CustomRules. One Spectral-compliant resource per consumed operation, prefixed with /v1. resources: - path: /v1/custom-rules name: custom-rules description: REST surface for custom-rules. operations: - method: GET name: listcustomrules description: List custom rules call: escape-customrules.listcustomrules with: context: rest.context outputParameters: - type: object mapping: $. - method: POST name: createcustomrule description: Create a custom rule call: escape-customrules.createcustomrule with: body: rest.body outputParameters: - type: object mapping: $. - path: /v1/custom-rules/{customruleid} name: custom-rules-customruleid description: REST surface for custom-rules-customRuleId. operations: - method: GET name: getcustomrule description: Get a custom rule call: escape-customrules.getcustomrule with: customRuleId: rest.customRuleId outputParameters: - type: object mapping: $. - method: PUT name: updatecustomrule description: Update a custom rule call: escape-customrules.updatecustomrule with: customRuleId: rest.customRuleId body: rest.body outputParameters: - type: object mapping: $. - method: DELETE name: deletecustomrule description: Delete a custom rule call: escape-customrules.deletecustomrule with: customRuleId: rest.customRuleId outputParameters: - type: object mapping: $. - type: mcp namespace: escape-customrules-mcp port: 9090 transport: http description: MCP adapter for Escape Public API — CustomRules. One tool per consumed operation, routed inline through this capability's consumes block. tools: - name: list-custom-rules description: List custom rules hints: readOnly: true destructive: false idempotent: true call: escape-customrules.listcustomrules with: context: tools.context outputParameters: - type: object mapping: $. - name: create-custom-rule description: Create a custom rule hints: readOnly: false destructive: false idempotent: false call: escape-customrules.createcustomrule with: body: tools.body outputParameters: - type: object mapping: $. - name: get-custom-rule description: Get a custom rule hints: readOnly: true destructive: false idempotent: true call: escape-customrules.getcustomrule with: customRuleId: tools.customRuleId outputParameters: - type: object mapping: $. - name: update-custom-rule description: Update a custom rule hints: readOnly: false destructive: false idempotent: true call: escape-customrules.updatecustomrule with: customRuleId: tools.customRuleId body: tools.body outputParameters: - type: object mapping: $. - name: delete-custom-rule description: Delete a custom rule hints: readOnly: false destructive: true idempotent: true call: escape-customrules.deletecustomrule with: customRuleId: tools.customRuleId outputParameters: - type: object mapping: $.