Convert PDF to HTML with Aspsoe.3D REST API throws Stream incorrect or unsupported error

Type: Aspose\ThreeD\Cloud\ApiException

Message: [400] Client error: POST https://api.aspose.cloud/v3.0/3d/saveas/newformat?name=Pricing.pdf&newformat=html&newfilename=testfile.html&IsOverwrite=false resulted in a 400 Bad Request response: {“error”:{“code”:“error”,“message”:"Stream incorrect or unsupported! AmazonS3 Storage exception: The specified key does (truncated…)

Error: PostConvertByFormat. Parameters: name ‘Pricing.pdf’, newformat ‘html’, newfilename ‘testfile.html’, IsOverwrite ‘False’. Exception: Stream incorrect or unsupported! AmazonS3 Storage exception: The specified key does not exist. Bucket ‘afc-filestorage’, FilePath ‘97832/4b403067-481d-47dc-986f-9b83c4903f77/Pricing.pdf’.

@Convertacad

We will appreciate it if you please share your input PDF document with us, we ill investigate the issue and will guide you.

sure
here is the pdf documentPricing.pdf (1.7 MB)

i’m also tried to convert a simple html file to pdf file but get same error
can you explain why i’m getting AmazonS3 Storage exception error.
i’m using aspose cloud storage

@Convertacad

Thanks for sharing the input PDF document. We have tested the scenario and noticed the reported issue, so logged a ticket THREEDCLOUD-44 for further investigation and resolution. We will keep you updated about the issue resolution progress within this forum thread. Meanwhile, you can use Aspose.PDF Cloud API for PDF to HTML or HTML to PDF conversion.

1 Like

@Convertacad

Please note Aspose.3D Cloud does not support HTML to PDF conversion. So please use Aspose.PDF Cloud API for HTML to PDF conversion.

Secondly, we hosted Aspose Cloud Storage at AmazonS3, so AmazonS3 is included in the exception message.

1 Like

@Convertacad

In reference to above reported issue THREEDCLOUD-44, please note Aspose.3D Cloud API only supports standard U3D embedded 3D content in PDF to HTML conversion. So your Pricing.pdf file can not be converted to HTML. So please use Aspose.PDF Cloud API for the conversion.

1 Like

sorry but i’m gettimg same error with other file format

Type: Aspose\ThreeD\Cloud\ApiException

Message: [400] Client error: POST https://api.aspose.cloud/v3.0/3d/saveas/newformat?name=Vehicles-6.dxf&newformat=ply&newfilename=new-3ds-file-convert.ply&IsOverwrite=false resulted in a 400 Bad Request response: {“error”:{“code”:“error”,“message”:"Stream incorrect or unsupported! AmazonS3 Storage exception: The specified key does (truncated…)

@Convertacad

We are sorry for the inconvenience. Please share the problematic document in this thread as a zip file. We will investigate it and will guide you.

sure
here is my document
Vehicles-6.zip (42.7 KB)

@Convertacad

Thanks for sharing the problematic document. We have noticed the reported issue and logged a ticket (THREEDCLOUD-45) for further investigation. We will update you as soon as it is resolved.

Hello, do you have an update on this? Thank you.

@Convertacad

We have investigated your DXF file and noticed it is a 2D CAD format file. Please note Aspose.3D only support open/save 3D format files.

Furthermore, you can use Aspose.PDF Cloud to convert 2D PDF format files and Aspose.CAD Cloud for 2D CAD format files.

i’m also checked with other formats but get same error
it doesn’t work

  1. ply to collada
    Error: PostConvertByFormat. Parameters: name ‘Handgun_ply.ply’, newformat ‘collada’, newfilename ‘new-collada-file-convert.collada’, IsOverwrite ‘False’. Exception: Stream incorrect or unsupported! AmazonS3 Storage exception: The specified key does not exist. Bucket ‘afc-filestorage’, FilePath ‘97832/4b403067-481d-47dc-986f-9b83c4903f77/Handgun_ply.ply’.

  2. x to ply
    Error: PostConvertByFormat. Parameters: name ‘Handgun_x.x’, newformat ‘ply’, newfilename ‘new-ply-file-convert.ply’, IsOverwrite ‘False’. Exception: Stream incorrect or unsupported! AmazonS3 Storage exception: The specified key does not exist. Bucket ‘afc-filestorage’, FilePath ‘97832/4b403067-481d-47dc-986f-9b83c4903f77/Handgun_x.x’.

  3. 3ds to ply
    Error: PostConvertByFormat. Parameters: name ‘Chair Miniforms Tube N060220.3ds’, newformat ‘ply’, newfilename ‘new-3ds-file-convert.ply’, IsOverwrite ‘False’. Exception: Stream incorrect or unsupported! AmazonS3 Storage exception: The specified key does not exist. Bucket ‘afc-filestorage’, FilePath ‘97832/4b403067-481d-47dc-986f-9b83c4903f77/Chair Miniforms Tube N060220.3ds’.

here are the files files.zip (886.3 KB)

@Convertacad

Please double check the storage path of the files. I have converted your shared files to the desired formats without any issue.files (2).zip (886.9 KB)

Furthermore, we are in the process to improve the exception handling of the API. Hopefully, in the coming release, it will return a meaningful exception message in case of any error.

curl -X POST "https://api.aspose.cloud/v3.0/3d/saveas/newformat?name=Handgun_ply.ply&newformat=collada&newfilename=Handgun_ply.dae&folder=Temp&IsOverwrite=true" 
-H "accept: application/json" 
-H "authorization: Bearer [Access_Token]" 

curl -X POST "https://api.aspose.cloud/v3.0/3d/saveas/newformat?name=Handgun_x.x&newformat=ply&newfilename=Handgun_x.ply&folder=Temp&IsOverwrite=true" 
-H "accept: application/json" 
-H "authorization: Bearer [Access_Token]"

curl -X POST "https://api.aspose.cloud/v3.0/3d/saveas/newformat?name=Chair%20Miniforms%20Tube%20N060220.3ds&newformat=ply&newfilename=Chair%20Miniforms%20Tube%20N060220.ply&folder=Temp&IsOverwrite=true" 
-H "accept: application/json" 
-H "authorization: Bearer [Access_Token]" 
-H "x-aspose-client: Containerize.Swagger"
1 Like

i just ask only one thing
in 1st api you add collada format as newformat and add extension .dae in filename
but i didn’t see anywhere collada file format in aspose 3d documentation
doccpng.png (34.8 KB)

can you explain this ?

Thank You so much
is there any method to get fileformat using filename ?

@Convertacad

I think it is already mentioned there. However, if there is any difference in your question and my understanding then please share some more details.

I’m afraid we do not have any such API at the moment. Please share some more details of your requirements along with an example. So we will investigate it and will guide you accordingly.

Currently, we have an API that provides a list of all supported file formats.

GET ​/3d​/fileformats Get all fileformat in detail

A post was split to a new topic: Convert STL to 3DS with Aspose.3D REST API error