diff --git a/core/runner/runner.go b/core/runner/runner.go index 4c18ab503..f8020a7be 100644 --- a/core/runner/runner.go +++ b/core/runner/runner.go @@ -9,6 +9,7 @@ import ( "github.com/nyaruka/goflow/assets" "github.com/nyaruka/goflow/excellent/types" "github.com/nyaruka/goflow/flows" + "github.com/nyaruka/goflow/flows/routers" "github.com/nyaruka/goflow/flows/triggers" "github.com/nyaruka/librato" "github.com/nyaruka/mailroom/core/goflow" @@ -84,6 +85,14 @@ func ResumeFlow(ctx context.Context, rt *runtime.Runtime, oa *models.OrgAssets, return nil, errors.Wrapf(err, "unable to create session from output") } + // set authentication token for zeroshot requests in goflow + apiToken := rt.Config.ZeroshotAPIToken + routers.SetToken(apiToken) + + // set base url for zeroshot requests + baseURL := rt.Config.ZeroshotAPIUrl + routers.SetAPIURL(baseURL) + // resume our session resumeStart := time.Now() sprint, err := fs.Resume(resume)