ACCESSING/CONTROLLING ONSHAPE FROM AN EXTERNAL PROGRAM (Python script for instance)

Hello,

Is it possible to access Onshape through an external program, perhaps something written in python?
I am working on a FeatureScript that generates a solid from a .csv file with vertex data.
My goal would be to automate the whole process by having a python script;
1 - generate/update the .csv file (independent from Onshape)
2 - access Onshape
3 - execute custom FeatureScript
4 - export solid model (in a given format, .STL or .STEP for instance)

Thank you!

Comments

  • awk
    awk Member, Onshape Employees, Developers Posts: 78 image
    Yes - this is possible using our REST APIs and an authentication mechanism known as an 'API Key'.

    Sign in to our Developer portal at https://dev-portal.onshape.com - you'll be asked to agree to our API usage terms & agreement the first time.

    In the Developer portal you'll find links to documentation on the API and API Keys, and links to sample code on github - https://github.com/onshape-public/apikey in particular has some python library code for making requests using an API Key.
    Director of API, Appstore, and App Partner Technical Support
  • fluvio_lobo_fenoglietto
    fluvio_lobo_fenoglietto Member Posts: 36 PRO
    @andrew_kimpton

    Thank you!
  • robin_jackl
    robin_jackl Member Posts: 2 ✭
    How does it work with the OAuth application. The application API Key isn't avaliable any longer so u have to use the OAuth ...