@soat/sdk 0.6.2 → 0.6.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.cts CHANGED
@@ -431,6 +431,14 @@ type Agent = {
431
431
  */
432
432
  write_memory_id?: string | null;
433
433
  } | null;
434
+ /**
435
+ * Maximum number of recent messages to include in the context window sent to the model. When null, all messages are included.
436
+ */
437
+ max_context_messages?: number | null;
438
+ /**
439
+ * When true, only one open session per actor_id is allowed for this agent. Creating a second open session for the same actor returns 409.
440
+ */
441
+ single_session_per_actor?: boolean;
434
442
  created_at?: Date;
435
443
  updated_at?: Date;
436
444
  };
@@ -474,6 +482,14 @@ type CreateAgentRequest = {
474
482
  */
475
483
  write_memory_id?: string | null;
476
484
  };
485
+ /**
486
+ * Maximum number of recent messages included in the context window. Null means no limit.
487
+ */
488
+ max_context_messages?: number;
489
+ /**
490
+ * When true, only one open session per actor_id is allowed for this agent.
491
+ */
492
+ single_session_per_actor?: boolean;
477
493
  };
478
494
  type UpdateAgentRequest = {
479
495
  ai_provider_id?: string;
@@ -508,6 +524,14 @@ type UpdateAgentRequest = {
508
524
  */
509
525
  write_memory_id?: string | null;
510
526
  } | null;
527
+ /**
528
+ * Maximum number of recent messages included in the context window. Null means no limit.
529
+ */
530
+ max_context_messages?: number | null;
531
+ /**
532
+ * When true, only one open session per actor_id is allowed for this agent.
533
+ */
534
+ single_session_per_actor?: boolean | null;
511
535
  };
512
536
  type CreateAgentGenerationRequest = {
513
537
  messages: Array<{
@@ -1144,6 +1168,14 @@ type AgentResourceProperties = {
1144
1168
  * Sampling temperature
1145
1169
  */
1146
1170
  temperature?: number | null;
1171
+ /**
1172
+ * Maximum number of recent messages to include in the context window sent to the model. When null, all messages are included.
1173
+ */
1174
+ max_context_messages?: number | null;
1175
+ /**
1176
+ * When true, only one open session per actor_id is allowed for this agent.
1177
+ */
1178
+ single_session_per_actor?: boolean | null;
1147
1179
  /**
1148
1180
  * Knowledge retrieval configuration. When set, relevant documents and memory entries are injected into every generation.
1149
1181
  */
@@ -2103,7 +2135,7 @@ type SessionRecord = {
2103
2135
  * Underlying conversation public ID
2104
2136
  */
2105
2137
  conversation_id?: string;
2106
- status?: 'open' | 'closed';
2138
+ status?: 'open' | 'closed' | 'expired';
2107
2139
  name?: string | null;
2108
2140
  /**
2109
2141
  * Public ID of the user actor
@@ -2128,6 +2160,14 @@ type SessionRecord = {
2128
2160
  tool_context?: {
2129
2161
  [key: string]: string;
2130
2162
  } | null;
2163
+ /**
2164
+ * Number of seconds of inactivity after which the session expires. 0 means the session never expires.
2165
+ */
2166
+ inactivity_ttl_seconds?: number;
2167
+ /**
2168
+ * Timestamp of the last activity on the session (message added or response generated).
2169
+ */
2170
+ last_activity_at?: Date | null;
2131
2171
  };
2132
2172
  type SessionMessage = {
2133
2173
  role?: 'user' | 'assistant' | 'unknown';
@@ -2157,6 +2197,10 @@ type CreateSessionRequest = {
2157
2197
  tool_context?: {
2158
2198
  [key: string]: string;
2159
2199
  } | null;
2200
+ /**
2201
+ * Number of seconds of inactivity after which the session expires. 0 means the session never expires.
2202
+ */
2203
+ inactivity_ttl_seconds?: number;
2160
2204
  };
2161
2205
  type UpdateSessionRequest = {
2162
2206
  /**
@@ -2166,7 +2210,7 @@ type UpdateSessionRequest = {
2166
2210
  /**
2167
2211
  * Session status
2168
2212
  */
2169
- status?: 'open' | 'closed';
2213
+ status?: 'open' | 'closed' | 'expired';
2170
2214
  /**
2171
2215
  * Enable or disable automatic generation after user messages.
2172
2216
  */
@@ -6683,9 +6727,9 @@ type ListAgentSessionsData = {
6683
6727
  */
6684
6728
  actor_id?: string;
6685
6729
  /**
6686
- * Filter by session status (open or closed)
6730
+ * Filter by session status (open, closed, or expired)
6687
6731
  */
6688
- status?: 'open' | 'closed';
6732
+ status?: 'open' | 'closed' | 'expired';
6689
6733
  limit?: number;
6690
6734
  offset?: number;
6691
6735
  };
@@ -6742,6 +6786,10 @@ type CreateAgentSessionErrors = {
6742
6786
  * Not found
6743
6787
  */
6744
6788
  404: ErrorResponse;
6789
+ /**
6790
+ * An open session already exists for this actor (single_session_per_actor is enabled)
6791
+ */
6792
+ 409: ErrorResponse;
6745
6793
  };
6746
6794
  type CreateAgentSessionError = CreateAgentSessionErrors[keyof CreateAgentSessionErrors];
6747
6795
  type CreateAgentSessionResponses = {
@@ -6981,6 +7029,10 @@ type GenerateSessionResponseErrors = {
6981
7029
  * Generation already in progress
6982
7030
  */
6983
7031
  409: ErrorResponse;
7032
+ /**
7033
+ * Session has expired due to inactivity
7034
+ */
7035
+ 410: ErrorResponse;
6984
7036
  };
6985
7037
  type GenerateSessionResponseError = GenerateSessionResponseErrors[keyof GenerateSessionResponseErrors];
6986
7038
  type GenerateSessionResponseResponses = {
package/dist/index.d.ts CHANGED
@@ -431,6 +431,14 @@ type Agent = {
431
431
  */
432
432
  write_memory_id?: string | null;
433
433
  } | null;
434
+ /**
435
+ * Maximum number of recent messages to include in the context window sent to the model. When null, all messages are included.
436
+ */
437
+ max_context_messages?: number | null;
438
+ /**
439
+ * When true, only one open session per actor_id is allowed for this agent. Creating a second open session for the same actor returns 409.
440
+ */
441
+ single_session_per_actor?: boolean;
434
442
  created_at?: Date;
435
443
  updated_at?: Date;
436
444
  };
@@ -474,6 +482,14 @@ type CreateAgentRequest = {
474
482
  */
475
483
  write_memory_id?: string | null;
476
484
  };
485
+ /**
486
+ * Maximum number of recent messages included in the context window. Null means no limit.
487
+ */
488
+ max_context_messages?: number;
489
+ /**
490
+ * When true, only one open session per actor_id is allowed for this agent.
491
+ */
492
+ single_session_per_actor?: boolean;
477
493
  };
478
494
  type UpdateAgentRequest = {
479
495
  ai_provider_id?: string;
@@ -508,6 +524,14 @@ type UpdateAgentRequest = {
508
524
  */
509
525
  write_memory_id?: string | null;
510
526
  } | null;
527
+ /**
528
+ * Maximum number of recent messages included in the context window. Null means no limit.
529
+ */
530
+ max_context_messages?: number | null;
531
+ /**
532
+ * When true, only one open session per actor_id is allowed for this agent.
533
+ */
534
+ single_session_per_actor?: boolean | null;
511
535
  };
512
536
  type CreateAgentGenerationRequest = {
513
537
  messages: Array<{
@@ -1144,6 +1168,14 @@ type AgentResourceProperties = {
1144
1168
  * Sampling temperature
1145
1169
  */
1146
1170
  temperature?: number | null;
1171
+ /**
1172
+ * Maximum number of recent messages to include in the context window sent to the model. When null, all messages are included.
1173
+ */
1174
+ max_context_messages?: number | null;
1175
+ /**
1176
+ * When true, only one open session per actor_id is allowed for this agent.
1177
+ */
1178
+ single_session_per_actor?: boolean | null;
1147
1179
  /**
1148
1180
  * Knowledge retrieval configuration. When set, relevant documents and memory entries are injected into every generation.
1149
1181
  */
@@ -2103,7 +2135,7 @@ type SessionRecord = {
2103
2135
  * Underlying conversation public ID
2104
2136
  */
2105
2137
  conversation_id?: string;
2106
- status?: 'open' | 'closed';
2138
+ status?: 'open' | 'closed' | 'expired';
2107
2139
  name?: string | null;
2108
2140
  /**
2109
2141
  * Public ID of the user actor
@@ -2128,6 +2160,14 @@ type SessionRecord = {
2128
2160
  tool_context?: {
2129
2161
  [key: string]: string;
2130
2162
  } | null;
2163
+ /**
2164
+ * Number of seconds of inactivity after which the session expires. 0 means the session never expires.
2165
+ */
2166
+ inactivity_ttl_seconds?: number;
2167
+ /**
2168
+ * Timestamp of the last activity on the session (message added or response generated).
2169
+ */
2170
+ last_activity_at?: Date | null;
2131
2171
  };
2132
2172
  type SessionMessage = {
2133
2173
  role?: 'user' | 'assistant' | 'unknown';
@@ -2157,6 +2197,10 @@ type CreateSessionRequest = {
2157
2197
  tool_context?: {
2158
2198
  [key: string]: string;
2159
2199
  } | null;
2200
+ /**
2201
+ * Number of seconds of inactivity after which the session expires. 0 means the session never expires.
2202
+ */
2203
+ inactivity_ttl_seconds?: number;
2160
2204
  };
2161
2205
  type UpdateSessionRequest = {
2162
2206
  /**
@@ -2166,7 +2210,7 @@ type UpdateSessionRequest = {
2166
2210
  /**
2167
2211
  * Session status
2168
2212
  */
2169
- status?: 'open' | 'closed';
2213
+ status?: 'open' | 'closed' | 'expired';
2170
2214
  /**
2171
2215
  * Enable or disable automatic generation after user messages.
2172
2216
  */
@@ -6683,9 +6727,9 @@ type ListAgentSessionsData = {
6683
6727
  */
6684
6728
  actor_id?: string;
6685
6729
  /**
6686
- * Filter by session status (open or closed)
6730
+ * Filter by session status (open, closed, or expired)
6687
6731
  */
6688
- status?: 'open' | 'closed';
6732
+ status?: 'open' | 'closed' | 'expired';
6689
6733
  limit?: number;
6690
6734
  offset?: number;
6691
6735
  };
@@ -6742,6 +6786,10 @@ type CreateAgentSessionErrors = {
6742
6786
  * Not found
6743
6787
  */
6744
6788
  404: ErrorResponse;
6789
+ /**
6790
+ * An open session already exists for this actor (single_session_per_actor is enabled)
6791
+ */
6792
+ 409: ErrorResponse;
6745
6793
  };
6746
6794
  type CreateAgentSessionError = CreateAgentSessionErrors[keyof CreateAgentSessionErrors];
6747
6795
  type CreateAgentSessionResponses = {
@@ -6981,6 +7029,10 @@ type GenerateSessionResponseErrors = {
6981
7029
  * Generation already in progress
6982
7030
  */
6983
7031
  409: ErrorResponse;
7032
+ /**
7033
+ * Session has expired due to inactivity
7034
+ */
7035
+ 410: ErrorResponse;
6984
7036
  };
6985
7037
  type GenerateSessionResponseError = GenerateSessionResponseErrors[keyof GenerateSessionResponseErrors];
6986
7038
  type GenerateSessionResponseResponses = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@soat/sdk",
3
- "version": "0.6.2",
3
+ "version": "0.6.4",
4
4
  "description": "TypeScript SDK for the SOAT API",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",