@compass-labs/api-sdk 0.3.3 → 0.4.0

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/bin/mcp-server.js CHANGED
@@ -34205,9 +34205,9 @@ var init_config = __esm(() => {
34205
34205
  SDK_METADATA = {
34206
34206
  language: "typescript",
34207
34207
  openapiDocVersion: "0.0.1",
34208
- sdkVersion: "0.3.3",
34208
+ sdkVersion: "0.4.0",
34209
34209
  genVersion: "2.616.1",
34210
- userAgent: "speakeasy-sdk/typescript 0.3.3 2.616.1 0.0.1 @compass-labs/api-sdk"
34210
+ userAgent: "speakeasy-sdk/typescript 0.4.0 2.616.1 0.0.1 @compass-labs/api-sdk"
34211
34211
  };
34212
34212
  });
34213
34213
 
@@ -35233,6 +35233,27 @@ function safeParse(rawValue, fn, errorMessage) {
35233
35233
  return ERR(new SDKValidationError(errorMessage, err, rawValue));
35234
35234
  }
35235
35235
  }
35236
+ function collectExtraKeys(obj, extrasKey, optional2) {
35237
+ return obj.transform((val) => {
35238
+ const extras = {};
35239
+ const { shape } = obj;
35240
+ for (const [key] of Object.entries(val)) {
35241
+ if (key in shape) {
35242
+ continue;
35243
+ }
35244
+ const v2 = val[key];
35245
+ if (typeof v2 === "undefined") {
35246
+ continue;
35247
+ }
35248
+ extras[key] = v2;
35249
+ delete val[key];
35250
+ }
35251
+ if (optional2 && Object.keys(extras).length === 0) {
35252
+ return val;
35253
+ }
35254
+ return { ...val, [extrasKey]: extras };
35255
+ });
35256
+ }
35236
35257
  var init_schemas = __esm(() => {
35237
35258
  init_sdkvalidationerror();
35238
35259
  });
@@ -38483,6 +38504,7 @@ var Body$inboundSchema, Body$outboundSchema, Body$, UserOperation$inboundSchema,
38483
38504
  var init_useroperation = __esm(() => {
38484
38505
  init_esm();
38485
38506
  init_primitives();
38507
+ init_schemas();
38486
38508
  init_aaveborrowparams();
38487
38509
  init_aaverepayparams();
38488
38510
  init_aavesupplyparams();
@@ -38591,7 +38613,7 @@ var init_useroperation = __esm(() => {
38591
38613
  Body$.inboundSchema = Body$inboundSchema;
38592
38614
  Body$.outboundSchema = Body$outboundSchema;
38593
38615
  })(Body$ ||= {});
38594
- UserOperation$inboundSchema = objectType({
38616
+ UserOperation$inboundSchema = collectExtraKeys(objectType({
38595
38617
  action_type: MulticallActionType$inboundSchema,
38596
38618
  body: unionType([
38597
38619
  UnwrapWethParams$inboundSchema,
@@ -38628,7 +38650,7 @@ var init_useroperation = __esm(() => {
38628
38650
  AerodromeSlipstreamMintLiquidityProvisionParams$inboundSchema,
38629
38651
  UniswapMintLiquidityProvisionParams$inboundSchema
38630
38652
  ])
38631
- }).transform((v2) => {
38653
+ }).catchall(anyType()), "additionalProperties", true).transform((v2) => {
38632
38654
  return remap(v2, {
38633
38655
  action_type: "actionType"
38634
38656
  });
@@ -38669,11 +38691,16 @@ var init_useroperation = __esm(() => {
38669
38691
  UniswapSellExactlyParams$outboundSchema,
38670
38692
  AerodromeSlipstreamMintLiquidityProvisionParams$outboundSchema,
38671
38693
  UniswapMintLiquidityProvisionParams$outboundSchema
38672
- ])
38694
+ ]),
38695
+ additionalProperties: recordType(anyType())
38673
38696
  }).transform((v2) => {
38674
- return remap(v2, {
38675
- actionType: "action_type"
38676
- });
38697
+ return {
38698
+ ...v2.additionalProperties,
38699
+ ...remap(v2, {
38700
+ actionType: "action_type",
38701
+ additionalProperties: null
38702
+ })
38703
+ };
38677
38704
  });
38678
38705
  ((UserOperation$) => {
38679
38706
  UserOperation$.inboundSchema = UserOperation$inboundSchema;
@@ -52410,7 +52437,7 @@ it to be traded on DeFi protocols.`,
52410
52437
  function createMCPServer(deps) {
52411
52438
  const server = new McpServer({
52412
52439
  name: "CompassApiSDK",
52413
- version: "0.3.3"
52440
+ version: "0.4.0"
52414
52441
  });
52415
52442
  const client = new CompassApiSDKCore({
52416
52443
  apiKeyAuth: deps.apiKeyAuth,
@@ -53767,7 +53794,7 @@ var routes = an({
53767
53794
  var app = He(routes, {
53768
53795
  name: "mcp",
53769
53796
  versionInfo: {
53770
- currentVersion: "0.3.3"
53797
+ currentVersion: "0.4.0"
53771
53798
  }
53772
53799
  });
53773
53800
  zt(app, process3.argv.slice(2), buildContext(process3));
@@ -53775,5 +53802,5 @@ export {
53775
53802
  app
53776
53803
  };
53777
53804
 
53778
- //# debugId=3D2806DB5BE5320464756E2164756E21
53805
+ //# debugId=8C0638600236ADC664756E2164756E21
53779
53806
  //# sourceMappingURL=mcp-server.js.map