@settlemint/sdk-mcp 2.1.4-prfa991a9d → 2.1.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.
- package/dist/mcp.js +152 -8
- package/dist/mcp.js.map +12 -8
- package/package.json +3 -3
package/dist/mcp.js
CHANGED
|
@@ -61129,7 +61129,7 @@ var {
|
|
|
61129
61129
|
var package_default = {
|
|
61130
61130
|
name: "@settlemint/sdk-mcp",
|
|
61131
61131
|
description: "MCP interface for SettleMint SDK, providing development tools and project management capabilities",
|
|
61132
|
-
version: "2.1.
|
|
61132
|
+
version: "2.1.5",
|
|
61133
61133
|
type: "module",
|
|
61134
61134
|
private: false,
|
|
61135
61135
|
license: "FSL-1.1-MIT",
|
|
@@ -61171,8 +61171,8 @@ var package_default = {
|
|
|
61171
61171
|
"@graphql-tools/load": "8.1.0",
|
|
61172
61172
|
"@graphql-tools/url-loader": "8.0.31",
|
|
61173
61173
|
"@modelcontextprotocol/sdk": "1.10.2",
|
|
61174
|
-
"@settlemint/sdk-js": "2.1.
|
|
61175
|
-
"@settlemint/sdk-utils": "2.1.
|
|
61174
|
+
"@settlemint/sdk-js": "2.1.5",
|
|
61175
|
+
"@settlemint/sdk-utils": "2.1.5",
|
|
61176
61176
|
"@commander-js/extra-typings": "11.1.0",
|
|
61177
61177
|
commander: "11.1.0",
|
|
61178
61178
|
zod: "3.24.3"
|
|
@@ -61936,6 +61936,7 @@ var registerBlockchainConcepts = (server) => {
|
|
|
61936
61936
|
### Blockchain Networks
|
|
61937
61937
|
- **Blockchain Network**: A blockchain instance running on the SettleMint platform
|
|
61938
61938
|
- **Blockchain Node**: Individual node in a blockchain network
|
|
61939
|
+
- **Load Balancer**: Distributes incoming JSON-RPC requests across multiple blockchain nodes
|
|
61939
61940
|
- **Network Type**: Type of blockchain network (Ethereum, Fabric, etc.)
|
|
61940
61941
|
- **Consensus Mechanism**: Method used to achieve agreement on the blockchain state
|
|
61941
61942
|
|
|
@@ -64233,6 +64234,7 @@ var getEnv = (gqlClient) => {
|
|
|
64233
64234
|
};
|
|
64234
64235
|
var LoadBalancerFragment = graphql(`
|
|
64235
64236
|
fragment LoadBalancer on LoadBalancer {
|
|
64237
|
+
__typename
|
|
64236
64238
|
id
|
|
64237
64239
|
uniqueName
|
|
64238
64240
|
name
|
|
@@ -65619,8 +65621,12 @@ var platformInsightsCreate = (server, env3, pat) => {
|
|
|
65619
65621
|
provider: z.string().describe("Provider for the insights"),
|
|
65620
65622
|
region: z.string().describe("Region for the insights"),
|
|
65621
65623
|
insightsCategory: z.enum(["BLOCKCHAIN_EXPLORER", "HYPERLEDGER_EXPLORER", "OTTERSCAN_BLOCKCHAIN_EXPLORER"]).describe("Category of insights"),
|
|
65622
|
-
blockchainNodeUniqueName: z.string().optional().describe("Unique name of the blockchain node to connect to")
|
|
65624
|
+
blockchainNodeUniqueName: z.string().optional().describe("Unique name of the blockchain node to connect to (mutually exclusive with loadBalancerUniqueName)"),
|
|
65625
|
+
loadBalancerUniqueName: z.string().optional().describe("Unique name of the load balancer to connect to (mutually exclusive with blockchainNodeUniqueName), prefer using a load balancer if available")
|
|
65623
65626
|
}, async (params) => {
|
|
65627
|
+
if (params.blockchainNodeUniqueName && params.loadBalancerUniqueName) {
|
|
65628
|
+
throw new Error("Only one of 'blockchainNodeUniqueName' and 'loadBalancerUniqueName' may be provided");
|
|
65629
|
+
}
|
|
65624
65630
|
const insights = await client.insights.create({
|
|
65625
65631
|
applicationUniqueName: params.applicationUniqueName,
|
|
65626
65632
|
name: params.name,
|
|
@@ -65629,7 +65635,8 @@ var platformInsightsCreate = (server, env3, pat) => {
|
|
|
65629
65635
|
provider: params.provider,
|
|
65630
65636
|
region: params.region,
|
|
65631
65637
|
insightsCategory: params.insightsCategory,
|
|
65632
|
-
blockchainNodeUniqueName: params.blockchainNodeUniqueName
|
|
65638
|
+
blockchainNodeUniqueName: params.blockchainNodeUniqueName,
|
|
65639
|
+
loadBalancerUniqueName: params.loadBalancerUniqueName
|
|
65633
65640
|
});
|
|
65634
65641
|
return {
|
|
65635
65642
|
content: [
|
|
@@ -65855,6 +65862,134 @@ var platformIntegrationToolRestart = (server, env3, pat) => {
|
|
|
65855
65862
|
});
|
|
65856
65863
|
};
|
|
65857
65864
|
|
|
65865
|
+
// src/tools/platform/load-balancer/create.ts
|
|
65866
|
+
var platformLoadBalancerCreate = (server, env3, pat) => {
|
|
65867
|
+
const instance = env3.SETTLEMINT_INSTANCE;
|
|
65868
|
+
if (!instance) {
|
|
65869
|
+
throw new Error("SETTLEMINT_INSTANCE is not set");
|
|
65870
|
+
}
|
|
65871
|
+
const client = createSettleMintClient({
|
|
65872
|
+
accessToken: pat,
|
|
65873
|
+
instance
|
|
65874
|
+
});
|
|
65875
|
+
server.tool("platform-load-balancer-create", {
|
|
65876
|
+
applicationUniqueName: z.string().describe("Unique name of the application to create the load balancer in"),
|
|
65877
|
+
name: z.string().describe("Name of the load balancer"),
|
|
65878
|
+
type: z.enum(["DEDICATED", "SHARED"]).describe("Type of the load balancer (DEDICATED or SHARED)"),
|
|
65879
|
+
size: z.enum(["SMALL", "MEDIUM", "LARGE"]).describe("Size of the load balancer"),
|
|
65880
|
+
provider: z.string().describe("Provider for the load balancer"),
|
|
65881
|
+
region: z.string().describe("Region for the load balancer"),
|
|
65882
|
+
blockchainNetworkUniqueName: z.string().describe("Unique name of the blockchain network for the load balancer"),
|
|
65883
|
+
connectedNodesUniqueNames: z.array(z.string()).describe("Unique names of the nodes to connect to the load balancer")
|
|
65884
|
+
}, async (params) => {
|
|
65885
|
+
const loadBalancer = await client.loadBalancer.create({
|
|
65886
|
+
applicationUniqueName: params.applicationUniqueName,
|
|
65887
|
+
name: params.name,
|
|
65888
|
+
type: params.type,
|
|
65889
|
+
size: params.size,
|
|
65890
|
+
provider: params.provider,
|
|
65891
|
+
region: params.region,
|
|
65892
|
+
blockchainNetworkUniqueName: params.blockchainNetworkUniqueName,
|
|
65893
|
+
connectedNodesUniqueNames: params.connectedNodesUniqueNames
|
|
65894
|
+
});
|
|
65895
|
+
return {
|
|
65896
|
+
content: [
|
|
65897
|
+
{
|
|
65898
|
+
type: "text",
|
|
65899
|
+
name: "Load Balancer Created",
|
|
65900
|
+
description: `Created load balancer: ${params.name} in application: ${params.applicationUniqueName}`,
|
|
65901
|
+
mimeType: "application/json",
|
|
65902
|
+
text: JSON.stringify(loadBalancer, null, 2)
|
|
65903
|
+
}
|
|
65904
|
+
]
|
|
65905
|
+
};
|
|
65906
|
+
});
|
|
65907
|
+
};
|
|
65908
|
+
|
|
65909
|
+
// src/tools/platform/load-balancer/list.ts
|
|
65910
|
+
var platformLoadBalancerList = (server, env3, pat) => {
|
|
65911
|
+
const instance = env3.SETTLEMINT_INSTANCE;
|
|
65912
|
+
if (!instance) {
|
|
65913
|
+
throw new Error("SETTLEMINT_INSTANCE is not set");
|
|
65914
|
+
}
|
|
65915
|
+
const client = createSettleMintClient({
|
|
65916
|
+
accessToken: pat,
|
|
65917
|
+
instance
|
|
65918
|
+
});
|
|
65919
|
+
server.tool("platform-load-balancer-list", {
|
|
65920
|
+
applicationUniqueName: z.string().describe("Unique name of the application to list load balancers from")
|
|
65921
|
+
}, async (params) => {
|
|
65922
|
+
const loadBalancers = await client.loadBalancer.list(params.applicationUniqueName);
|
|
65923
|
+
return {
|
|
65924
|
+
content: [
|
|
65925
|
+
{
|
|
65926
|
+
type: "text",
|
|
65927
|
+
name: "Load Balancer List",
|
|
65928
|
+
description: `List of load balancers in application: ${params.applicationUniqueName}`,
|
|
65929
|
+
mimeType: "application/json",
|
|
65930
|
+
text: JSON.stringify(loadBalancers, null, 2)
|
|
65931
|
+
}
|
|
65932
|
+
]
|
|
65933
|
+
};
|
|
65934
|
+
});
|
|
65935
|
+
};
|
|
65936
|
+
|
|
65937
|
+
// src/tools/platform/load-balancer/read.ts
|
|
65938
|
+
var platformLoadBalancerRead = (server, env3, pat) => {
|
|
65939
|
+
const instance = env3.SETTLEMINT_INSTANCE;
|
|
65940
|
+
if (!instance) {
|
|
65941
|
+
throw new Error("SETTLEMINT_INSTANCE is not set");
|
|
65942
|
+
}
|
|
65943
|
+
const client = createSettleMintClient({
|
|
65944
|
+
accessToken: pat,
|
|
65945
|
+
instance
|
|
65946
|
+
});
|
|
65947
|
+
server.tool("platform-load-balancer-read", {
|
|
65948
|
+
loadBalancerUniqueName: z.string().describe("Unique name of the load balancer to read")
|
|
65949
|
+
}, async (params) => {
|
|
65950
|
+
const loadBalancer = await client.loadBalancer.read(params.loadBalancerUniqueName);
|
|
65951
|
+
return {
|
|
65952
|
+
content: [
|
|
65953
|
+
{
|
|
65954
|
+
type: "text",
|
|
65955
|
+
name: "Load Balancer Details",
|
|
65956
|
+
description: `Details for load balancer: ${params.loadBalancerUniqueName}`,
|
|
65957
|
+
mimeType: "application/json",
|
|
65958
|
+
text: JSON.stringify(loadBalancer, null, 2)
|
|
65959
|
+
}
|
|
65960
|
+
]
|
|
65961
|
+
};
|
|
65962
|
+
});
|
|
65963
|
+
};
|
|
65964
|
+
|
|
65965
|
+
// src/tools/platform/load-balancer/restart.ts
|
|
65966
|
+
var platformLoadBalancerRestart = (server, env3, pat) => {
|
|
65967
|
+
const instance = env3.SETTLEMINT_INSTANCE;
|
|
65968
|
+
if (!instance) {
|
|
65969
|
+
throw new Error("SETTLEMINT_INSTANCE is not set");
|
|
65970
|
+
}
|
|
65971
|
+
const client = createSettleMintClient({
|
|
65972
|
+
accessToken: pat,
|
|
65973
|
+
instance
|
|
65974
|
+
});
|
|
65975
|
+
server.tool("platform-load-balancer-restart", {
|
|
65976
|
+
loadBalancerUniqueName: z.string().describe("Unique name of the load balancer to restart")
|
|
65977
|
+
}, async (params) => {
|
|
65978
|
+
const loadBalancer = await client.loadBalancer.restart(params.loadBalancerUniqueName);
|
|
65979
|
+
return {
|
|
65980
|
+
content: [
|
|
65981
|
+
{
|
|
65982
|
+
type: "text",
|
|
65983
|
+
name: "Load Balancer Restarted",
|
|
65984
|
+
description: `Restarted load balancer: ${params.loadBalancerUniqueName}`,
|
|
65985
|
+
mimeType: "application/json",
|
|
65986
|
+
text: JSON.stringify(loadBalancer, null, 2)
|
|
65987
|
+
}
|
|
65988
|
+
]
|
|
65989
|
+
};
|
|
65990
|
+
});
|
|
65991
|
+
};
|
|
65992
|
+
|
|
65858
65993
|
// src/tools/platform/middleware/create.ts
|
|
65859
65994
|
var platformMiddlewareCreate = (server, env3, pat) => {
|
|
65860
65995
|
const instance = env3.SETTLEMINT_INSTANCE;
|
|
@@ -65873,8 +66008,12 @@ var platformMiddlewareCreate = (server, env3, pat) => {
|
|
|
65873
66008
|
provider: z.string().describe("Provider for the middleware"),
|
|
65874
66009
|
region: z.string().describe("Region for the middleware"),
|
|
65875
66010
|
interface: z.enum(["ATTESTATION_INDEXER", "BESU", "FIREFLY_FABCONNECT", "GRAPH", "HA_GRAPH", "SMART_CONTRACT_PORTAL"]).describe("Interface type for the middleware"),
|
|
65876
|
-
blockchainNodeUniqueName: z.string().optional().describe("Unique name of the blockchain node to connect to")
|
|
66011
|
+
blockchainNodeUniqueName: z.string().optional().describe("Unique name of the blockchain node to connect to (mutually exclusive with loadBalancerUniqueName), preferred option for interface SMART_CONTRACT_PORTAL"),
|
|
66012
|
+
loadBalancerUniqueName: z.string().optional().describe("Unique name of the load balancer to connect to (mutually exclusive with blockchainNodeUniqueName), preferred option for all other interfaces")
|
|
65877
66013
|
}, async (params) => {
|
|
66014
|
+
if (params.blockchainNodeUniqueName && params.loadBalancerUniqueName) {
|
|
66015
|
+
throw new Error("Only one of 'blockchainNodeUniqueName' and 'loadBalancerUniqueName' may be provided");
|
|
66016
|
+
}
|
|
65878
66017
|
const middleware = await client.middleware.create({
|
|
65879
66018
|
applicationUniqueName: params.applicationUniqueName,
|
|
65880
66019
|
name: params.name,
|
|
@@ -65883,7 +66022,8 @@ var platformMiddlewareCreate = (server, env3, pat) => {
|
|
|
65883
66022
|
provider: params.provider,
|
|
65884
66023
|
region: params.region,
|
|
65885
66024
|
interface: params.interface,
|
|
65886
|
-
blockchainNodeUniqueName: params.blockchainNodeUniqueName
|
|
66025
|
+
blockchainNodeUniqueName: params.blockchainNodeUniqueName,
|
|
66026
|
+
loadBalancerUniqueName: params.loadBalancerUniqueName
|
|
65887
66027
|
});
|
|
65888
66028
|
return {
|
|
65889
66029
|
content: [
|
|
@@ -66731,6 +66871,10 @@ async function main() {
|
|
|
66731
66871
|
platformBlockchainNodeRead(server, env3, pat);
|
|
66732
66872
|
platformBlockchainNodeCreate(server, env3, pat);
|
|
66733
66873
|
platformBlockchainNodeRestart(server, env3, pat);
|
|
66874
|
+
platformLoadBalancerList(server, env3, pat);
|
|
66875
|
+
platformLoadBalancerRead(server, env3, pat);
|
|
66876
|
+
platformLoadBalancerCreate(server, env3, pat);
|
|
66877
|
+
platformLoadBalancerRestart(server, env3, pat);
|
|
66734
66878
|
platformMiddlewareList(server, env3, pat);
|
|
66735
66879
|
platformMiddlewareRead(server, env3, pat);
|
|
66736
66880
|
platformMiddlewareCreate(server, env3, pat);
|
|
@@ -66768,4 +66912,4 @@ await main().catch((error2) => {
|
|
|
66768
66912
|
process.exit(1);
|
|
66769
66913
|
});
|
|
66770
66914
|
|
|
66771
|
-
//# debugId=
|
|
66915
|
+
//# debugId=201A98534B1091FB64756E2164756E21
|