naftiko: 1.0.0-alpha2 info: label: Civitai Site API — Vault description: 'Civitai Site API — Vault. Membership-tier model storage: query, toggle, and inspect the current user vault. Self-contained Naftiko capability.' tags: - Civitai - Vault - Storage created: '2026-05-25' modified: '2026-05-25' binds: - namespace: env keys: CIVITAI_API_KEY: CIVITAI_API_KEY capability: consumes: - type: http namespace: site-vault baseUri: https://civitai.com description: Civitai Site Vault. resources: - name: vault-get path: /api/v1/vault/get operations: - name: getvaultitem method: GET description: Get vault item for a model version. outputRawFormat: json outputParameters: - { name: result, type: object, value: $. } inputParameters: - { name: modelVersionId, in: query, type: integer, required: true } - name: vault-all path: /api/v1/vault/all operations: - name: getallvault method: GET description: Get all vault items. outputRawFormat: json outputParameters: - { name: result, type: object, value: $. } - name: vault-check path: /api/v1/vault/check-vault operations: - name: checkvault method: GET description: Check vault subscription and storage status. outputRawFormat: json outputParameters: - { name: result, type: object, value: $. } - name: vault-toggle path: /api/v1/vault/toggle-version operations: - name: togglevaultversion method: POST description: Toggle a model version in the vault. outputRawFormat: json outputParameters: - { name: result, type: object, value: $. } inputParameters: - { name: body, in: body, type: object, required: true } authentication: type: apikey key: Authorization value: 'Bearer {{env.CIVITAI_API_KEY}}' placement: header exposes: - type: rest namespace: site-vault-rest port: 8080 description: REST adapter for Civitai Vault. resources: - path: /v1/vault/get name: vault-get operations: - method: GET name: getvaultitem description: Get vault item. call: site-vault.getvaultitem with: { modelVersionId: rest.query.modelVersionId } outputParameters: [{ type: object, mapping: $. }] - path: /v1/vault/all name: vault-all operations: - method: GET name: getallvault description: Get all vault items. call: site-vault.getallvault outputParameters: [{ type: object, mapping: $. }] - path: /v1/vault/check-vault name: vault-check operations: - method: GET name: checkvault description: Check vault status. call: site-vault.checkvault outputParameters: [{ type: object, mapping: $. }] - path: /v1/vault/toggle-version name: vault-toggle operations: - method: POST name: togglevaultversion description: Toggle vault version. call: site-vault.togglevaultversion with: { body: rest.body } outputParameters: [{ type: object, mapping: $. }] - type: mcp namespace: site-vault-mcp port: 9090 transport: http description: MCP adapter for Civitai Vault. tools: - name: civitai-get-vault-item description: Get a vault item. hints: { readOnly: true, destructive: false, idempotent: true } call: site-vault.getvaultitem with: { modelVersionId: tools.modelVersionId } outputParameters: [{ type: object, mapping: $. }] - name: civitai-get-all-vault description: Get all vault items. hints: { readOnly: true, destructive: false, idempotent: true } call: site-vault.getallvault outputParameters: [{ type: object, mapping: $. }] - name: civitai-check-vault description: Check vault status. hints: { readOnly: true, destructive: false, idempotent: true } call: site-vault.checkvault outputParameters: [{ type: object, mapping: $. }] - name: civitai-toggle-vault-version description: Toggle a model version in the vault. hints: { readOnly: false, destructive: false, idempotent: false } call: site-vault.togglevaultversion with: { body: tools.body } outputParameters: [{ type: object, mapping: $. }]