0

I am following the tutorial to upload a NWD file to view in a browser, and I'm using the following steps:

  1. Registered an APP
  2. Acquired Auth token

I am then using the Postman to send the request through APIs

  1. Authenticate with scope data:read data:write data:create bucket:read bucket:create to get the Access token - Successful
  2. Create Bucket – Successful
  3. Upload File – Successful
{
    "bucketKey": "test_27052918",
    "objectId": "urn:adsk.objects:os.object:qrailtest_27052918/Z2_07_85_FULL.nwd",
    "objectKey": "Z2_07_85_FULL.nwd",
    "sha1": "b25528317db44a06e39a3fa2314af11d21802def",
    "size": 28824,
    "contentType": "application/octet-stream",
    "location": "https://developer.api.autodesk.com/oss/v2/buckets/qrailtest_27052918/objects/Z2_07_85_FULL.nwd"
}
  1. Post Job SVF – successful
{
    "result": "success",
    "urn": "dXJuOmFkc2sub2JqZWN0czpvcy5vYmplY3Q6cXJhaWx0ZXN0XzI3MDUyOTE4L1oyXzA3Xzg1X0ZVTEwubndk",
    "acceptedJobs": {
        "output": {
            "destination": {
                "region": "us"
            },
            "formats": [
                {
                    "type": "svf",
                    "views": [
                        "3d",
                        "2d"
                    ]
                }
            ]
        }
    }
}
  1. Check job status – Failed
{
    "type": "manifest",
    "hasThumbnail": "false",
    "status": "failed",
    "progress": "complete",
    "region": "US",
    "urn": "dXJuOmFkc2sub2JqZWN0czpvcy5vYmplY3Q6cXJhaWx0ZXN0XzI3MDUyOTE4L1oyXzA3Xzg1X0ZVTEwubndk",
    "version": "1.0",
    "derivatives": [
        {
            "name": "LMV Bubble",
            "hasThumbnail": "false",
            "status": "failed",
            "progress": "complete",
            "messages": [
                {
                    "type": "error",
                    "message": "Translation failure",
                    "code": "TranslationWorker-InternalFailure"
                }
            ],
            "outputType": "svf"
        }
    ]
}

Is there anything that I'm missing here? Please suggest.

4levels
  • 3,134
  • 1
  • 23
  • 22
vivek shukla
  • 56
  • 1
  • 4
  • Could you share the job configuration body you used to trigger a translation? The only one I can see is the response of POST Job API. – Eason Kang May 29 '18 at 07:42

1 Answers1

0

This case is processed via Forge Help since it contains private information from the requester. In our conversation, we found the job body in the Postman collection he provided is incorrect for an NWD file. The job config should have to change it into this one:

{
   "input": {
     "urn": "YOUR_URN"
   },
   "output": {
     "formats": [
       {
         "type": "svf",
         "views": [
           "2d",
           "3d"
         ]
       }
     ]
   }
 }

Note: Before triggering a new job, the failed translation result should be deleted via calling DELETE :urn/manifest or pass x-ads-force: true in to request header of the API POST job call. Otherwise, the translation result will remain the old one, the failed one in this case.

Eason Kang
  • 6,155
  • 1
  • 7
  • 24