Skip to main content
Solved

Difficulties of using the import API to create new diagrams


Forum|alt.badge.img+1

Hi,

I am trying to create new diagrams using the import API but I am facing lots of issues:

  • If I take an existing diagram that I want to use as a template, the format for the import is different
  • I can't use the same shapes that in my original diagram (e.g. AWS shapes) in a JSON file that I want to use to import

This is quite blocking honestly. Why can't we create diagrams similar to existing ones created from the editor?

Best answer by alec.bingham

Hey Pierrick, I’m Alec, I’m an engineer with Lucid, hopefully I can help answer your questions/concerns!

As far as your first point goes, I think you’ve confused the separation between our create, copy, and import functionalities (which can be confusing, as they share an endpoint). Our documentation here shows that template is only a parameter when copying a document, not when creating or importing.

Relating to your second point, our JSON Import does not currently support all shape libraries in Lucid. Our documentation here has a list of the available shape libraries, and their corresponding JSON formatting to import. We are however always looking for feedback about what shape libraries customers miss seeing in the JSON Import, so I’ll be sure to let the team know about your request for the AWS shape library.

View original

Forum|alt.badge.img+2

Hey Pierrick, I’m Alec, I’m an engineer with Lucid, hopefully I can help answer your questions/concerns!

As far as your first point goes, I think you’ve confused the separation between our create, copy, and import functionalities (which can be confusing, as they share an endpoint). Our documentation here shows that template is only a parameter when copying a document, not when creating or importing.

Relating to your second point, our JSON Import does not currently support all shape libraries in Lucid. Our documentation here has a list of the available shape libraries, and their corresponding JSON formatting to import. We are however always looking for feedback about what shape libraries customers miss seeing in the JSON Import, so I’ll be sure to let the team know about your request for the AWS shape library.


Forum|alt.badge.img+1

Thanks Alec. As far as I am concerned, the AWS library is essential.

But you should work on making sure that if a shape library is available in your out-of-the-box version, it should also be available through the API.

Thanks


Reply