Hi, is there a way to get the date and time of the...
# ask-community
j
Hi, is there a way to get the date and time of the last successful run of a particular job from the context object? We would like to use this information to parameterize a call to an external API. Many thanks
🌈 1
🤖 1
s
Hi James, You should be able to get the
DagsterInstance
via
context.instance
and then call
get_run_records
on it: https://docs.dagster.io/_apidocs/internals#dagster.DagsterInstance.get_run_records. It’s poorly documented but
RunRecord
objects have a
create_timestamp
attribute.