cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
LukeMifsud
New Member

Setting the Created By on DevOps Work Items using Flow

Hi,

 

We have created a flow that generates a number of Work Items that are linked as children when a certain Work Item is created in Azure DevOps.

 

The issue we currently have is that these generated Work Items have the creator of the flow set as the person that created these Work Items.

 

Is it possible to dictate the created by field to the person that creates the Work Item that triggers the flow or is this field not editable in DevOps?

1 REPLY 1
Expiscornovus
Super User
Super User

Hi @LukeMifsud,


You can use the bypassRules property in the creation of a work item via the Azure DevOps Rest API. This allows you to set the createdby if you have sufficient permissions in the DevOps Project.

https://developercommunity.visualstudio.com/t/change-systemcreatedby/283179

https://docs.microsoft.com/en-us/rest/api/azure/devops/wit/work%20items/create?view=azure-devops-res...

 

Below is an example of that.

 

[
  {
    "op": "add",
    "path": "/fields/System.Title",
    "from": null,
    "value": "Sample task"
  },
  {
    "op": "add",
    "path": "/fields/System.CreatedBy",
    "value": "Jane Doe"
  },
 {
    "op": "add",
    "path": "/fields/System.ChangedBy",
    "value": "Jane Doe"
  }
]

createdby_changedby_bypassrules_devops.png

 

This example will create a task.

 

createdbytask.png

 

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Users online (2,632)