naftiko: 1.0.0-alpha2 info: label: Loops OpenAPI Spec — Campaigns description: 'Loops OpenAPI Spec — Campaigns. 4 operations. Lead operation: List campaigns. Self-contained Naftiko capability covering one Loops business surface.' tags: - Loops - Campaigns created: '2026-05-19' modified: '2026-05-19' binds: - namespace: env keys: LOOPS_API_KEY: LOOPS_API_KEY capability: consumes: - type: http namespace: loops-campaigns baseUri: https://app.loops.so/api/v1 description: Loops OpenAPI Spec — Campaigns business capability. Self-contained, no shared references. resources: - name: campaigns path: /campaigns operations: - name: get method: GET description: List campaigns outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: perPage in: query type: string description: How many results to return in each request. Must be between 10 and 50. Default is 20. - name: cursor in: query type: string description: A cursor to return a specific page of results. Cursors can be found from the `pagination.nextCursor` value in each response. - name: post method: POST description: Create a campaign outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: body in: body type: object description: Request body (JSON). required: true - name: campaigns-campaignId path: /campaigns/{campaignId} operations: - name: get method: GET description: Get a campaign outputRawFormat: json outputParameters: - name: result type: object value: $. - name: post method: POST description: Update a campaign outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: body in: body type: object description: Request body (JSON). required: true authentication: type: bearer token: '{{env.LOOPS_API_KEY}}' exposes: - type: rest namespace: loops-campaigns-rest port: 8080 description: REST adapter for Loops OpenAPI Spec — Campaigns. One Spectral-compliant resource per consumed operation, prefixed with /v1. resources: - path: /v1/campaigns name: campaigns description: REST surface for campaigns. operations: - method: GET name: get description: List campaigns call: loops-campaigns.get with: perPage: rest.perPage cursor: rest.cursor outputParameters: - type: object mapping: $. - method: POST name: post description: Create a campaign call: loops-campaigns.post with: body: rest.body outputParameters: - type: object mapping: $. - path: /v1/campaigns/{campaignid} name: campaigns-campaignid description: REST surface for campaigns-campaignId. operations: - method: GET name: get description: Get a campaign call: loops-campaigns.get outputParameters: - type: object mapping: $. - method: POST name: post description: Update a campaign call: loops-campaigns.post with: body: rest.body outputParameters: - type: object mapping: $. - type: mcp namespace: loops-campaigns-mcp port: 9090 transport: http description: MCP adapter for Loops OpenAPI Spec — Campaigns. One tool per consumed operation, routed inline through this capability's consumes block. tools: - name: list-campaigns description: List campaigns hints: readOnly: true destructive: false idempotent: true call: loops-campaigns.get with: perPage: tools.perPage cursor: tools.cursor outputParameters: - type: object mapping: $. - name: create-campaign description: Create a campaign hints: readOnly: false destructive: false idempotent: false call: loops-campaigns.post with: body: tools.body outputParameters: - type: object mapping: $. - name: get-campaign description: Get a campaign hints: readOnly: true destructive: false idempotent: true call: loops-campaigns.get outputParameters: - type: object mapping: $. - name: update-campaign description: Update a campaign hints: readOnly: false destructive: false idempotent: false call: loops-campaigns.post with: body: tools.body outputParameters: - type: object mapping: $.