A2ATaskStore
Defined in: agents/src/a2a/tasks.ts:62
Methods
Section titled “Methods”create()
Section titled “create()”create(record): Promise<{ created: boolean; record: A2ATaskRecord;}>;Defined in: agents/src/a2a/tasks.ts:64
Atomic on both (scope,id) and (scope,messageId). Changed duplicate content must throw.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
record |
A2ATaskRecord |
Returns
Section titled “Returns”Promise<{
created: boolean;
record: A2ATaskRecord;
}>
findMessage()
Section titled “findMessage()”findMessage(scope, id): Promise< | A2ATaskRecord| null>;Defined in: agents/src/a2a/tasks.ts:66
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
scope |
A2ATaskScope |
id |
string |
Returns
Section titled “Returns”Promise<
| A2ATaskRecord
| null>
get(scope, id): Promise< | A2ATaskRecord| null>;Defined in: agents/src/a2a/tasks.ts:65
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
scope |
A2ATaskScope |
id |
string |
Returns
Section titled “Returns”Promise<
| A2ATaskRecord
| null>
hasContext()
Section titled “hasContext()”hasContext(scope, contextId): Promise<boolean>;Defined in: agents/src/a2a/tasks.ts:78
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
scope |
A2ATaskScope |
contextId |
string |
Returns
Section titled “Returns”Promise<boolean>
list()
Section titled “list()”list(scope, filter): Promise<{ nextPageToken: string; tasks: A2ATaskRecord[];}>;Defined in: agents/src/a2a/tasks.ts:74
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
scope |
A2ATaskScope |
filter |
{ contextId?: string; pageSize: number; pageToken?: string; } |
filter.contextId? |
string |
filter.pageSize |
number |
filter.pageToken? |
string |
Returns
Section titled “Returns”Promise<{
nextPageToken: string;
tasks: A2ATaskRecord[];
}>
update()
Section titled “update()”update( scope, id, patch, revision): Promise<A2ATaskRecord>;Defined in: agents/src/a2a/tasks.ts:68
CAS also claims every newly added messageId across the scope. No writes on conflict.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
scope |
A2ATaskScope |
id |
string |
patch |
A2ATaskPatch |
revision |
string |
Returns
Section titled “Returns”Promise<A2ATaskRecord>