GoodMemGoodMem
ReferenceSdkV2.NET

Instance

Singleton GoodMem instance identity, ownership, and audit metadata.

Namespace: Goodmem.Client.Api · Class: InstanceApi

Reach this surface as client.Instance on a GoodmemClient. Every network method is asynchronous — it returns a Task<T> (or an IAsyncEnumerable<T> for pagination and streaming) and accepts a CancellationToken; the Async suffix marks the standard .NET Task-based async pattern.

Methods

MethodSummary
GetAsyncGet the GoodMem instance.

GetAsync

Returns singleton instance identity, ownership, and audit metadata after requiring effective READ_INSTANCE authority. The built-in ADMIN role supplies this authority; instance ownership alone does not. A scoped API key must also retain READ_INSTANCE in its immutable ceiling. This operation does not expose credentials or mutate instance state.

Declaration

public Task<GoodMemInstance> GetAsync(CancellationToken ct = default)

HTTPGET /v1/instance

Parameters

TypeNameDescription
CancellationTokenctCancellation / deadline signal for the call. (optional)

Returns

Task<GoodMemInstance> — an awaitable that resolves to GoodMemInstance.

Exceptions

TypeCondition
NetworkExceptionThe request could not reach the server (DNS, connection, or TLS failure).
ApiExceptionThe server returned a non-success (non-2xx) status. A status-specific subtype is thrown where it applies — e.g. NotFoundException (404), PermissionDeniedException (403), ConflictException (409).

Example

var instance = await client.Instance.GetAsync();
Console.WriteLine($"{instance.InstanceId} {instance.OwnerId}");


On this page