我試圖在我的Rails應用程序中使用Datalogics PDF(https://api.datalogics-cloud.com/docs#fillform)填寫可輸入的pdf(使用Adobe Acrobat製作)。Datalogics PDF填充軌道
我很難搞清楚如何進行api調用。即我無法弄清楚在哪裏/如何放置參數。任何幫助深表感謝!謝謝!
其中一個例子是使用curl,所以在控制器操作中,我把curl https://pdfprocess.datalogics.com/api/actions/render/pages --insecure --form 'application={"id": "xxxxx", "key": "xxxxxxx"}' --form [email protected]_world.pdf --form inputName=hello_world.pdf --output flattened.pdf
這使pdf hello_world(位於我的rails根目錄中)變成了一個名爲flattened.pdf的pdf。
雖然我不確定如何理解此代碼。
此外,我想過的不是使用控制器,而是使用表單,其操作是url,並具有各種字段的標籤,這是否是一種有效的可能性?
對於填表,我試圖這樣curl命令:
`curl https://pdfprocess.datalogics.com/api/actions/fill/form --insecure --form 'application={"id": "xxxxx", "key": "xxxxxx"}' --form [email protected]/fillable/CG1218_6-95.pdf --form [email protected] --output flattened.pdf`
您能向我們展示您到目前爲止所得到的結果以及您收到的任何錯誤嗎?還有什麼你試過等? (注意:不要把它放在評論中,編輯你的問題並在那裏添加它,因爲這些東西應該是你問題的一部分) –