Hi, I am trying to establish a connection via Postman to test the API. I am using the ‘form-data’ body, with width, height and pdfBase64 as keys. In the headers I used the Rapidapi key and host. I am getting a result, but this result is a generic output from RapidAPI, and definitely not the ZPL output. Below a start of the response, which is actually 2130 rows. Could you let me know what is going wrong?
<!DOCTYPE html>
<html lang=“en-US”>
<head>
<meta charset=“UTF-8”>
<link rel=“profile” href=“https://gmpg.org/xfn/11”>
<meta name=‘robots’ content=‘index, follow, max-image-preview:large, max-snippet: -1, max-video-preview: -1’ />
<title>RapidAPI - The Next Generation API Platform</title>
<meta name=“description” content=“Use RapidAPI to Find, Connect, & Share 1000s of APIs using our Multi-cloud platform. Improve Developer Experience with API Design, Testing, Monitoring, & More!” />
<link rel=“canonical” href=“https://rapidapi.com/” />
<meta property=“og:locale” content=“en_US” />
<meta property=“og:type” content=“website” />
<meta property=“og:title” content=“RapidAPI - The Next Generation API Platform” />
<meta property=“og:description” content=“Use RapidAPI to Find, Connect, & Share 1000s of APIs using our Multi-cloud platform. Improve Developer Experience with API Design, Testing, Monitoring, & More!” />
<meta property=“og:url” content=“https://rapidapi.com/” />
<meta property=“og:site_name” content=“RapidAPI” />
<meta property=“article:publisher” content=“https://www.facebook.com/Rapid-API-860822767286196” />
<meta property=“article:modified_time” content=“2022-09-15T14:04:40+00:00” />
<meta property=“og:image” content=“https://rapidapi.com/wp-content/uploads/2021/02/marketplace.jpg” />
<meta property=“og:image:width” content=“1665” />
<meta property=“og:image:height” content=“1203” />
<meta name=“twitter:card” content=“summary_large_image” />
<meta name=“twitter:image” content=“https://rapidapi.com/wp-content/uploads/2021/02/marketplace.jpg” />
<meta name=“twitter:site” content="@Rapid_API" />
<meta name=“twitter:label1” content=“Est. reading time” />
<meta name=“twitter:data1” content=“5 minutes” />
<script type=“application/ld+json” class=“yoast-schema-graph”>{
아래에 의견을 추가하고 토론에 참여하세요.
Hi @integrationsopposuits,
That’s a great feature request. I think we’ll be able to add support for rotating PDFs quickly.
I’m hoping to have something for you to try by beginning of next week!
Hi @dablabs, thank you for the information! It works now! I have just printed our label, however we see that we need the label command to print the label 90 degrees rotated. I have tried to update the settings of the Zebra printer, but it seems that the ZPL command overwrites this setting. Do you perhaps know if its possible to change the rotation of the supplied ZPL command? Thank you!
I was able to get it working in Postman by using “application/json” as Content-Type and then posting the parameters in the body as json.
Here are two screenshots of the settings I used:
@integrationsopposuits Perhaps the Content-Type header is set incorrectly?
I’ll see if I can make an example in Postman and will post it here shortly.
@dablabs Thank you for your reply! I used this and it seems like the request is working, however I receive the following response:
Invalid request, “html or pdfBase64” parameter not present in request.
I use in the body the setting “form-data”, including the parameter “pdfBase64” with the base64 string. Should be all set right? I also tried to use the sampe .base64 file from the documentation, but this resulted in the same error message.
Hi @integrationsopposuits,
This looks like the endpoint in Postman is set incorrectly.
Could you please verify that the endpoint is set to:
https://html-to-zpl.p.rapidapi.com/pdf2zpl
Let me know if this helps!