Skip to main content

Overview

The ClientOptions interface is used to configure the global behavior of the MemMachineClient, including authentication and network settings.

Properties

PropertyTypeDescription
api_keystringOptional. The API key used to authenticate requests.
base_urlstringOptional. The root URL of your MemMachine server instance.
max_retriesnumberOptional. The number of times to attempt a request before failing.
timeoutnumberOptional. The maximum duration (in ms) to wait for a server response.

Usage Example

import { MemMachineClient, ClientOptions } from '@memmachine/client';

const config: ClientOptions = {
  api_key: 'mm_live_...',
  base_url: '[https://api.memmachine.ai](https://api.memmachine.ai)',
  timeout: 5000
};

const client = new MemMachineClient(config);