During Design Automation for Revit WorkItem process, Revit model and all links should be upload to the Application bucket, it works well when I am testing lightweight Revit files (about 10Mb each), but when I've got real building Revit model (primary file 4.2Gb) with 24 links (from 60Mb to 2Gb size range), I have an error.
Status shows me an 'error 413'
And response message
"Payload length of 33269 bytes exceeds the allowed limit of 16384 bytes. (Parameter 'ContentLength')"
I am using this WorkItem where described all uploading files:
{
"activityId": "{{applicationNickname}}.{{revitApplicationId}}Activity+{{revitApplicationAlias}}",
"arguments": {
"rvtFile": {
"url": "urn:adsk.objects:os.object:wip.dm.prod/6470e126-43a9-49b8-abe5-8bd1ad064a0c.rvt",
"localName" : "Interr_AR.rvt", //--4.3Gb
"references": [
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/85174092-4d9d-42e4-81e1-2cf70f54a16a.rvt",
"localName" : "PRK_AR.rvt",//--567Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/14bcd135-76f9-48f0-802a-59f622044666.rvt",
"localName" : "PRK_CMI_M.rvt",//--331Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/bba52679-0317-4918-bedb-94bb8557d8fd.rvt",
"localName" : "PRK_ST.rvt",//--222Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/a1e17364-b950-484b-a1bc-5d78ffe69d33.rvt",
"localName" : "BLDNG_ARUP_E.rvt",//--284Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/5ac9dbf8-b064-4f23-bd40-0ab015c49983.rvt",
"localName" : "BLDNG_CMI_MD.rvt",//--515Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/bc15fb42-1be4-4d09-afc0-670cab90e26f.rvt",
"localName" : "BLDNG_CMI_MP.rvt",//--577Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/6673fbd6-275d-4aa1-a103-50a304f2dd86.rvt",
"localName" : "BLDNG_FS.rvt",//--290Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/d7920542-4900-40fa-9145-c1033f30d51a.rvt",
"localName" : "BLDNG_GS.rvt",//--203Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/62b93ae7-c414-4ea2-a053-38d030ef559c.rvt",
"localName" : "BLDNG_M.rvt",//--141.4Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/97541c10-c05f-4dd1-9fd0-7ee7d0d9a500.rvt",
"localName" : "BLDNG_P.rvt",//--106Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/3f561390-903b-4b5f-a95e-1e3b5ac7dae3.rvt",
"localName" : "BLDNG_PLIFT.rvt",//--101Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/710cf78b-77fd-446c-9498-7399b9d3cfb0.rvt",
"localName" : "BLDNG_PPM_MAC.rvt",//--286Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/7996b88e-1ca3-4b91-a0d9-8fbfc6183a97.rvt",
"localName" : "BLDNG_PPM_PL_MG.rvt",//--1.9Gb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/639dbb20-29c5-4a86-8ec4-3c835908c9e5.rvt",
"localName" : "BLDNG_PPM_PL_PG.rvt",//--576Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/dd5301eb-3502-4e98-b6f4-cc38f6247cba.rvt",
"localName" : "BLDNG_REI_E.rvt",//--487Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/7ab9c8e7-6d0c-4fc7-81c1-a9c4a465e404.rvt",
"localName" : "LAYOUT TEMPLATE.rvt",//--7Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/03322d3a-eeb0-435c-b656-6e3cd0da21ad.rvt",
"localName" : "BLDNG_TRANSLOGIC_PTC.rvt",//--487Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/0e2edb3d-1021-44d1-91f4-e48240d134db.rvt",
"localName" : "BLDNG_SE.rvt",//--462Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/1abd6eb3-087a-4f98-a88b-12a8f70a5cfc.rvt",
"localName" : "BLDNG_ST.rvt",//--80Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/e376cd0c-e18b-46b7-a104-e9b72b6c626e.rvt",
"localName" : "BLDNG_Shell_AR.rvt",//--86Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/529df3ae-cbb8-439c-a904-b1c44d27e426.rvt",
"localName" : "SitePlane_AR.rvt",//--96Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/95e979d7-cb85-4d47-b40c-3ca2e30ffa74.rvt",
"localName" : "Furniture.rvt",//--97Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/30ff421d-8757-43e0-9251-2eac817a0b2a.rvt",
"localName" : "Grids.rvt",//--15Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
},
{
"url": "urn:adsk.objects:os.object:wip.dm.prod/c481d4c1-85ee-4f0c-a449-77701f09b4b1.rvt",
"localName" : "RF Shielding.rvt",//--106Mb
"headers": {
"Authorization": "Bearer {{token}}"
}
}
],
"headers": {
"Authorization": "Bearer {{token}}"
}
},
"input" :{
"url": "data:application/json,{ \"Names\" : [ \"XYICON LEVEL 1 Revised\", \"XYICON LEVEL 2 Revised\", \"XYICON LEVEL 3 Revised\", \"XYICON LEVEL 4 Revised\", \"XYICON LEVEL 5 Revised\", \"XYICON LEVEL 6 Revised\", \"XYICON LOWER LEVEL Revised\", \"XYICON ROOF LEVEL Revised\"] }",
"headers": {
"Authorization": "Bearer {{token}}"
}
},
"output_zip_file": {
"url": "urn:adsk.objects:os.object:{{bucketKey}}/revit_output.zip",
"verb": "post",
"headers": {
"Authorization": "Bearer {{token}}"
}
},
"outputJsonFile": {
"url": "urn:adsk.objects:os.object:{{bucketKey}}/output.json",
"verb": "post",
"headers": {
"Authorization": "Bearer {{token}}"
}
}
}
}
All of them reasonably small, but as the summary it's about 12Gb. Would it make sense to zip file at one and upload it in the bucket?
Is there any way to work with files in place where they located (do not copy to the bucket)?
Is there a solution to work with huge files (more than 5Gb)?
The maximum permitted size for a work item's JSON payload is 16KB. However, the payload, after including the bearer token, is around 32KB. This is why you are encountering a 413 Payload Too Large error. I suggest keeping the payload within 16KB. You can also fetch these files from your plugin, as DA allows network requests within plugin code. I copied the payload content into wi.json
and tested.
Refer: https://aps.autodesk.com/en/docs/design-automation/v3/developers_guide/rate-limits/da-rate-limits/