CodeTransparencyClient.GetEntryStatement Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
GetEntryStatement(String, RequestContext) |
[Protocol Method] Get the transparent statement consisting of the signed statement and the receipt embedded in the header
|
GetEntryStatement(String, CancellationToken) |
Get the transparent statement consisting of the signed statement and the receipt embedded in the header. |
GetEntryStatement(String, RequestContext)
- Source:
- CodeTransparencyClient.cs
[Protocol Method] Get the transparent statement consisting of the signed statement and the receipt embedded in the header
- This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
- Please try the simpler GetEntryStatement(String, CancellationToken) convenience overload with strongly typed models first.
public virtual Azure.Response GetEntryStatement(string entryId, Azure.RequestContext context);
abstract member GetEntryStatement : string * Azure.RequestContext -> Azure.Response
override this.GetEntryStatement : string * Azure.RequestContext -> Azure.Response
Public Overridable Function GetEntryStatement (entryId As String, context As RequestContext) As Response
Parameters
- entryId
- String
ID of the entry to retrieve.
- context
- RequestContext
The request context, which can override default behaviors of the client pipeline on a per-call basis.
Returns
The response returned from the service.
Exceptions
entryId
is null.
entryId
is an empty string, and was expected to be non-empty.
Service returned a non-success status code.
Examples
This sample shows how to call GetEntryStatement and parse the result.
Uri endpoint = new Uri("<endpoint>");
AzureKeyCredential credential = new AzureKeyCredential("<key>");
CodeTransparencyClient client = new CodeTransparencyClient(endpoint, credential);
Response response = client.GetEntryStatement("2.131", null);
JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement;
Console.WriteLine(result.ToString());
Applies to
GetEntryStatement(String, CancellationToken)
- Source:
- CodeTransparencyClient.cs
Get the transparent statement consisting of the signed statement and the receipt embedded in the header.
public virtual Azure.Response<BinaryData> GetEntryStatement(string entryId, System.Threading.CancellationToken cancellationToken = default);
abstract member GetEntryStatement : string * System.Threading.CancellationToken -> Azure.Response<BinaryData>
override this.GetEntryStatement : string * System.Threading.CancellationToken -> Azure.Response<BinaryData>
Public Overridable Function GetEntryStatement (entryId As String, Optional cancellationToken As CancellationToken = Nothing) As Response(Of BinaryData)
Parameters
- entryId
- String
ID of the entry to retrieve.
- cancellationToken
- CancellationToken
The cancellation token to use.
Returns
Exceptions
entryId
is null.
entryId
is an empty string, and was expected to be non-empty.
Examples
This sample shows how to call GetEntryStatement.
Uri endpoint = new Uri("<endpoint>");
AzureKeyCredential credential = new AzureKeyCredential("<key>");
CodeTransparencyClient client = new CodeTransparencyClient(endpoint, credential);
Response<BinaryData> response = client.GetEntryStatement("2.131");