@inkeep/agents-manage-api 0.32.2 → 0.33.1
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.cjs +5 -6
- package/dist/index.js +5 -6
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -21,8 +21,7 @@ agentsCore.loadEnvironmentFiles();
|
|
|
21
21
|
var envSchema = zod.z.object({
|
|
22
22
|
NODE_ENV: zod.z.enum(["development", "production", "test"]).optional(),
|
|
23
23
|
ENVIRONMENT: zod.z.enum(["development", "production", "pentest", "test"]).optional(),
|
|
24
|
-
|
|
25
|
-
AGENTS_RUN_API_URL: zod.z.string().optional().default("http://localhost:3003"),
|
|
24
|
+
INKEEP_AGENTS_MANAGE_API_URL: zod.z.string().optional().default("http://localhost:3002"),
|
|
26
25
|
DATABASE_URL: zod.z.string().optional(),
|
|
27
26
|
LOG_LEVEL: zod.z.enum(["trace", "debug", "info", "warn", "error"]).optional().default("debug"),
|
|
28
27
|
NANGO_SERVER_URL: zod.z.string().optional().default("https://api.nango.dev"),
|
|
@@ -31,8 +30,7 @@ var envSchema = zod.z.object({
|
|
|
31
30
|
});
|
|
32
31
|
var parseEnv = () => {
|
|
33
32
|
try {
|
|
34
|
-
|
|
35
|
-
return parsedEnv;
|
|
33
|
+
return envSchema.parse(process.env);
|
|
36
34
|
} catch (error) {
|
|
37
35
|
if (error instanceof zod.z.ZodError) {
|
|
38
36
|
const missingVars = error.issues.map((issue) => issue.path.join("."));
|
|
@@ -73,6 +71,7 @@ var apiKeyAuth = () => factory.createMiddleware(async (c, next) => {
|
|
|
73
71
|
function setupOpenAPIRoutes(app25) {
|
|
74
72
|
app25.get("/openapi.json", (c) => {
|
|
75
73
|
try {
|
|
74
|
+
const serverUrl = process.env.VERCEL_ENV === "production" && process.env.VERCEL_PROJECT_PRODUCTION_URL ? `https://${process.env.VERCEL_PROJECT_PRODUCTION_URL}` : process.env.VERCEL_ENV === "preview" && process.env.VERCEL_URL ? `https://${process.env.VERCEL_URL}` : env.INKEEP_AGENTS_MANAGE_API_URL;
|
|
76
75
|
const document = app25.getOpenAPIDocument({
|
|
77
76
|
openapi: "3.0.0",
|
|
78
77
|
info: {
|
|
@@ -82,7 +81,7 @@ function setupOpenAPIRoutes(app25) {
|
|
|
82
81
|
},
|
|
83
82
|
servers: [
|
|
84
83
|
{
|
|
85
|
-
url:
|
|
84
|
+
url: serverUrl,
|
|
86
85
|
description: "API Server"
|
|
87
86
|
}
|
|
88
87
|
]
|
|
@@ -4815,7 +4814,7 @@ var OAuthService = class {
|
|
|
4815
4814
|
clientName: config.clientName || process.env.OAUTH_CLIENT_NAME || "Inkeep Agent Framework",
|
|
4816
4815
|
clientUri: config.clientUri || process.env.OAUTH_CLIENT_URI || "https://inkeep.com",
|
|
4817
4816
|
logoUri: config.logoUri || process.env.OAUTH_CLIENT_LOGO_URI || "https://inkeep.com/images/logos/inkeep-logo-blue.svg",
|
|
4818
|
-
redirectBaseUrl: config.redirectBaseUrl || env.
|
|
4817
|
+
redirectBaseUrl: config.redirectBaseUrl || env.INKEEP_AGENTS_MANAGE_API_URL
|
|
4819
4818
|
};
|
|
4820
4819
|
}
|
|
4821
4820
|
/**
|
package/dist/index.js
CHANGED
|
@@ -17,8 +17,7 @@ loadEnvironmentFiles();
|
|
|
17
17
|
var envSchema = z.object({
|
|
18
18
|
NODE_ENV: z.enum(["development", "production", "test"]).optional(),
|
|
19
19
|
ENVIRONMENT: z.enum(["development", "production", "pentest", "test"]).optional(),
|
|
20
|
-
|
|
21
|
-
AGENTS_RUN_API_URL: z.string().optional().default("http://localhost:3003"),
|
|
20
|
+
INKEEP_AGENTS_MANAGE_API_URL: z.string().optional().default("http://localhost:3002"),
|
|
22
21
|
DATABASE_URL: z.string().optional(),
|
|
23
22
|
LOG_LEVEL: z.enum(["trace", "debug", "info", "warn", "error"]).optional().default("debug"),
|
|
24
23
|
NANGO_SERVER_URL: z.string().optional().default("https://api.nango.dev"),
|
|
@@ -27,8 +26,7 @@ var envSchema = z.object({
|
|
|
27
26
|
});
|
|
28
27
|
var parseEnv = () => {
|
|
29
28
|
try {
|
|
30
|
-
|
|
31
|
-
return parsedEnv;
|
|
29
|
+
return envSchema.parse(process.env);
|
|
32
30
|
} catch (error) {
|
|
33
31
|
if (error instanceof z.ZodError) {
|
|
34
32
|
const missingVars = error.issues.map((issue) => issue.path.join("."));
|
|
@@ -69,6 +67,7 @@ var apiKeyAuth = () => createMiddleware(async (c, next) => {
|
|
|
69
67
|
function setupOpenAPIRoutes(app25) {
|
|
70
68
|
app25.get("/openapi.json", (c) => {
|
|
71
69
|
try {
|
|
70
|
+
const serverUrl = process.env.VERCEL_ENV === "production" && process.env.VERCEL_PROJECT_PRODUCTION_URL ? `https://${process.env.VERCEL_PROJECT_PRODUCTION_URL}` : process.env.VERCEL_ENV === "preview" && process.env.VERCEL_URL ? `https://${process.env.VERCEL_URL}` : env.INKEEP_AGENTS_MANAGE_API_URL;
|
|
72
71
|
const document = app25.getOpenAPIDocument({
|
|
73
72
|
openapi: "3.0.0",
|
|
74
73
|
info: {
|
|
@@ -78,7 +77,7 @@ function setupOpenAPIRoutes(app25) {
|
|
|
78
77
|
},
|
|
79
78
|
servers: [
|
|
80
79
|
{
|
|
81
|
-
url:
|
|
80
|
+
url: serverUrl,
|
|
82
81
|
description: "API Server"
|
|
83
82
|
}
|
|
84
83
|
]
|
|
@@ -4811,7 +4810,7 @@ var OAuthService = class {
|
|
|
4811
4810
|
clientName: config.clientName || process.env.OAUTH_CLIENT_NAME || "Inkeep Agent Framework",
|
|
4812
4811
|
clientUri: config.clientUri || process.env.OAUTH_CLIENT_URI || "https://inkeep.com",
|
|
4813
4812
|
logoUri: config.logoUri || process.env.OAUTH_CLIENT_LOGO_URI || "https://inkeep.com/images/logos/inkeep-logo-blue.svg",
|
|
4814
|
-
redirectBaseUrl: config.redirectBaseUrl || env.
|
|
4813
|
+
redirectBaseUrl: config.redirectBaseUrl || env.INKEEP_AGENTS_MANAGE_API_URL
|
|
4815
4814
|
};
|
|
4816
4815
|
}
|
|
4817
4816
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@inkeep/agents-manage-api",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.33.1",
|
|
4
4
|
"description": "Agents Manage API for Inkeep Agent Framework - handles CRUD operations and OAuth",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"openid-client": "^6.6.4",
|
|
24
24
|
"pino": "^9.7.0",
|
|
25
25
|
"zod": "^4.1.11",
|
|
26
|
-
"@inkeep/agents-core": "^0.
|
|
26
|
+
"@inkeep/agents-core": "^0.33.1"
|
|
27
27
|
},
|
|
28
28
|
"optionalDependencies": {
|
|
29
29
|
"keytar": "^7.9.0"
|