Can we trigger another job after one job is finished

we have several test job and we run it at night time when there is no deployment going on so we are planing to execute them such that one test job executes and that will trigger another test job and so on. Can we do that?

1 Like

You could use the testproject api’s TestProject API v2 and at the end of job 1 add a step to start a new job .

@jmulcahy
Can you provide the steps?

Create Jobs that you want to execute

Create a test to trigger job 2 calling the testproject api using the API addon

https://api.testproject.io/v2/projects/1/jobs/1/run

With the following request body

{

“agentId”:“My_TestProject_Agent”,

“browsers”:[

“Chrome”

],

“queue”:true

}

The api auth token can be found following these steps Getting Started With Using the TestProject API - TestProject Documentation

This will trigger job 2 after job 1 has completed

1 Like

hey, @jmulcahy Thank you
It is working.