@sonzai-labs/agents 1.1.0 → 1.1.1

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.cjs CHANGED
@@ -1305,8 +1305,8 @@ var Agents = class {
1305
1305
  );
1306
1306
  }
1307
1307
  // -- Events --
1308
- /** Trigger a game event / activity for an agent. */
1309
- async triggerGameEvent(agentId, options) {
1308
+ /** Trigger a backend event / activity for an agent. */
1309
+ async triggerBackendEvent(agentId, options) {
1310
1310
  const body = {
1311
1311
  user_id: options.userId,
1312
1312
  event_type: options.eventType
@@ -1316,6 +1316,7 @@ var Agents = class {
1316
1316
  if (options.metadata) body.metadata = options.metadata;
1317
1317
  if (options.language) body.language = options.language;
1318
1318
  if (options.instanceId) body.instance_id = options.instanceId;
1319
+ if (options.messages) body.messages = options.messages;
1319
1320
  return this.http.post(
1320
1321
  `/api/v1/agents/${agentId}/events`,
1321
1322
  body
@@ -2328,7 +2329,7 @@ var Sonzai = class {
2328
2329
  projectConfig;
2329
2330
  /** Project-scoped custom LLM provider configuration. */
2330
2331
  customLLM;
2331
- /** Project-scoped notification polling for game backends. */
2332
+ /** Project-scoped notification polling for backends. */
2332
2333
  projectNotifications;
2333
2334
  http;
2334
2335
  constructor(config) {