Open itsikbelson-spotlight opened 8 months ago
@itsikbelson-spotlight,
Unfortunately, I was unable to reproduce the error you described. The savePresentation
method works fine on our end. Could you please share the presentation file you used?
Sure. Attached. Note that it happened with every other pptx I've tried. itsik-test.pptx
@itsikbelson-spotlight, I am still unable to reproduce the problem you are experiencing. I used the following code example:
slidesApi.savePresentation("itsik-test.pptx", "Pdf", "output.pdf").then(() => {
})
.catch(error => {
console.error(error.message);
});
Could you please indicate the version of Node.js you are using?
Sure. We're using node v18.
@itsikbelson-spotlight,
I checked the problem with Node.js 18. The savePresentation
method works fine.
Note that it happened with every other pptx I've tried.
It looks like the issue is not related to Aspose.Slides for Node.js. You should check your environment.
Thanks @andreypotapovaspose, but it also happened to me when using direct requests (using PostMan). In fact, the request id in the comment is the one taken with postman.
@itsikbelson-spotlight, Thank you for the details. I am working on the issue and will get back to you soon.
@itsikbelson-spotlight, Unfortunately, I was still unable to reproduce the error using Postman. We need more details to investigate the case.
LMK what more info is needed. In the meantime, that's the curl request I ran in order to reproduce: To get the token:
curl --location 'https://api.aspose.cloud/connect/token' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'grant_type=client_credentials' \
--data-urlencode 'client_id=<CLIENT_ID>' \
--data-urlencode 'client_secret=<CLIENT_SECRET'
To do the conversion (this one returns 411):
curl -w '%{http_code}\n' --location --request PUT 'https://api.aspose.cloud/v3.0/slides/itsik-test.pptx/Pdf?outPath=dacHYDUidgPpUSWMOPnadMXZfYi1%2Fdoc%2Fitsik-test.pdf&folder=dacHYDUidgPpUSWMOPnadMXZfYi1%2Fdoc%2Fsources&storage=remote-assets-dev' \
--header 'x-aspose-client: nodejs sdk v23.11.0' \
--header 'Authorization: Bearer <ACCESS_TOKEN>'
@andreypotapovaspose, Please try the simplest request example first and check your results. I saved the "itsik-test.pptx" file to the root of the default storage and performed the request. It works fine. I hope this will help you to isolate the problem.
ok. thanks
I'm using the following code to convert pptx to pdf (using integration with cloud storage).
The file conversion suceeds and is saved in the
outPath
. However, thesavePresentation
call returns error:I've tried to call the HTTP API directly using postman, and got a similar response:
How can it be resolved?