Making Existing Layouts Shared
Monday, December 19, 2022 at 01:37pmWe have a number of existing layouts and we want to make them shared. Is there a way to do it via the API> We's list the layouts and then allow them to tell which ones we need to make shared
Reply to: Making Existing Layouts Shared
Tuesday, December 20, 2022 at 09:27amHi Richard,
You can list the layouts with this API call:
GET /api/layouts
Some useful parameters are:
GET /api/layouts?from=1&to=100&summary=true&visibility=SENDER&ownerUserId=bBfXECpDr04L
(You can find the swagger here.)
If to share the layout is defined by its "visibility", SENDER means not shared and ACCOUNT is shared.
#1 For above API call, it returns layouts created by "ownerUserId". To avoid duplicated layouts shared by other senders, I would suggest to query with the parameter visibility=SENDER
#2 Layout is also a type of package. To update a layout, you simply do:
PUT /api/packages/{layoutId}
{"visibility":"ACCOUNT"}
Duo