@sprucelabs/mercury-core-events 27.2.3 → 27.2.5

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.
Files changed (19) hide show
  1. package/build/.spruce/events/events.contract.d.ts +0 -2
  2. package/build/.spruce/events/mercury/listLocations.v2020_12_25.contract.js +1 -1
  3. package/build/.spruce/events/mercury/listOrganizations.v2020_12_25.contract.js +1 -1
  4. package/build/.spruce/events/mercury/updateLocation.v2020_12_25.contract.d.ts +0 -1
  5. package/build/.spruce/events/mercury/updateLocation.v2020_12_25.contract.js +0 -1
  6. package/build/.spruce/events/mercury/updateOrganization.v2020_12_25.contract.d.ts +0 -1
  7. package/build/.spruce/events/mercury/updateOrganization.v2020_12_25.contract.js +0 -1
  8. package/build/.spruce/schemas/mercury/v2020_12_25/sendMessageMessagePayload.schema.js +6 -0
  9. package/build/.spruce/schemas/schemas.types.d.ts +8 -0
  10. package/build/esm/.spruce/events/events.contract.d.ts +0 -2
  11. package/build/esm/.spruce/events/mercury/listLocations.v2020_12_25.contract.js +1 -1
  12. package/build/esm/.spruce/events/mercury/listOrganizations.v2020_12_25.contract.js +1 -1
  13. package/build/esm/.spruce/events/mercury/updateLocation.v2020_12_25.contract.d.ts +0 -1
  14. package/build/esm/.spruce/events/mercury/updateLocation.v2020_12_25.contract.js +0 -1
  15. package/build/esm/.spruce/events/mercury/updateOrganization.v2020_12_25.contract.d.ts +0 -1
  16. package/build/esm/.spruce/events/mercury/updateOrganization.v2020_12_25.contract.js +0 -1
  17. package/build/esm/.spruce/schemas/mercury/v2020_12_25/sendMessageMessagePayload.schema.js +6 -0
  18. package/build/esm/.spruce/schemas/schemas.types.d.ts +8 -0
  19. package/package.json +11 -11
@@ -732,7 +732,6 @@ declare const _default: ({
732
732
  eventSignatures: {
733
733
  'update-location::v2020_12_25': {
734
734
  description: string;
735
- aiInstructions: string;
736
735
  emitPayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateLocationEmitTargetAndPayloadSchema;
737
736
  responsePayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateLocationResponsePayloadSchema;
738
737
  };
@@ -741,7 +740,6 @@ declare const _default: ({
741
740
  eventSignatures: {
742
741
  'update-organization::v2020_12_25': {
743
742
  description: string;
744
- aiInstructions: string;
745
743
  emitPayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateOrganizationEmitTargetAndPayloadSchema;
746
744
  responsePayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateOrgResponsePayloadSchema;
747
745
  };
@@ -11,7 +11,7 @@ const listLocationsEventContract = (0, mercury_types_1.buildEventContract)({
11
11
  eventSignatures: {
12
12
  'list-locations::v2020_12_25': {
13
13
  description: `Look through all locations.`,
14
- aiInstructions: `Lists all locations. It can be useful to ask if the user if they want to filter by organization and if so, have them select one first (list-organizations event).`,
14
+ aiInstructions: `Lists all locations. It can be useful to ask if the user if they want to filter by organization and if so, have them select one first (list-organizations event). If only 1 location comes back, you can autoselect it.`,
15
15
  emitPayloadSchema: listLocationsEmitTargetAndPayload_schema_1.default,
16
16
  responsePayloadSchema: listLocationsResponsePayload_schema_1.default,
17
17
  }
@@ -11,7 +11,7 @@ const listOrganizationsEventContract = (0, mercury_types_1.buildEventContract)({
11
11
  eventSignatures: {
12
12
  'list-organizations::v2020_12_25': {
13
13
  description: `Look through all organizations.`,
14
- aiInstructions: `Lists all organizations. You can ignore the target for this event as the payload is where all the useful filters are for our use cases.`,
14
+ aiInstructions: `Lists all organizations. You can ignore the target for this event as the payload is where all the useful filters are for our use cases. If another event requires an organizationId, you can use this event to have the user select one first. If there is only one organization, just auto-select it.`,
15
15
  emitPayloadSchema: listOrganizationsEmitTargetAndPayload_schema_1.default,
16
16
  responsePayloadSchema: listOrgsResponsePayload_schema_1.default,
17
17
  }
@@ -3,7 +3,6 @@ declare const updateLocationEventContract: {
3
3
  eventSignatures: {
4
4
  'update-location::v2020_12_25': {
5
5
  description: string;
6
- aiInstructions: string;
7
6
  emitPayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateLocationEmitTargetAndPayloadSchema;
8
7
  responsePayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateLocationResponsePayloadSchema;
9
8
  };
@@ -11,7 +11,6 @@ const updateLocationEventContract = (0, mercury_types_1.buildEventContract)({
11
11
  eventSignatures: {
12
12
  'update-location::v2020_12_25': {
13
13
  description: `Update a new location at your organization.`,
14
- aiInstructions: `This will allow someone to update any location where they work (if they have permissions). Since you need a location id, you will have to start with the list-locations event.`,
15
14
  emitPayloadSchema: updateLocationEmitTargetAndPayload_schema_1.default,
16
15
  responsePayloadSchema: updateLocationResponsePayload_schema_1.default,
17
16
  }
@@ -3,7 +3,6 @@ declare const updateOrganizationEventContract: {
3
3
  eventSignatures: {
4
4
  'update-organization::v2020_12_25': {
5
5
  description: string;
6
- aiInstructions: string;
7
6
  emitPayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateOrganizationEmitTargetAndPayloadSchema;
8
7
  responsePayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateOrgResponsePayloadSchema;
9
8
  };
@@ -11,7 +11,6 @@ const updateOrganizationEventContract = (0, mercury_types_1.buildEventContract)(
11
11
  eventSignatures: {
12
12
  'update-organization::v2020_12_25': {
13
13
  description: `Update your organization.`,
14
- aiInstructions: `This will allow someone to update any organization where they work (if they have permissions). Since you need an organization's id, you will have to start with the list-organizations event.`,
15
14
  emitPayloadSchema: updateOrganizationEmitTargetAndPayload_schema_1.default,
16
15
  responsePayloadSchema: updateOrgResponsePayload_schema_1.default,
17
16
  }
@@ -18,6 +18,12 @@ const sendMessageMessagePayloadSchema = {
18
18
  hint: 'An arbitrary id that can be used to track this message when being sent and not yet assigned an Id.',
19
19
  options: undefined
20
20
  },
21
+ /** . If this message is a reply to another message, this is the id of that original message. */
22
+ 'inReplyToMessageId': {
23
+ type: 'id',
24
+ hint: 'If this message is a reply to another message, this is the id of that original message.',
25
+ options: undefined
26
+ },
21
27
  /** . */
22
28
  'classification': {
23
29
  type: 'select',
@@ -7269,6 +7269,8 @@ declare module '@sprucelabs/spruce-core-schemas/build/.spruce/schemas/core.schem
7269
7269
  interface SendMessageMessagePayload {
7270
7270
  /** . An arbitrary id that can be used to track this message when being sent and not yet assigned an Id. */
7271
7271
  'trackingId'?: string | undefined | null;
7272
+ /** . If this message is a reply to another message, this is the id of that original message. */
7273
+ 'inReplyToMessageId'?: string | undefined | null;
7272
7274
  'classification': ("auth" | "transactional" | "promotional" | "incoming");
7273
7275
  'body': string;
7274
7276
  'context'?: (Record<string, any>) | undefined | null;
@@ -7288,6 +7290,12 @@ declare module '@sprucelabs/spruce-core-schemas/build/.spruce/schemas/core.schem
7288
7290
  hint: 'An arbitrary id that can be used to track this message when being sent and not yet assigned an Id.';
7289
7291
  options: undefined;
7290
7292
  };
7293
+ /** . If this message is a reply to another message, this is the id of that original message. */
7294
+ 'inReplyToMessageId': {
7295
+ type: 'id';
7296
+ hint: 'If this message is a reply to another message, this is the id of that original message.';
7297
+ options: undefined;
7298
+ };
7291
7299
  /** . */
7292
7300
  'classification': {
7293
7301
  type: 'select';
@@ -732,7 +732,6 @@ declare const _default: ({
732
732
  eventSignatures: {
733
733
  'update-location::v2020_12_25': {
734
734
  description: string;
735
- aiInstructions: string;
736
735
  emitPayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateLocationEmitTargetAndPayloadSchema;
737
736
  responsePayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateLocationResponsePayloadSchema;
738
737
  };
@@ -741,7 +740,6 @@ declare const _default: ({
741
740
  eventSignatures: {
742
741
  'update-organization::v2020_12_25': {
743
742
  description: string;
744
- aiInstructions: string;
745
743
  emitPayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateOrganizationEmitTargetAndPayloadSchema;
746
744
  responsePayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateOrgResponsePayloadSchema;
747
745
  };
@@ -6,7 +6,7 @@ const listLocationsEventContract = buildEventContract({
6
6
  eventSignatures: {
7
7
  'list-locations::v2020_12_25': {
8
8
  description: `Look through all locations.`,
9
- aiInstructions: `Lists all locations. It can be useful to ask if the user if they want to filter by organization and if so, have them select one first (list-organizations event).`,
9
+ aiInstructions: `Lists all locations. It can be useful to ask if the user if they want to filter by organization and if so, have them select one first (list-organizations event). If only 1 location comes back, you can autoselect it.`,
10
10
  emitPayloadSchema: listLocationsEmitTargetAndPayloadSchema,
11
11
  responsePayloadSchema: listLocationsResponsePayloadSchema,
12
12
  }
@@ -6,7 +6,7 @@ const listOrganizationsEventContract = buildEventContract({
6
6
  eventSignatures: {
7
7
  'list-organizations::v2020_12_25': {
8
8
  description: `Look through all organizations.`,
9
- aiInstructions: `Lists all organizations. You can ignore the target for this event as the payload is where all the useful filters are for our use cases.`,
9
+ aiInstructions: `Lists all organizations. You can ignore the target for this event as the payload is where all the useful filters are for our use cases. If another event requires an organizationId, you can use this event to have the user select one first. If there is only one organization, just auto-select it.`,
10
10
  emitPayloadSchema: listOrganizationsEmitTargetAndPayloadSchema,
11
11
  responsePayloadSchema: listOrgsResponsePayloadSchema,
12
12
  }
@@ -3,7 +3,6 @@ declare const updateLocationEventContract: {
3
3
  eventSignatures: {
4
4
  'update-location::v2020_12_25': {
5
5
  description: string;
6
- aiInstructions: string;
7
6
  emitPayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateLocationEmitTargetAndPayloadSchema;
8
7
  responsePayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateLocationResponsePayloadSchema;
9
8
  };
@@ -6,7 +6,6 @@ const updateLocationEventContract = buildEventContract({
6
6
  eventSignatures: {
7
7
  'update-location::v2020_12_25': {
8
8
  description: `Update a new location at your organization.`,
9
- aiInstructions: `This will allow someone to update any location where they work (if they have permissions). Since you need a location id, you will have to start with the list-locations event.`,
10
9
  emitPayloadSchema: updateLocationEmitTargetAndPayloadSchema,
11
10
  responsePayloadSchema: updateLocationResponsePayloadSchema,
12
11
  }
@@ -3,7 +3,6 @@ declare const updateOrganizationEventContract: {
3
3
  eventSignatures: {
4
4
  'update-organization::v2020_12_25': {
5
5
  description: string;
6
- aiInstructions: string;
7
6
  emitPayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateOrganizationEmitTargetAndPayloadSchema;
8
7
  responsePayloadSchema: import("@sprucelabs/mercury-types").SpruceSchemas.Mercury.v2020_12_25.UpdateOrgResponsePayloadSchema;
9
8
  };
@@ -6,7 +6,6 @@ const updateOrganizationEventContract = buildEventContract({
6
6
  eventSignatures: {
7
7
  'update-organization::v2020_12_25': {
8
8
  description: `Update your organization.`,
9
- aiInstructions: `This will allow someone to update any organization where they work (if they have permissions). Since you need an organization's id, you will have to start with the list-organizations event.`,
10
9
  emitPayloadSchema: updateOrganizationEmitTargetAndPayloadSchema,
11
10
  responsePayloadSchema: updateOrgResponsePayloadSchema,
12
11
  }
@@ -13,6 +13,12 @@ const sendMessageMessagePayloadSchema = {
13
13
  hint: 'An arbitrary id that can be used to track this message when being sent and not yet assigned an Id.',
14
14
  options: undefined
15
15
  },
16
+ /** . If this message is a reply to another message, this is the id of that original message. */
17
+ 'inReplyToMessageId': {
18
+ type: 'id',
19
+ hint: 'If this message is a reply to another message, this is the id of that original message.',
20
+ options: undefined
21
+ },
16
22
  /** . */
17
23
  'classification': {
18
24
  type: 'select',
@@ -7269,6 +7269,8 @@ declare module '@sprucelabs/spruce-core-schemas/build/.spruce/schemas/core.schem
7269
7269
  interface SendMessageMessagePayload {
7270
7270
  /** . An arbitrary id that can be used to track this message when being sent and not yet assigned an Id. */
7271
7271
  'trackingId'?: string | undefined | null;
7272
+ /** . If this message is a reply to another message, this is the id of that original message. */
7273
+ 'inReplyToMessageId'?: string | undefined | null;
7272
7274
  'classification': ("auth" | "transactional" | "promotional" | "incoming");
7273
7275
  'body': string;
7274
7276
  'context'?: (Record<string, any>) | undefined | null;
@@ -7288,6 +7290,12 @@ declare module '@sprucelabs/spruce-core-schemas/build/.spruce/schemas/core.schem
7288
7290
  hint: 'An arbitrary id that can be used to track this message when being sent and not yet assigned an Id.';
7289
7291
  options: undefined;
7290
7292
  };
7293
+ /** . If this message is a reply to another message, this is the id of that original message. */
7294
+ 'inReplyToMessageId': {
7295
+ type: 'id';
7296
+ hint: 'If this message is a reply to another message, this is the id of that original message.';
7297
+ options: undefined;
7298
+ };
7291
7299
  /** . */
7292
7300
  'classification': {
7293
7301
  type: 'select';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sprucelabs/mercury-core-events",
3
- "version": "27.2.3",
3
+ "version": "27.2.5",
4
4
  "description": "Events Mercury provides out of the box.",
5
5
  "skill": {
6
6
  "namespace": "mercury-core-events",
@@ -58,12 +58,12 @@
58
58
  "watch.tsc": "tsc -w"
59
59
  },
60
60
  "devDependencies": {
61
- "@sprucelabs/esm-postbuild": "^7.0.38",
62
- "@sprucelabs/jest-json-reporter": "^9.0.58",
63
- "@sprucelabs/resolve-path-aliases": "^3.0.26",
61
+ "@sprucelabs/esm-postbuild": "^7.0.40",
62
+ "@sprucelabs/jest-json-reporter": "^9.0.60",
63
+ "@sprucelabs/resolve-path-aliases": "^3.0.27",
64
64
  "@sprucelabs/semantic-release": "^5.0.2",
65
- "@sprucelabs/test": "^10.0.22",
66
- "@types/node": "^24.6.0",
65
+ "@sprucelabs/test": "^10.0.23",
66
+ "@types/node": "^24.6.2",
67
67
  "chokidar-cli": "^3.0.0",
68
68
  "eslint": "^9.36.0",
69
69
  "eslint-config-spruce": "^11.2.26",
@@ -73,13 +73,13 @@
73
73
  "ts-node": "^10.9.2",
74
74
  "tsc-watch": "^7.2.0",
75
75
  "tsconfig-paths": "^4.2.0",
76
- "typescript": "^5.9.2"
76
+ "typescript": "^5.9.3"
77
77
  },
78
78
  "dependencies": {
79
- "@sprucelabs/mercury-types": "^48.0.105",
80
- "@sprucelabs/schema": "^32.1.55",
81
- "@sprucelabs/spruce-core-schemas": "^41.1.20",
82
- "@sprucelabs/spruce-event-utils": "^41.0.119"
79
+ "@sprucelabs/mercury-types": "^48.0.107",
80
+ "@sprucelabs/schema": "^32.1.57",
81
+ "@sprucelabs/spruce-core-schemas": "^41.2.1",
82
+ "@sprucelabs/spruce-event-utils": "^41.0.120"
83
83
  },
84
84
  "jest": {
85
85
  "testRunner": "jest-circus/runner",