This documentation is for the unstable version of GoodData, currrently in development.
For stable version, go to the latest stable version of this article.
For stable version, go to the latest stable version of this article.
catalog_workspace_content.
load_and_put_declarative_analytics_model
load_and_put_declarative_analytics_model(workspace_id: str, layout_root_path: Path)
This method combines load_declarative_analytics_model and put_analytics_model methods to load and set layouts stored using store_declarative_analytics_model.
Parameters
| name | type | description |
|---|---|---|
| workspace_id | str | Workspace identification string e.g. "demo" |
| layout_root_path | Path | Path to the root of the layout directory. Defaults to Path.cwd(). |
Returns
NoneExample
The load and put can be done two ways.
Either by one call:
# Load and put on server the stored layout
sdk.catalog_workspace_content.load_and_put_declarative_analytics_model(
workspace_id="123",
layout_root_path=Path.cwd()
)Or by two separate calls:
# Get analytics layout
declarative_analytics = sdk.catalog_workspace_content.load_declarative_analytics_model(
workspace_id="123",
layout_root_path=Path.cwd()
)
# Put analytics model object back to the server:
sdk.catalog_workspace_content.put_declarative_analytics_model(
workspace_id="123",
analytics_model=declarative_analytics
)The result is identical.