@kaiban/sdk 0.1.2 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +0 -9
- package/dist/index.js +0 -9
- package/dist/lib/resources/CardsClient.d.ts +1 -1
- package/dist/types/requests.d.ts +0 -22
- package/dist/types/requests.js +19 -1
- package/dist/types/responses.d.ts +0 -31
- package/package.json +1 -1
- package/dist/types/a2a-data-parts.d.ts +0 -64
- package/dist/types/a2a-data-parts.js +0 -13
package/dist/index.d.ts
CHANGED
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
export * from './lib/client';
|
|
2
2
|
export * from './lib/http/errors';
|
|
3
3
|
export * from './lib/http/types';
|
|
4
|
-
export * from './lib/resources/ActivitiesClient';
|
|
5
|
-
export * from './lib/resources/AgentsClient';
|
|
6
|
-
export * from './lib/resources/BoardsClient';
|
|
7
|
-
export * from './lib/resources/CardsClient';
|
|
8
|
-
export * from './lib/resources/ExternalChannelsClient';
|
|
9
|
-
export * from './lib/resources/ResourcesClient';
|
|
10
|
-
export * from './lib/resources/TeamsClient';
|
|
11
|
-
export * from './types/a2a-data-parts';
|
|
12
4
|
export * from './types/entities';
|
|
13
|
-
export * from './types/requests';
|
|
14
5
|
export * from './types/responses';
|
package/dist/index.js
CHANGED
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
export * from './lib/client';
|
|
2
2
|
export * from './lib/http/errors';
|
|
3
3
|
export * from './lib/http/types';
|
|
4
|
-
export * from './lib/resources/ActivitiesClient';
|
|
5
|
-
export * from './lib/resources/AgentsClient';
|
|
6
|
-
export * from './lib/resources/BoardsClient';
|
|
7
|
-
export * from './lib/resources/CardsClient';
|
|
8
|
-
export * from './lib/resources/ExternalChannelsClient';
|
|
9
|
-
export * from './lib/resources/ResourcesClient';
|
|
10
|
-
export * from './lib/resources/TeamsClient';
|
|
11
|
-
export * from './types/a2a-data-parts';
|
|
12
4
|
export * from './types/entities';
|
|
13
|
-
export * from './types/requests';
|
|
14
5
|
export * from './types/responses';
|
|
@@ -223,7 +223,7 @@ export declare class CardsClient {
|
|
|
223
223
|
* ]);
|
|
224
224
|
* ```
|
|
225
225
|
*/
|
|
226
|
-
createBatchActivities(cardId: string, data: Omit<ActivityCreate, 'card_id'>[], options?: RequestOptions): Promise<Activity>;
|
|
226
|
+
createBatchActivities(cardId: string, data: Omit<ActivityCreate, 'card_id'>[], options?: RequestOptions): Promise<Activity[]>;
|
|
227
227
|
/**
|
|
228
228
|
* List activities for a specific card with pagination, filters, and sorting
|
|
229
229
|
*
|
package/dist/types/requests.d.ts
CHANGED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
export type Empty = Record<string, never>;
|
|
2
|
-
export interface ActivitiesBatchRequestItem {
|
|
3
|
-
board_id: string;
|
|
4
|
-
card_id: string;
|
|
5
|
-
team_id: string;
|
|
6
|
-
type: string;
|
|
7
|
-
description: string;
|
|
8
|
-
actor: {
|
|
9
|
-
id: string;
|
|
10
|
-
type: 'user' | 'agent' | 'system';
|
|
11
|
-
name: string;
|
|
12
|
-
};
|
|
13
|
-
changes?: Array<{
|
|
14
|
-
field: string;
|
|
15
|
-
old_value: unknown;
|
|
16
|
-
new_value: unknown;
|
|
17
|
-
}>;
|
|
18
|
-
metadata?: Record<string, unknown>;
|
|
19
|
-
}
|
|
20
|
-
export interface ActivitiesBatchRequest {
|
|
21
|
-
items: ActivitiesBatchRequestItem[];
|
|
22
|
-
}
|
package/dist/types/requests.js
CHANGED
|
@@ -1 +1,19 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
// export type Empty = Record<string, never>;
|
|
3
|
+
// export interface ActivitiesBatchRequestItem {
|
|
4
|
+
// board_id: string;
|
|
5
|
+
// card_id: string;
|
|
6
|
+
// team_id: string;
|
|
7
|
+
// type: string;
|
|
8
|
+
// description: string;
|
|
9
|
+
// actor: {
|
|
10
|
+
// id: string;
|
|
11
|
+
// type: 'user' | 'agent' | 'system';
|
|
12
|
+
// name: string;
|
|
13
|
+
// };
|
|
14
|
+
// changes?: Array<{ field: string; old_value: unknown; new_value: unknown }>;
|
|
15
|
+
// metadata?: Record<string, unknown>;
|
|
16
|
+
// }
|
|
17
|
+
// export interface ActivitiesBatchRequest {
|
|
18
|
+
// items: ActivitiesBatchRequestItem[];
|
|
19
|
+
// }
|
|
@@ -9,37 +9,6 @@ export interface PaginationMeta {
|
|
|
9
9
|
/** Cursor for next page, null if no next page */
|
|
10
10
|
next_cursor: string | null;
|
|
11
11
|
}
|
|
12
|
-
/**
|
|
13
|
-
* API meta information returned with each response
|
|
14
|
-
*/
|
|
15
|
-
export interface ResponseMeta {
|
|
16
|
-
/** Server timestamp (ISO8601) */
|
|
17
|
-
timestamp: string;
|
|
18
|
-
/** Request ID included only when server generated it (client did not provide) */
|
|
19
|
-
request_id?: string;
|
|
20
|
-
}
|
|
21
|
-
/**
|
|
22
|
-
* Standard error object
|
|
23
|
-
*/
|
|
24
|
-
export interface ApiErrorObject {
|
|
25
|
-
code: 'invalid_argument' | 'unauthenticated' | 'permission_denied' | 'not_found' | 'conflict' | 'internal' | 'validation_error' | 'rate_limit_exceeded' | 'bad_gateway' | 'service_unavailable' | 'gateway_timeout' | string;
|
|
26
|
-
message: string;
|
|
27
|
-
details?: unknown;
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* Generic success envelope
|
|
31
|
-
*/
|
|
32
|
-
export interface SuccessEnvelope<T> {
|
|
33
|
-
data: T;
|
|
34
|
-
meta: ResponseMeta;
|
|
35
|
-
}
|
|
36
|
-
/**
|
|
37
|
-
* Generic error envelope
|
|
38
|
-
*/
|
|
39
|
-
export interface ErrorEnvelope {
|
|
40
|
-
error: ApiErrorObject;
|
|
41
|
-
meta: ResponseMeta;
|
|
42
|
-
}
|
|
43
12
|
/**
|
|
44
13
|
* Generic paginated response format
|
|
45
14
|
*/
|
package/package.json
CHANGED
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
import { Activity } from './entities';
|
|
2
|
-
export declare const A2ADataPartType: {
|
|
3
|
-
readonly TOOL_CALL_START: "tool_call_start";
|
|
4
|
-
readonly TOOL_CALL_ARGS: "tool_call_args";
|
|
5
|
-
readonly TOOL_CALL_END: "tool_call_end";
|
|
6
|
-
readonly TOOL_CALL_RESULT: "tool_call_result";
|
|
7
|
-
readonly TASK_INFO_MESSAGE: "task_info_message";
|
|
8
|
-
readonly TASK_STEP_OUTPUT: "task_step_output";
|
|
9
|
-
readonly USER_EVALUATION: "user_evaluation";
|
|
10
|
-
readonly USER_THREAD_FEEDBACK: "user_thread_feedback";
|
|
11
|
-
readonly KAIBAN_ACTIVITY: "kaiban_activity";
|
|
12
|
-
readonly AGENT_STATUS: "agent_status";
|
|
13
|
-
};
|
|
14
|
-
export type A2ADataPartType = (typeof A2ADataPartType)[keyof typeof A2ADataPartType];
|
|
15
|
-
export interface A2ADataPartBase<T extends A2ADataPartType, P extends object> {
|
|
16
|
-
data: {
|
|
17
|
-
type: T;
|
|
18
|
-
} & P;
|
|
19
|
-
}
|
|
20
|
-
export type ToolCallStartPart = A2ADataPartBase<'tool_call_start', {
|
|
21
|
-
toolName: string;
|
|
22
|
-
}>;
|
|
23
|
-
export type ToolCallArgsPart = A2ADataPartBase<'tool_call_args', {
|
|
24
|
-
toolName: string;
|
|
25
|
-
args: Record<string, unknown>;
|
|
26
|
-
}>;
|
|
27
|
-
export type ToolCallEndPart = A2ADataPartBase<'tool_call_end', {
|
|
28
|
-
toolName: string;
|
|
29
|
-
}>;
|
|
30
|
-
export type ToolCallResultPart = A2ADataPartBase<'tool_call_result', {
|
|
31
|
-
toolName: string;
|
|
32
|
-
result: Record<string, unknown>;
|
|
33
|
-
}>;
|
|
34
|
-
export type TaskInfoMessagePart = A2ADataPartBase<'task_info_message', {
|
|
35
|
-
message: string;
|
|
36
|
-
}>;
|
|
37
|
-
export type TaskStepOutputPart = A2ADataPartBase<'task_step_output', {
|
|
38
|
-
stepName: string;
|
|
39
|
-
output?: Record<string, unknown>;
|
|
40
|
-
costs?: Array<{
|
|
41
|
-
model: string;
|
|
42
|
-
inputTokens: number;
|
|
43
|
-
outputTokens: number;
|
|
44
|
-
totalTokens: number;
|
|
45
|
-
reasoningTokens: number;
|
|
46
|
-
cachedInputTokens: number;
|
|
47
|
-
}>;
|
|
48
|
-
duration: number;
|
|
49
|
-
}>;
|
|
50
|
-
export type UserEvaluationPart = A2ADataPartBase<'user_evaluation', {
|
|
51
|
-
messageId: string;
|
|
52
|
-
evaluation: 'good' | 'bad';
|
|
53
|
-
}>;
|
|
54
|
-
export type UserThreadFeedbackPart = A2ADataPartBase<'user_thread_feedback', {
|
|
55
|
-
wasHelpful: boolean;
|
|
56
|
-
feedback: string;
|
|
57
|
-
}>;
|
|
58
|
-
export type KaibanActivityPart = A2ADataPartBase<'kaiban_activity', {
|
|
59
|
-
activity: Activity;
|
|
60
|
-
}>;
|
|
61
|
-
export type AgentStatusPart = A2ADataPartBase<'agent_status', {
|
|
62
|
-
status: string;
|
|
63
|
-
}>;
|
|
64
|
-
export type AnyA2ADataPart = ToolCallStartPart | ToolCallArgsPart | ToolCallEndPart | ToolCallResultPart | TaskInfoMessagePart | TaskStepOutputPart | UserEvaluationPart | UserThreadFeedbackPart | KaibanActivityPart | AgentStatusPart;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
// A2A Data Part type identifiers
|
|
2
|
-
export const A2ADataPartType = {
|
|
3
|
-
TOOL_CALL_START: 'tool_call_start',
|
|
4
|
-
TOOL_CALL_ARGS: 'tool_call_args',
|
|
5
|
-
TOOL_CALL_END: 'tool_call_end',
|
|
6
|
-
TOOL_CALL_RESULT: 'tool_call_result',
|
|
7
|
-
TASK_INFO_MESSAGE: 'task_info_message',
|
|
8
|
-
TASK_STEP_OUTPUT: 'task_step_output',
|
|
9
|
-
USER_EVALUATION: 'user_evaluation',
|
|
10
|
-
USER_THREAD_FEEDBACK: 'user_thread_feedback',
|
|
11
|
-
KAIBAN_ACTIVITY: 'kaiban_activity',
|
|
12
|
-
AGENT_STATUS: 'agent_status',
|
|
13
|
-
};
|