FoundryStateStore Class

Definition

Developer-facing client for one explicit Foundry state store, bound to a single caller-chosen store Name.

public class FoundryStateStore
type FoundryStateStore = class
Public Class FoundryStateStore
Inheritance
FoundryStateStore

Remarks

Session or conversation scoping is expressed by encoding that identity into the store name itself (for example checkpoints/<conversation-id>). Prefer GetOrCreateAsync over constructing directly: it resolves (or creates) the server-side store resource in one call.

Constructors

Name Description
FoundryStateStore()

Initializes a new instance of the FoundryStateStore class for mocking.

Fields

Name Description
DefaultItemTtlSeconds

The default per-item TTL (30 days, in seconds) applied at store creation.

Properties

Name Description
Name

Gets the logical store name bound to this client.

Methods

Name Description
CreateItemAsync(String, IDictionary<String,BinaryData>, IReadOnlyDictionary<String,String>, CancellationToken)

Creates a new item, failing on a duplicate key.

CreateItemAsync(String, IDictionary<String,BinaryData>, IReadOnlyDictionary<String,String>, String, CancellationToken)

Creates a new item, failing on a duplicate key.

DeleteAsync(CancellationToken)

Deletes the bound store, cascading to every item under it.

DeleteItemAsync(String, String, CancellationToken)

Deletes one item by key.

DeleteItemAsync(String, String, String, CancellationToken)

Deletes one item by key.

GetAsync(CancellationToken)

Fetches the bound store's own descriptor.

GetItemAsync(String, CancellationToken)

Fetches one item by key.

GetItemAsync(String, String, CancellationToken)

Fetches one item by key.

GetOrCreateAsync(String, TokenCredential, Uri, Boolean, Int32, String, IReadOnlyDictionary<String,String>, String, String, CancellationToken)

Returns a client bound to name, creating the store if it does not exist.

ListKeysAsync(IReadOnlyDictionary<String,String>, Nullable<Int32>, String, String, ListRequestOrder, CancellationToken)

Lists keys within the bound store.

ListKeysAsync(IReadOnlyDictionary<String,String>, Nullable<Int32>, String, String, ListRequestOrder, String, CancellationToken)

Lists keys within the bound store.

SetItemAsync(String, IDictionary<String,BinaryData>, IReadOnlyDictionary<String,String>, String, Boolean, CancellationToken)

Creates or replaces one item by key.

SetItemAsync(String, IDictionary<String,BinaryData>, IReadOnlyDictionary<String,String>, String, Boolean, String, CancellationToken)

Creates or replaces one item by key.

UpdateAsync(StateStoreUpdateOptions, CancellationToken)

Updates the bound store's mutable metadata (description / tags).

Applies to