User Profile
NishantLakhanpal
Joined 5 years ago
User Widgets
Recent Discussions
Re: Can't update printer
MCecile Hi, The defaults being configured should be present in the capabilities of the printer. You can get the capabilities of the printer using this API: GET https://graph.microsoft.com/v1.0/print/printers/{printerId}?$select=id,displayName,capabilities746Views0likes0CommentsRe: Get printerCreateOperation while registering the printer using java msal?
Hi HimanJo, The printer-create action is a long running operation. Hence, it returns an empty response body and a URL(in 'Operation-Location' header) to track the status of the operation. Due to limitation in Graph SDK, you can't directly fetch the response headers for POST request that returns empty response body. There's a workaround for that. You can get request from Graph SDK: graphClient.print().printers() .create(PrinterCreateParameterSet .newBuilder() .withDisplayName(displayName) .withManufacturer(manufacturer) .withModel(model) .withPhysicalDeviceId(physicalDeviceId) .withHasPhysicalDevice(hasPhysicalDevice) .withCertificateSigningRequest(certificateSigningRequest) .withConnectorId(connectorId) .build()) .buildRequest().getHttpRequest(); Then you can use native client to get response, similar to this: https://github.com/microsoftgraph/msgraph-sdk-java-core#3-make-requests-against-the-service After fetching the operationId from "Operation-Location" header, you can get operation: PrintOperation printOperation = graphClient.print().operations("{printOperationId}") .buildRequest() .get(); This return type is PrintOperation, however, it will return PrinterCreateOperation (which inherits from PrintOperation). Hence, you can explicitly cast printOperation to PrinterCreateOperation.667Views0likes0CommentsRe: Universal Print not supporting IPP tag "nameWithoutLanguage" for attribute "media-type-supported"
Hello, Yes as per IPP, media-type-supported can be either "keyword" or "name". However, Microsoft Windows supports only the "keyword" values and skips the "name" values for media-type-supported attribute.1.5KViews1like1Comment