runtime state change from stopped to started Adf pipeline Rest ApI

Rajesh Gopisetti 5 Reputation points
2023-08-02T17:46:16.99+00:00

I am triggering an adf pipeline from ADF REST API and able to set the schedule trigger and i can see the trigger in Author tab but trigger runtime state showing as “stopped”. I want to make that to Started status so that my pipeline attached to trigger can trigger. How can this changing of trigger programmatically from stopped to started

Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
10,196 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. ShaikMaheer-MSFT 38,401 Reputation points Microsoft Employee
    2023-08-03T17:18:37.6333333+00:00

    Hi

    Thank you for posting query in Microsoft Q&A Platform.

    Considering make below REST API call to start trigger.

    PATCH https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{dataFactoryName}/triggers/{triggerName}?api-version=2018-06-01
    
    Content-Type: application/json
    
    {
      "properties": {
        "runtimeState": "Started"
      }
    }
    
    
    

    Below is the reference document for same.

    https://learn.microsoft.com/en-us/rest/api/datafactory/triggers/create-or-update?tabs=HTTP

    Hope this helps. Please let me know if any further queries.


    Please consider hitting Accept Answer button. Accepted answers help community as well.