Get files

veryfront__get_files

Requires project.files.read.

Access

No external-service connection is required. Use a Veryfront credential with access to the requested resources.

Call type: Read-only.

Arguments

FieldTypeRequiredDescription and constraints
refstringNoContent to read: main, branch:<name-or-id>, release:<version> or env:<name>. Omit for main.
pathsstring[]YesExact file paths to read, at most 50. Results keep this order.
project_referencestringNoProject ID or slug (defaults to the current project)

Example request

Send this JSON-RPC request through an initialized MCP client. Replace sample identifiers and values before calling the tool. See MCP client setup.

json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "veryfront__get_files",
    "arguments": {
      "paths": [
        "example"
      ]
    }
  }
}

Result

The published output shape is summarized below. Inspect both the MCP response content and isError when handling a call.

FieldTypeRequiredDescription and constraints
dataobject[]YesPrimary result records returned by the tool.

Full schemas

json
{
  "type": "object",
  "properties": {
    "ref": {
      "type": "string",
      "description": "Content to read: main, branch:<name-or-id>, release:<version> or env:<name>. Omit for main."
    },
    "paths": {
      "type": "array",
      "items": {
        "type": "string",
        "minLength": 1,
        "maxLength": 1024,
        "description": "One path item supplied to the tool."
      },
      "minItems": 1,
      "maxItems": 50,
      "description": "Exact file paths to read, at most 50. Results keep this order."
    },
    "project_reference": {
      "type": "string",
      "description": "Project ID or slug (defaults to the current project)"
    }
  },
  "required": [
    "paths"
  ],
  "additionalProperties": false,
  "$schema": "http://json-schema.org/draft-07/schema#",
  "description": "Arguments for the get_files tool."
}
json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "path": {
            "type": "string",
            "description": "The requested path, or the stored path of the file it resolved to."
          },
          "found": {
            "type": "boolean",
            "description": "False for a path that names no file or a file the caller may not read."
          },
          "file": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "id": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "File ID, or null when the content source supplies none."
                  },
                  "version_id": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "Current version ID, or null when the content source supplies none."
                  },
                  "path": {
                    "type": "string",
                    "description": "Project-relative source path."
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "page",
                      "function",
                      "component",
                      "file"
                    ],
                    "description": "File kind: page, function, component or file."
                  },
                  "content": {
                    "type": "string",
                    "description": "Full text content."
                  },
                  "size_bytes": {
                    "type": "number",
                    "description": "Size of the content encoded as UTF-8, in bytes."
                  },
                  "binary": {
                    "type": "object",
                    "properties": {
                      "content_hash": {
                        "type": "string",
                        "pattern": "^[a-f0-9]{64}$"
                      },
                      "byte_size": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 8388608
                      },
                      "content_type": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 200,
                        "pattern": "^[\\x20-\\x7e]+$"
                      }
                    },
                    "required": [
                      "content_hash",
                      "byte_size",
                      "content_type"
                    ],
                    "additionalProperties": false
                  },
                  "checksum": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "SHA-256 content hash, or null when unavailable."
                  },
                  "updated_at": {
                    "type": "string",
                    "description": "Last content update time, RFC 3339."
                  }
                },
                "required": [
                  "id",
                  "version_id",
                  "path",
                  "type",
                  "content",
                  "size_bytes",
                  "checksum",
                  "updated_at"
                ],
                "additionalProperties": false,
                "description": "Structured file details associated with this tool result."
              },
              {
                "type": "null",
                "description": "The file returned by the tool."
              }
            ],
            "description": "The file, or null when found is false."
          },
          "error": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "const": "internal",
                    "description": "Always internal: the read of this path failed."
                  },
                  "message": {
                    "type": "string",
                    "description": "Why the read of this path failed."
                  }
                },
                "required": [
                  "code",
                  "message"
                ],
                "additionalProperties": false,
                "description": "Error details returned by the tool."
              },
              {
                "type": "null",
                "description": "Error details returned by the tool."
              }
            ],
            "description": "Set only when the read of this path failed; null for a missing or restricted path."
          }
        },
        "required": [
          "path",
          "found",
          "file",
          "error"
        ],
        "additionalProperties": false
      },
      "description": "Primary result records returned by the tool."
    }
  },
  "required": [
    "data"
  ],
  "additionalProperties": false,
  "description": "Structured result returned by the get_files tool.",
  "$schema": "http://json-schema.org/draft-07/schema#"
}