naftiko: 1.0.0-alpha2 info: label: Memesio API Contracts — ai-jobs description: 'Memesio API Contracts — ai-jobs. 10 operations. Lead operation: Run One-Click Background Removal for Image or Video Frame with Edge Refinement Slider and Optional Mask Brush Edits. Self-contained Naftiko capability covering one Memesio business surface.' tags: - Memesio - ai-jobs created: '2026-05-19' modified: '2026-05-19' binds: - namespace: env keys: MEMESIO_API_KEY: MEMESIO_API_KEY capability: consumes: - type: http namespace: memesio-ai-jobs baseUri: '' description: Memesio API Contracts — ai-jobs business capability. Self-contained, no shared references. resources: - name: api-ai-background-remove path: /api/ai/background-remove operations: - name: post method: POST description: Run One-Click Background Removal for Image or Video Frame with Edge Refinement Slider and Optional Mask Brush Edits outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: body in: body type: object description: Request body (JSON). required: true - name: api-ai-edit-history path: /api/ai/edit-history operations: - name: get method: GET description: List or Compare Versioned AI Edit History for a Layer outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: projectId in: query type: string required: true - name: layerId in: query type: string required: true - name: mode in: query type: string - name: limit in: query type: integer - name: fromVersionId in: query type: string - name: toVersionId in: query type: string - name: post method: POST description: Record or Rollback Versioned AI Edit State for a Layer outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: body in: body type: object description: Request body (JSON). required: true - name: api-ai-face-swap path: /api/ai/face-swap operations: - name: post method: POST description: Execute Real-Time Face Swap for Image/Video Frame, with Preview Fallback When GPU Estimate Exceeds 2 Seconds outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: body in: body type: object description: Request body (JSON). required: true - name: api-ai-face-targets path: /api/ai/face-targets operations: - name: post method: POST description: Detect Multiple Face Targets and Return Selector Payload for Target Selection UI outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: body in: body type: object description: Request body (JSON). required: true - name: api-ai-jobs path: /api/ai/jobs operations: - name: get method: GET description: List AI Jobs outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: status in: query type: string - name: page in: query type: integer - name: pageSize in: query type: integer - name: post method: POST description: Submit AI Job outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: body in: body type: object description: Request body (JSON). required: true - name: api-ai-jobs-jobId path: /api/ai/jobs/{jobId} operations: - name: get method: GET description: Get AI Job Status outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: jobId in: path type: string required: true - name: api-ai-jobs-jobId-cancel path: /api/ai/jobs/{jobId}/cancel operations: - name: post method: POST description: Cancel AI Job outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: jobId in: path type: string required: true - name: body in: body type: object description: Request body (JSON). required: false - name: api-ai-jobs-jobId-complete path: /api/ai/jobs/{jobId}/complete operations: - name: post method: POST description: Complete AI Job and Log Metered AI Cost outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: jobId in: path type: string required: true - name: body in: body type: object description: Request body (JSON). required: true authentication: type: apikey key: x-developer-api-key value: '{{env.MEMESIO_API_KEY}}' placement: header exposes: - type: rest namespace: memesio-ai-jobs-rest port: 8080 description: REST adapter for Memesio API Contracts — ai-jobs. One Spectral-compliant resource per consumed operation, prefixed with /v1. resources: - path: /v1/api/ai/background-remove name: api-ai-background-remove description: REST surface for api-ai-background-remove. operations: - method: POST name: post description: Run One-Click Background Removal for Image or Video Frame with Edge Refinement Slider and Optional Mask Brush Edits call: memesio-ai-jobs.post with: body: rest.body outputParameters: - type: object mapping: $. - path: /v1/api/ai/edit-history name: api-ai-edit-history description: REST surface for api-ai-edit-history. operations: - method: GET name: get description: List or Compare Versioned AI Edit History for a Layer call: memesio-ai-jobs.get with: projectId: rest.projectId layerId: rest.layerId mode: rest.mode limit: rest.limit fromVersionId: rest.fromVersionId toVersionId: rest.toVersionId outputParameters: - type: object mapping: $. - method: POST name: post description: Record or Rollback Versioned AI Edit State for a Layer call: memesio-ai-jobs.post with: body: rest.body outputParameters: - type: object mapping: $. - path: /v1/api/ai/face-swap name: api-ai-face-swap description: REST surface for api-ai-face-swap. operations: - method: POST name: post description: Execute Real-Time Face Swap for Image/Video Frame, with Preview Fallback When GPU Estimate Exceeds 2 Seconds call: memesio-ai-jobs.post with: body: rest.body outputParameters: - type: object mapping: $. - path: /v1/api/ai/face-targets name: api-ai-face-targets description: REST surface for api-ai-face-targets. operations: - method: POST name: post description: Detect Multiple Face Targets and Return Selector Payload for Target Selection UI call: memesio-ai-jobs.post with: body: rest.body outputParameters: - type: object mapping: $. - path: /v1/api/ai/jobs name: api-ai-jobs description: REST surface for api-ai-jobs. operations: - method: GET name: get description: List AI Jobs call: memesio-ai-jobs.get with: status: rest.status page: rest.page pageSize: rest.pageSize outputParameters: - type: object mapping: $. - method: POST name: post description: Submit AI Job call: memesio-ai-jobs.post with: body: rest.body outputParameters: - type: object mapping: $. - path: /v1/api/ai/jobs/{jobid} name: api-ai-jobs-jobid description: REST surface for api-ai-jobs-jobId. operations: - method: GET name: get description: Get AI Job Status call: memesio-ai-jobs.get with: jobId: rest.jobId outputParameters: - type: object mapping: $. - path: /v1/api/ai/jobs/{jobid}/cancel name: api-ai-jobs-jobid-cancel description: REST surface for api-ai-jobs-jobId-cancel. operations: - method: POST name: post description: Cancel AI Job call: memesio-ai-jobs.post with: jobId: rest.jobId body: rest.body outputParameters: - type: object mapping: $. - path: /v1/api/ai/jobs/{jobid}/complete name: api-ai-jobs-jobid-complete description: REST surface for api-ai-jobs-jobId-complete. operations: - method: POST name: post description: Complete AI Job and Log Metered AI Cost call: memesio-ai-jobs.post with: jobId: rest.jobId body: rest.body outputParameters: - type: object mapping: $. - type: mcp namespace: memesio-ai-jobs-mcp port: 9090 transport: http description: MCP adapter for Memesio API Contracts — ai-jobs. One tool per consumed operation, routed inline through this capability's consumes block. tools: - name: run-one-click-background-removal description: Run One-Click Background Removal for Image or Video Frame with Edge Refinement Slider and Optional Mask Brush Edits hints: readOnly: false destructive: false idempotent: false call: memesio-ai-jobs.post with: body: tools.body outputParameters: - type: object mapping: $. - name: list-compare-versioned-ai-edit description: List or Compare Versioned AI Edit History for a Layer hints: readOnly: true destructive: false idempotent: true call: memesio-ai-jobs.get with: projectId: tools.projectId layerId: tools.layerId mode: tools.mode limit: tools.limit fromVersionId: tools.fromVersionId toVersionId: tools.toVersionId outputParameters: - type: object mapping: $. - name: record-rollback-versioned-ai-edit description: Record or Rollback Versioned AI Edit State for a Layer hints: readOnly: false destructive: false idempotent: false call: memesio-ai-jobs.post with: body: tools.body outputParameters: - type: object mapping: $. - name: execute-real-time-face-swap description: Execute Real-Time Face Swap for Image/Video Frame, with Preview Fallback When GPU Estimate Exceeds 2 Seconds hints: readOnly: false destructive: false idempotent: false call: memesio-ai-jobs.post with: body: tools.body outputParameters: - type: object mapping: $. - name: detect-multiple-face-targets-and description: Detect Multiple Face Targets and Return Selector Payload for Target Selection UI hints: readOnly: true destructive: false idempotent: false call: memesio-ai-jobs.post with: body: tools.body outputParameters: - type: object mapping: $. - name: list-ai-jobs description: List AI Jobs hints: readOnly: true destructive: false idempotent: true call: memesio-ai-jobs.get with: status: tools.status page: tools.page pageSize: tools.pageSize outputParameters: - type: object mapping: $. - name: submit-ai-job description: Submit AI Job hints: readOnly: false destructive: false idempotent: false call: memesio-ai-jobs.post with: body: tools.body outputParameters: - type: object mapping: $. - name: get-ai-job-status description: Get AI Job Status hints: readOnly: true destructive: false idempotent: true call: memesio-ai-jobs.get with: jobId: tools.jobId outputParameters: - type: object mapping: $. - name: cancel-ai-job description: Cancel AI Job hints: readOnly: false destructive: false idempotent: false call: memesio-ai-jobs.post with: jobId: tools.jobId body: tools.body outputParameters: - type: object mapping: $. - name: complete-ai-job-and-log description: Complete AI Job and Log Metered AI Cost hints: readOnly: false destructive: false idempotent: false call: memesio-ai-jobs.post with: jobId: tools.jobId body: tools.body outputParameters: - type: object mapping: $.