Skip to main content
Participant
June 4, 2022
Question

PDF to EXCEl using restapi , unable to get output as xlsx file

  • June 4, 2022
  • 0 replies
  • 318 views

Hi Team,

 

I am using PDF API services for PDF to Excel conversion  , successfully able to get access token and response from Export PDF API is 202,

the GET Poll status is giving 200 response but unable to find the converted XLSX file.

 

CURL:

// Please refer our Rest API docs for more information
// https://documentcloud.adobe.com/document-services/index.html#post-exportPDF

curl --location --request POST 'https://cpf-ue1.adobe.io/ops/:create?respondWith=%7B%22reltype%22%3A%20%22http%3A%2F%2Fns.adobe.com%2Frel%2Fprimary%22%7D' \
--header 'Authorization: Bearer {{Placeholder for token}}' \
--header 'Accept: application/json, text/plain, */*' \
--header 'x-api-key: {{Placeholder for client_id}}' \
--header 'Prefer: respond-async,wait=0' \
--form 'contentAnalyzerRequests="{
\"cpf:inputs\": {
\"params\": {
\"cpf:inline\": {
\"targetFormat\": \"xlsx\"
}
},
\"documentIn\": {
\"cpf:location\": \"InputFile0\",
\"dc:format\": \"application/pdf\"
}
},
\"cpf:engine\": {
\"repo:assetId\": \"urn:aaid:cpf:Service-26c7fda2890b44ad9a82714682e35888\"
},
\"cpf:outputs\": {
\"documentOut\": {
\"cpf:location\": \"multipartLabelOut\",
\"dc:format\": \"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
}
}
}"' \
--form 'InputFile0=@"{{Placeholder for input file (absolute path)}}"'

 

 

Get POLL Status Response is :

 

--Boundary_1526075_924791208_1654376593433
Content-Type: application/json
Content-Disposition: form-data; name="contentAnalyzerResponse"

{"cpf:inputs":{"params":{"cpf:inline":{"targetFormat":"xlsx"}},"documentIn":{"cpf:location":"InputFile0","dc:format":"application/pdf"}},"cpf:engine":{"repo:assetId":"urn:aaid:cpf:Service-26c7fda2890b44ad9a82714682e35888"},"cpf:status":{"completed":true,"type":"","status":200},"cpf:outputs":{"documentOut":{"cpf:location":"multipartLabelOut","dc:format":"Represents "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" media type"}}}
--Boundary_1526075_924791208_1654376593433
Content-Type: application/octet-stream
Content-Disposition: form-data; name="multipartLabelOut"

PK

 

 

where can i find the xlsx converted file.

This topic has been closed for replies.