mirror of
https://github.com/eliasstepanik/core.git
synced 2026-01-11 09:48:27 +00:00
* Feat: added integration connect and mcp oAuth * Feat: add mcp support to chat * Fix: UI for integrations and logs * Fix: ui * Fix: proxy server * Feat: enhance MCP tool integration and loading functionality * Fix: added header * Fix: Linear integration sync --------- Co-authored-by: Manoj K <saimanoj58@gmail.com>
22 lines
663 B
TypeScript
22 lines
663 B
TypeScript
import { createActionApiRoute } from "~/services/routeBuilders/apiBuilder.server";
|
|
import { callbackHandler } from "~/services/oauth/oauth.server";
|
|
import type { CallbackParams } from "~/services/oauth/oauth-utils.server";
|
|
|
|
// This route handles the OAuth callback, similar to the NestJS controller
|
|
const { loader } = createActionApiRoute(
|
|
{
|
|
allowJWT: false,
|
|
corsStrategy: "all",
|
|
},
|
|
async ({ request }) => {
|
|
const url = new URL(request.url);
|
|
const params: CallbackParams = {};
|
|
for (const [key, value] of url.searchParams.entries()) {
|
|
params[key] = value;
|
|
}
|
|
return await callbackHandler(params);
|
|
},
|
|
);
|
|
|
|
export { loader };
|