@daeda/mcp-pro 0.1.7 → 0.1.8

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 (2) hide show
  1. package/dist/index.js +18 -2
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -4225,7 +4225,7 @@ operationType MUST match the HubSpot property type:
4225
4225
  - NUMBER \u2192 for number properties. Operators: IS_EQUAL_TO, IS_NOT_EQUAL_TO, IS_BETWEEN, IS_GREATER_THAN, IS_LESS_THAN.
4226
4226
  - BOOL \u2192 for boolean properties. Operators: IS_EQUAL_TO, IS_NOT_EQUAL_TO.
4227
4227
  - TIME_POINT \u2192 for date/datetime properties (single point comparison). Operators: IS_AFTER, IS_BEFORE.
4228
- - TIME_RANGED \u2192 for date/datetime properties (range). Operators: IS_BETWEEN. REQUIRED fields in the operation: lowerBoundEndpointBehavior ("INCLUSIVE"), upperBoundEndpointBehavior ("INCLUSIVE"), lowerBoundTimePoint, upperBoundTimePoint. Offset format uses individual fields: { days: -90 } (NOT { unit: "DAY", amount: -90 }). Full TIME_RANGED example: { operationType: "TIME_RANGED", operator: "IS_BETWEEN", lowerBoundEndpointBehavior: "INCLUSIVE", upperBoundEndpointBehavior: "INCLUSIVE", lowerBoundTimePoint: { timeType: "INDEXED", timezoneSource: "CUSTOM", zoneId: "US/Eastern", indexReference: { referenceType: "TODAY" }, offset: { days: -90 } }, upperBoundTimePoint: { timeType: "INDEXED", timezoneSource: "CUSTOM", zoneId: "US/Eastern", indexReference: { referenceType: "TODAY" }, offset: { days: 0 } } }.
4228
+ - TIME_RANGED \u2192 for date/datetime properties (range). Operators: IS_BETWEEN. REQUIRED fields in the operation: lowerBoundEndpointBehavior, upperBoundEndpointBehavior, lowerBoundTimePoint, upperBoundTimePoint. Endpoint behaviors: lowerBoundEndpointBehavior is always "INCLUSIVE". upperBoundEndpointBehavior MUST be "EXCLUSIVE" when using referenceType "TODAY", and "INCLUSIVE" only when using referenceType "NOW". Offset format uses individual fields: { days: -90 } (NOT { unit: "DAY", amount: -90 }). For "last N days" ranges, use referenceType "TODAY" for the lower bound and "NOW" for the upper bound. Full TIME_RANGED "last 90 days" example: { operationType: "TIME_RANGED", operator: "IS_BETWEEN", lowerBoundEndpointBehavior: "INCLUSIVE", upperBoundEndpointBehavior: "INCLUSIVE", lowerBoundTimePoint: { timeType: "INDEXED", timezoneSource: "CUSTOM", zoneId: "US/Eastern", indexReference: { referenceType: "TODAY" }, offset: { days: -90 } }, upperBoundTimePoint: { timeType: "INDEXED", timezoneSource: "CUSTOM", zoneId: "US/Eastern", indexReference: { referenceType: "NOW" } } }.
4229
4229
  - ALL_PROPERTY \u2192 any property type. Operators: IS_KNOWN, IS_UNKNOWN, IS_BLANK, IS_NOT_BLANK. WARNING: IS_NOT_KNOWN is NOT valid \u2014 use IS_UNKNOWN instead.
4230
4230
  Enum filter example: { filterType: "PROPERTY", property: "lifecyclestage", operation: { operationType: "ENUMERATION", operator: "IS_ANY_OF", values: ["lead"] } }
4231
4231
 
@@ -7118,6 +7118,12 @@ var collectPropertyFilters = (branches, parentObjectTypeId) => {
7118
7118
  }
7119
7119
  return refs;
7120
7120
  };
7121
+ var getUpperBoundRefType = (op) => {
7122
+ const upper = op.upperBoundTimePoint;
7123
+ if (!upper) return void 0;
7124
+ const ref = upper.indexReference;
7125
+ return ref?.referenceType;
7126
+ };
7121
7127
  var collectTimeRangeIssues = (branches, index) => {
7122
7128
  const issues = [];
7123
7129
  for (const branch of branches) {
@@ -7134,8 +7140,18 @@ var collectTimeRangeIssues = (branches, index) => {
7134
7140
  severity: "error",
7135
7141
  operation_index: index,
7136
7142
  code: "INVALID_TIME_RANGE_ENDPOINT",
7137
- message: `TIME_RANGED filter on '${f.property ?? "unknown"}' is missing required field(s): ${missing.join(", ")}. Both must be set to "INCLUSIVE".`
7143
+ message: `TIME_RANGED filter on '${f.property ?? "unknown"}' is missing required field(s): ${missing.join(", ")}. Set lowerBoundEndpointBehavior to "INCLUSIVE" and upperBoundEndpointBehavior to "EXCLUSIVE" (or "INCLUSIVE" only with referenceType "NOW").`
7138
7144
  });
7145
+ } else if (op.upperBoundEndpointBehavior === "INCLUSIVE") {
7146
+ const upperRef = getUpperBoundRefType(op);
7147
+ if (upperRef && upperRef !== "NOW") {
7148
+ issues.push({
7149
+ severity: "error",
7150
+ operation_index: index,
7151
+ code: "INVALID_TIME_RANGE_ENDPOINT",
7152
+ message: `TIME_RANGED filter on '${f.property ?? "unknown"}' has upperBoundEndpointBehavior "INCLUSIVE" but upper bound uses referenceType "${upperRef}". HubSpot only accepts "INCLUSIVE" with referenceType "NOW" \u2014 use "EXCLUSIVE" instead, or change the upper bound to referenceType "NOW".`
7153
+ });
7154
+ }
7139
7155
  }
7140
7156
  }
7141
7157
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@daeda/mcp-pro",
3
- "version": "0.1.7",
3
+ "version": "0.1.8",
4
4
  "description": "MCP server for HubSpot CRM — sync, query, and manage your portal data",
5
5
  "type": "module",
6
6
  "bin": {