Generate API Token
Login to https://arescli.graebert.com/ platform and access Tokens tab.
Click Generate new API key, copy and use it on API endpoints.
Load Environment
Use POST /{type}/upload, with type = environment to load the .zip file. Get the response environment ID to use on job execution.Load File
Use POST /{type}/upload, with type = file to load the file to be processed (.rvt file).
Get the response file ID to use on job execution.Execute Job
Use POST /execute to create and run a new job.
Fill:
“environment:“ with environment ID
”configuration:” with configuaration content (see in the right panel).
“files:“ with file ID
{ "Inputs": { "comment": "the input file format as uploaded on the ARESCLI portal Environment NOTE: should be same of script var BIM_input in the script section for this script", "inputfileformat": "rvt", "script": { "comment": "location and extension of the script as uploaded on the ARESCLI portal Environment. Also the variables used the script are defined in this section", "scriptpath": "scripts/bim2pdf.scr", "scriptformat": "scr", "scriptvariables": [{ "name": "OUTPUTDIR", "value": "output.dwg", "comment":"name of the desired output file, NOTE: this name should be same as the first name of the outputfilename(extension should be dwg) in Outputs section" }, { "name": "BIM_input", "value": "input.rvt", "comment":"name of the rvt file as uploaded on the ARESCLI portal, NOTE:this is not the fileId" }, { "name": "BIM_AUTO_TEMPLATE", "value": "templates/bimautotemplates/ISO_A1_Landscape(1_100)_Header_wfields.dwg", "comment":"location of the bim templates in zip uploaded on the ARESCLI portal Environment" }] }, "templates": { "comment": "location of the templates in zip and their extensions as uploaded on the ARESCLI portal Environment", "drawingtemplate": "templates/drawingtemplates/standardiso_mm.dwt", "drawingtemplateformat": "dwt", "bimautotemplates": "templates/bimautotemplates/ISO_A1_Landscape(1_100)_Header_wfields.dwg", "bimautotemplatesformat": "dwg" } }, "Outputs": { "outputfileformat": "pdf", "outputfilename": "output.pdf", "comment": "name of the desired output file NOTE: the name of file without the extension should be same as the script var OUTPUTDIR for this bim2pdf script" } }
Track Job status
Use GET/jobs/{jobId}/download/{type}/{jobid} to track the status of the job.
- PENDING
- COMPLETE
- FAILUREDownload job result
Use GET /jobs/{jobId}/download/{type} with type = result to download the output file.
In case the job failed, download type = log and type = zip to get the files to investigate the error.