Instance
Methods on this page are called as client.instance.<method>(...) on a Goodmem instance.
Class — ai.pairsys.goodmem.client.api.InstanceAPI (extends internal InstanceAPIBase).
import ai.pairsys.goodmem.client.Goodmem;
try (Goodmem client = Goodmem.builder()
.baseUrl("http://localhost:8080")
.apiKey("gm_...")
.build()) {
// client.instance.<method>(...)
}Async variants
Every method listed below also exists on ai.pairsys.goodmem.client.api.AsyncInstanceAPI (accessed via asyncClient.instance on an AsyncGoodmem) with the same parameter list, wrapped in CompletableFuture<T>. Paginated list methods return CompletableFuture<AsyncPage<T>>. See the async client guide for composition patterns.
import ai.pairsys.goodmem.client.AsyncGoodmem;
try (AsyncGoodmem asyncClient = AsyncGoodmem.builder()
.baseUrl("http://localhost:8080")
.apiKey("gm_...")
.build()) {
asyncClient.instance.<method>(...) // returns CompletableFuture<T>
}Method Summary
| Modifier and Type | Method | Description |
|---|---|---|
GoodMemInstance | get() | Get the GoodMem instance |
Method Detail
get()
GoodMemInstance get()Javadoc — get()
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.
HTTP — GET /v1/instance
Parameters
(no parameters)
Returns — GoodMemInstance
Throws
GoodmemException— base type for every SDK error. A concrete HTTP-status subclass (ApiException,NotFoundException,BadRequestException, …) is thrown per response code. All unchecked (RuntimeException). See Errors.
Example
GoodMemInstance goodMemInstance = client.instance.get();REST equivalent
curl -X GET 'http://localhost:8080/v1/instance' \
-H "x-api-key: gm_..."Errors
Every method on this page may throw the standard HTTP-error class hierarchy rooted at GoodmemException:
BadRequestException (400), AuthenticationException (401), PermissionDeniedException (403), NotFoundException (404), ConflictException (409), UnprocessableEntityException (422), RateLimitException (429), InternalServerException (5xx), or the generic ApiException for any other 4xx/5xx. All are unchecked (RuntimeException). See Errors.
All error classes live in ai.pairsys.goodmem.client.errors and are unchecked (RuntimeException). Async siblings complete the returned CompletableFuture exceptionally with the same types, wrapped in CompletionException at await time. See Errors on the index for the full table.