@avallon-labs/mcp 24.2.0 → 24.3.0-staging.613
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.js
CHANGED
|
@@ -646,6 +646,42 @@ var getSessionToken = async (getSessionTokenBody, options) => {
|
|
|
646
646
|
headers: res.headers
|
|
647
647
|
};
|
|
648
648
|
};
|
|
649
|
+
var getExperimentalSignUpUrl = () => {
|
|
650
|
+
return `/experimental/auth/sign-up`;
|
|
651
|
+
};
|
|
652
|
+
var experimentalSignUp = async (experimentalSignUpBody, options) => {
|
|
653
|
+
const res = await fetch(getExperimentalSignUpUrl(), {
|
|
654
|
+
...options,
|
|
655
|
+
method: "POST",
|
|
656
|
+
headers: { "Content-Type": "application/json", ...options?.headers },
|
|
657
|
+
body: JSON.stringify(experimentalSignUpBody)
|
|
658
|
+
});
|
|
659
|
+
const body = [204, 205, 304].includes(res.status) ? null : await res.text();
|
|
660
|
+
const data = body ? JSON.parse(body) : {};
|
|
661
|
+
return {
|
|
662
|
+
data,
|
|
663
|
+
status: res.status,
|
|
664
|
+
headers: res.headers
|
|
665
|
+
};
|
|
666
|
+
};
|
|
667
|
+
var getExperimentalSignInUrl = () => {
|
|
668
|
+
return `/experimental/auth/sign-in`;
|
|
669
|
+
};
|
|
670
|
+
var experimentalSignIn = async (experimentalSignInBody, options) => {
|
|
671
|
+
const res = await fetch(getExperimentalSignInUrl(), {
|
|
672
|
+
...options,
|
|
673
|
+
method: "POST",
|
|
674
|
+
headers: { "Content-Type": "application/json", ...options?.headers },
|
|
675
|
+
body: JSON.stringify(experimentalSignInBody)
|
|
676
|
+
});
|
|
677
|
+
const body = [204, 205, 304].includes(res.status) ? null : await res.text();
|
|
678
|
+
const data = body ? JSON.parse(body) : {};
|
|
679
|
+
return {
|
|
680
|
+
data,
|
|
681
|
+
status: res.status,
|
|
682
|
+
headers: res.headers
|
|
683
|
+
};
|
|
684
|
+
};
|
|
649
685
|
var getListCallsUrl = (params) => {
|
|
650
686
|
const normalizedParams = new URLSearchParams();
|
|
651
687
|
Object.entries(params || {}).forEach(([key, value]) => {
|
|
@@ -2637,6 +2673,28 @@ var getSessionTokenHandler = async (args) => {
|
|
|
2637
2673
|
]
|
|
2638
2674
|
};
|
|
2639
2675
|
};
|
|
2676
|
+
var experimentalSignUpHandler = async (args) => {
|
|
2677
|
+
const res = await experimentalSignUp(args.bodyParams);
|
|
2678
|
+
return {
|
|
2679
|
+
content: [
|
|
2680
|
+
{
|
|
2681
|
+
type: "text",
|
|
2682
|
+
text: JSON.stringify(res)
|
|
2683
|
+
}
|
|
2684
|
+
]
|
|
2685
|
+
};
|
|
2686
|
+
};
|
|
2687
|
+
var experimentalSignInHandler = async (args) => {
|
|
2688
|
+
const res = await experimentalSignIn(args.bodyParams);
|
|
2689
|
+
return {
|
|
2690
|
+
content: [
|
|
2691
|
+
{
|
|
2692
|
+
type: "text",
|
|
2693
|
+
text: JSON.stringify(res)
|
|
2694
|
+
}
|
|
2695
|
+
]
|
|
2696
|
+
};
|
|
2697
|
+
};
|
|
2640
2698
|
var listCallsHandler = async (args) => {
|
|
2641
2699
|
const res = await listCalls(args.queryParams);
|
|
2642
2700
|
return {
|
|
@@ -5048,6 +5106,36 @@ var GetSessionTokenResponse = zod.object({
|
|
|
5048
5106
|
tenant_id: zod.string(),
|
|
5049
5107
|
expires_in: zod.number()
|
|
5050
5108
|
});
|
|
5109
|
+
var ExperimentalSignUpBody = zod.object({
|
|
5110
|
+
email: zod.string().email(),
|
|
5111
|
+
password: zod.string()
|
|
5112
|
+
});
|
|
5113
|
+
var ExperimentalSignUpResponse = zod.object({
|
|
5114
|
+
pending_authentication_token: zod.string().optional()
|
|
5115
|
+
});
|
|
5116
|
+
var ExperimentalSignInBody = zod.union([
|
|
5117
|
+
zod.object({
|
|
5118
|
+
type: zod.literal("password"),
|
|
5119
|
+
email: zod.string(),
|
|
5120
|
+
password: zod.string()
|
|
5121
|
+
}),
|
|
5122
|
+
zod.object({
|
|
5123
|
+
type: zod.literal("oauth"),
|
|
5124
|
+
code: zod.string(),
|
|
5125
|
+
verifier: zod.string()
|
|
5126
|
+
}),
|
|
5127
|
+
zod.object({
|
|
5128
|
+
type: zod.literal("email_otp"),
|
|
5129
|
+
email: zod.string().email(),
|
|
5130
|
+
token: zod.string().min(1),
|
|
5131
|
+
pending_authentication_token: zod.string().min(1)
|
|
5132
|
+
})
|
|
5133
|
+
]);
|
|
5134
|
+
var ExperimentalSignInResponse = zod.object({
|
|
5135
|
+
access_token: zod.string(),
|
|
5136
|
+
refresh_token: zod.string(),
|
|
5137
|
+
expires_at: zod.string().datetime({})
|
|
5138
|
+
});
|
|
5051
5139
|
var listCallsQueryCountDefault = 50;
|
|
5052
5140
|
var listCallsQueryCountMax = 100;
|
|
5053
5141
|
var listCallsQueryOffsetDefault = 0;
|
|
@@ -7050,6 +7138,22 @@ server.tool(
|
|
|
7050
7138
|
},
|
|
7051
7139
|
getSessionTokenHandler
|
|
7052
7140
|
);
|
|
7141
|
+
server.tool(
|
|
7142
|
+
"experimentalSignUp",
|
|
7143
|
+
"Sign up (experimental)",
|
|
7144
|
+
{
|
|
7145
|
+
bodyParams: ExperimentalSignUpBody
|
|
7146
|
+
},
|
|
7147
|
+
experimentalSignUpHandler
|
|
7148
|
+
);
|
|
7149
|
+
server.tool(
|
|
7150
|
+
"experimentalSignIn",
|
|
7151
|
+
"Sign in (experimental)",
|
|
7152
|
+
{
|
|
7153
|
+
bodyParams: ExperimentalSignInBody
|
|
7154
|
+
},
|
|
7155
|
+
experimentalSignInHandler
|
|
7156
|
+
);
|
|
7053
7157
|
server.tool(
|
|
7054
7158
|
"listCalls",
|
|
7055
7159
|
"List calls",
|
|
@@ -7697,4 +7801,4 @@ var transport = new StdioServerTransport();
|
|
|
7697
7801
|
server.connect(transport).then(() => {
|
|
7698
7802
|
console.error("MCP server running on stdio");
|
|
7699
7803
|
}).catch(console.error);
|
|
7700
|
-
//# sourceMappingURL=server-
|
|
7804
|
+
//# sourceMappingURL=server-3A7OZLRM.js.map
|