Skip to content

Latest commit

 

History

History
111 lines (86 loc) · 4.13 KB

File metadata and controls

111 lines (86 loc) · 4.13 KB
title printJob: abort
description Abort a print job.
author nilakhan
ms.localizationpriority medium
ms.subservice universal-print
doc_type apiPageType
ms.date 04/05/2024

printJob: abort

Namespace: microsoft.graph

[!INCLUDE beta-disclaimer]

Abort a print job. Only applications using application permissions can abort a print job.

Aborting a print job will only succeed if there is a printTask in a processing state on the associated print job, started by a trigger that the requesting app created. For details about how to register a task trigger, see Extending Universal Print to support pull printing.

[!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

POST /print/printers/{id}/jobs/{id}/abort

Request headers

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

Request body

In the request body, you can optionally provide the reason why the job is being aborted.

Property Type Description
reason String Reason why job is being aborted.

Response

If successful, this method returns a 204 No Content response code. It doesn't return anything in the response body.

Example

The following example shows how to call this API.

Request

The following example shows a request.

POST https://graph.microsoft.com/beta/print/printers/{id}/jobs/{id}/abort

[!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

The following example shows the response.

HTTP/1.1 204 No Content