public void TestCreateBug() { string constantValue = string.Format("{0} at {1} UTC", DateTime.UtcNow.ToLongDateString(), DateTime.UtcNow.ToLongTimeString()); //This is to list fields and their values for bug creation IEnumerable <JsonPatchItem> bugItemValues = FieldValueMap.CreateInstance(Maps.TFSEnumToJsonMap) .Append(FieldName.Title, string.Format("Test Bug Created via API on '{0}'", constantValue)) .Append(FieldName.AssignedTo, "Bankey Sharma") .Append(FieldName.AreaPath, "area-path-value") .Append(FieldName.IterationPath, "iteration-value") .Append(FieldName.Tags, "available-tags") .Append(FieldName.ReproSteps, string.Format("Sample repro steps.\r\n{0}", constantValue)) .Append(FieldName.Priority, "1") .Append(FieldName.Severity, "2 - High") .Build(); azureContext.CreateBug(bugItemValues); }