Discard an audit object - Metasys - LIT-12013522 - Software Application - Basic Services client library for .NET (and COM) - Metasys API - 4.2

Metasys REST Client for .NET and COM Developer Guide

Brand
Metasys
Product name
Basic Services client library for .NET (and COM)
Metasys API
Document type
API Reference Guide
Document number
LIT-12013522
Version
4.2
Revision date
2021-04-07
Language
English (United States)

To discard an audit, use the Discard method. Discard combines the GUID of the audit and the text of an annotation and uses them for the Discard comment. Discard does not return a value.

Note: Discard is only available with API v3.
Table 1. Discard an audit object .NET signature
Library method name Discard
Description Discard an audit object
Method signature Discard(auditID, annotationText);
Method input parameters
  • auditId: GUID of the audit you want to discard.
  • annotationText: the text attached to the audit that you want to discard.
Return value None
The following .NET C# code is an example of a discard audit call:
Guid auditId = new Guid("9cf1c11d-a8cc-48e6-9e4c-f02af26e8fdf");
string annotationText = "Reason why the audit has been discarded";
client.Audits.Discard(auditId, annotationText);