GoodMemGoodMem
ReferenceSdkV2Go

Instance

package goodmem // import "fury.io/pairsys/goodmem"

Singleton GoodMem instance identity, ownership, and audit metadata.

Methods are called as client.Instance().<Method>(ctx, ...) on a *goodmem.Client. Service: InstanceService.

Index

type InstanceService

type InstanceService struct{ … }

Access this service as client.Instance() on a *goodmem.Client. Its methods follow.

func (s *InstanceService) Get

func (s *InstanceService) Get(ctx context.Context) (*models.GoodMemInstance, error)

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.

HTTPGET /v1/instance

Parameters

  • ctx (context.Context) — carries the deadline and cancellation signal for the call.

Returns(*models.GoodMemInstance, error)

Example

instance, err := client.Instance().Get(ctx)
if err != nil {
	log.Fatal(err)
}
_ = instance.InstanceID
_ = instance.OwnerID