No, you do not need any specific account. The Free Trial plan provides all the functionalities and features except the 150 API monthly limit.
As shared in the private message. I’m able to convert your shared file using the following cURL command. Please check your cloud storage for the output and confirm
//Convert USDZ to GLTF
curl -X POST "https://api.aspose.cloud/v3.0/3d/saveas/newformat?name=framedpicture.usdz&newformat=gltf&newfilename=framedpicture.gltf&IsOverwrite=true"
-H "accept: application/json"
-H "authorization: Bearer [Access_Token]"
You may check your usage logs from your aspose.cloud dashboard.
It depends upon the file size/contents and network. However, it should be converted within seconds.
@tilal.ahmad I have tried to use your codes and instructions verbatim, but the requests do not seem to reach your back end if I trigger them (can’t even see any of the requests in the log, while the others arrive).
Can you please confirm that you are not in some sort of VPN, have a whitelisted IP address, or anything of such nature?
I can see the requests works for you. But the exact same code (of course with the correct Bearer token) does not work if I try it from any of my servers, using curl on Mac or Linux.
No, I’m not using any VPN or some special arrangements. It is quite strange that the Upload File API request is working fine at your end but Conversion is failing.
Did you try the conversion from some other computer?
Can you please test the following C# code with your credentials using Aspose.3D Cloud NuGet Package and share the result?
using Aspose.ThreeD.Cloud.SDK.Api;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1
{
class Program
{
static String ClientId = "xxxxxx-xxxx-xxxx-xxxx-xxxxxxx";
static String ClientSecret = "xxxxxxxxxxxxxxxxxxxx";
static void Main(string[] args)
{
Convert_3d();
Console.WriteLine("Completed...");
Console.ReadKey();
}
public static void Convert_3d() {
var threeDCloudApi = new ThreeDCloudApi("client_credentials", ClientId, ClientSecret);
string name = "framedpicture.usdz";
string newformat = "gltf2";
string newfilename = "framedpicture.gltf";
//string folder = "3DToPdf";
bool isOverwrite = true;
//string storage = "MyStorage";
var response = threeDCloudApi.PostConvertByFormat(name, newformat, newfilename, null, isOverwrite, null);
}
}
}
Thanks @tilal.ahmad - yes I tried from multiple computers/servers with different OSes in different countries. None of them managed to trigger a /saveas command with cURL that shows in the activity log. The other commands showed in the activitiy logs (and worked).
Thanks for the C# code, I will try it and get back to you. Your help is much appreciated!
By the way, I’ve found the solution. Your server seems to reject the request if the content length is 0 but the header doesn’t indicate that content length will be zero. Therefore adding the parameter -d "" to the cURL command seems to have solved the problem.
It is good to know that you have managed to resolve the issue. It might be the cURL version as the request calls are working fine with me without -d cURL parameter.
{“RequestId”:“71492472-ae74-4d67-b5d0-d7034e83a01d”,“Error”:{“Code”:“internalError”,“Message”:“Stream incorrect or unsupported! Object reference not set to an instance of an object.”,“Description”:“Operation Failed. Internal error.”,“DateTime”:“2023-09-29T19:41:00.9035868Z”,“InnerError”:null}}%
The Conversion is working fine with my sample document. Please share your input document along with the sample code. We will look into the issue and guide you accordingly.
Thanks for sharing the input document. We have tested the scenario and noticed the reported issue with your shared file. So I logged a ticket(THREEDCLOUD-80) for further investigation and rectification. We will notify you as soon as it is resolved.
I am afraid the issue is still pending for investigation in the queue. We will share an update/ETA with you as soon as the issue investigation is completed.
We are truly sorry for the inconvenience. Actually, there are a number of apps and tools being used to create 3D files (USDZ), so the file structure of the same file format varies from one app/tool to another app/tool which causes problems in a file conversion app/tool. We have requested an update from our product team and will share it with you accordingly.