Calling JS API's from a custom Feature using FeatureScript

Klinefelters
Klinefelters Member Posts: 2 EDU
Is it possible to call publicly available JS api's from inside of a feature using feature script. I saw a post about using OpenAI's API and OnShape's in python to make a chat-gpt that can generate parts. Since it was mostly api calls I think it can be rewritten to use the JS api's in which case I was thinking of making a chrome extension to do it. Overall it would be a lot easier if it could be incorporated as a feature using featurescript however, as it would be more recognizable to users. Any ideas?

Comments

  • NeilCooke
    NeilCooke Moderator, Onshape Employees Posts: 6,126 image
    FeatureScript cannot access your hard drive or the internet so that custom features can be used by everyone without fear of malware. However, you can use the Onshape API to post FeatureScript code to a Part Studio context, which is what you have read about.
    Senior Director, Technical Services, EMEA