gooddata_sdk.insight.InsightService

class gooddata_sdk.insight.InsightService(api_client: gooddata_sdk.client.GoodDataApiClient)

Bases: object

Insight Service allows retrieval of insights from a GD.CN workspace. The insights are returned as instances of Insight which allows convenient introspection and necessary functions to convert the insight into a form where it can be sent for computation.

Note: the insights are created using GD.CN Analytical Designer or using GoodData.UI SDK. They are stored as visualization objects with a free-form body. This body is specific for AD & SDK. The Insight wrapper exists to take care of these discrepancies.

__init__(api_client: gooddata_sdk.client.GoodDataApiClient) None

Methods

__init__(api_client)

get_insight(workspace_id, insight_id)

Gets a single insight from a workspace.

get_insights(workspace_id)

Gets all insights for a workspace.

get_insight(workspace_id: str, insight_id: str) gooddata_sdk.insight.Insight

Gets a single insight from a workspace.

Parameters
  • workspace_id – identifier of workspace to load insight from

  • insight_id – identifier of the insight

Returns

single insight; the insight will contain sideloaded metadata about the entities it references

Return type

Insight

get_insights(workspace_id: str) list[Insight]

Gets all insights for a workspace. The insights will contain side loaded metadata for all execution entities that they reference.

Parameters

workspace_id – identifier of workspace to load insights from

Returns

all available insights, each insight will contain side loaded metadata about the entities it references