Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape, CAD, maker project and design.

First time visiting? Here are some places to start:

  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. Be respectful, on topic and if you see a problem, Flag it.

If you would like to contact our Community Manager personally, feel free to send a private message or an email.

Embed Onshape Model

dan_engererdan_engerer Member Posts: 61 PRO
edited November 29 in Using Onshape
Hello. 

I want to embed an Onshape model on my customer platform (such as with iFrame or something similar). How can I do this? 

I know that the Clara.IO app makes this relatively easy. However, if I'm not mistaken, the model is not live and therefore takes constant manual "updating"/importing via the Clara.IO approach. Is that true? It's important because we like to keep our customers in the loop during the entire design process, and we don't want to have to constantly update something - that's the beauty of Onshape's "live" nature. Now, if only we could embed this on a page...

Being able to embed the live Onshape model to my customer platform would be an absolute game-changer and really allow Onshape to shine. 
I absolutely love how cutting-edge Onshape is, and I take full advantage of Onshape's live, instant-collaboration to present to my customers. 

Thanks! 

Comments

  • mbartlett21mbartlett21 Member Posts: 1,142 EDU
    You may be able to create something like the Helioz 3d view in its configurator.

    You'd probably need an API key and Three.js or something
    MB (I make FeatureScripts: view FS)
  • michael_mcclainmichael_mcclain Member Posts: 147 PRO
    Hello Dan, maybe take a look at @billy2's post: https://forum.onshape.com/discussion/10618/stacks#latest

    It may offer some good insight into a solution. He posted a different post somewhere on the same topic, but I'm on the phone and can't find it right now.
  • michael_mcclainmichael_mcclain Member Posts: 147 PRO
    Yep that's the post. Thanks @mbartlett21!
  • billy2billy2 Member, OS Professional, Mentor, Developers Posts: 1,079 PRO
    edited November 29
    @dan_engerer we share the same vision. This is what I've been working on. I've added a "Test Block" button that I'm using to create a configurator so you can see it in action. What rusty shed does is call onshape and reads the configuration table for an element in a document and builds an html block with descriptions and variables. Look below and the "Configuration Variables" is this conversion. Change some variables and hit "Submit". 

    Rustyshed.com uses ES6 javascript (I'm currently not transcribing, sorry), it may not work on a cell phone or older browser. 

    Goto https://rustyshed.com and click on "Test Block".



    @mbartlett21 is right, you'll need to use the api key & Three.js. 

    I've been posting on this forum in the programming section how to do this. It's kind of scrambled though. If you're really interested, send me an email [email protected] There's a lot to it.

    In the mean time, share a document that has a configuration in it to [email protected] and we'll see if your idea works. I think it will. Send something that can be public.



  • billy2billy2 Member, OS Professional, Mentor, Developers Posts: 1,079 PRO
    edited November 29
    Rustyshed.com is a live link to the OS document.

    If I change the OS document by moving the block size configuration list down to the pocket size:




    Then click on "Test Block" to re-load the page:



    Notice the "Configuration Variables" updated and "Block Size" is next to "Pocket Size".

    I've been talking to companies that write web configurators and their biggest expense, their biggest head ache are the engineers creating the rules based engines that their configurators are based on. This is silly. The vision is to have something that's easily maintainable and I agree with Dan using OS is going to create a CAD revolution.




  • dan_engererdan_engerer Member Posts: 61 PRO
    Billy2, you must be some kind of genius. 

    I will GLADLY pay you to help me develop an embeddable (such as iFrame) Onshape viewer. In particular, I use the platform called "Quip.com" for engineering documentation, and I allow my customers complete access to our engineering, calculations, and of course, link to our Onshape 3D model. I would LOVE to replace our "Click here for 3D model" link with a live view of the latest Onshape model without us having to constantly update it (like the Clara.IO viewer). 

    So, my problem is two-fold: Getting onshape to "play nice" and then somehow writing a custom script (forgive my layman's language) to work within Quip, which is not like a traditional website. 

    This would be amazing for my business.
  • billy2billy2 Member, OS Professional, Mentor, Developers Posts: 1,079 PRO
    Dan thanks for the kind words....


  • john_mcclaryjohn_mcclary Member, Developers Posts: 1,310 PRO
    @billy2 Having it configure and give a model on the website is what we are looking for too!

    Can you have it spit out a PDF of a drawing?

    This would be perfect for our spiral chute online quote we have been wanting.
  • billy2billy2 Member, OS Professional, Mentor, Developers Posts: 1,079 PRO
    @john_mcclary I'm working on it. I want that too.


  • billy2billy2 Member, OS Professional, Mentor, Developers Posts: 1,079 PRO
    edited December 1
    @john_mcclary Thanks for sharing with me. These are live so any changes that you make to your element's, they will show up here.



    It's interesting to see the variations in assemblies, part studios, feature scripts & elements to see how you're representing shapes. There's a lot of things I can do to help navigate through a document, assembly or part studio.

    I'm wondering if I could add a button that'll allow an onshape user the ability to add a part from your public company library and use it in their design. That way you could keep pricing & availability updated, also you could watch downloads and anticipate demand. If a 1,000 engineers download your part into their latest layouts, you might want to increase production.

    The rubik's cube is really cool, but there wasn't much I could do with it at this time. I'm kinda stuck at part studios with configurations at this time. But, you know, there's always tomorrow.


  • john_mcclaryjohn_mcclary Member, Developers Posts: 1,310 PRO
    edited December 1
    I shared the cube because I figured the beams was going to be too complicated, the only config part in cube was the pointer.

    I wasn't at home so I shared the only public ones I had with configs :)

    Good stuff.

    So what are the requirements to access the document with a website like you did? do you login with a user account in your website script?
    Would we share the document with a dummy user that the website logs in with?
    Does it need to be a public document?

    any luck figuring out PDF export of a drawing?
  • billy2billy2 Member, OS Professional, Mentor, Developers Posts: 1,079 PRO
    edited December 1
    The drawing...
    I'm stuck at updating my DXF editor for updating my border. Turns out I downloaded draft sight from dassault and it took forever, that's when I started on your stuff. The download is finally done and I feel like I've been violated from the experience. I'm ragging on about downloading software. I'll knock it out tomorrow. I've got a motorcycle in my garage and she wants me to pamper her.

    So...
    This is how it works. I have a special link that allows my server access to my OS account. It's extremely secure and borderline a pain-in-the-ass to setup. You share a document with me and it's as if it's mine. If you stop sharing, rustyshed can't show anything, you're in control. If you want it on your site, there's many ways. The easiest is to use an iframe that points to rustyshed. I'll setup a query/route that'll branch and rustyshed does what you want. We could setup a DNS that points to rustyshed and knowing where the request is coming from, we branch. This is referred to as routing and it's one line of code. Ultimately we could setup your own server, which everyone should have, and serve up a configurator, backup, website or what ever. You having a server is the future. Remember the cloud is servers talking to servers.

    The future...
    I think rustyshed is cool,  it's not that hard to do and there's many people building configurators and offering their services. The way the models are built is still key to how this all works out. Building robust parts is going to be everything. 




  • john_mcclaryjohn_mcclary Member, Developers Posts: 1,310 PRO
    Ok, it's pretty much like I figured. So it doesn't need to be public then eh? as long as your login account can have access to the document.

    I know how you feel about draftsight... my computer at work hasn't been able to run Acad (tried 2004 thru 2018) in a few years. It just crashes at launch. (probably some corrupt dll)

    So I've been forced to do everything in DS. Coming from autodesk cad, DS is barely useable. But at least it opens and saves DWG...
    I'm trying out NanoCad now, seems to be a little better so far.

    Yes, if this comes to fruition. I'm going to have to create a quote only document that does nothing but spit out Quote drawings and a step file.
    being able to have a customer get a basic model for their layouts without me dropping everything and busting one out (usually takes me a couple hours, but most of that is reading and understanding their email and size specs)
  • 3dcad3dcad Member, OS Professional, Mentor Posts: 2,287 PRO
    Awesome stuff, awaiting for Onshape to provide 'Share to website' checkbox to add configurator and easily embed into any website straight from their servers. Going forward having a module to implement price calculation into webshop. So why not go straight to word press 'view 3d model' plugin + woocommerce 'calculate price and add to cart' plugin.  B)
    //rami
  • Paul_J_PremakumarPaul_J_Premakumar Member, Onshape Employees Posts: 118
    @3dcad : Can you please write up an IR for being able to embed a model into another website? Thank you.
  • 3dcad3dcad Member, OS Professional, Mentor Posts: 2,287 PRO
    @Paul_J_Premakumar
    I already did, on September 13, 2015 18:11  =)
    //rami
  • john_mcclaryjohn_mcclary Member, Developers Posts: 1,310 PRO
    can you link it, I'd like to vote it up if I haven't already.

    I don't see it in your discussion list
  • 3dcad3dcad Member, OS Professional, Mentor Posts: 2,287 PRO
    //rami
  • Paul_J_PremakumarPaul_J_Premakumar Member, Onshape Employees Posts: 118
    Thanks @3dcad. I had a hard time finding it :).
Sign In or Register to comment.