Method: Aws::WorkDocs::Client#get_document

Defined in:
lib/aws-sdk-workdocs/client.rb

#get_document(params = {}) ⇒ Types::GetDocumentResponse

Retrieves details of a document.

Examples:

Request syntax with placeholder values


resp = client.get_document({
  authentication_token: "AuthenticationHeaderType",
  document_id: "ResourceIdType", # required
  include_custom_metadata: false,
})

Response structure


resp..id #=> String
resp..creator_id #=> String
resp..parent_folder_id #=> String
resp..created_timestamp #=> Time
resp..modified_timestamp #=> Time
resp...id #=> String
resp...name #=> String
resp...content_type #=> String
resp...size #=> Integer
resp...signature #=> String
resp...status #=> String, one of "INITIALIZED", "ACTIVE"
resp...created_timestamp #=> Time
resp...modified_timestamp #=> Time
resp...content_created_timestamp #=> Time
resp...content_modified_timestamp #=> Time
resp...creator_id #=> String
resp...thumbnail #=> Hash
resp...thumbnail["DocumentThumbnailType"] #=> String
resp...source #=> Hash
resp...source["DocumentSourceType"] #=> String
resp..resource_state #=> String, one of "ACTIVE", "RESTORING", "RECYCLING", "RECYCLED"
resp..labels #=> Array
resp..labels[0] #=> String
resp. #=> Hash
resp.["CustomMetadataKeyType"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :authentication_token (String)

    Amazon WorkDocs authentication token. Not required when using Amazon Web Services administrator credentials to access the API.

  • :document_id (required, String)

    The ID of the document.

  • :include_custom_metadata (Boolean)

    Set this to ‘TRUE` to include custom metadata in the response.

Returns:

See Also:



2115
2116
2117
2118
# File 'lib/aws-sdk-workdocs/client.rb', line 2115

def get_document(params = {}, options = {})
  req = build_request(:get_document, params)
  req.send_request(options)
end