Get Print-Job Information

Gets print-job information for an active or recently finished print job.

Note: For more information about this command, including descriptions of any path and request parameters, request body schema, response codes and schemas, and payload examples, refer to the online API reference for this command at the following web page:

Get print-job information

URI

https://bartendercloud.com/api/printers/{printerId}/queue/{printJobId}

Note: The bartendercloud.com domain that is referenced in the URI and in the code examples that follow must be replaced with the contents of the DataCenterURI claim that is extracted from your access token. For more information, refer to Extracting the DataCenterURI Claim.

Path Parameters

printerId

Type: String

Identifies the print queue. Required.

printerJobId

Type: String

Identifies the print job. Required.

Example

You can use any one of several methods to send the command to the server, as shown in the following code samples.

Note: In each of the following samples, you must replace "____PASTE_YOUR_ACCESS_TOKEN_HERE____" with your access token. For more information about your access token, refer to Authentication.

The following cURL command returns print job information on an active or recently finished print job.

Copy
--request GET \
--url 'https://bartendercloud.com/api/printers/{printerId}/queue/2022-09-24/4' \
--header 'Authorization: Bearer ____PASTE_YOUR_ACCESS_TOKEN_HERE____' \
--header 'Content-Type: text/yaml'

The following C# HttpClient example returns print job information about an active or recently finished print job.

Copy
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("https://bartendercloud.com/api/printers/{printerId}/queue/2022-09-24/4"),
    Headers =
    {
        { "Authorization", "Bearer ____PASTE_YOUR_ACCESS_TOKEN_HERE____" },
    },
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}