Guilherme Silva
07/26/2024, 1:22 PMJoseph Heun
07/26/2024, 2:36 PMGuilherme Silva
07/26/2024, 4:28 PMGuilherme Silva
07/26/2024, 8:46 PMIvana Gasparekova
07/30/2024, 11:14 AMGuilherme Silva
07/30/2024, 2:56 PMBranislav Slávik
08/02/2024, 1:43 PMexport_pdf
method currently does not support using and setting the filter values. I reached out to our developers and they are currently reviewing the option of adding this feature. In the meantime, I found a possible workaround -> using the following API calls:
https://www.gooddata.com/docs/cloud/api-and-sdk/api/api_reference_all/#operation/createPdfExport
followed by:
https://www.gooddata.com/docs/cloud/api-and-sdk/api/api_reference_all/#operation/getExportedFile
With that in mind, you can for example "wrap" the calls by using the requests
or some similar package(s):
https://requests.readthedocs.io/en/latest/
I hope that it helps. 🤞🤓Branislav Slávik
08/12/2024, 9:05 AMexport_pdf
method. The change has been included in the version 1.24.0, which was released last week:
https://github.com/gooddata/gooddata-python-sdk/releases/tag/v1.24.0
It can be done by using the metadata
parameter in the same way as if it were via the API call.Guilherme Silva
08/14/2024, 12:57 PMEvangelos Malandrakis
04/14/2025, 8:42 AMfilter_context
id and/or the localIdentifier
? 😊Branislav Slávik
04/24/2025, 3:19 PMfrom gooddata_sdk import GoodDataSdk
from pathlib import Path
profiles = Path("profiles.yaml")
sdk = GoodDataSdk.create_from_profile(profile="bsla.cloud", profiles_path=profiles)
sdk.export.export_pdf(
workspace_id="....",
dashboard_id="....",
file_name="test",
metadata={"filters":[{"dateFilter":{"granularity":"GDC.time.date","type":"absolute","from":"2020-03-24 00:00","to":"2025-04-24 23:59"}},{"attributeFilter":{"attributeElements":{"uris":["James","Jane"]},"displayForm":{"identifier":"NAME","type":"displayForm"},"negativeSelection":False,"localIdentifier":"465a183c6cab4bf4ad9783760cc21bc0","selectionMode":"multi"}}]}
)
In this case, the localIdentifier
was required.
I would say that the best way to get the correct metadata would be to execute the export manually via the UI and then get the metadata
based on the particular exportId
by sending a GET request to the following endpoint:
https://www.gooddata.com/docs/cloud/api-and-sdk/api/api_reference_all/#operation/getMetadata
I hope it helps... 🤞 🤓Evangelos Malandrakis
04/25/2025, 12:58 PM