Files are binary or text artifacts produced by Syntage resources, such as PDFs, XML files, CSV exports, and generated reports.Most file records are returned from another resource first. For example, an invoice, tax return, export, background check, or company verification report may include one or more files. Use the file endpoint when you need the file metadata, and use the download endpoint when you need the actual file content.The download response content type depends on the stored file. Common formats include PDF, XML, CSV, XLSX, JSON, and plain text.
Use the file metadata to inspect the file type, name, size, and related resource before downloading the content.
To download a file, call GET /files/{id}/download with the file ID from the file resource.The download response returns a redirect: the Location header contains the actual URL where the file content is served. Your HTTP client must follow the redirect to receive the bytes. The redirect URL is short-lived, so request it again each time you need to download.Most HTTP clients follow redirects by default. If yours does not, enable redirect following (for example, curl -L) before reading the response body. You can also pass ?redirect=false to receive a JSON response containing the generated url.For endpoint details, see Files API Reference.
Was this page helpful?
Assistant
Responses are generated using AI and may contain mistakes.