Shows how to start an image-to-3D session using the legacy endpoint used by the
official Python SDK, then poll for its status.
This example assumes using CsmAi; is in scope and apiKey contains your CsmAi API key.
1 2 3 4 5 6 7 8 9101112131415
usingvarclient=newCsmAiClient(apiKey);// Kick off an image-to-3D session from a public image URL.varenvelope=awaitclient.ImageTo3d.CreateImageTo3DSessionAsync(newLegacyImageTo3DRequest{ImageUrl="https://via.placeholder.com/300/09f/fff.png",GeometryModel=GeometryModel.Turbo,TextureModel=TextureModel.Pbr,});Console.WriteLine($"Session Code: {envelope.Data.SessionCode}");// Retrieve current status once.varstatus=awaitclient.ImageTo3d.GetImageTo3DSessionAsync(envelope.Data.SessionCode!);Console.WriteLine($"Status: {status.Data!.SessionStatus}, Progress: {status.Data.PercentDone}%");