blob: 9a1b5ab5f22632f8c532f94482e1ad07e8b976f5 [file] [edit]
<html><body>
<style>
body, h1, h2, h3, div, span, p, pre, a {
margin: 0;
padding: 0;
border: 0;
font-weight: inherit;
font-style: inherit;
font-size: 100%;
font-family: inherit;
vertical-align: baseline;
}
body {
font-size: 13px;
padding: 1em;
}
h1 {
font-size: 26px;
margin-bottom: 1em;
}
h2 {
font-size: 24px;
margin-bottom: 1em;
}
h3 {
font-size: 20px;
margin-bottom: 1em;
margin-top: 1em;
}
pre, code {
line-height: 1.5;
font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
}
pre {
margin-top: 0.5em;
}
h1, h2, h3, p {
font-family: Arial, sans serif;
}
h1, h2, h3 {
border-bottom: solid #CCC 1px;
}
.toc_element {
margin-top: 0.5em;
}
.firstline {
margin-left: 2 em;
}
.method {
margin-top: 1em;
border: solid 1px #CCC;
padding: 1em;
background: #EEE;
}
.details {
font-weight: bold;
font-size: 14px;
}
</style>
<h1><a href="deepreview_v1.html">Deep Review API</a> . <a href="deepreview_v1.media.html">media</a></h1>
<h2>Instance Methods</h2>
<p class="toc_element">
<code><a href="#close">close()</a></code></p>
<p class="firstline">Close httplib2 connections.</p>
<p class="toc_element">
<code><a href="#download">download(name, x__xgafv=None)</a></code></p>
<p class="firstline">Downloads the original document content (PDF binary) using media streaming. Pass `alt=media` as a query parameter to stream the binary PDF bytes. Without `alt=media`, a JSON response is returned.</p>
<p class="toc_element">
<code><a href="#download_media">download_media(name, x__xgafv=None)</a></code></p>
<p class="firstline">Downloads the original document content (PDF binary) using media streaming. Pass `alt=media` as a query parameter to stream the binary PDF bytes. Without `alt=media`, a JSON response is returned.</p>
<p class="toc_element">
<code><a href="#upload">upload(body=None, documentId=None, media_body=None, media_mime_type=None, requestId=None, x__xgafv=None)</a></code></p>
<p class="firstline">Creates a new Document resource and ingests the manuscript using media upload or Google Drive.</p>
<h3>Method Details</h3>
<div class="method">
<code class="details" id="close">close()</code>
<pre>Close httplib2 connections.</pre>
</div>
<div class="method">
<code class="details" id="download">download(name, x__xgafv=None)</code>
<pre>Downloads the original document content (PDF binary) using media streaming. Pass `alt=media` as a query parameter to stream the binary PDF bytes. Without `alt=media`, a JSON response is returned.
Args:
name: string, Required. The resource name of the document to download. (required)
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # Response message for downloading a Document&#x27;s raw content using media download.
}</pre>
</div>
<div class="method">
<code class="details" id="download_media">download_media(name, x__xgafv=None)</code>
<pre>Downloads the original document content (PDF binary) using media streaming. Pass `alt=media` as a query parameter to stream the binary PDF bytes. Without `alt=media`, a JSON response is returned.
Args:
name: string, Required. The resource name of the document to download. (required)
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
The media object as a string.
</pre>
</div>
<div class="method">
<code class="details" id="upload">upload(body=None, documentId=None, media_body=None, media_mime_type=None, requestId=None, x__xgafv=None)</code>
<pre>Creates a new Document resource and ingests the manuscript using media upload or Google Drive.
Args:
body: object, The request body.
The object takes the form of:
{ # A document uploaded for automated review. Documents are immutable post-creation; to review a new version, create a new Document.
&quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the document was initially created.
&quot;displayName&quot;: &quot;A String&quot;, # Optional. User-provided display title or filename for the document.
&quot;driveSource&quot;: { # Configuration for importing a document directly from Google Drive. # Optional. Reference to a Google Drive file to import.
&quot;fileId&quot;: &quot;A String&quot;, # Required. Immutable. The Google Drive file ID (e.g. &quot;1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgvE2upms&quot;). For Google Drive shortcuts, callers must pass the resolved target file&#x27;s `file_id` and `resource_key`.
&quot;resourceKey&quot;: &quot;A String&quot;, # Optional. Input only. Immutable. Resource key (`^[a-zA-Z0-9_-]{1,128}$`) required to access certain older link-shared Google Drive files returned by the Google Drive Picker (for shortcuts, pass the resolved target file&#x27;s resource key). Never persisted in database records or returned in Document resources (see companion field `resource_key_set`, AIP-147).
&quot;resourceKeySet&quot;: True or False, # Output only. Indicates whether a resource key was provided for this Drive source.
&quot;revisionId&quot;: &quot;A String&quot;, # Optional. Input only. Immutable. Importing a specific revision is not currently supported; non-empty values return INVALID_ARGUMENT.
},
&quot;latestReviewSummary&quot;: { # Lightweight summary of a Review execution run for display in Document views. # Output only. Summary of the most recent review run for this document, if any. Populated by `GetDocument` and `ListDocuments`; unset on the document returned by `CreateDocument`, which has no reviews yet.
&quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this review attempt was initiated.
&quot;review&quot;: &quot;A String&quot;, # Output only. Resource name of the Review.
&quot;state&quot;: &quot;A String&quot;, # Output only. Current review lifecycle state.
},
&quot;name&quot;: &quot;A String&quot;, # Identifier. Resource name in format `documents/{document}`.
}
documentId: string, Optional. The ID to use for the document, which will become the final component of the document&#x27;s resource name. If not provided, a unique server-generated UUID will be assigned.
media_body: string, The filename of the media request body, or an instance of a MediaUpload object.
media_mime_type: string, The MIME type of the media request body, or an instance of a MediaUpload object.
requestId: string, Optional. Idempotency identifier for network retry safety (AIP-155). Must be a valid UUID4 string.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A document uploaded for automated review. Documents are immutable post-creation; to review a new version, create a new Document.
&quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the document was initially created.
&quot;displayName&quot;: &quot;A String&quot;, # Optional. User-provided display title or filename for the document.
&quot;driveSource&quot;: { # Configuration for importing a document directly from Google Drive. # Optional. Reference to a Google Drive file to import.
&quot;fileId&quot;: &quot;A String&quot;, # Required. Immutable. The Google Drive file ID (e.g. &quot;1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgvE2upms&quot;). For Google Drive shortcuts, callers must pass the resolved target file&#x27;s `file_id` and `resource_key`.
&quot;resourceKey&quot;: &quot;A String&quot;, # Optional. Input only. Immutable. Resource key (`^[a-zA-Z0-9_-]{1,128}$`) required to access certain older link-shared Google Drive files returned by the Google Drive Picker (for shortcuts, pass the resolved target file&#x27;s resource key). Never persisted in database records or returned in Document resources (see companion field `resource_key_set`, AIP-147).
&quot;resourceKeySet&quot;: True or False, # Output only. Indicates whether a resource key was provided for this Drive source.
&quot;revisionId&quot;: &quot;A String&quot;, # Optional. Input only. Immutable. Importing a specific revision is not currently supported; non-empty values return INVALID_ARGUMENT.
},
&quot;latestReviewSummary&quot;: { # Lightweight summary of a Review execution run for display in Document views. # Output only. Summary of the most recent review run for this document, if any. Populated by `GetDocument` and `ListDocuments`; unset on the document returned by `CreateDocument`, which has no reviews yet.
&quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this review attempt was initiated.
&quot;review&quot;: &quot;A String&quot;, # Output only. Resource name of the Review.
&quot;state&quot;: &quot;A String&quot;, # Output only. Current review lifecycle state.
},
&quot;name&quot;: &quot;A String&quot;, # Identifier. Resource name in format `documents/{document}`.
}</pre>
</div>
</body></html>