Theo Platt
04/20/2023, 7:03 PMfrom prefect.client.client import Client
c = Client(api_token='xxxxxxxxxx')
params = {'param1': 'Foo', 'param2': 'Bar'}
c.create_flow_run(
version_group_id='xxxx-xxxxxx-xxxxxx-xxxxx',
run_name='my_run_name',
parameters = params)
But I can't see a good example of how to do the same with v2! I think I'm missing something fundamental! ThanksZanie
04/20/2023, 7:04 PMrun_deployment
Theo Platt
04/20/2023, 7:05 PMZanie
04/20/2023, 9:41 PMprefect cloud login
— the variables needed for authentication in other contexts can then be viewed with prefect config view
(the API URL and API KEY are the relevant ones).
You don’t need to provide a client manually to run_deployment
it’ll read settings from the environment.prefect deployment run hello/test
you’d do run_deployment(name="hello/test")
Theo Platt
04/20/2023, 9:43 PMZanie
04/20/2023, 10:18 PM