REST Api endpoints

Hi

Really struggeling with integrating with the plumsail API.
I really need an example on the V2 API for converting html to pdf.

http://api.plumsail.com/api/v2/convert/jobs/html-to-pdf

tried to use the documentation and example for the api, but its just giving me "Failed to fetch" error.
Plumsail Actions

Anyone got an example on this endpoint? At this point i will take anything, but im intergrating with C#

All documentation is around the Power connector, do i have to look around for something else?

Hi @Schwenk,

I reproduced the issue with the swagger and reported to the developers. They're researching it now.
You can find examples of usage in the article. I'll also check if there are other examples, specifically for HTML to PDF case.

Best regards,
Petr
Plumsail team

Thanks for replying Petr.

The examples provided in the article is not very helpful, atleast its not really related to the direct conversion of html to pdf. Looking at the Swagger docu, trial and error has not lead me to success :frowning: if someone from development could provide insights or a example of the HTML to PDF case, it would be amazing!

@Petr I have manged to get the endpoint working, but im not getting expected results.
got a job ID to this http://api.plumsail.com/api/v2/convert/jobs/html-to-pdf/0HMJNV331S7CD6C384f26e8b
but it returns an error, KeyNotFoundException - Cannot find the endpoint.

Hi @Schwenk,

This is how we tried it in Postman

Without URL variable

Try to test it using Postman or something similar as well

The error KeyNotFoundException indicates that probably the API key wasn't provided.

Best regards,
Petr
Plumsail team

@Petr Amazing support, maby the problem is, that im using Documents api key, is it really the intention that the endpoint, html-to-pdf, uses Actions and not documents?

Hi @Schwenk,

HTML to PDF action is an action from the Documents package and there should be Documents API key.

Let me check the log files, probably we'll find some extra details about the recent job issue.

Best regards,
Petr
Plumsail team

Hi @Schwenk,

I discussed the issue with the team and we decided to make some improvements that should fix the error message you received: KeyNotFoundException

I'll notify you once it's released.

Best regards,
Petr
Plumsail team

@Petr Hm, im currently using a API key from our Documents subscription, but the html-to-pdf request is showing under Actions, so im guessing its expecting an Actions subscription and API key?

Hi @Schwenk,

I confirmed with the developers that using html to pdf requires Documents subscription and an API key.

Your requests pass the key validation, but there is an error at the time of conversion because of the wrong parameter in the request, which we can't reproduce. We will improve the action to ignore the wrong paramter to get the action completed without the error.

Best regards,
Petr
Plumsail team

Hi again @Petr ,

Okay, all the requests gets listed on the 'Actions' dashboard and not the 'Documents' dashboard. Thats why i wondered what API key/Subscription it called for.

Strange that it returns the KeyNotFoundException if the request passes key validation.

Any news on this matter?

Hi @Schwenk,

We improved HTML to PDF action and made it more stable. Also, it should ignore invalid parameters. please give it a try and let us know if there are any issues.

Best regards,
Petr
Plumsail team