How can I get the flow run url from inside the `on...
# ask-community
j
How can I get the flow run url from inside the
on_completion
flow callback?
1
Specifically, getting the
account_id
and
workspace_id
seem like the hard parts. From those I could construct the flow run url.
j
Can you point me to the correct attribute names within the
SettingsContext
that will provide
workspace_id
and
account_id
? I am not seeing them.
Okay here it is:
Copy code
from prefect.context import get_settings_context()
get_settings_context().settings.PREFECT_API_URL
The `PREFECT_API_URL`contains within it the account_id and the workspace_id
🙌 1