This is a simple Java client that exercises the predefined PlotToPDF
activity.
It issues direct HTTP requests to call the Autodesk Forge Design Automation API.
- Download and install IntelliJ Community or Ultimate. In the latest test, the version is IntelliJ Community 2017.3 .
- Forge Account: Learn how to create a Forge Account, activate subscription and create an app at this tutorial. Make sure to select the service Design Automation.
- Make a note with the credentials (client id and client secret) of the app.
- Set enviroment variables.
- Mac OSX/Linux (Terminal). Note: to let IntelliJ refresh with the updated enviroment variables, perform
open -a "IntelliJ IDEA CE" to start IntelliJ Community
OR
open -a "IntelliJ IDEA" to start IntelliJ Ultimate
export FORGE_CLIENT_ID=<<YOUR CLIENT ID FROM FORGE DEVELOPER PORTAL>>
export FORGE_CLIENT_SECRET=<<YOUR FORGE CLIENT SECRET>>
- Windows (command line)
set FORGE_CLIENT_ID=<<YOUR CLIENT ID FROM FORGE DEVELOPER PORTAL>>
set FORGE_CLIENT_SECRET=<<YOUR FORGE CLIENT SECRET>>
- In IntelliJ, open the project as Maven oriject
- Configure with available JAVA enviroment
- Run or debug src/Main, the work item will be posted, and status is shown in the console.
- IntelliJ IDEA might not get updated enviorment varaiables on Mac OS. The solution is described at fix PATH environment variable for IntelliJ IDEA on Mac OS X
These samples are licensed under the terms of the MIT License. Please see the LICENSE file for full details.
- Jonathan Miao
- Version 2.0.0 by Jeremy Tammik, The Building Coder, ADN Open, Autodesk Inc. migrated to Design Automation API on November 7-8, 2016.