Community Tip - When posting, your subject should be specific and summarize your question. Here are some additional tips on asking a great question. X
I have some familiarity with the odata/rest functionality with my org's WC setup, but am now looking to adapt that to directly download associated visualizations/representations of documents (PDF files) to a folder using the same type of http request - looking at the URLs of the files associated with a given document, I dont see anything explicit on how to reference a specific visualization for a given document number (each visualization seems to have a new object number, not related to the parent docmgmt object number, at least in the console/http request for the file).
Is there a http string that will let me download all visualizations for a specific document object? or a set of search parameters in the 'DocMgmt' domain? or is it in the 'Visualization' domain?
Downloading the files individually from WC, the links show up in my console as 'WindchillGWAUTH' domain, which seems separate from odata entirely, is there any way to reference these from the odata/rest side? I would imagine there is some logic to how the docmgmt object is related to the visualization page, but it isnt readily apparent.
Hi @EB_10397747
If you need to download visualization data (additional data PDF,STEP etc.) with http request, you would need to crate own custom method to do so.
this is just idea how to achieve what you need.
package cz.aveng.AVIntegration;
public class AVDataExchange implements RemoteAccess
{
public static void AVDownloadPDF(HTTPRequest req, HTTPResponse resp) throws WTException
{
try
{
OutputStream browserStream = resp.getOutputStream();
int httpResult = collectAllMyDataAndsaveToOutpuStream(browserStream); // a job to collect all data you need.
((HTTPServletResponse)resp).setStatus(httpResult);
} catch (IOException e)
{
e.printStackTrace();
}
}
}
A http link example
windchillServer.ptc.com/Windchill/servlet/WindchillAuthGW/cz.aveng.AVIntegration.AVDataExchange/AVDownloadPDF?objectNumber=8541231.ASM
PetrH