naftiko: 1.0.0-alpha2 info: label: Figma REST API — Files description: 'Figma REST API — Files. 5 operations. Lead operation: Figma Get File. Self-contained Naftiko capability covering one Figma business surface.' tags: - Figma - Files created: '2026-05-19' modified: '2026-05-19' binds: - namespace: env keys: FIGMA_API_KEY: FIGMA_API_KEY capability: consumes: - type: http namespace: rest-files baseUri: https://api.figma.com description: Figma REST API — Files business capability. Self-contained, no shared references. resources: - name: v1-files-file_key path: /v1/files/{file_key} operations: - name: getfile method: GET description: Figma Get File outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: version in: query type: string description: A specific version ID to get. Omitting this will get the current version. - name: ids in: query type: string description: Comma-separated list of nodes that you want to receive. If not set, all nodes are returned. - name: depth in: query type: integer description: Positive integer representing how deep into the document tree to traverse. For example, setting depth=1 returns only pages. - name: geometry in: query type: string description: Set to "paths" to export vector data. - name: plugin_data in: query type: string description: Comma-separated list of plugin IDs or the string "shared" for data present in all plugins. - name: branch_data in: query type: boolean description: Set to true to include branch metadata in the response. - name: v1-files-file_key-image_fills path: /v1/files/{file_key}/image_fills operations: - name: getimagefills method: GET description: Figma Get Image Fills outputRawFormat: json outputParameters: - name: result type: object value: $. - name: v1-files-file_key-nodes path: /v1/files/{file_key}/nodes operations: - name: getfilenodes method: GET description: Figma Get File Nodes outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: ids in: query type: string description: Comma-separated list of node IDs to retrieve. required: true - name: version in: query type: string description: A specific version ID to get. - name: depth in: query type: integer description: Positive integer for how deep into the node tree to traverse. - name: geometry in: query type: string description: Set to "paths" to export vector data. - name: plugin_data in: query type: string description: Comma-separated list of plugin IDs or "shared". - name: v1-files-file_key-versions path: /v1/files/{file_key}/versions operations: - name: getfileversions method: GET description: Figma Get File Version History outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: page_size in: query type: integer description: Number of items to return per page. Defaults to 30. - name: before in: query type: string description: Version ID before which to start listing versions. Used for pagination. - name: after in: query type: string description: Version ID after which to start listing versions. Used for pagination. - name: v1-images-file_key path: /v1/images/{file_key} operations: - name: getimages method: GET description: Figma Get Image Renders outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: ids in: query type: string description: Comma-separated list of node IDs to render. required: true - name: scale in: query type: number description: A number between 0.01 and 4, the image scaling factor. - name: format in: query type: string description: Image output format. - name: svg_include_id in: query type: boolean description: Whether to include id attributes for all SVG elements. - name: svg_simplify_stroke in: query type: boolean description: Whether to simplify inside/outside strokes and use stroke attribute. - name: use_absolute_bounds in: query type: boolean description: Use the full dimensions of the node regardless of cropping. - name: version in: query type: string description: A specific version ID to get. authentication: type: bearer token: '{{env.FIGMA_API_KEY}}' exposes: - type: rest namespace: rest-files-rest port: 8080 description: REST adapter for Figma REST API — Files. One Spectral-compliant resource per consumed operation, prefixed with /v1. resources: - path: /v1/v1/files/{file-key} name: v1-files-file-key description: REST surface for v1-files-file_key. operations: - method: GET name: getfile description: Figma Get File call: rest-files.getfile with: version: rest.version ids: rest.ids depth: rest.depth geometry: rest.geometry plugin_data: rest.plugin_data branch_data: rest.branch_data outputParameters: - type: object mapping: $. - path: /v1/v1/files/{file-key}/image-fills name: v1-files-file-key-image-fills description: REST surface for v1-files-file_key-image_fills. operations: - method: GET name: getimagefills description: Figma Get Image Fills call: rest-files.getimagefills outputParameters: - type: object mapping: $. - path: /v1/v1/files/{file-key}/nodes name: v1-files-file-key-nodes description: REST surface for v1-files-file_key-nodes. operations: - method: GET name: getfilenodes description: Figma Get File Nodes call: rest-files.getfilenodes with: ids: rest.ids version: rest.version depth: rest.depth geometry: rest.geometry plugin_data: rest.plugin_data outputParameters: - type: object mapping: $. - path: /v1/v1/files/{file-key}/versions name: v1-files-file-key-versions description: REST surface for v1-files-file_key-versions. operations: - method: GET name: getfileversions description: Figma Get File Version History call: rest-files.getfileversions with: page_size: rest.page_size before: rest.before after: rest.after outputParameters: - type: object mapping: $. - path: /v1/v1/images/{file-key} name: v1-images-file-key description: REST surface for v1-images-file_key. operations: - method: GET name: getimages description: Figma Get Image Renders call: rest-files.getimages with: ids: rest.ids scale: rest.scale format: rest.format svg_include_id: rest.svg_include_id svg_simplify_stroke: rest.svg_simplify_stroke use_absolute_bounds: rest.use_absolute_bounds version: rest.version outputParameters: - type: object mapping: $. - type: mcp namespace: rest-files-mcp port: 9090 transport: http description: MCP adapter for Figma REST API — Files. One tool per consumed operation, routed inline through this capability's consumes block. tools: - name: figma-get-file description: Figma Get File hints: readOnly: true destructive: false idempotent: true call: rest-files.getfile with: version: tools.version ids: tools.ids depth: tools.depth geometry: tools.geometry plugin_data: tools.plugin_data branch_data: tools.branch_data outputParameters: - type: object mapping: $. - name: figma-get-image-fills description: Figma Get Image Fills hints: readOnly: true destructive: false idempotent: true call: rest-files.getimagefills outputParameters: - type: object mapping: $. - name: figma-get-file-nodes description: Figma Get File Nodes hints: readOnly: true destructive: false idempotent: true call: rest-files.getfilenodes with: ids: tools.ids version: tools.version depth: tools.depth geometry: tools.geometry plugin_data: tools.plugin_data outputParameters: - type: object mapping: $. - name: figma-get-file-version-history description: Figma Get File Version History hints: readOnly: true destructive: false idempotent: true call: rest-files.getfileversions with: page_size: tools.page_size before: tools.before after: tools.after outputParameters: - type: object mapping: $. - name: figma-get-image-renders description: Figma Get Image Renders hints: readOnly: true destructive: false idempotent: true call: rest-files.getimages with: ids: tools.ids scale: tools.scale format: tools.format svg_include_id: tools.svg_include_id svg_simplify_stroke: tools.svg_simplify_stroke use_absolute_bounds: tools.use_absolute_bounds version: tools.version outputParameters: - type: object mapping: $.