fix auth link
This commit is contained in:
parent
cdf7b01768
commit
f89a9abece
4 changed files with 4 additions and 6 deletions
1
.vscode/launch.json
vendored
1
.vscode/launch.json
vendored
|
|
@ -38,6 +38,7 @@
|
|||
"internalConsoleOptions": "openOnSessionStart",
|
||||
"cwd": "${workspaceFolder}/binary",
|
||||
"env": {
|
||||
// "CONTROL_PLANE_ENV": "test",
|
||||
"CONTINUE_DEVELOPMENT": "true",
|
||||
"CONTINUE_GLOBAL_DIR": "${workspaceFolder}/extensions/.continue-debug"
|
||||
}
|
||||
|
|
|
|||
2
binary/package-lock.json
generated
2
binary/package-lock.json
generated
|
|
@ -48,7 +48,7 @@
|
|||
"@aws-sdk/client-sagemaker-runtime": "^3.621.0",
|
||||
"@aws-sdk/credential-providers": "^3.620.1",
|
||||
"@continuedev/config-types": "^1.0.13",
|
||||
"@continuedev/config-yaml": "^1.0.10",
|
||||
"@continuedev/config-yaml": "^1.0.16",
|
||||
"@continuedev/fetch": "^1.0.4",
|
||||
"@continuedev/llm-info": "^1.0.2",
|
||||
"@continuedev/openai-adapters": "^1.0.10",
|
||||
|
|
|
|||
|
|
@ -2,14 +2,11 @@ import { v4 as uuidv4 } from "uuid";
|
|||
|
||||
import { controlPlaneEnv } from "../env";
|
||||
|
||||
const CLIENT_ID = "client_01J0FW6XN8N2XJAECF7NE0Y65J";
|
||||
// const CLIENT_ID = "client_01J0FW6XCPMJMQ3CG51RB4HBZQ"; // Staging
|
||||
|
||||
export async function getAuthUrlForTokenPage(): Promise<string> {
|
||||
const url = new URL("https://api.workos.com/user_management/authorize");
|
||||
const params = {
|
||||
response_type: "code",
|
||||
client_id: CLIENT_ID,
|
||||
client_id: controlPlaneEnv.WORKOS_CLIENT_ID,
|
||||
redirect_uri: `${controlPlaneEnv.APP_URL}tokens/callback`,
|
||||
// redirect_uri: "http://localhost:3000/tokens/callback",
|
||||
state: uuidv4(),
|
||||
|
|
|
|||
|
|
@ -135,7 +135,7 @@ class ContinueAuthService {
|
|||
private fun openSignInPage(project: Project) {
|
||||
val coreMessenger = project.service<ContinuePluginService>().coreMessenger
|
||||
coreMessenger?.request("auth/getAuthUrl", null, null) { response ->
|
||||
val authUrl = (response as? Map<*, *>)?.get("url") as? String
|
||||
val authUrl = ((response as? Map<*, *>)?.get("content") as? Map<*, *>)?.get("url") as? String
|
||||
if (authUrl != null) {
|
||||
// Open the auth URL in the browser
|
||||
Desktop.getDesktop().browse(java.net.URI(authUrl))
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue