MCP Tools Reference: drivemcp.googleapis.com

Tool: download_file_content

Call this tool to download the content of a Drive file as raw binary data (bytes).

If the file is a Google Drive first-party mime type, the exportMimeType field is required and will determine the format of the downloaded file.

If the file is not found, try using other tools like search_files to find the file the user is requesting.

If the user wants a natural language representation of their Drive content, use the read_file_content tool ( read_file_content should be smaller and easier to parse).

The following sample demonstrate how to use curl to invoke the download_file_content MCP tool.

Curl Request
curl  
--location  
 'https://drivemcp.googleapis.com/mcp' 
  
 \ 
--header  
 'content-type: application/json' 
  
 \ 
--header  
 'accept: application/json, text/event-stream' 
  
 \ 
--data  
 '{ 
 "method": "tools/call", 
 "params": { 
 "name": "download_file_content", 
 "arguments": { 
 // provide these details according to the tool MCP specification 
 } 
 }, 
 "jsonrpc": "2.0", 
 "id": 1 
 }' 
  

Input Schema

Defines a request to download a file's content.

DownloadFileRequest

JSON representation
 { 
 "fileId" 
 : 
 string 
 , 
 "exportMimeType" 
 : 
 string 
 } 
Fields
fileId

string

Required. The ID of the file to retrieve.

exportMimeType

string

Optional. For Google native files, the MIME type to export the file to, ignored otherwise. Defaults to text if not specified.

Output Schema

CallToolResponse

JSON representation
 { 
 "common" 
 : 
 { 
 object (  ResponseFields 
 
) 
 } 
 , 
 "content" 
 : 
 [ 
 { 
 object (  Content 
 
) 
 } 
 ] 
 , 
 "structuredContent" 
 : 
 { 
 object 
 } 
 , 
 "isError" 
 : 
 boolean 
 } 
Fields
common

object ( ResponseFields )

content[]

object ( Content )

structuredContent

object ( Struct format)

If the tool defines an output schema, this field will be populated. Clients that support structured output should ignore the content field above if this field is set.

isError

boolean

Optional.

ResponseFields

JSON representation
 { 
 "instructions" 
 : 
 string 
 , 
 "metadata" 
 : 
 { 
 object 
 } 
 , 
 "dependentRequests" 
 : 
 { 
 string 
 : 
 { 
 object (  ServerInitiatedRequest 
 
) 
 } 
 , 
 ... 
 } 
 , 
 "resumeData" 
 : 
 { 
 object 
 } 
 } 
Fields
instructions

string

Optional. Sent only on the initial response on any RPC.

metadata

object ( Struct format)

Escape hatch for arbitrary side-channel data.

dependentRequests

map (key: string, value: object ( ServerInitiatedRequest ))

Dependent requests. The presence of this field tells the client that the request is incomplete and that the client must try its request again with the result of these dependent requests in the dependent_responses field.

An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" } .

resumeData

object ( Struct format)

State for the client to echo back in subsequent RPCs for the same peristant request.

Struct

JSON representation
 { 
 "fields" 
 : 
 { 
 string 
 : 
 value 
 , 
 ... 
 } 
 } 
Fields
fields

map (key: string, value: value ( Value format))

Unordered map of dynamically typed values.

An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" } .

FieldsEntry

JSON representation
 { 
 "key" 
 : 
 string 
 , 
 "value" 
 : 
 value 
 } 
Fields
key

string

value

value ( Value format)

Value

JSON representation
 { 
 "nullValue" 
 : 
 null 
 , 
 "numberValue" 
 : 
 number 
 , 
 "stringValue" 
 : 
 string 
 , 
 "boolValue" 
 : 
 boolean 
 , 
 "structValue" 
 : 
 { 
 object 
 } 
 , 
 "listValue" 
 : 
 array 
 } 
Fields
Union field kind . The kind of value. kind can be only one of the following:
nullValue

null

Represents a JSON null .

numberValue

number

Represents a JSON number. Must not be NaN , Infinity or -Infinity , since those are not supported in JSON. This also cannot represent large Int64 values, since JSON format generally does not support them in its number type.

stringValue

string

Represents a JSON string.

boolValue

boolean

Represents a JSON boolean ( true or false literal in JSON).

structValue

object ( Struct format)

Represents a JSON object.

listValue

array ( ListValue format)

Represents a JSON array.

ListValue

JSON representation
 { 
 "values" 
 : 
 [ 
 value 
 ] 
 } 
Fields
values[]

value ( Value format)

Repeated field of dynamically typed values.

DependentRequestsEntry

JSON representation
 { 
 "key" 
 : 
 string 
 , 
 "value" 
 : 
 { 
 object (  ServerInitiatedRequest 
 
) 
 } 
 } 
Fields
key

string

value

object ( ServerInitiatedRequest )

ServerInitiatedRequest

JSON representation
 { 
 "samplingCreateMessage" 
 : 
 { 
 object (  SamplingCreateMessageRequest 
 
) 
 } 
 , 
 "listRootsRequest" 
 : 
 { 
 object ( ListRootsRequest 
) 
 } 
 , 
 "notifyOnRootListUpdate" 
 : 
 boolean 
 , 
 "elicitRequest" 
 : 
 { 
 object (  ElicitRequest 
 
) 
 } 
 } 
Fields
samplingCreateMessage

object ( SamplingCreateMessageRequest )

Sampling, as per https://modelcontextprotocol.io/specification/2025-03-26/client/sampling .

listRootsRequest

object ( ListRootsRequest )

Root list request, as per https://modelcontextprotocol.io/specification/2025-03-26/client/roots .

notifyOnRootListUpdate

boolean

elicitRequest

object ( ElicitRequest )

Elicitations, as per https://modelcontextprotocol.io/specification/2025-06-18/client/elicitation .

SamplingCreateMessageRequest

JSON representation
 { 
 "messages" 
 : 
 [ 
 { 
 object (  SamplingMessage 
 
) 
 } 
 ] 
 , 
 "modelPreferences" 
 : 
 { 
 object (  ModelPreferences 
 
) 
 } 
 , 
 "systemPrompt" 
 : 
 string 
 , 
 "includeContext" 
 : 
 enum ( IncludeContext 
) 
 , 
 "temperature" 
 : 
 number 
 , 
 "maxTokens" 
 : 
 integer 
 , 
 "stopSequence" 
 : 
 [ 
 string 
 ] 
 } 
Fields
messages[]

object ( SamplingMessage )

modelPreferences

object ( ModelPreferences )

Optional.

systemPrompt

string

Optional.

includeContext

enum ( IncludeContext )

Optional.

temperature

number

Optional.

maxTokens

integer

Optional.

stopSequence[]

string

Optional.

SamplingMessage

JSON representation
 { 
 "role" 
 : 
 enum ( Role 
) 
 , 
 "text" 
 : 
 { 
 object (  TextContent 
 
) 
 } 
 , 
 "image" 
 : 
 { 
 object (  ImageContent 
 
) 
 } 
 , 
 "audio" 
 : 
 { 
 object (  AudioContent 
 
) 
 } 
 } 
Fields
role

enum ( Role )

Which role is sending the message.

text

object ( TextContent )

Exactly one of these fields must be populated. (Not using "oneof", since that causes forward-compatibility problems.)

image

object ( ImageContent )

audio

object ( AudioContent )

TextContent

JSON representation
 { 
 "text" 
 : 
 string 
 , 
 "annotations" 
 : 
 { 
 object (  Annotations 
 
) 
 } 
 } 
Fields
text

string

annotations

object ( Annotations )

Optional.

Annotations

JSON representation
 { 
 "audience" 
 : 
 [ 
 enum ( Role 
) 
 ] 
 , 
 "priority" 
 : 
 number 
 } 
Fields
audience[]

enum ( Role )

priority

number

Must be in range [0,1].

ImageContent

JSON representation
 { 
 "data" 
 : 
 string 
 , 
 "mimeType" 
 : 
 string 
 , 
 "annotations" 
 : 
 { 
 object (  Annotations 
 
) 
 } 
 } 
Fields
data

string ( bytes format)

A base64-encoded string.

mimeType

string

annotations

object ( Annotations )

Optional.

AudioContent

JSON representation
 { 
 "data" 
 : 
 string 
 , 
 "mimeType" 
 : 
 string 
 , 
 "annotations" 
 : 
 { 
 object (  Annotations 
 
) 
 } 
 } 
Fields
data

string ( bytes format)

A base64-encoded string.

mimeType

string

annotations

object ( Annotations )

Optional.

ModelPreferences

JSON representation
 { 
 "hints" 
 : 
 [ 
 { 
 object (  ModelHint 
 
) 
 } 
 ] 
 , 
 "intelligencePriority" 
 : 
 number 
 , 
 "speedPriority" 
 : 
 number 
 , 
 "costPriority" 
 : 
 number 
 } 
Fields
hints[]

object ( ModelHint )

intelligencePriority

number

speedPriority

number

costPriority

number

ModelHint

JSON representation
 { 
 "name" 
 : 
 string 
 } 
Fields
name

string

Optional.

ElicitRequest

JSON representation
 { 
 "message" 
 : 
 string 
 , 
 "requestedSchema" 
 : 
 { 
 string 
 : 
 { 
 object (  PrimitiveSchemaDefinition 
 
) 
 } 
 , 
 ... 
 } 
 , 
 "requiredFields" 
 : 
 [ 
 string 
 ] 
 } 
Fields
message

string

Message to present to user. Required.

requestedSchema

map (key: string, value: object ( PrimitiveSchemaDefinition ))

An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" } .

requiredFields[]

string

RequestedSchemaEntry

JSON representation
 { 
 "key" 
 : 
 string 
 , 
 "value" 
 : 
 { 
 object (  PrimitiveSchemaDefinition 
 
) 
 } 
 } 
Fields
key

string

value

object ( PrimitiveSchemaDefinition )

PrimitiveSchemaDefinition

JSON representation
 { 
 "stringSchema" 
 : 
 { 
 object (  StringSchema 
 
) 
 } 
 , 
 "numberSchema" 
 : 
 { 
 object (  NumberSchema 
 
) 
 } 
 , 
 "booleanSchema" 
 : 
 { 
 object (  BooleanSchema 
 
) 
 } 
 , 
 "enumSchema" 
 : 
 { 
 object (  EnumSchema 
 
) 
 } 
 } 
Fields
stringSchema

object ( StringSchema )

Exactly one of these fields will be present. (Not using "oneof", since that causes forward-compatibility problems.)

numberSchema

object ( NumberSchema )

booleanSchema

object ( BooleanSchema )

enumSchema

object ( EnumSchema )

StringSchema

JSON representation
 { 
 "title" 
 : 
 string 
 , 
 "description" 
 : 
 string 
 , 
 "minLength" 
 : 
 string 
 , 
 "maxLength" 
 : 
 string 
 , 
 "format" 
 : 
 enum ( Format 
) 
 } 
Fields
title

string

description

string

minLength

string

maxLength

string

format

enum ( Format )

NumberSchema

JSON representation
 { 
 "title" 
 : 
 string 
 , 
 "description" 
 : 
 string 
 , 
 "minimum" 
 : 
 string 
 , 
 "maximum" 
 : 
 string 
 } 
Fields
title

string

description

string

minimum

string

maximum

string

BooleanSchema

JSON representation
 { 
 "title" 
 : 
 string 
 , 
 "description" 
 : 
 string 
 , 
 "default" 
 : 
 boolean 
 } 
Fields
title

string

description

string

default

boolean

EnumSchema

JSON representation
 { 
 "title" 
 : 
 string 
 , 
 "description" 
 : 
 string 
 , 
 "enumList" 
 : 
 [ 
 string 
 ] 
 , 
 "enumNames" 
 : 
 [ 
 string 
 ] 
 } 
Fields
title

string

description

string

enumList[]

string

enumNames[]

string

Content

JSON representation
 { 
 "text" 
 : 
 { 
 object (  TextContent 
 
) 
 } 
 , 
 "image" 
 : 
 { 
 object (  ImageContent 
 
) 
 } 
 , 
 "audio" 
 : 
 { 
 object (  AudioContent 
 
) 
 } 
 , 
 "embeddedResource" 
 : 
 { 
 object (  EmbeddedResource 
 
) 
 } 
 , 
 "resourceLink" 
 : 
 { 
 object (  Resource 
 
) 
 } 
 } 
Fields
text

object ( TextContent )

Unstructured result contents. At least one will be populated if the tool does not define an output schema. If the tool does define an output schema, the structured_content field will be populated instead, but one of these fields may still be populated for backward compatibility.

No more than one of these fields must be populated. (Not using "oneof", since that causes forward-compatibility problems.)

image

object ( ImageContent )

audio

object ( AudioContent )

embeddedResource

object ( EmbeddedResource )

resourceLink

object ( Resource )

EmbeddedResource

JSON representation
 { 
 "contents" 
 : 
 { 
 object (  ResourceContents 
 
) 
 } 
 , 
 "annotations" 
 : 
 { 
 object (  Annotations 
 
) 
 } 
 } 
Fields
contents

object ( ResourceContents )

annotations

object ( Annotations )

Optional.

ResourceContents

JSON representation
 { 
 "uri" 
 : 
 string 
 , 
 "mimeType" 
 : 
 string 
 , 
 "text" 
 : 
 string 
 , 
 "blob" 
 : 
 string 
 } 
Fields
uri

string

mimeType

string

text

string

Exactly one of these fields must be populated. (Not using "oneof", since that causes forward-compatibility problems.)

blob

string ( bytes format)

A base64-encoded string.

Resource

JSON representation
 { 
 "uri" 
 : 
 string 
 , 
 "name" 
 : 
 string 
 , 
 "title" 
 : 
 string 
 , 
 "description" 
 : 
 string 
 , 
 "mimeType" 
 : 
 string 
 , 
 "annotations" 
 : 
 { 
 object (  Annotations 
 
) 
 } 
 , 
 "size" 
 : 
 string 
 } 
Fields
uri

string

name

string

title

string

description

string

Optional.

mimeType

string

Optional.

annotations

object ( Annotations )

Optional.

size

string

Optional.

Tool Annotations

Destructive Hint: ❌ | Idempotent Hint: ✅ | Read Only Hint: ✅ | Open World Hint: ❌

Create a Mobile Website
View Site in Mobile | Classic
Share by: