@personaai/sdkv0.9.0

stores — @personaai/sdk

Generated field tables for stores — do not edit

Generated from sdk/typescript/dist/typedoc.json — do not edit. Regenerate with node platform/scripts/typedoc-resources.mjs.

stores

Auth: Requires Authorization: Bearer <keyId>.<secret> (server-side). For per-user calls add x-persona-external-user-id. See .

Stores are named mount points agents can be assigned to — filesystem-backed alternative to contextOverride for larger reference material.

Example

TypeScript

ts
const store = await persona.stores.create({ name: 'Handbook', scope: 'domain', accessMode: 'readwrite' });await persona.stores.writeFile(store._id, { path: 'intro.md', content: '# Hello' });

cURL

bash
curl https://api.persona.hasanraiyan.me/api/v1/developer/stores \  -H "Authorization: Bearer $PERSONA_CREDENTIAL" -H "Content-Type: application/json" \  -d '{"name":"Handbook","scope":"domain"}'

Response

json
{  "success": true,  "data": { "_id": "store_123", "name": "Handbook" }}

Store

A named, scoped mount point assignable to Agents (Agent.storeMounts), generalizing the fixed /memories/user///memories/agent/ mounts into arbitrarily-named ones. Mounted at /stores/<name>/ in the Agent's filesystem.

Source: types/store.ts:10

Interface

FieldTypeDescription
_idstring— _ types/store.ts:11_
domainstring— _ types/store.ts:12_
namestring— _ types/store.ts:13_
descriptionstring— _ types/store.ts:14_
scopeStoreScopedomain: one shared namespace for the whole Project. externalUser: one namespace per external user, resolved per Agent run. Immutable after creation. — _ types/store.ts:18_
accessModeStoreAccessModereadonly: Agents can read but never write via their own tool calls — content is populated only through this API. readwrite: Agents can also write_file/edit_file into it. — _ types/store.ts:22_
createdAtstring— _ types/store.ts:23_
updatedAtstring— _ types/store.ts:24_

StoreScope

Source: types/store.ts:1

Kind 2097152

ts
type StoreScope = "domain" | "externalUser"

StoreAccessMode

Source: types/store.ts:2

Kind 2097152

ts
type StoreAccessMode = "readonly" | "readwrite"

CreateStoreInput

Source: types/store.ts:27

Interface

FieldTypeDescription
namestring— _ types/store.ts:28_
description?string— _ types/store.ts:29_
scopeStoreScope— _ types/store.ts:30_
accessMode?StoreAccessMode— _ types/store.ts:32_

UpdateStoreInput

scope is intentionally not included — immutable after creation.

Source: types/store.ts:36

Interface

FieldTypeDescription
name?string— _ types/store.ts:37_
description?string— _ types/store.ts:38_
accessMode?StoreAccessMode— _ types/store.ts:39_

DiscoverStoresParams

Source: types/store.ts:42

Interface

FieldTypeDescription
page?number— _ types/store.ts:44_
limit?number— _ types/store.ts:46_
search?stringFree-text match against name. — _ types/store.ts:48_

StoreFile

Source: types/store.ts:51

Interface

FieldTypeDescription
pathstring— _ types/store.ts:52_
contentstring— _ types/store.ts:53_
mimeTypestring— _ types/store.ts:54_
createdAtstring— _ types/store.ts:55_
updatedAtstring— _ types/store.ts:56_

GetStoreFileParams

Source: types/store.ts:59

Interface

FieldTypeDescription
pathstring— _ types/store.ts:60_

DeleteStoreFileParams

Source: types/store.ts:63

Interface

FieldTypeDescription
pathstring— _ types/store.ts:64_

WriteStoreFileInput

Source: types/store.ts:67

Interface

FieldTypeDescription
pathstring— _ types/store.ts:68_
contentstring— _ types/store.ts:69_