Skip to content

Commit 307d953

Browse files
authored
[Confidential Ledger] [DP] Readme Updates for tags (Azure#50727)
* [Confidential Ledger] [DP] Readme Updates for tags
1 parent 47c95e1 commit 307d953

File tree

1 file changed

+17
-1
lines changed
  • sdk/confidentialledger/Azure.Security.ConfidentialLedger

1 file changed

+17
-1
lines changed

sdk/confidentialledger/Azure.Security.ConfidentialLedger/README.md

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -288,10 +288,26 @@ Console.WriteLine($"The latest ledger entry from the collection is {latestCollec
288288
Ledger entries in a collection may be retrieved over a range of transaction ids.
289289
Note: Both ranges are optional; they can be provided individually or not at all.
290290

291-
```C# Snippet:RangedQuery
291+
```C#
292292
ledgerClient.GetLedgerEntries(fromTransactionId: "2.1", toTransactionId: collectionTransactionId);
293293
```
294+
#### Tags
295+
It is possible to further organize data within a collection as part of the latest preview version dated `2024-12-09-preview` or newer.
296+
297+
Specify the `tags` parameter as part of the create entry operation. Multiple tags can be specified using commas. There is a limit of five tags per transaction.
294298

299+
```C#
300+
string tags = "tag1,tag2";
301+
302+
Response result = await Client.CreateLedgerEntryAsync(content, collectionId, tags);
303+
```
304+
305+
```C#
306+
307+
// Specify collection ID and tag. Optionally add a range of transaction IDs.
308+
// Only one tag is permitted in each retrieval operation.
309+
var result = Client.GetLedgerEntriesAsync(collectionId, "tag1");
310+
```
295311
### User management
296312

297313
Users are managed directly with the confidential ledger instead of through Azure. New users may be AAD-based or certificate-based.

0 commit comments

Comments
 (0)