2

I created a project from this tutorial.

How may I send a huge json file by user to be read in Command.cs in Design Automation for Revit on cloud? I receive the file in DesignAutomationController.cs using form, but i am unable to send it to Command.cs as in this the url becomes way too huge.

XrefTreeArgument inputJsonArgument = new XrefTreeArgument()
{
    Url = "data:application/json, " + ((JObject)inputJson).ToString(Formatting.None).Replace("\"", "'")
};
Rahul Bhobe
  • 4,165
  • 4
  • 17
  • 32

1 Answers1

1

How huge is the json file? The workitem payload limit is only 16 kb.

We recommend embedded json only for small contents. For anything big, you may upload the json content to a cloud storage and pass the signed url to the file as input argument URL.

Design Automation API limits are defined here:

https://forge.autodesk.com/en/docs/design-automation/v3/developers_guide/quotas/

Rahul Bhobe
  • 4,165
  • 4
  • 17
  • 32
  • I thought a DA4R app has no network or Internet access during work item execution. How can it grab the uploaded JSON data from the URL if it has no network access? – Jeremy Tammik Feb 23 '20 at 10:00
  • @JeremyTammik - The signed url to the JSON file would have to be provided at the time of posting the workitem. It is then similar to how one provides the input rvt file. – Rahul Bhobe Feb 25 '20 at 12:02