package gapi-ocaml

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
module Corpus : sig ... end
val copy : ?base_url:string -> ?std_params:GapiService.StandardParameters.t -> ?custom_headers:GapiCore.Header.t list -> ?enforceSingleParent:bool -> ?ignoreDefaultVisibility:bool -> ?keepRevisionForever:bool -> ?supportsAllDrives:bool -> ?supportsTeamDrives:bool -> ?includePermissionsForView:string -> ?ocrLanguage:string -> fileId:string -> GapiDriveV3Model.File.t -> GapiConversation.Session.t -> GapiDriveV3Model.File.t * GapiConversation.Session.t

Creates a copy of a file and applies any requested updates with patch semantics. Folders cannot be copied.

  • parameter base_url

    Service endpoint base URL (defaults to "https://www.googleapis.com/drive/v3/").

  • parameter std_params

    Optional standard parameters.

  • parameter custom_headers

    Optional HTTP custom headers.

  • parameter enforceSingleParent

    Deprecated. Copying files into multiple folders is no longer supported. Use shortcuts instead.

  • parameter ignoreDefaultVisibility

    Whether to ignore the domain's default visibility settings for the created file. Domain administrators can choose to make all uploaded files visible to the domain by default; this parameter bypasses that behavior for the request. Permissions are still inherited from parent folders.

  • parameter keepRevisionForever

    Whether to set the 'keepForever' field in the new head revision. This is only applicable to files with binary content in Google Drive. Only 200 revisions for the file can be kept forever. If the limit is reached, try deleting pinned revisions.

  • parameter supportsAllDrives

    Whether the requesting application supports both My Drives and shared drives.

  • parameter supportsTeamDrives

    Deprecated use supportsAllDrives instead.

  • parameter includePermissionsForView

    Specifies which additional view's permissions to include in the response. Only 'published' is supported.

  • parameter ocrLanguage

    A language hint for OCR processing during image import (ISO 639-1 code).

  • parameter fileId

    The ID of the file.

val create : ?base_url:string -> ?std_params:GapiService.StandardParameters.t -> ?media_source:GapiMediaResource.t -> ?custom_headers:GapiCore.Header.t list -> ?enforceSingleParent:bool -> ?ignoreDefaultVisibility:bool -> ?keepRevisionForever:bool -> ?supportsAllDrives:bool -> ?supportsTeamDrives:bool -> ?useContentAsIndexableText:bool -> ?includePermissionsForView:string -> ?ocrLanguage:string -> GapiDriveV3Model.File.t -> GapiConversation.Session.t -> GapiDriveV3Model.File.t * GapiConversation.Session.t

Creates a new file.

  • parameter base_url

    Service endpoint base URL (defaults to "https://www.googleapis.com/drive/v3/").

  • parameter std_params

    Optional standard parameters.

  • parameter custom_headers

    Optional HTTP custom headers.

  • parameter enforceSingleParent

    Deprecated. Creating files in multiple folders is no longer supported.

  • parameter ignoreDefaultVisibility

    Whether to ignore the domain's default visibility settings for the created file. Domain administrators can choose to make all uploaded files visible to the domain by default; this parameter bypasses that behavior for the request. Permissions are still inherited from parent folders.

  • parameter keepRevisionForever

    Whether to set the 'keepForever' field in the new head revision. This is only applicable to files with binary content in Google Drive. Only 200 revisions for the file can be kept forever. If the limit is reached, try deleting pinned revisions.

  • parameter supportsAllDrives

    Whether the requesting application supports both My Drives and shared drives.

  • parameter supportsTeamDrives

    Deprecated use supportsAllDrives instead.

  • parameter useContentAsIndexableText

    Whether to use the uploaded content as indexable text.

  • parameter includePermissionsForView

    Specifies which additional view's permissions to include in the response. Only 'published' is supported.

  • parameter ocrLanguage

    A language hint for OCR processing during image import (ISO 639-1 code).

val delete : ?base_url:string -> ?std_params:GapiService.StandardParameters.t -> ?custom_headers:GapiCore.Header.t list -> ?enforceSingleParent:bool -> ?supportsAllDrives:bool -> ?supportsTeamDrives:bool -> fileId:string -> GapiConversation.Session.t -> unit * GapiConversation.Session.t

Permanently deletes a file owned by the user without moving it to the trash. If the file belongs to a shared drive the user must be an organizer on the parent. If the target is a folder, all descendants owned by the user are also deleted.

  • parameter base_url

    Service endpoint base URL (defaults to "https://www.googleapis.com/drive/v3/").

  • parameter std_params

    Optional standard parameters.

  • parameter custom_headers

    Optional HTTP custom headers.

  • parameter enforceSingleParent

    Deprecated. If an item is not in a shared drive and its last parent is deleted but the item itself is not, the item will be placed under its owner's root.

  • parameter supportsAllDrives

    Whether the requesting application supports both My Drives and shared drives.

  • parameter supportsTeamDrives

    Deprecated use supportsAllDrives instead.

  • parameter fileId

    The ID of the file.

val emptyTrash : ?base_url:string -> ?std_params:GapiService.StandardParameters.t -> ?custom_headers:GapiCore.Header.t list -> ?enforceSingleParent:bool -> GapiConversation.Session.t -> unit * GapiConversation.Session.t

Permanently deletes all of the user's trashed files.

  • parameter base_url

    Service endpoint base URL (defaults to "https://www.googleapis.com/drive/v3/").

  • parameter std_params

    Optional standard parameters.

  • parameter custom_headers

    Optional HTTP custom headers.

  • parameter enforceSingleParent

    Deprecated. If an item is not in a shared drive and its last parent is deleted but the item itself is not, the item will be placed under its owner's root.

val export : ?base_url:string -> ?std_params:GapiService.StandardParameters.t -> ?media_download:GapiMediaResource.download -> ?custom_headers:GapiCore.Header.t list -> fileId:string -> mimeType:string -> GapiConversation.Session.t -> unit * GapiConversation.Session.t

Exports a Google Doc to the requested MIME type and returns the exported content. Please note that the exported content is limited to 10MB.

If std_params includes setting alt="media", the file content is downloaded as per media_download.

  • parameter base_url

    Service endpoint base URL (defaults to "https://www.googleapis.com/drive/v3/").

  • parameter std_params

    Optional standard parameters.

  • parameter media_download

    Location where the content will be saved.

  • parameter custom_headers

    Optional HTTP custom headers.

  • parameter fileId

    The ID of the file.

  • parameter mimeType

    The MIME type of the format requested for this export.

val generateIds : ?base_url:string -> ?std_params:GapiService.StandardParameters.t -> ?custom_headers:GapiCore.Header.t list -> ?count:int -> ?space:string -> ?_type:string -> GapiConversation.Session.t -> GapiDriveV3Model.GeneratedIds.t * GapiConversation.Session.t

Generates a set of file IDs which can be provided in create or copy requests.

  • parameter base_url

    Service endpoint base URL (defaults to "https://www.googleapis.com/drive/v3/").

  • parameter std_params

    Optional standard parameters.

  • parameter custom_headers

    Optional HTTP custom headers.

  • parameter count

    The number of IDs to return.

  • parameter space

    The space in which the IDs can be used to create new files. Supported values are 'drive' and 'appDataFolder'. (Default: 'drive')

  • parameter _type

    The type of items which the IDs can be used for. Supported values are 'files' and 'shortcuts'. Note that 'shortcuts' are only supported in the drive 'space'. (Default: 'files')

val get : ?base_url:string -> ?etag:string -> ?std_params:GapiService.StandardParameters.t -> ?media_download:GapiMediaResource.download -> ?custom_headers:GapiCore.Header.t list -> ?acknowledgeAbuse:bool -> ?supportsAllDrives:bool -> ?supportsTeamDrives:bool -> ?includePermissionsForView:string -> fileId:string -> GapiConversation.Session.t -> GapiDriveV3Model.File.t * GapiConversation.Session.t

Gets a file's metadata or content by ID.

If std_params includes setting alt="media", the file content is downloaded as per media_download.

  • parameter base_url

    Service endpoint base URL (defaults to "https://www.googleapis.com/drive/v3/").

  • parameter etag

    Optional ETag.

  • parameter std_params

    Optional standard parameters.

  • parameter media_download

    Location where the content will be saved.

  • parameter custom_headers

    Optional HTTP custom headers.

  • parameter acknowledgeAbuse

    Whether the user is acknowledging the risk of downloading known malware or other abusive files. This is only applicable when alt=media.

  • parameter supportsAllDrives

    Whether the requesting application supports both My Drives and shared drives.

  • parameter supportsTeamDrives

    Deprecated use supportsAllDrives instead.

  • parameter includePermissionsForView

    Specifies which additional view's permissions to include in the response. Only 'published' is supported.

  • parameter fileId

    The ID of the file.

val list : ?base_url:string -> ?std_params:GapiService.StandardParameters.t -> ?custom_headers:GapiCore.Header.t list -> ?includeItemsFromAllDrives:bool -> ?includeTeamDriveItems:bool -> ?pageSize:int -> ?spaces:string -> ?supportsAllDrives:bool -> ?supportsTeamDrives:bool -> ?corpora:string -> ?corpus:Corpus.t -> ?driveId:string -> ?includePermissionsForView:string -> ?orderBy:string -> ?pageToken:string -> ?q:string -> ?teamDriveId:string -> GapiConversation.Session.t -> GapiDriveV3Model.FileList.t * GapiConversation.Session.t

Lists or searches files.

  • parameter base_url

    Service endpoint base URL (defaults to "https://www.googleapis.com/drive/v3/").

  • parameter std_params

    Optional standard parameters.

  • parameter custom_headers

    Optional HTTP custom headers.

  • parameter includeItemsFromAllDrives

    Whether both My Drive and shared drive items should be included in results.

  • parameter includeTeamDriveItems

    Deprecated use includeItemsFromAllDrives instead.

  • parameter pageSize

    The maximum number of files to return per page. Partial or empty result pages are possible even before the end of the files list has been reached.

  • parameter spaces

    A comma-separated list of spaces to query within the corpus. Supported values are 'drive' and 'appDataFolder'.

  • parameter supportsAllDrives

    Whether the requesting application supports both My Drives and shared drives.

  • parameter supportsTeamDrives

    Deprecated use supportsAllDrives instead.

  • parameter corpora

    Groupings of files to which the query applies. Supported groupings are: 'user' (files created by, opened by, or shared directly with the user), 'drive' (files in the specified shared drive as indicated by the 'driveId'), 'domain' (files shared to the user's domain), and 'allDrives' (A combination of 'user' and 'drive' for all drives where the user is a member). When able, use 'user' or 'drive', instead of 'allDrives', for efficiency.

  • parameter corpus

    The source of files to list. Deprecated: use 'corpora' instead.

  • parameter driveId

    ID of the shared drive to search.

  • parameter includePermissionsForView

    Specifies which additional view's permissions to include in the response. Only 'published' is supported.

  • parameter orderBy

    A comma-separated list of sort keys. Valid keys are 'createdTime', 'folder', 'modifiedByMeTime', 'modifiedTime', 'name', 'name_natural', 'quotaBytesUsed', 'recency', 'sharedWithMeTime', 'starred', and 'viewedByMeTime'. Each key sorts ascending by default, but may be reversed with the 'desc' modifier. Example usage: ?orderBy=folder,modifiedTime desc,name. Please note that there is a current limitation for users with approximately one million files in which the requested sort order is ignored.

  • parameter pageToken

    The token for continuing a previous list request on the next page. This should be set to the value of 'nextPageToken' from the previous response.

  • parameter q

    A query for filtering the file results. See the "Search for Files" guide for supported syntax.

  • parameter teamDriveId

    Deprecated use driveId instead.

val update : ?base_url:string -> ?std_params:GapiService.StandardParameters.t -> ?media_source:GapiMediaResource.t -> ?custom_headers:GapiCore.Header.t list -> ?enforceSingleParent:bool -> ?keepRevisionForever:bool -> ?supportsAllDrives:bool -> ?supportsTeamDrives:bool -> ?useContentAsIndexableText:bool -> ?addParents:string -> ?includePermissionsForView:string -> ?ocrLanguage:string -> ?removeParents:string -> fileId:string -> GapiDriveV3Model.File.t -> GapiConversation.Session.t -> GapiDriveV3Model.File.t * GapiConversation.Session.t

Updates a file's metadata and/or content. This method supports patch semantics.

  • parameter base_url

    Service endpoint base URL (defaults to "https://www.googleapis.com/drive/v3/").

  • parameter std_params

    Optional standard parameters.

  • parameter custom_headers

    Optional HTTP custom headers.

  • parameter enforceSingleParent

    Deprecated. Adding files to multiple folders is no longer supported. Use shortcuts instead.

  • parameter keepRevisionForever

    Whether to set the 'keepForever' field in the new head revision. This is only applicable to files with binary content in Google Drive. Only 200 revisions for the file can be kept forever. If the limit is reached, try deleting pinned revisions.

  • parameter supportsAllDrives

    Whether the requesting application supports both My Drives and shared drives.

  • parameter supportsTeamDrives

    Deprecated use supportsAllDrives instead.

  • parameter useContentAsIndexableText

    Whether to use the uploaded content as indexable text.

  • parameter addParents

    A comma-separated list of parent IDs to add.

  • parameter includePermissionsForView

    Specifies which additional view's permissions to include in the response. Only 'published' is supported.

  • parameter ocrLanguage

    A language hint for OCR processing during image import (ISO 639-1 code).

  • parameter removeParents

    A comma-separated list of parent IDs to remove.

  • parameter fileId

    The ID of the file.

val watch : ?base_url:string -> ?std_params:GapiService.StandardParameters.t -> ?media_download:GapiMediaResource.download -> ?custom_headers:GapiCore.Header.t list -> ?acknowledgeAbuse:bool -> ?supportsAllDrives:bool -> ?supportsTeamDrives:bool -> ?includePermissionsForView:string -> fileId:string -> GapiDriveV3Model.Channel.t -> GapiConversation.Session.t -> GapiDriveV3Model.Channel.t * GapiConversation.Session.t

Subscribes to changes to a file

If std_params includes setting alt="media", the file content is downloaded as per media_download.

  • parameter base_url

    Service endpoint base URL (defaults to "https://www.googleapis.com/drive/v3/").

  • parameter std_params

    Optional standard parameters.

  • parameter media_download

    Location where the content will be saved.

  • parameter custom_headers

    Optional HTTP custom headers.

  • parameter acknowledgeAbuse

    Whether the user is acknowledging the risk of downloading known malware or other abusive files. This is only applicable when alt=media.

  • parameter supportsAllDrives

    Whether the requesting application supports both My Drives and shared drives.

  • parameter supportsTeamDrives

    Deprecated use supportsAllDrives instead.

  • parameter includePermissionsForView

    Specifies which additional view's permissions to include in the response. Only 'published' is supported.

  • parameter fileId

    The ID of the file.

OCaml

Innovation. Community. Security.