If I recall correclty, Carl Bass mentioned at Maker Faire this year that Autodesk would be releasing a Python and Javascript API for fusion 360.
I was wondering if there was any update timeline for that?
Thanks!
Solved! Go to Solution.
Solved by charegb. Go to Solution.
Hello Jeff, Frank,
We are indeed working on a comprehensive API for Fusion 360. We intend to have a full C++ API and a scripting version of the API, starting with JavaScript, for automation. We are looking at releasing a tech preview in late summer/Fall.
I would really like to get some early feedback from interested users like you. I'll set up a call in a month or so to show you what we have built so that your can tell me how it will work for you.
Regards,
Bankim
Hey Bankim,.
I *do* have specific plans ... Why did you choose javascript over python? It seems the CAD community is much more fluent in python than Javascript. Or even something like Ruby to appeal to the massive ruby community. When you say a "scripting version" - what do you mean by that? Looking forward to the call - do you have my contact info?
Thanks!
Jeff
Hi Jeff,
It's exciting for us that you have plans to build things with the API.
We have chosen JS as the first scripting language because HTML+JS allows you to create very powerful custom UIs for whatever you are building, something that is not trivial in Python. Also, please keep in mind that starting with JS doesn't mean we can't do Python in the future... we had to choose one so that we can deliver a good experience in one environment rather than spreading the tea thin supporting multiple environments from the get go.
As soon as I'm ready in a week or two to show you a demo of what we have built so far, I'll post to his thread and also the broader group to setup one on one web meetings.
Thanks,
Bankim
bankim.charegaonkar@autodesk.com
248 449 2213
Product Manager - Fusion 360
Hi Jeff,
Thanks for the reminder, I'm late checking back in to this thread.
The new API will be available in the next update of Fusion that is comming soon. As I have mentioned before we will support JavaScript as the scripting language in this update but the plan is to support C++ and Python versions of the API in subsequent updates too.
Here is a sample to give you an idea of what the API will look like. This following script will open a comma seperated file and read in point information to create a spline in the active document. This is only a small example of what you can do.
var app = adsk.core.Application.get(); ui = app.userInterface; var design = adsk.fusion.Design(app.activeProduct); var title = 'Import Spline CSV'; if (!design) { ui.messageBox('No active design', title); adsk.terminate(); return; } var dlg = ui.createFileDialog(); dlg.title = 'Open CSV File'; dlg.filter = 'Comma Separated Values (*.csv);;All Files (*.*)'; if (dlg.showOpen() !== adsk.core.DialogResults.DialogOK) { adsk.terminate(); return; } var filename = dlg.filename; var buffer = adsk.readFile(filename); if (!buffer) { ui.messageBox('Failed to open ' + filename); adsk.terminate(); return; } var data = adsk.utf8ToString(buffer); data = data.split('\n'); var i, j, points = adsk.core.ObjectCollection.create(); for (i = 0;i < data.length;++i) { data[i] = data[i].split(','); for (j = 0;j < data[i].length;++j) { data[i][j] = parseFloat(data[i][j]); } if (data[i].length >= 3) { var point = adsk.core.Point3D.create(data[i][0], data[i][1], data[i][2]); points.add(point); } } var root = design.rootComponent; var sketch = root.sketches.add(root.xYConstructionPlane); sketch.sketchCurves.sketchFittedSplines.add(points);
If you, or anyone else interested in this topic, would like to talk to me about the API and how you would want to use it, please email me bankim.charegaonkar@autodesk.com.I'll happily setup a web meeting for us to look at the current API and talk about we can enhance it in the future.
Thanks,
Bankim
Hi Jeff,
This API, the script editor and debugger will all be included in the next update. You won't have to install any libraries to work with it, the update will just deliver everything you need.
This first release of the API focuses on the design space so all the APIs will work on the active doc or other open docs and all the execution is local. We absolutely plan to give you access to cloud data via the API but as you expect, calling remote is slightly more tricky with authentication,tokens and keys involved. We are working though how we can make this secure but simple and will address this in a future update in Fall.
Thanks,
Bankim
Hi Jeff and other API tinkerers,
The new release is live with the JS API. Please checkout the documentation here and start building!
http://fusion360.autodesk.com/resources (Programming Interface in the index on the left)
Cheers,
Bankim
Thanks for trying out the API functionality. Please share your feedback in this forum. If you have new ideas, idea station would be better.
Thanks,
Prabakar.
We have an API preview forum here - http://forums.autodesk.com/t5/preview-api-and-scripts/bd-p/22
Please post questions or comments here and our API team and I will answer asap..
Cheers,
Bankim