Skip to content

Latest commit

 

History

History
61 lines (39 loc) · 3.4 KB

GetFilesApi.md

File metadata and controls

61 lines (39 loc) · 3.4 KB

Zuora::GetFilesApi

All URIs are relative to https://rest.zuora.com

Method HTTP request Description
get_files GET /v1/files/{file-id} Get files

get_files

get_files(file_id, opts)

Get files

Retrieve a file by specifying its file ID. You can retrieve accounting period reports, such as the Revenue Detail report, as well as other files such as invoice PDFs. ## Example curl curl -i -k -H \"apiAccessKeyId:$USER_NAME\" -H \"apiSecretAccessKey:$PASSWORD\" -H \"Accept:application/pdf\" -X GET https://rest.zuora.com/v1/files/2c92c08c55534cf00155581fb474314d -o /Users/jsmith/Downloads/invoiceFile1.pdf The invoice PDF is downloaded to /Users/jsmith/Downloads and named invoiceFile1.pdf. ## File Size Limitation The maximum export file size is 2047MB. If you have large data requests that go over this limit, you will get the following 403 HTTP response code from Zuora. <security:max-object-size>2047MB</security:max-object-size> Submit a request at Zuora Global Support if you require additional assistance. We can work with you to determine if large file optimization is an option for you.

Example

# load the gem
require 'zuora'

api_instance = Zuora::GetFilesApi.new

file_id = "file_id_example" # String | The Zuora ID of the file you want to retrieve. 

opts = { 
  entity_id: "entity_id_example", # String | The Id of the entity that you want to access. Note that you must have permission to access the entity. For more information, see [REST Authentication](https://www.zuora.com/developer/api-reference/#section/Authentication/Entity-Id-and-Entity-Name).
  entity_name: "entity_name_example" # String | The [name of the entity](https://knowledgecenter.zuora.com/BB_Introducing_Z_Business/Multi-entity/B_Introduction_to_Entity_and_Entity_Hierarchy#Name_and_Display_Name) that you want to access. Note that you must have permission to access the entity. For more information, see [REST Authentication](https://www.zuora.com/developer/api-reference/#section/Authentication/Entity-Id-and-Entity-Name).
}

begin
  #Get files
  api_instance.get_files(file_id, opts)
rescue Zuora::ApiError => e
  puts "Exception when calling GetFilesApi->get_files: #{e}"
end

Parameters

Name Type Description Notes
file_id String The Zuora ID of the file you want to retrieve.
entity_id String The Id of the entity that you want to access. Note that you must have permission to access the entity. For more information, see REST Authentication. [optional]
entity_name String The name of the entity that you want to access. Note that you must have permission to access the entity. For more information, see REST Authentication. [optional]

Return type

nil (empty response body)

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json; charset=utf-8
  • Accept: application/json; charset=utf-8