Skip to content

Latest commit

 

History

History
97 lines (74 loc) · 3.97 KB

File metadata and controls

97 lines (74 loc) · 3.97 KB
title Download printDocument binary file
description Download the binary file associated with the document.
author braedenp-msft
ms.localizationpriority medium
ms.subservice universal-print
doc_type apiPageType
ms.date 04/05/2024

Download printDocument binary file

Namespace: microsoft.graph

[!INCLUDE beta-disclaimer]

Download the binary file associated with a printDocument. Calling this method yields a redirect response with a preauthenticated URL that can be used to download the payload.

[!INCLUDE national-cloud-support]

Permissions

Choose the permission or permissions marked as least privileged for this API. Use a higher privileged permission or permissions only if your app requires it. For details about delegated and application permissions, see Permission types. To learn more about these permissions, see the permissions reference.

[!INCLUDE permissions-table]

HTTP request

GET /print/printers/{id}/jobs/{id}/documents/{id}/$value

Request headers

Name Description
Authorization Bearer {token}. Required. Learn more about authentication and authorization.

Request body

Don't supply a request body for this method.

Response

If successful, this method returns 302 Found and the preauthenticated download URL in the Location header.

Examples

The following example shows how to call this API to acquire a preauthenticated download URL. To start the download, follow the redirect URL in the response.

Request

GET https://graph.microsoft.com/beta/print/printers/fcb0bc53-a446-41d0-bfc3-5c56cdbb0f2a/jobs/46140/documents/bd260b1a-044e-4ca6-afa9-17d9a587d254/$value

[!INCLUDE sample-code] [!INCLUDE sdk-documentation]

[!INCLUDE sample-code] [!INCLUDE sdk-documentation]

[!INCLUDE sample-code] [!INCLUDE sdk-documentation]

[!INCLUDE sample-code] [!INCLUDE sdk-documentation]

[!INCLUDE sample-code] [!INCLUDE sdk-documentation]

[!INCLUDE sample-code] [!INCLUDE sdk-documentation]

[!INCLUDE sample-code] [!INCLUDE sdk-documentation]


Response

HTTP/1.1 302 Found
Location: https://print.print.microsoft.com/downloads/bd260b1a-044e-4ca6-afa9-17d9a587d254?tempauthtoken={accesstoken}