api

package
v0.0.0-...-796927e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 3, 2026 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Package api contains generated HTTP client bindings for memoryd.

Package api provides primitives to interact with the openapi HTTP API.

Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.8.0 DO NOT EDIT.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewBrowseMemoriesRequest

func NewBrowseMemoriesRequest(server string, params *BrowseMemoriesParams) (*http.Request, error)

NewBrowseMemoriesRequest constructs an http.Request for the BrowseMemories method

func NewDeleteMemoryRequest

func NewDeleteMemoryRequest(server string, memoryId MemoryId) (*http.Request, error)

NewDeleteMemoryRequest constructs an http.Request for the DeleteMemory method

func NewGetLivenessRequest

func NewGetLivenessRequest(server string) (*http.Request, error)

NewGetLivenessRequest constructs an http.Request for the GetLiveness method

func NewGetMemoryContentRequest

func NewGetMemoryContentRequest(server string, memoryId MemoryId) (*http.Request, error)

NewGetMemoryContentRequest constructs an http.Request for the GetMemoryContent method

func NewGetMemoryRequest

func NewGetMemoryRequest(server string, memoryId MemoryId) (*http.Request, error)

NewGetMemoryRequest constructs an http.Request for the GetMemory method

func NewGetReadinessRequest

func NewGetReadinessRequest(server string) (*http.Request, error)

NewGetReadinessRequest constructs an http.Request for the GetReadiness method

func NewGetRebuildStatusRequest

func NewGetRebuildStatusRequest(server string, rebuildId openapi_types.UUID) (*http.Request, error)

NewGetRebuildStatusRequest constructs an http.Request for the GetRebuildStatus method

func NewImportMemoryRequestWithBody

func NewImportMemoryRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewImportMemoryRequestWithBody constructs an http.Request for the ImportMemory method, with any body, and a specified content type

func NewRebuildMemoryRequest

func NewRebuildMemoryRequest(server string, memoryId MemoryId, body RebuildMemoryJSONRequestBody) (*http.Request, error)

NewRebuildMemoryRequest calls the generic RebuildMemory builder with application/json body

func NewRebuildMemoryRequestWithBody

func NewRebuildMemoryRequestWithBody(server string, memoryId MemoryId, contentType string, body io.Reader) (*http.Request, error)

NewRebuildMemoryRequestWithBody constructs an http.Request for the RebuildMemory method, with any body, and a specified content type

func NewSearchMemoriesRequest

func NewSearchMemoriesRequest(server string, params *SearchMemoriesParams) (*http.Request, error)

NewSearchMemoriesRequest constructs an http.Request for the SearchMemories method

Types

type BrowseMemoriesParams

type BrowseMemoriesParams struct {
	Limit  *Limit  `form:"limit,omitempty" json:"limit,omitempty"`
	Cursor *Cursor `form:"cursor,omitempty" json:"cursor,omitempty"`
}

BrowseMemoriesParams defines parameters for BrowseMemories.

type BrowseMemoriesResponse

type BrowseMemoriesResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	// JSON200 the response for an HTTP 200 `application/json` response
	JSON200 *MemoryPage
	// JSON400 the response for an HTTP 400 `application/json` response
	JSON400 *Error
}

func ParseBrowseMemoriesResponse

func ParseBrowseMemoriesResponse(rsp *http.Response) (*BrowseMemoriesResponse, error)

ParseBrowseMemoriesResponse parses an HTTP response from a BrowseMemoriesWithResponse call

func (BrowseMemoriesResponse) ContentType

func (r BrowseMemoriesResponse) ContentType() string

ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers

func (BrowseMemoriesResponse) GetBody

func (r BrowseMemoriesResponse) GetBody() []byte

GetBody returns the raw response body bytes

func (BrowseMemoriesResponse) GetJSON200

func (r BrowseMemoriesResponse) GetJSON200() *MemoryPage

GetJSON200 returns the response for an HTTP 200 `application/json` response

func (BrowseMemoriesResponse) GetJSON400

func (r BrowseMemoriesResponse) GetJSON400() *Error

GetJSON400 returns the response for an HTTP 400 `application/json` response

func (BrowseMemoriesResponse) Status

func (r BrowseMemoriesResponse) Status() string

Status returns HTTPResponse.Status

func (BrowseMemoriesResponse) StatusCode

func (r BrowseMemoriesResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type Client

type Client struct {
	// The endpoint of the server conforming to this interface, with scheme,
	// https://api.deepmap.com for example. This can contain a path relative
	// to the server, such as https://api.deepmap.com/dev-test, and all the
	// paths in the swagger spec will be appended to the server.
	Server string

	// Doer for performing requests, typically a *http.Client with any
	// customized settings, such as certificate chains.
	Client HttpRequestDoer

	// A list of callbacks for modifying requests which are generated before sending over
	// the network.
	RequestEditors []RequestEditorFn
}

Client which conforms to the OpenAPI3 specification for this service.

func NewClient

func NewClient(server string, opts ...ClientOption) (*Client, error)

Creates a new Client, with reasonable defaults

func (*Client) BrowseMemories

func (c *Client) BrowseMemories(ctx context.Context, params *BrowseMemoriesParams, reqEditors ...RequestEditorFn) (*http.Response, error)

BrowseMemories Browse committed Memories

Corresponds with GET /memories (the `BrowseMemories` operationId).

func (*Client) DeleteMemory

func (c *Client) DeleteMemory(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*http.Response, error)

DeleteMemory Delete one Memory and its Blob

Permanently deletes the Memory, its Understanding Runs, and the immutable Blob referenced by it. The Vault reuses the Blob only when its content is imported again.

Corresponds with DELETE /memories/{memoryId} (the `DeleteMemory` operationId).

func (*Client) GetLiveness

func (c *Client) GetLiveness(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

GetLiveness Check whether the process is alive

Corresponds with GET /livez (the `GetLiveness` operationId).

func (*Client) GetMemory

func (c *Client) GetMemory(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*http.Response, error)

GetMemory Get committed Memory details

Corresponds with GET /memories/{memoryId} (the `GetMemory` operationId).

func (*Client) GetMemoryContent

func (c *Client) GetMemoryContent(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*http.Response, error)

GetMemoryContent Download and verify a Memory's immutable Blob

Corresponds with GET /memories/{memoryId}/content (the `GetMemoryContent` operationId).

func (*Client) GetReadiness

func (c *Client) GetReadiness(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

GetReadiness Check whether the server can accept requests

Corresponds with GET /readyz (the `GetReadiness` operationId).

func (*Client) GetRebuildStatus

func (c *Client) GetRebuildStatus(ctx context.Context, rebuildId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error)

GetRebuildStatus Poll a retained process-local Rebuild

Retained until superseded by a newly accepted attempt, Memory deletion, or restart. Terminal handles remain readable; no artifacts are returned.

Corresponds with GET /rebuild-status/{rebuildId} (the `GetRebuildStatus` operationId).

func (*Client) ImportMemoryWithBody

func (c *Client) ImportMemoryWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

ImportMemoryWithBody Durably import one Blob as a Memory

Upload one Blob and return after its bytes are durably published and the Memory is committed. A Blob may contain at most 100 MiB (104857600 bytes). The server permits bounded multipart protocol overhead in addition to that Blob limit. Duplicate content is rejected with HTTP 409. Document Understanding is not performed by this request.

Takes any type of body and a specified content type.

Corresponds with POST /memories/import (the `ImportMemory` operationId).

func (*Client) RebuildMemory

func (c *Client) RebuildMemory(ctx context.Context, memoryId MemoryId, body RebuildMemoryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

RebuildMemory Request a Memory Rebuild

Accept process-local work using current Document Understanding methods. An optional user_note replaces the saved Memory guidance; absent or null user_note reuses the saved note, and an empty string clears it. The original Blob and previous active Run remain unchanged. Acceptance is best effort: queued/running work and polling handles are lost on restart. Competing queued/running work returns 409 without scheduling or changing the saved note.

Takes a body of the `application/json` content type.

Corresponds with POST /memories/{memoryId}/rebuild (the `RebuildMemory` operationId).

func (*Client) RebuildMemoryWithBody

func (c *Client) RebuildMemoryWithBody(ctx context.Context, memoryId MemoryId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

RebuildMemoryWithBody Request a Memory Rebuild

Accept process-local work using current Document Understanding methods. An optional user_note replaces the saved Memory guidance; absent or null user_note reuses the saved note, and an empty string clears it. The original Blob and previous active Run remain unchanged. Acceptance is best effort: queued/running work and polling handles are lost on restart. Competing queued/running work returns 409 without scheduling or changing the saved note.

Takes any type of body and a specified content type.

Corresponds with POST /memories/{memoryId}/rebuild (the `RebuildMemory` operationId).

func (*Client) SearchMemories

func (c *Client) SearchMemories(ctx context.Context, params *SearchMemoriesParams, reqEditors ...RequestEditorFn) (*http.Response, error)

SearchMemories Search committed Memories

Search results are returned in ranked pages. Supply the returned cursor with the same trimmed query to continue. Cursors do not snapshot Vault mutations between requests.

Corresponds with GET /memories/search (the `SearchMemories` operationId).

type ClientInterface

type ClientInterface interface {

	// GetLiveness Check whether the process is alive
	//
	// Corresponds with GET /livez (the `GetLiveness` operationId).
	GetLiveness(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// BrowseMemories Browse committed Memories
	//
	// Corresponds with GET /memories (the `BrowseMemories` operationId).
	BrowseMemories(ctx context.Context, params *BrowseMemoriesParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// ImportMemoryWithBody Durably import one Blob as a Memory
	//
	// Upload one Blob and return after its bytes are durably published and
	// the Memory is committed. A Blob may contain at most 100 MiB
	// (104857600 bytes). The server permits bounded multipart protocol
	// overhead in addition to that Blob limit. Duplicate content is rejected
	// with HTTP 409. Document Understanding is not performed by this request.
	//
	// Takes any type of body and a specified content type.
	//
	// Corresponds with POST /memories/import (the `ImportMemory` operationId).
	ImportMemoryWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	// SearchMemories Search committed Memories
	//
	// Search results are returned in ranked pages. Supply the returned cursor
	// with the same trimmed query to continue. Cursors do not snapshot Vault
	// mutations between requests.
	//
	// Corresponds with GET /memories/search (the `SearchMemories` operationId).
	SearchMemories(ctx context.Context, params *SearchMemoriesParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteMemory Delete one Memory and its Blob
	//
	// Permanently deletes the Memory, its Understanding Runs, and the
	// immutable Blob referenced by it. The Vault reuses the Blob only when
	// its content is imported again.
	//
	// Corresponds with DELETE /memories/{memoryId} (the `DeleteMemory` operationId).
	DeleteMemory(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetMemory Get committed Memory details
	//
	// Corresponds with GET /memories/{memoryId} (the `GetMemory` operationId).
	GetMemory(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetMemoryContent Download and verify a Memory's immutable Blob
	//
	// Corresponds with GET /memories/{memoryId}/content (the `GetMemoryContent` operationId).
	GetMemoryContent(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*http.Response, error)

	// RebuildMemoryWithBody Request a Memory Rebuild
	//
	// Accept process-local work using current Document Understanding methods.
	// An optional user_note replaces the saved Memory guidance; absent or
	// null user_note reuses the saved note, and an empty string clears it.
	// The original Blob and previous active Run remain unchanged. Acceptance
	// is best effort: queued/running work and polling handles are lost on
	// restart. Competing queued/running work returns 409 without scheduling
	// or changing the saved note.
	//
	// Takes any type of body and a specified content type.
	//
	// Corresponds with POST /memories/{memoryId}/rebuild (the `RebuildMemory` operationId).
	RebuildMemoryWithBody(ctx context.Context, memoryId MemoryId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	// RebuildMemory Request a Memory Rebuild
	//
	// Accept process-local work using current Document Understanding methods.
	// An optional user_note replaces the saved Memory guidance; absent or
	// null user_note reuses the saved note, and an empty string clears it.
	// The original Blob and previous active Run remain unchanged. Acceptance
	// is best effort: queued/running work and polling handles are lost on
	// restart. Competing queued/running work returns 409 without scheduling
	// or changing the saved note.
	//
	// Takes a body of the `application/json` content type.
	//
	// Corresponds with POST /memories/{memoryId}/rebuild (the `RebuildMemory` operationId).
	RebuildMemory(ctx context.Context, memoryId MemoryId, body RebuildMemoryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetReadiness Check whether the server can accept requests
	//
	// Corresponds with GET /readyz (the `GetReadiness` operationId).
	GetReadiness(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetRebuildStatus Poll a retained process-local Rebuild
	//
	// Retained until superseded by a newly accepted attempt, Memory deletion,
	// or restart. Terminal handles remain readable; no artifacts are returned.
	//
	// Corresponds with GET /rebuild-status/{rebuildId} (the `GetRebuildStatus` operationId).
	GetRebuildStatus(ctx context.Context, rebuildId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error)
}

The interface specification for the client above.

type ClientOption

type ClientOption func(*Client) error

ClientOption allows setting custom parameters during construction

func WithBaseURL

func WithBaseURL(baseURL string) ClientOption

WithBaseURL overrides the baseURL.

func WithHTTPClient

func WithHTTPClient(doer HttpRequestDoer) ClientOption

WithHTTPClient allows overriding the default Doer, which is automatically created using http.Client. This is useful for tests.

func WithRequestEditorFn

func WithRequestEditorFn(fn RequestEditorFn) ClientOption

WithRequestEditorFn allows setting up a callback function, which will be called right before sending the request. This can be used to mutate the request.

type ClientWithResponses

type ClientWithResponses struct {
	ClientInterface
}

ClientWithResponses builds on ClientInterface to offer response payloads

func NewClientWithResponses

func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error)

NewClientWithResponses creates a new ClientWithResponses, which wraps Client with return type handling

func (*ClientWithResponses) BrowseMemoriesWithResponse

func (c *ClientWithResponses) BrowseMemoriesWithResponse(ctx context.Context, params *BrowseMemoriesParams, reqEditors ...RequestEditorFn) (*BrowseMemoriesResponse, error)

BrowseMemoriesWithResponse Browse committed Memories

Returns a wrapper object for the known response body format(s).

Corresponds with GET /memories (the `BrowseMemories` operationId).

func (*ClientWithResponses) DeleteMemoryWithResponse

func (c *ClientWithResponses) DeleteMemoryWithResponse(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*DeleteMemoryResponse, error)

DeleteMemoryWithResponse Delete one Memory and its Blob

Permanently deletes the Memory, its Understanding Runs, and the immutable Blob referenced by it. The Vault reuses the Blob only when its content is imported again.

Returns a wrapper object for the known response body format(s).

Corresponds with DELETE /memories/{memoryId} (the `DeleteMemory` operationId).

func (*ClientWithResponses) GetLivenessWithResponse

func (c *ClientWithResponses) GetLivenessWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetLivenessResponse, error)

GetLivenessWithResponse Check whether the process is alive

Returns a wrapper object for the known response body format(s).

Corresponds with GET /livez (the `GetLiveness` operationId).

func (*ClientWithResponses) GetMemoryContentWithResponse

func (c *ClientWithResponses) GetMemoryContentWithResponse(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*GetMemoryContentResponse, error)

GetMemoryContentWithResponse Download and verify a Memory's immutable Blob

Returns a wrapper object for the known response body format(s).

Corresponds with GET /memories/{memoryId}/content (the `GetMemoryContent` operationId).

func (*ClientWithResponses) GetMemoryWithResponse

func (c *ClientWithResponses) GetMemoryWithResponse(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*GetMemoryResponse, error)

GetMemoryWithResponse Get committed Memory details

Returns a wrapper object for the known response body format(s).

Corresponds with GET /memories/{memoryId} (the `GetMemory` operationId).

func (*ClientWithResponses) GetReadinessWithResponse

func (c *ClientWithResponses) GetReadinessWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetReadinessResponse, error)

GetReadinessWithResponse Check whether the server can accept requests

Returns a wrapper object for the known response body format(s).

Corresponds with GET /readyz (the `GetReadiness` operationId).

func (*ClientWithResponses) GetRebuildStatusWithResponse

func (c *ClientWithResponses) GetRebuildStatusWithResponse(ctx context.Context, rebuildId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetRebuildStatusResponse, error)

GetRebuildStatusWithResponse Poll a retained process-local Rebuild

Retained until superseded by a newly accepted attempt, Memory deletion, or restart. Terminal handles remain readable; no artifacts are returned.

Returns a wrapper object for the known response body format(s).

Corresponds with GET /rebuild-status/{rebuildId} (the `GetRebuildStatus` operationId).

func (*ClientWithResponses) ImportMemoryWithBodyWithResponse

func (c *ClientWithResponses) ImportMemoryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ImportMemoryResponse, error)

ImportMemoryWithBodyWithResponse Durably import one Blob as a Memory

Upload one Blob and return after its bytes are durably published and the Memory is committed. A Blob may contain at most 100 MiB (104857600 bytes). The server permits bounded multipart protocol overhead in addition to that Blob limit. Duplicate content is rejected with HTTP 409. Document Understanding is not performed by this request.

Takes any type of body and a specified content type, and returns a wrapper object for the known response body format(s).

Corresponds with POST /memories/import (the `ImportMemory` operationId).

func (*ClientWithResponses) RebuildMemoryWithBodyWithResponse

func (c *ClientWithResponses) RebuildMemoryWithBodyWithResponse(ctx context.Context, memoryId MemoryId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RebuildMemoryResponse, error)

RebuildMemoryWithBodyWithResponse Request a Memory Rebuild

Accept process-local work using current Document Understanding methods. An optional user_note replaces the saved Memory guidance; absent or null user_note reuses the saved note, and an empty string clears it. The original Blob and previous active Run remain unchanged. Acceptance is best effort: queued/running work and polling handles are lost on restart. Competing queued/running work returns 409 without scheduling or changing the saved note.

Takes any type of body and a specified content type, and returns a wrapper object for the known response body format(s).

Corresponds with POST /memories/{memoryId}/rebuild (the `RebuildMemory` operationId).

func (*ClientWithResponses) RebuildMemoryWithResponse

func (c *ClientWithResponses) RebuildMemoryWithResponse(ctx context.Context, memoryId MemoryId, body RebuildMemoryJSONRequestBody, reqEditors ...RequestEditorFn) (*RebuildMemoryResponse, error)

RebuildMemoryWithResponse Request a Memory Rebuild

Accept process-local work using current Document Understanding methods. An optional user_note replaces the saved Memory guidance; absent or null user_note reuses the saved note, and an empty string clears it. The original Blob and previous active Run remain unchanged. Acceptance is best effort: queued/running work and polling handles are lost on restart. Competing queued/running work returns 409 without scheduling or changing the saved note.

Takes a body of the `application/json` content type, and returns a wrapper object for the known response body format(s).

Corresponds with POST /memories/{memoryId}/rebuild (the `RebuildMemory` operationId).

func (*ClientWithResponses) SearchMemoriesWithResponse

func (c *ClientWithResponses) SearchMemoriesWithResponse(ctx context.Context, params *SearchMemoriesParams, reqEditors ...RequestEditorFn) (*SearchMemoriesResponse, error)

SearchMemoriesWithResponse Search committed Memories

Search results are returned in ranked pages. Supply the returned cursor with the same trimmed query to continue. Cursors do not snapshot Vault mutations between requests.

Returns a wrapper object for the known response body format(s).

Corresponds with GET /memories/search (the `SearchMemories` operationId).

type ClientWithResponsesInterface

type ClientWithResponsesInterface interface {

	// GetLivenessWithResponse Check whether the process is alive
	//
	// Returns a wrapper object for the known response body format(s).
	//
	// Corresponds with GET /livez (the `GetLiveness` operationId).
	GetLivenessWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetLivenessResponse, error)

	// BrowseMemoriesWithResponse Browse committed Memories
	//
	// Returns a wrapper object for the known response body format(s).
	//
	// Corresponds with GET /memories (the `BrowseMemories` operationId).
	BrowseMemoriesWithResponse(ctx context.Context, params *BrowseMemoriesParams, reqEditors ...RequestEditorFn) (*BrowseMemoriesResponse, error)

	// ImportMemoryWithBodyWithResponse Durably import one Blob as a Memory
	//
	// Upload one Blob and return after its bytes are durably published and
	// the Memory is committed. A Blob may contain at most 100 MiB
	// (104857600 bytes). The server permits bounded multipart protocol
	// overhead in addition to that Blob limit. Duplicate content is rejected
	// with HTTP 409. Document Understanding is not performed by this request.
	//
	// Takes any type of body and a specified content type, and returns a wrapper object for the known response body format(s).
	//
	// Corresponds with POST /memories/import (the `ImportMemory` operationId).
	ImportMemoryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ImportMemoryResponse, error)

	// SearchMemoriesWithResponse Search committed Memories
	//
	// Search results are returned in ranked pages. Supply the returned cursor
	// with the same trimmed query to continue. Cursors do not snapshot Vault
	// mutations between requests.
	//
	// Returns a wrapper object for the known response body format(s).
	//
	// Corresponds with GET /memories/search (the `SearchMemories` operationId).
	SearchMemoriesWithResponse(ctx context.Context, params *SearchMemoriesParams, reqEditors ...RequestEditorFn) (*SearchMemoriesResponse, error)

	// DeleteMemoryWithResponse Delete one Memory and its Blob
	//
	// Permanently deletes the Memory, its Understanding Runs, and the
	// immutable Blob referenced by it. The Vault reuses the Blob only when
	// its content is imported again.
	//
	// Returns a wrapper object for the known response body format(s).
	//
	// Corresponds with DELETE /memories/{memoryId} (the `DeleteMemory` operationId).
	DeleteMemoryWithResponse(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*DeleteMemoryResponse, error)

	// GetMemoryWithResponse Get committed Memory details
	//
	// Returns a wrapper object for the known response body format(s).
	//
	// Corresponds with GET /memories/{memoryId} (the `GetMemory` operationId).
	GetMemoryWithResponse(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*GetMemoryResponse, error)

	// GetMemoryContentWithResponse Download and verify a Memory's immutable Blob
	//
	// Returns a wrapper object for the known response body format(s).
	//
	// Corresponds with GET /memories/{memoryId}/content (the `GetMemoryContent` operationId).
	GetMemoryContentWithResponse(ctx context.Context, memoryId MemoryId, reqEditors ...RequestEditorFn) (*GetMemoryContentResponse, error)

	// RebuildMemoryWithBodyWithResponse Request a Memory Rebuild
	//
	// Accept process-local work using current Document Understanding methods.
	// An optional user_note replaces the saved Memory guidance; absent or
	// null user_note reuses the saved note, and an empty string clears it.
	// The original Blob and previous active Run remain unchanged. Acceptance
	// is best effort: queued/running work and polling handles are lost on
	// restart. Competing queued/running work returns 409 without scheduling
	// or changing the saved note.
	//
	// Takes any type of body and a specified content type, and returns a wrapper object for the known response body format(s).
	//
	// Corresponds with POST /memories/{memoryId}/rebuild (the `RebuildMemory` operationId).
	RebuildMemoryWithBodyWithResponse(ctx context.Context, memoryId MemoryId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RebuildMemoryResponse, error)

	// RebuildMemoryWithResponse Request a Memory Rebuild
	//
	// Accept process-local work using current Document Understanding methods.
	// An optional user_note replaces the saved Memory guidance; absent or
	// null user_note reuses the saved note, and an empty string clears it.
	// The original Blob and previous active Run remain unchanged. Acceptance
	// is best effort: queued/running work and polling handles are lost on
	// restart. Competing queued/running work returns 409 without scheduling
	// or changing the saved note.
	//
	// Takes a body of the `application/json` content type, and returns a wrapper object for the known response body format(s).
	//
	// Corresponds with POST /memories/{memoryId}/rebuild (the `RebuildMemory` operationId).
	RebuildMemoryWithResponse(ctx context.Context, memoryId MemoryId, body RebuildMemoryJSONRequestBody, reqEditors ...RequestEditorFn) (*RebuildMemoryResponse, error)

	// GetReadinessWithResponse Check whether the server can accept requests
	//
	// Returns a wrapper object for the known response body format(s).
	//
	// Corresponds with GET /readyz (the `GetReadiness` operationId).
	GetReadinessWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetReadinessResponse, error)

	// GetRebuildStatusWithResponse Poll a retained process-local Rebuild
	//
	// Retained until superseded by a newly accepted attempt, Memory deletion,
	// or restart. Terminal handles remain readable; no artifacts are returned.
	//
	// Returns a wrapper object for the known response body format(s).
	//
	// Corresponds with GET /rebuild-status/{rebuildId} (the `GetRebuildStatus` operationId).
	GetRebuildStatusWithResponse(ctx context.Context, rebuildId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetRebuildStatusResponse, error)
}

ClientWithResponsesInterface is the interface specification for the client with responses above.

type CostEstimate

type CostEstimate struct {
	AmountUsd   float64 `json:"amount_usd"`
	Basis       string  `json:"basis"`
	PricingDate *string `json:"pricing_date,omitempty"`
	PricingUrl  *string `json:"pricing_url,omitempty"`
}

CostEstimate defines model for CostEstimate.

type Cursor

type Cursor = string

Cursor defines model for Cursor.

type DeleteMemoryResponse

type DeleteMemoryResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	// JSON404 the response for an HTTP 404 `application/json` response
	JSON404 *Error
}

func ParseDeleteMemoryResponse

func ParseDeleteMemoryResponse(rsp *http.Response) (*DeleteMemoryResponse, error)

ParseDeleteMemoryResponse parses an HTTP response from a DeleteMemoryWithResponse call

func (DeleteMemoryResponse) ContentType

func (r DeleteMemoryResponse) ContentType() string

ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers

func (DeleteMemoryResponse) GetBody

func (r DeleteMemoryResponse) GetBody() []byte

GetBody returns the raw response body bytes

func (DeleteMemoryResponse) GetJSON404

func (r DeleteMemoryResponse) GetJSON404() *Error

GetJSON404 returns the response for an HTTP 404 `application/json` response

func (DeleteMemoryResponse) Status

func (r DeleteMemoryResponse) Status() string

Status returns HTTPResponse.Status

func (DeleteMemoryResponse) StatusCode

func (r DeleteMemoryResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type DerivedContent

type DerivedContent struct {
	BlobHash string `json:"blob_hash"`
	ByteSize int64  `json:"byte_size"`

	// Content Literal UTF-8 text content.
	Content     string             `json:"content"`
	ContentType string             `json:"content_type"`
	Id          openapi_types.UUID `json:"id"`

	// Provenance Optional opaque plugin-defined JSON metadata.
	Provenance interface{} `json:"provenance,omitempty"`

	// Scope Optional opaque plugin-defined JSON metadata.
	Scope interface{} `json:"scope,omitempty"`
}

DerivedContent Independent text artifact belonging to its containing Run.

type DuplicateMemory

type DuplicateMemory struct {
	Id openapi_types.UUID `json:"id"`
}

DuplicateMemory defines model for DuplicateMemory.

type Error

type Error struct {
	// Code Example: memory_not_found
	Code    string                  `json:"code"`
	Details *map[string]interface{} `json:"details,omitempty"`

	// ExistingMemory Present on a duplicate import conflict so clients can recover.
	ExistingMemory *DuplicateMemory `json:"existing_memory,omitempty"`
	Message        string           `json:"message"`
}

Error defines model for Error.

type GetLivenessResponse

type GetLivenessResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	// JSON200 the response for an HTTP 200 `application/json` response
	JSON200 *HealthResponse
}

func ParseGetLivenessResponse

func ParseGetLivenessResponse(rsp *http.Response) (*GetLivenessResponse, error)

ParseGetLivenessResponse parses an HTTP response from a GetLivenessWithResponse call

func (GetLivenessResponse) ContentType

func (r GetLivenessResponse) ContentType() string

ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers

func (GetLivenessResponse) GetBody

func (r GetLivenessResponse) GetBody() []byte

GetBody returns the raw response body bytes

func (GetLivenessResponse) GetJSON200

func (r GetLivenessResponse) GetJSON200() *HealthResponse

GetJSON200 returns the response for an HTTP 200 `application/json` response

func (GetLivenessResponse) Status

func (r GetLivenessResponse) Status() string

Status returns HTTPResponse.Status

func (GetLivenessResponse) StatusCode

func (r GetLivenessResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetMemoryContentResponse

type GetMemoryContentResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	// JSON404 the response for an HTTP 404 `application/json` response
	JSON404 *Error
	// JSON500 the response for an HTTP 500 `application/json` response
	JSON500 *Error
	// JSON507 the response for an HTTP 507 `application/json` response
	JSON507 *Error
	// Headers200 the parsed response headers for an HTTP 200 response
	Headers200 *GetMemoryContentResponse200Headers
}

func ParseGetMemoryContentResponse

func ParseGetMemoryContentResponse(rsp *http.Response) (*GetMemoryContentResponse, error)

ParseGetMemoryContentResponse parses an HTTP response from a GetMemoryContentWithResponse call

func (GetMemoryContentResponse) ContentType

func (r GetMemoryContentResponse) ContentType() string

ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers

func (GetMemoryContentResponse) GetBody

func (r GetMemoryContentResponse) GetBody() []byte

GetBody returns the raw response body bytes

func (GetMemoryContentResponse) GetJSON404

func (r GetMemoryContentResponse) GetJSON404() *Error

GetJSON404 returns the response for an HTTP 404 `application/json` response

func (GetMemoryContentResponse) GetJSON500

func (r GetMemoryContentResponse) GetJSON500() *Error

GetJSON500 returns the response for an HTTP 500 `application/json` response

func (GetMemoryContentResponse) GetJSON507

func (r GetMemoryContentResponse) GetJSON507() *Error

GetJSON507 returns the response for an HTTP 507 `application/json` response

func (GetMemoryContentResponse) Status

func (r GetMemoryContentResponse) Status() string

Status returns HTTPResponse.Status

func (GetMemoryContentResponse) StatusCode

func (r GetMemoryContentResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetMemoryContentResponse200Headers

type GetMemoryContentResponse200Headers struct {
	ContentDisposition *string
	ETag               *string
}

GetMemoryContentResponse200Headers the declared response headers of an HTTP 200 response for GetMemoryContent

type GetMemoryResponse

type GetMemoryResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	// JSON200 the response for an HTTP 200 `application/json` response
	JSON200 *MemoryDetail
	// JSON404 the response for an HTTP 404 `application/json` response
	JSON404 *Error
}

func ParseGetMemoryResponse

func ParseGetMemoryResponse(rsp *http.Response) (*GetMemoryResponse, error)

ParseGetMemoryResponse parses an HTTP response from a GetMemoryWithResponse call

func (GetMemoryResponse) ContentType

func (r GetMemoryResponse) ContentType() string

ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers

func (GetMemoryResponse) GetBody

func (r GetMemoryResponse) GetBody() []byte

GetBody returns the raw response body bytes

func (GetMemoryResponse) GetJSON200

func (r GetMemoryResponse) GetJSON200() *MemoryDetail

GetJSON200 returns the response for an HTTP 200 `application/json` response

func (GetMemoryResponse) GetJSON404

func (r GetMemoryResponse) GetJSON404() *Error

GetJSON404 returns the response for an HTTP 404 `application/json` response

func (GetMemoryResponse) Status

func (r GetMemoryResponse) Status() string

Status returns HTTPResponse.Status

func (GetMemoryResponse) StatusCode

func (r GetMemoryResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetReadinessResponse

type GetReadinessResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	// JSON200 the response for an HTTP 200 `application/json` response
	JSON200 *HealthResponse
}

func ParseGetReadinessResponse

func ParseGetReadinessResponse(rsp *http.Response) (*GetReadinessResponse, error)

ParseGetReadinessResponse parses an HTTP response from a GetReadinessWithResponse call

func (GetReadinessResponse) ContentType

func (r GetReadinessResponse) ContentType() string

ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers

func (GetReadinessResponse) GetBody

func (r GetReadinessResponse) GetBody() []byte

GetBody returns the raw response body bytes

func (GetReadinessResponse) GetJSON200

func (r GetReadinessResponse) GetJSON200() *HealthResponse

GetJSON200 returns the response for an HTTP 200 `application/json` response

func (GetReadinessResponse) Status

func (r GetReadinessResponse) Status() string

Status returns HTTPResponse.Status

func (GetReadinessResponse) StatusCode

func (r GetReadinessResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetRebuildStatusResponse

type GetRebuildStatusResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	// JSON200 the response for an HTTP 200 `application/json` response
	JSON200 *RebuildStatus
	// JSON404 the response for an HTTP 404 `application/json` response
	JSON404 *Error
	// Headers200 the parsed response headers for an HTTP 200 response
	Headers200 *GetRebuildStatusResponse200Headers
	// Headers404 the parsed response headers for an HTTP 404 response
	Headers404 *GetRebuildStatusResponse404Headers
}

func ParseGetRebuildStatusResponse

func ParseGetRebuildStatusResponse(rsp *http.Response) (*GetRebuildStatusResponse, error)

ParseGetRebuildStatusResponse parses an HTTP response from a GetRebuildStatusWithResponse call

func (GetRebuildStatusResponse) ContentType

func (r GetRebuildStatusResponse) ContentType() string

ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers

func (GetRebuildStatusResponse) GetBody

func (r GetRebuildStatusResponse) GetBody() []byte

GetBody returns the raw response body bytes

func (GetRebuildStatusResponse) GetJSON200

func (r GetRebuildStatusResponse) GetJSON200() *RebuildStatus

GetJSON200 returns the response for an HTTP 200 `application/json` response

func (GetRebuildStatusResponse) GetJSON404

func (r GetRebuildStatusResponse) GetJSON404() *Error

GetJSON404 returns the response for an HTTP 404 `application/json` response

func (GetRebuildStatusResponse) Status

func (r GetRebuildStatusResponse) Status() string

Status returns HTTPResponse.Status

func (GetRebuildStatusResponse) StatusCode

func (r GetRebuildStatusResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetRebuildStatusResponse200Headers

type GetRebuildStatusResponse200Headers struct {
	CacheControl *string
}

GetRebuildStatusResponse200Headers the declared response headers of an HTTP 200 response for GetRebuildStatus

type GetRebuildStatusResponse404Headers

type GetRebuildStatusResponse404Headers struct {
	CacheControl *string
}

GetRebuildStatusResponse404Headers the declared response headers of an HTTP 404 response for GetRebuildStatus

type HealthResponse

type HealthResponse struct {
	Status  HealthResponseStatus `json:"status"`
	Version *string              `json:"version,omitempty"`
}

HealthResponse defines model for HealthResponse.

type HealthResponseStatus

type HealthResponseStatus string

HealthResponseStatus defines model for HealthResponse.Status.

const (
	Ok HealthResponseStatus = "ok"
)

Defines values for HealthResponseStatus.

func (HealthResponseStatus) Valid

func (e HealthResponseStatus) Valid() bool

Valid indicates whether the value is a known member of the HealthResponseStatus enum.

type HttpRequestDoer

type HttpRequestDoer interface {
	Do(req *http.Request) (*http.Response, error)
}

Doer performs HTTP requests.

The standard http.Client implements this interface.

type ImportContext

type ImportContext struct {
	FilesystemCreatedAt  *time.Time `json:"filesystem_created_at,omitempty"`
	FilesystemModifiedAt *time.Time `json:"filesystem_modified_at,omitempty"`
	FullPath             *string    `json:"full_path,omitempty"`
	OriginalFilename     string     `json:"original_filename"`
	RelativePath         *string    `json:"relative_path,omitempty"`
}

ImportContext Stored provenance from the first successful import.

type ImportContextInput

type ImportContextInput struct {
	FilesystemCreatedAt  *time.Time `json:"filesystem_created_at,omitempty"`
	FilesystemModifiedAt *time.Time `json:"filesystem_modified_at,omitempty"`
	FullPath             *string    `json:"full_path,omitempty"`
	RelativePath         *string    `json:"relative_path,omitempty"`
}

ImportContextInput Optional client-observed provenance sent as one application/json multipart part. The original filename comes from the Blob part. Omitted values remain unknown; malformed timestamps reject the import.

type ImportMemoryMultipartRequestBody

type ImportMemoryMultipartRequestBody = ImportMultipart

ImportMemoryMultipartRequestBody defines body for ImportMemory for multipart/form-data ContentType.

type ImportMemoryResponse

type ImportMemoryResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	// JSON201 the response for an HTTP 201 `application/json` response
	JSON201 *MemorySummary
	// JSON400 the response for an HTTP 400 `application/json` response
	JSON400 *Error
	// JSON409 the response for an HTTP 409 `application/json` response
	JSON409 *Error
	// JSON413 the response for an HTTP 413 `application/json` response
	JSON413 *Error
	// JSON500 the response for an HTTP 500 `application/json` response
	JSON500 *Error
}

func ParseImportMemoryResponse

func ParseImportMemoryResponse(rsp *http.Response) (*ImportMemoryResponse, error)

ParseImportMemoryResponse parses an HTTP response from a ImportMemoryWithResponse call

func (ImportMemoryResponse) ContentType

func (r ImportMemoryResponse) ContentType() string

ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers

func (ImportMemoryResponse) GetBody

func (r ImportMemoryResponse) GetBody() []byte

GetBody returns the raw response body bytes

func (ImportMemoryResponse) GetJSON201

func (r ImportMemoryResponse) GetJSON201() *MemorySummary

GetJSON201 returns the response for an HTTP 201 `application/json` response

func (ImportMemoryResponse) GetJSON400

func (r ImportMemoryResponse) GetJSON400() *Error

GetJSON400 returns the response for an HTTP 400 `application/json` response

func (ImportMemoryResponse) GetJSON409

func (r ImportMemoryResponse) GetJSON409() *Error

GetJSON409 returns the response for an HTTP 409 `application/json` response

func (ImportMemoryResponse) GetJSON413

func (r ImportMemoryResponse) GetJSON413() *Error

GetJSON413 returns the response for an HTTP 413 `application/json` response

func (ImportMemoryResponse) GetJSON500

func (r ImportMemoryResponse) GetJSON500() *Error

GetJSON500 returns the response for an HTTP 500 `application/json` response

func (ImportMemoryResponse) Status

func (r ImportMemoryResponse) Status() string

Status returns HTTPResponse.Status

func (ImportMemoryResponse) StatusCode

func (r ImportMemoryResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type ImportMultipart

type ImportMultipart struct {
	// File One Blob of at most 100 MiB with a nonblank filename in
	// Content-Disposition. The server detects its Media Type from content
	// first and may fall back to a valid, specific part Content-Type.
	File openapi_types.File `json:"file"`

	// ImportContext Optional client-observed provenance sent as one application/json
	// multipart part. The original filename comes from the Blob part. Omitted
	// values remain unknown; malformed timestamps reject the import.
	ImportContext *ImportContextInput `json:"import_context,omitempty"`
}

ImportMultipart defines model for ImportMultipart.

type Limit

type Limit = int32

Limit defines model for Limit.

type MemoryDetail

type MemoryDetail struct {
	// ContentUrl Relative URL of the content download endpoint.
	ContentUrl *string `json:"content_url,omitempty"`

	// ImportContext Stored provenance from the first successful import.
	ImportContext ImportContext        `json:"import_context"`
	Memory        MemorySummary        `json:"memory"`
	Understanding UnderstandingDetails `json:"understanding"`
}

MemoryDetail defines model for MemoryDetail.

type MemoryId

type MemoryId = openapi_types.UUID

MemoryId defines model for MemoryId.

type MemoryPage

type MemoryPage struct {
	Items      []MemorySummary `json:"items"`
	NextCursor *string         `json:"next_cursor,omitempty"`
}

MemoryPage defines model for MemoryPage.

type MemorySummary

type MemorySummary struct {
	// BlobHash Canonical SHA-256 Blobref of the immutable Blob.
	BlobHash           string             `json:"blob_hash"`
	ByteSize           int64              `json:"byte_size"`
	Id                 openapi_types.UUID `json:"id"`
	ImportedAt         time.Time          `json:"imported_at"`
	MediaType          string             `json:"media_type"`
	OriginalCreatedAt  *time.Time         `json:"original_created_at,omitempty"`
	OriginalFilename   string             `json:"original_filename"`
	OriginalModifiedAt *time.Time         `json:"original_modified_at,omitempty"`
}

MemorySummary defines model for MemorySummary.

type RebuildMemoryJSONRequestBody

type RebuildMemoryJSONRequestBody = RebuildRequest

RebuildMemoryJSONRequestBody defines body for RebuildMemory for application/json ContentType.

type RebuildMemoryResponse

type RebuildMemoryResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	// JSON202 the response for an HTTP 202 `application/json` response
	JSON202 *RebuildStatus
	// JSON404 the response for an HTTP 404 `application/json` response
	JSON404 *Error
	// JSON409 the response for an HTTP 409 `application/json` response
	JSON409 *RebuildStatus
	// JSON503 the response for an HTTP 503 `application/json` response
	JSON503 *Error
	// Headers202 the parsed response headers for an HTTP 202 response
	Headers202 *RebuildMemoryResponse202Headers
	// Headers409 the parsed response headers for an HTTP 409 response
	Headers409 *RebuildMemoryResponse409Headers
}

func ParseRebuildMemoryResponse

func ParseRebuildMemoryResponse(rsp *http.Response) (*RebuildMemoryResponse, error)

ParseRebuildMemoryResponse parses an HTTP response from a RebuildMemoryWithResponse call

func (RebuildMemoryResponse) ContentType

func (r RebuildMemoryResponse) ContentType() string

ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers

func (RebuildMemoryResponse) GetBody

func (r RebuildMemoryResponse) GetBody() []byte

GetBody returns the raw response body bytes

func (RebuildMemoryResponse) GetJSON202

func (r RebuildMemoryResponse) GetJSON202() *RebuildStatus

GetJSON202 returns the response for an HTTP 202 `application/json` response

func (RebuildMemoryResponse) GetJSON404

func (r RebuildMemoryResponse) GetJSON404() *Error

GetJSON404 returns the response for an HTTP 404 `application/json` response

func (RebuildMemoryResponse) GetJSON409

func (r RebuildMemoryResponse) GetJSON409() *RebuildStatus

GetJSON409 returns the response for an HTTP 409 `application/json` response

func (RebuildMemoryResponse) GetJSON503

func (r RebuildMemoryResponse) GetJSON503() *Error

GetJSON503 returns the response for an HTTP 503 `application/json` response

func (RebuildMemoryResponse) Status

func (r RebuildMemoryResponse) Status() string

Status returns HTTPResponse.Status

func (RebuildMemoryResponse) StatusCode

func (r RebuildMemoryResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type RebuildMemoryResponse202Headers

type RebuildMemoryResponse202Headers struct {
	CacheControl *string
}

RebuildMemoryResponse202Headers the declared response headers of an HTTP 202 response for RebuildMemory

type RebuildMemoryResponse409Headers

type RebuildMemoryResponse409Headers struct {
	CacheControl *string
}

RebuildMemoryResponse409Headers the declared response headers of an HTTP 409 response for RebuildMemory

type RebuildRequest

type RebuildRequest struct {
	// UserNote Optional owner guidance; null reuses the saved note, empty string clears it.
	UserNote *string `json:"user_note,omitempty"`
}

RebuildRequest defines model for RebuildRequest.

type RebuildStatus

type RebuildStatus struct {
	Attempt   UnderstandingAttempt `json:"attempt"`
	MemoryId  openapi_types.UUID   `json:"memory_id"`
	StatusUrl string               `json:"status_url"`
}

RebuildStatus defines model for RebuildStatus.

type RequestEditorFn

type RequestEditorFn func(ctx context.Context, req *http.Request) error

RequestEditorFn is the function signature for the RequestEditor callback function

type SearchExcerptPart

type SearchExcerptPart struct {
	Match bool   `json:"match"`
	Text  string `json:"text"`
}

SearchExcerptPart defines model for SearchExcerptPart.

type SearchHit

type SearchHit struct {
	Excerpt []SearchExcerptPart `json:"excerpt"`

	// MatchTier 0 for complete whole-word/stem matches; 1 for fragment-dependent matches. Lower tiers sort first.
	MatchTier int           `json:"match_tier"`
	Memory    MemorySummary `json:"memory"`

	// Score SQLite BM25 from the word index for tier 0 and trigram index for tier 1. When no indexed fragments match, tier 1 falls back to word-index BM25 or 0. Lower scores sort first within each match tier; ties sort by Memory ID. Scores from different indexes are not comparable across tiers.
	Score float64 `json:"score"`
}

SearchHit defines model for SearchHit.

type SearchLimit

type SearchLimit = int64

SearchLimit defines model for SearchLimit.

type SearchMemoriesParams

type SearchMemoriesParams struct {
	Query  SearchQuery  `form:"query" json:"query"`
	Limit  *SearchLimit `form:"limit,omitempty" json:"limit,omitempty"`
	Cursor *Cursor      `form:"cursor,omitempty" json:"cursor,omitempty"`
}

SearchMemoriesParams defines parameters for SearchMemories.

type SearchMemoriesResponse

type SearchMemoriesResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	// JSON200 the response for an HTTP 200 `application/json` response
	JSON200 *SearchPage
	// JSON400 the response for an HTTP 400 `application/json` response
	JSON400 *Error
	// Headers200 the parsed response headers for an HTTP 200 response
	Headers200 *SearchMemoriesResponse200Headers
	// Headers400 the parsed response headers for an HTTP 400 response
	Headers400 *SearchMemoriesResponse400Headers
}

func ParseSearchMemoriesResponse

func ParseSearchMemoriesResponse(rsp *http.Response) (*SearchMemoriesResponse, error)

ParseSearchMemoriesResponse parses an HTTP response from a SearchMemoriesWithResponse call

func (SearchMemoriesResponse) ContentType

func (r SearchMemoriesResponse) ContentType() string

ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers

func (SearchMemoriesResponse) GetBody

func (r SearchMemoriesResponse) GetBody() []byte

GetBody returns the raw response body bytes

func (SearchMemoriesResponse) GetJSON200

func (r SearchMemoriesResponse) GetJSON200() *SearchPage

GetJSON200 returns the response for an HTTP 200 `application/json` response

func (SearchMemoriesResponse) GetJSON400

func (r SearchMemoriesResponse) GetJSON400() *Error

GetJSON400 returns the response for an HTTP 400 `application/json` response

func (SearchMemoriesResponse) Status

func (r SearchMemoriesResponse) Status() string

Status returns HTTPResponse.Status

func (SearchMemoriesResponse) StatusCode

func (r SearchMemoriesResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type SearchMemoriesResponse200Headers

type SearchMemoriesResponse200Headers struct {
	CacheControl *string
}

SearchMemoriesResponse200Headers the declared response headers of an HTTP 200 response for SearchMemories

type SearchMemoriesResponse400Headers

type SearchMemoriesResponse400Headers struct {
	CacheControl *string
}

SearchMemoriesResponse400Headers the declared response headers of an HTTP 400 response for SearchMemories

type SearchPage

type SearchPage struct {
	Items      []SearchHit     `json:"items"`
	NextCursor *string         `json:"next_cursor,omitempty"`
	QueryPlan  SearchQueryPlan `json:"query_plan"`
	Total      int64           `json:"total"`
}

SearchPage defines model for SearchPage.

type SearchQuery

type SearchQuery = string

SearchQuery defines model for SearchQuery.

type SearchQueryPlan

type SearchQueryPlan struct {
	Query string   `json:"query"`
	Terms []string `json:"terms"`
}

SearchQueryPlan defines model for SearchQueryPlan.

type Statistics

type Statistics struct {
	Usage *TokenUsage `json:"usage,omitempty"`
}

Statistics defines model for Statistics.

type TokenUsage

type TokenUsage struct {
	CacheWriteInputTokens *int64 `json:"cache_write_input_tokens,omitempty"`
	CachedInputTokens     *int64 `json:"cached_input_tokens,omitempty"`
	InputTokens           *int64 `json:"input_tokens,omitempty"`
	OutputTokens          *int64 `json:"output_tokens,omitempty"`
	ReasoningOutputTokens *int64 `json:"reasoning_output_tokens,omitempty"`
	TotalTokens           *int64 `json:"total_tokens,omitempty"`
}

TokenUsage defines model for TokenUsage.

type UnderstandingAttempt

type UnderstandingAttempt struct {
	CompletedAt *time.Time                `json:"completed_at,omitempty"`
	Diagnostics *UnderstandingDiagnostics `json:"diagnostics,omitempty"`
	Id          openapi_types.UUID        `json:"id"`

	// PluginId Configured plugin ID; empty when no plugin is selected.
	PluginId  string                    `json:"plugin_id"`
	QueuedAt  time.Time                 `json:"queued_at"`
	StartedAt *time.Time                `json:"started_at,omitempty"`
	Status    UnderstandingAttemptState `json:"status"`
}

UnderstandingAttempt defines model for UnderstandingAttempt.

type UnderstandingAttemptState

type UnderstandingAttemptState string

UnderstandingAttemptState defines model for UnderstandingAttemptState.

const (
	UnderstandingAttemptStateDone    UnderstandingAttemptState = "done"
	UnderstandingAttemptStateFailed  UnderstandingAttemptState = "failed"
	UnderstandingAttemptStateQueued  UnderstandingAttemptState = "queued"
	UnderstandingAttemptStateRunning UnderstandingAttemptState = "running"
)

Defines values for UnderstandingAttemptState.

func (UnderstandingAttemptState) Valid

func (e UnderstandingAttemptState) Valid() bool

Valid indicates whether the value is a known member of the UnderstandingAttemptState enum.

type UnderstandingDetails

type UnderstandingDetails struct {
	// ActiveRun The last complete successful Run; failed attempts do not replace it.
	ActiveRun     *UnderstandingRun          `json:"active_run"`
	LatestAttempt *UnderstandingAttempt      `json:"latest_attempt"`
	Status        UnderstandingDetailsStatus `json:"status"`

	// StatusUrl Process-local polling URL; absent for durable history after restart.
	StatusUrl *string `json:"status_url,omitempty"`

	// UserNote Latest saved owner guidance for this Memory; empty when absent or cleared.
	UserNote string `json:"user_note"`
}

UnderstandingDetails defines model for UnderstandingDetails.

type UnderstandingDetailsStatus

type UnderstandingDetailsStatus string

UnderstandingDetailsStatus defines model for UnderstandingDetails.Status.

const (
	UnderstandingDetailsStatusDone       UnderstandingDetailsStatus = "done"
	UnderstandingDetailsStatusFailed     UnderstandingDetailsStatus = "failed"
	UnderstandingDetailsStatusNotStarted UnderstandingDetailsStatus = "not_started"
	UnderstandingDetailsStatusQueued     UnderstandingDetailsStatus = "queued"
	UnderstandingDetailsStatusRunning    UnderstandingDetailsStatus = "running"
)

Defines values for UnderstandingDetailsStatus.

func (UnderstandingDetailsStatus) Valid

func (e UnderstandingDetailsStatus) Valid() bool

Valid indicates whether the value is a known member of the UnderstandingDetailsStatus enum.

type UnderstandingDiagnostics

type UnderstandingDiagnostics struct {
	Error    string `json:"error"`
	ExitCode *int   `json:"exit_code,omitempty"`

	// Stderr Captured plugin diagnostics; may contain private source content.
	Stderr string `json:"stderr"`

	// Stdout Captured plugin stdout, including invalid protocol output.
	Stdout string `json:"stdout"`
}

UnderstandingDiagnostics defines model for UnderstandingDiagnostics.

type UnderstandingRun

type UnderstandingRun struct {
	Artifacts   []DerivedContent   `json:"artifacts"`
	AttemptId   openapi_types.UUID `json:"attempt_id"`
	CompletedAt time.Time          `json:"completed_at"`

	// CostEstimate Optional API-equivalent estimate, not subscription charges.
	CostEstimate  *CostEstimate      `json:"cost_estimate,omitempty"`
	CreatedAt     time.Time          `json:"created_at"`
	Id            openapi_types.UUID `json:"id"`
	PluginId      string             `json:"plugin_id"`
	PluginVersion string             `json:"plugin_version"`
	SourceBlobref string             `json:"source_blobref"`

	// Statistics Optional plugin-reported Run totals.
	Statistics *Statistics `json:"statistics,omitempty"`

	// UserNote Owner guidance captured by this successful Run; empty when absent.
	UserNote string   `json:"user_note"`
	Warnings []string `json:"warnings"`
}

UnderstandingRun defines model for UnderstandingRun.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL