@opengeni/core 4.0.3-canary.36079201993001 → 4.0.3
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/application/new-session-drafts.d.ts +3 -3
- package/dist/domain/capabilities.d.ts +1 -2
- package/dist/domain/knowledge-messages.d.ts +2 -2
- package/dist/domain/pr-review.d.ts +2 -2
- package/dist/index.js +22 -97
- package/dist/index.js.map +1 -1
- package/package.json +12 -12
- package/src/application/session-mcp-credential-rotation.ts +15 -57
- package/src/domain/capabilities.ts +1 -17
- package/dist/domain/session-native-connection-replacement.d.ts +0 -14
- package/src/domain/session-native-connection-replacement.ts +0 -64
|
@@ -50,7 +50,7 @@ export declare function getActorNewSessionDefaults(deps: Parameters<typeof getAc
|
|
|
50
50
|
eager?: boolean | undefined;
|
|
51
51
|
optional?: boolean | undefined;
|
|
52
52
|
}[];
|
|
53
|
-
firstPartyMcpTools?: ("artifacts_archive" | "artifacts_create" | "artifacts_get_source" | "artifacts_list" | "artifacts_prepare_upload" | "artifacts_publish" | "artifacts_restore" | "artifacts_rollback" | "atlassian_get" | "atlassian_search" | "atlassian_sources_list" | "browser_act" | "browser_auth" | "browser_clipboard" | "browser_debug" | "browser_identity" | "browser_lifecycle" | "browser_observe" | "browser_open" | "browser_publish" | "browser_read" | "browser_screenshot" | "browser_tabs" | "capability_authorization_request" | "capability_catalog_search" | "command_read" | "command_wait" | "company_profile_confirm" | "company_profile_propose" | "computer_act" | "computer_clipboard" | "computer_lifecycle" | "computer_observe" | "computer_open" | "computer_targets" | "connected_machine_enroll_token" | "connected_machine_remove" | "
|
|
53
|
+
firstPartyMcpTools?: ("artifacts_archive" | "artifacts_create" | "artifacts_get_source" | "artifacts_list" | "artifacts_prepare_upload" | "artifacts_publish" | "artifacts_restore" | "artifacts_rollback" | "atlassian_get" | "atlassian_search" | "atlassian_sources_list" | "browser_act" | "browser_auth" | "browser_clipboard" | "browser_debug" | "browser_identity" | "browser_lifecycle" | "browser_observe" | "browser_open" | "browser_publish" | "browser_read" | "browser_screenshot" | "browser_tabs" | "capability_authorization_request" | "capability_catalog_search" | "command_read" | "command_wait" | "company_profile_confirm" | "company_profile_propose" | "computer_act" | "computer_clipboard" | "computer_lifecycle" | "computer_observe" | "computer_open" | "computer_targets" | "connected_machine_enroll_token" | "connected_machine_remove" | "editable_artifact_apply" | "editable_artifact_create" | "editable_artifact_export" | "editable_artifact_export_status" | "editable_artifact_get" | "editable_artifact_import" | "editable_artifact_inspect" | "editable_artifact_list" | "environment_list" | "environment_set_variable" | "fiken_bank_accounts_list" | "fiken_companies_list" | "fiken_contact_create" | "fiken_contacts_list" | "fiken_invoice_draft_create" | "fiken_invoice_get" | "fiken_invoices_list" | "fiken_products_list" | "fiken_purchases_list" | "fiken_sales_list" | "github_connect_link" | "github_repositories_list" | "goal_complete" | "goal_pause" | "goal_progress" | "goal_resume" | "goal_set" | "goal_update" | "instruction_policy_get" | "instruction_policy_propose" | "instruction_policy_save" | "interaction_discover" | "interaction_request_human" | "knowledge_archive" | "knowledge_browse" | "knowledge_correct" | "knowledge_get" | "knowledge_prepare_save" | "knowledge_propose" | "knowledge_retain_file" | "knowledge_retain_message" | "knowledge_save" | "knowledge_search" | "memory_correct" | "memory_save" | "memory_search" | "preference_propose" | "preference_registry_get" | "preference_registry_summary" | "project_create" | "project_delete" | "project_get" | "project_list" | "project_reorder" | "project_update" | "reddit_accounts_list" | "reddit_mentions_live" | "reddit_post_reply" | "reddit_posts_sync" | "reddit_search_live" | "reddit_thread_fetch" | "remember" | "remember_confirm" | "rig_get" | "rig_list" | "rig_promote" | "rig_propose_change" | "rig_verify" | "run_on" | "sandbox_attach" | "sandbox_file_publish" | "sandbox_provision" | "sandbox_swap" | "sandboxes_list" | "scheduled_task_runs_list" | "scheduled_tasks_create" | "scheduled_tasks_delete" | "scheduled_tasks_get" | "scheduled_tasks_list" | "scheduled_tasks_pause" | "scheduled_tasks_resume" | "scheduled_tasks_trigger" | "scheduled_tasks_update" | "session_create" | "session_events" | "session_get" | "session_human_input_respond" | "session_pause" | "session_resume" | "session_send_message" | "session_set_project" | "session_steer" | "session_wait" | "sessions_list" | "set_other_session_title" | "set_session_title" | "slack_bot_channel_history" | "slack_bot_delete_message" | "slack_bot_file_content" | "slack_bot_file_info" | "slack_bot_list_channels" | "slack_bot_list_files" | "slack_bot_list_users" | "slack_bot_post_message" | "slack_bot_search" | "slack_bot_thread_replies" | "social_connections_list" | "social_daily_analysis_context" | "social_mentions_live" | "social_post_reply" | "social_posts_recent" | "social_posts_sync" | "social_search_live" | "social_thread_fetch" | "task_note_archive" | "task_note_promote_instruction_policy" | "task_note_promote_knowledge" | "task_note_promote_preference" | "task_note_replace" | "task_note_save" | "task_notes_list" | "variable_set_get_variable" | "variable_set_list" | "variable_set_set_variable" | "wait_for_input" | "work_claim_release" | "work_claim_upsert" | "x_accounts_list" | "x_mentions_live" | "x_post_reply" | "x_posts_sync" | "x_search_live" | "x_thread_fetch")[];
|
|
54
54
|
firstPartyMcpPermissions?: ("account:admin" | "account:read" | "api_keys:manage" | "artifacts:publish" | "artifacts:read" | "billing:manage" | "billing:read" | "capabilities:manage" | "codemode:call" | "connections:read" | "connections:write" | "documents:manage" | "documents:search" | "enrollments:manage" | "enrollments:read" | "environments:manage" | "environments:use" | "files:read" | "files:upload" | "files:write" | "github:manage" | "github:use" | "goals:manage" | "mcp_servers:attach" | "members:manage" | "rigs:manage" | "rigs:use" | "scheduled_tasks:manage" | "scheduled_tasks:run" | "secrets:list" | "secrets:read" | "secrets:write" | "sessions:control" | "sessions:create" | "sessions:read" | "stream:acknowledge" | "stream:control" | "stream:view" | "terminal:attach" | "variable-sets:attach" | "variable-sets:list" | "variable-sets:manage" | "variable-sets:read" | "variable-sets:use" | "variable-sets:write" | "workspace:admin" | "workspace:create" | "workspace:read")[];
|
|
55
55
|
variableSetIds?: string[];
|
|
56
56
|
rigId?: string;
|
|
@@ -80,7 +80,7 @@ export declare function getActorNewSessionDefaults(deps: Parameters<typeof getAc
|
|
|
80
80
|
githubRepositoryId?: number | undefined;
|
|
81
81
|
}[];
|
|
82
82
|
excludedMcpServerIds: string[];
|
|
83
|
-
firstPartyMcpTools?: ("artifacts_archive" | "artifacts_create" | "artifacts_get_source" | "artifacts_list" | "artifacts_prepare_upload" | "artifacts_publish" | "artifacts_restore" | "artifacts_rollback" | "atlassian_get" | "atlassian_search" | "atlassian_sources_list" | "browser_act" | "browser_auth" | "browser_clipboard" | "browser_debug" | "browser_identity" | "browser_lifecycle" | "browser_observe" | "browser_open" | "browser_publish" | "browser_read" | "browser_screenshot" | "browser_tabs" | "capability_authorization_request" | "capability_catalog_search" | "command_read" | "command_wait" | "company_profile_confirm" | "company_profile_propose" | "computer_act" | "computer_clipboard" | "computer_lifecycle" | "computer_observe" | "computer_open" | "computer_targets" | "connected_machine_enroll_token" | "connected_machine_remove" | "
|
|
83
|
+
firstPartyMcpTools?: ("artifacts_archive" | "artifacts_create" | "artifacts_get_source" | "artifacts_list" | "artifacts_prepare_upload" | "artifacts_publish" | "artifacts_restore" | "artifacts_rollback" | "atlassian_get" | "atlassian_search" | "atlassian_sources_list" | "browser_act" | "browser_auth" | "browser_clipboard" | "browser_debug" | "browser_identity" | "browser_lifecycle" | "browser_observe" | "browser_open" | "browser_publish" | "browser_read" | "browser_screenshot" | "browser_tabs" | "capability_authorization_request" | "capability_catalog_search" | "command_read" | "command_wait" | "company_profile_confirm" | "company_profile_propose" | "computer_act" | "computer_clipboard" | "computer_lifecycle" | "computer_observe" | "computer_open" | "computer_targets" | "connected_machine_enroll_token" | "connected_machine_remove" | "editable_artifact_apply" | "editable_artifact_create" | "editable_artifact_export" | "editable_artifact_export_status" | "editable_artifact_get" | "editable_artifact_import" | "editable_artifact_inspect" | "editable_artifact_list" | "environment_list" | "environment_set_variable" | "fiken_bank_accounts_list" | "fiken_companies_list" | "fiken_contact_create" | "fiken_contacts_list" | "fiken_invoice_draft_create" | "fiken_invoice_get" | "fiken_invoices_list" | "fiken_products_list" | "fiken_purchases_list" | "fiken_sales_list" | "github_connect_link" | "github_repositories_list" | "goal_complete" | "goal_pause" | "goal_progress" | "goal_resume" | "goal_set" | "goal_update" | "instruction_policy_get" | "instruction_policy_propose" | "instruction_policy_save" | "interaction_discover" | "interaction_request_human" | "knowledge_archive" | "knowledge_browse" | "knowledge_correct" | "knowledge_get" | "knowledge_prepare_save" | "knowledge_propose" | "knowledge_retain_file" | "knowledge_retain_message" | "knowledge_save" | "knowledge_search" | "memory_correct" | "memory_save" | "memory_search" | "preference_propose" | "preference_registry_get" | "preference_registry_summary" | "project_create" | "project_delete" | "project_get" | "project_list" | "project_reorder" | "project_update" | "reddit_accounts_list" | "reddit_mentions_live" | "reddit_post_reply" | "reddit_posts_sync" | "reddit_search_live" | "reddit_thread_fetch" | "remember" | "remember_confirm" | "rig_get" | "rig_list" | "rig_promote" | "rig_propose_change" | "rig_verify" | "run_on" | "sandbox_attach" | "sandbox_file_publish" | "sandbox_provision" | "sandbox_swap" | "sandboxes_list" | "scheduled_task_runs_list" | "scheduled_tasks_create" | "scheduled_tasks_delete" | "scheduled_tasks_get" | "scheduled_tasks_list" | "scheduled_tasks_pause" | "scheduled_tasks_resume" | "scheduled_tasks_trigger" | "scheduled_tasks_update" | "session_create" | "session_events" | "session_get" | "session_human_input_respond" | "session_pause" | "session_resume" | "session_send_message" | "session_set_project" | "session_steer" | "session_wait" | "sessions_list" | "set_other_session_title" | "set_session_title" | "slack_bot_channel_history" | "slack_bot_delete_message" | "slack_bot_file_content" | "slack_bot_file_info" | "slack_bot_list_channels" | "slack_bot_list_files" | "slack_bot_list_users" | "slack_bot_post_message" | "slack_bot_search" | "slack_bot_thread_replies" | "social_connections_list" | "social_daily_analysis_context" | "social_mentions_live" | "social_post_reply" | "social_posts_recent" | "social_posts_sync" | "social_search_live" | "social_thread_fetch" | "task_note_archive" | "task_note_promote_instruction_policy" | "task_note_promote_knowledge" | "task_note_promote_preference" | "task_note_replace" | "task_note_save" | "task_notes_list" | "variable_set_get_variable" | "variable_set_list" | "variable_set_set_variable" | "wait_for_input" | "work_claim_release" | "work_claim_upsert" | "x_accounts_list" | "x_mentions_live" | "x_post_reply" | "x_posts_sync" | "x_search_live" | "x_thread_fetch")[];
|
|
84
84
|
firstPartyMcpPermissions?: ("account:admin" | "account:read" | "api_keys:manage" | "artifacts:publish" | "artifacts:read" | "billing:manage" | "billing:read" | "capabilities:manage" | "codemode:call" | "connections:read" | "connections:write" | "documents:manage" | "documents:search" | "enrollments:manage" | "enrollments:read" | "environments:manage" | "environments:use" | "files:read" | "files:upload" | "files:write" | "github:manage" | "github:use" | "goals:manage" | "mcp_servers:attach" | "members:manage" | "rigs:manage" | "rigs:use" | "scheduled_tasks:manage" | "scheduled_tasks:run" | "secrets:list" | "secrets:read" | "secrets:write" | "sessions:control" | "sessions:create" | "sessions:read" | "stream:acknowledge" | "stream:control" | "stream:view" | "terminal:attach" | "variable-sets:attach" | "variable-sets:list" | "variable-sets:manage" | "variable-sets:read" | "variable-sets:use" | "variable-sets:write" | "workspace:admin" | "workspace:create" | "workspace:read")[];
|
|
85
85
|
variableSetIds?: string[];
|
|
86
86
|
rigId?: string;
|
|
@@ -109,7 +109,7 @@ export declare function getActorNewSessionDefaults(deps: Parameters<typeof getAc
|
|
|
109
109
|
githubInstallationId?: number | undefined;
|
|
110
110
|
githubRepositoryId?: number | undefined;
|
|
111
111
|
}[];
|
|
112
|
-
firstPartyMcpTools?: ("artifacts_archive" | "artifacts_create" | "artifacts_get_source" | "artifacts_list" | "artifacts_prepare_upload" | "artifacts_publish" | "artifacts_restore" | "artifacts_rollback" | "atlassian_get" | "atlassian_search" | "atlassian_sources_list" | "browser_act" | "browser_auth" | "browser_clipboard" | "browser_debug" | "browser_identity" | "browser_lifecycle" | "browser_observe" | "browser_open" | "browser_publish" | "browser_read" | "browser_screenshot" | "browser_tabs" | "capability_authorization_request" | "capability_catalog_search" | "command_read" | "command_wait" | "company_profile_confirm" | "company_profile_propose" | "computer_act" | "computer_clipboard" | "computer_lifecycle" | "computer_observe" | "computer_open" | "computer_targets" | "connected_machine_enroll_token" | "connected_machine_remove" | "
|
|
112
|
+
firstPartyMcpTools?: ("artifacts_archive" | "artifacts_create" | "artifacts_get_source" | "artifacts_list" | "artifacts_prepare_upload" | "artifacts_publish" | "artifacts_restore" | "artifacts_rollback" | "atlassian_get" | "atlassian_search" | "atlassian_sources_list" | "browser_act" | "browser_auth" | "browser_clipboard" | "browser_debug" | "browser_identity" | "browser_lifecycle" | "browser_observe" | "browser_open" | "browser_publish" | "browser_read" | "browser_screenshot" | "browser_tabs" | "capability_authorization_request" | "capability_catalog_search" | "command_read" | "command_wait" | "company_profile_confirm" | "company_profile_propose" | "computer_act" | "computer_clipboard" | "computer_lifecycle" | "computer_observe" | "computer_open" | "computer_targets" | "connected_machine_enroll_token" | "connected_machine_remove" | "editable_artifact_apply" | "editable_artifact_create" | "editable_artifact_export" | "editable_artifact_export_status" | "editable_artifact_get" | "editable_artifact_import" | "editable_artifact_inspect" | "editable_artifact_list" | "environment_list" | "environment_set_variable" | "fiken_bank_accounts_list" | "fiken_companies_list" | "fiken_contact_create" | "fiken_contacts_list" | "fiken_invoice_draft_create" | "fiken_invoice_get" | "fiken_invoices_list" | "fiken_products_list" | "fiken_purchases_list" | "fiken_sales_list" | "github_connect_link" | "github_repositories_list" | "goal_complete" | "goal_pause" | "goal_progress" | "goal_resume" | "goal_set" | "goal_update" | "instruction_policy_get" | "instruction_policy_propose" | "instruction_policy_save" | "interaction_discover" | "interaction_request_human" | "knowledge_archive" | "knowledge_browse" | "knowledge_correct" | "knowledge_get" | "knowledge_prepare_save" | "knowledge_propose" | "knowledge_retain_file" | "knowledge_retain_message" | "knowledge_save" | "knowledge_search" | "memory_correct" | "memory_save" | "memory_search" | "preference_propose" | "preference_registry_get" | "preference_registry_summary" | "project_create" | "project_delete" | "project_get" | "project_list" | "project_reorder" | "project_update" | "reddit_accounts_list" | "reddit_mentions_live" | "reddit_post_reply" | "reddit_posts_sync" | "reddit_search_live" | "reddit_thread_fetch" | "remember" | "remember_confirm" | "rig_get" | "rig_list" | "rig_promote" | "rig_propose_change" | "rig_verify" | "run_on" | "sandbox_attach" | "sandbox_file_publish" | "sandbox_provision" | "sandbox_swap" | "sandboxes_list" | "scheduled_task_runs_list" | "scheduled_tasks_create" | "scheduled_tasks_delete" | "scheduled_tasks_get" | "scheduled_tasks_list" | "scheduled_tasks_pause" | "scheduled_tasks_resume" | "scheduled_tasks_trigger" | "scheduled_tasks_update" | "session_create" | "session_events" | "session_get" | "session_human_input_respond" | "session_pause" | "session_resume" | "session_send_message" | "session_set_project" | "session_steer" | "session_wait" | "sessions_list" | "set_other_session_title" | "set_session_title" | "slack_bot_channel_history" | "slack_bot_delete_message" | "slack_bot_file_content" | "slack_bot_file_info" | "slack_bot_list_channels" | "slack_bot_list_files" | "slack_bot_list_users" | "slack_bot_post_message" | "slack_bot_search" | "slack_bot_thread_replies" | "social_connections_list" | "social_daily_analysis_context" | "social_mentions_live" | "social_post_reply" | "social_posts_recent" | "social_posts_sync" | "social_search_live" | "social_thread_fetch" | "task_note_archive" | "task_note_promote_instruction_policy" | "task_note_promote_knowledge" | "task_note_promote_preference" | "task_note_replace" | "task_note_save" | "task_notes_list" | "variable_set_get_variable" | "variable_set_list" | "variable_set_set_variable" | "wait_for_input" | "work_claim_release" | "work_claim_upsert" | "x_accounts_list" | "x_mentions_live" | "x_post_reply" | "x_posts_sync" | "x_search_live" | "x_thread_fetch")[];
|
|
113
113
|
firstPartyMcpPermissions?: ("account:admin" | "account:read" | "api_keys:manage" | "artifacts:publish" | "artifacts:read" | "billing:manage" | "billing:read" | "capabilities:manage" | "codemode:call" | "connections:read" | "connections:write" | "documents:manage" | "documents:search" | "enrollments:manage" | "enrollments:read" | "environments:manage" | "environments:use" | "files:read" | "files:upload" | "files:write" | "github:manage" | "github:use" | "goals:manage" | "mcp_servers:attach" | "members:manage" | "rigs:manage" | "rigs:use" | "scheduled_tasks:manage" | "scheduled_tasks:run" | "secrets:list" | "secrets:read" | "secrets:write" | "sessions:control" | "sessions:create" | "sessions:read" | "stream:acknowledge" | "stream:control" | "stream:view" | "terminal:attach" | "variable-sets:attach" | "variable-sets:list" | "variable-sets:manage" | "variable-sets:read" | "variable-sets:use" | "variable-sets:write" | "workspace:admin" | "workspace:create" | "workspace:read")[];
|
|
114
114
|
variableSetIds?: string[];
|
|
115
115
|
rigId?: string;
|
|
@@ -47,13 +47,12 @@ export type McpCapabilityProbeInput = {
|
|
|
47
47
|
url: string;
|
|
48
48
|
timeoutMs: number;
|
|
49
49
|
headers?: Record<string, string>;
|
|
50
|
-
settings?: Settings;
|
|
51
50
|
};
|
|
52
51
|
export type McpCapabilityProbeResult = {
|
|
53
52
|
toolCount: number;
|
|
54
53
|
};
|
|
55
54
|
export type McpCapabilityProbe = (input: McpCapabilityProbeInput) => Promise<McpCapabilityProbeResult>;
|
|
56
|
-
export declare function validateMcpCapabilityConnection(item: CapabilityCatalogItem, probe?: McpCapabilityProbe, headers?: Record<string, string
|
|
55
|
+
export declare function validateMcpCapabilityConnection(item: CapabilityCatalogItem, probe?: McpCapabilityProbe, headers?: Record<string, string>): Promise<Record<string, unknown>>;
|
|
57
56
|
export declare function disableCapability(input: {
|
|
58
57
|
db: Database;
|
|
59
58
|
accountId: string;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { type Database, type KnowledgeContext } from "@opengeni/db";
|
|
2
2
|
/** Retain actual message bytes, never a model-authored reconstruction of a confirmation. */
|
|
3
3
|
export declare function retainKnowledgeMessage(db: Database, context: KnowledgeContext, messageId?: string): Promise<{
|
|
4
|
-
revisionId?: never;
|
|
5
4
|
retained: boolean;
|
|
6
5
|
reason: string;
|
|
7
6
|
entryId?: never;
|
|
7
|
+
revisionId?: never;
|
|
8
8
|
outcome?: never;
|
|
9
9
|
messageId?: never;
|
|
10
10
|
reused?: never;
|
|
11
11
|
} | {
|
|
12
|
-
revisionId?: never;
|
|
13
12
|
retained: boolean;
|
|
14
13
|
reason: string;
|
|
15
14
|
entryId: string;
|
|
15
|
+
revisionId?: never;
|
|
16
16
|
outcome?: never;
|
|
17
17
|
messageId?: never;
|
|
18
18
|
reused?: never;
|
|
@@ -47,7 +47,7 @@ export declare const PR_REVIEW_AUTOMATION_SETUP: {
|
|
|
47
47
|
eager?: boolean | undefined;
|
|
48
48
|
optional?: boolean | undefined;
|
|
49
49
|
}[];
|
|
50
|
-
firstPartyMcpTools: ("artifacts_archive" | "artifacts_create" | "artifacts_get_source" | "artifacts_list" | "artifacts_prepare_upload" | "artifacts_publish" | "artifacts_restore" | "artifacts_rollback" | "atlassian_get" | "atlassian_search" | "atlassian_sources_list" | "browser_act" | "browser_auth" | "browser_clipboard" | "browser_debug" | "browser_identity" | "browser_lifecycle" | "browser_observe" | "browser_open" | "browser_publish" | "browser_read" | "browser_screenshot" | "browser_tabs" | "capability_authorization_request" | "capability_catalog_search" | "command_read" | "command_wait" | "company_profile_confirm" | "company_profile_propose" | "computer_act" | "computer_clipboard" | "computer_lifecycle" | "computer_observe" | "computer_open" | "computer_targets" | "connected_machine_enroll_token" | "connected_machine_remove" | "
|
|
50
|
+
firstPartyMcpTools: ("artifacts_archive" | "artifacts_create" | "artifacts_get_source" | "artifacts_list" | "artifacts_prepare_upload" | "artifacts_publish" | "artifacts_restore" | "artifacts_rollback" | "atlassian_get" | "atlassian_search" | "atlassian_sources_list" | "browser_act" | "browser_auth" | "browser_clipboard" | "browser_debug" | "browser_identity" | "browser_lifecycle" | "browser_observe" | "browser_open" | "browser_publish" | "browser_read" | "browser_screenshot" | "browser_tabs" | "capability_authorization_request" | "capability_catalog_search" | "command_read" | "command_wait" | "company_profile_confirm" | "company_profile_propose" | "computer_act" | "computer_clipboard" | "computer_lifecycle" | "computer_observe" | "computer_open" | "computer_targets" | "connected_machine_enroll_token" | "connected_machine_remove" | "editable_artifact_apply" | "editable_artifact_create" | "editable_artifact_export" | "editable_artifact_export_status" | "editable_artifact_get" | "editable_artifact_import" | "editable_artifact_inspect" | "editable_artifact_list" | "environment_list" | "environment_set_variable" | "fiken_bank_accounts_list" | "fiken_companies_list" | "fiken_contact_create" | "fiken_contacts_list" | "fiken_invoice_draft_create" | "fiken_invoice_get" | "fiken_invoices_list" | "fiken_products_list" | "fiken_purchases_list" | "fiken_sales_list" | "github_connect_link" | "github_repositories_list" | "goal_complete" | "goal_pause" | "goal_progress" | "goal_resume" | "goal_set" | "goal_update" | "instruction_policy_get" | "instruction_policy_propose" | "instruction_policy_save" | "interaction_discover" | "interaction_request_human" | "knowledge_archive" | "knowledge_browse" | "knowledge_correct" | "knowledge_get" | "knowledge_prepare_save" | "knowledge_propose" | "knowledge_retain_file" | "knowledge_retain_message" | "knowledge_save" | "knowledge_search" | "memory_correct" | "memory_save" | "memory_search" | "preference_propose" | "preference_registry_get" | "preference_registry_summary" | "project_create" | "project_delete" | "project_get" | "project_list" | "project_reorder" | "project_update" | "reddit_accounts_list" | "reddit_mentions_live" | "reddit_post_reply" | "reddit_posts_sync" | "reddit_search_live" | "reddit_thread_fetch" | "remember" | "remember_confirm" | "rig_get" | "rig_list" | "rig_promote" | "rig_propose_change" | "rig_verify" | "run_on" | "sandbox_attach" | "sandbox_file_publish" | "sandbox_provision" | "sandbox_swap" | "sandboxes_list" | "scheduled_task_runs_list" | "scheduled_tasks_create" | "scheduled_tasks_delete" | "scheduled_tasks_get" | "scheduled_tasks_list" | "scheduled_tasks_pause" | "scheduled_tasks_resume" | "scheduled_tasks_trigger" | "scheduled_tasks_update" | "session_create" | "session_events" | "session_get" | "session_human_input_respond" | "session_pause" | "session_resume" | "session_send_message" | "session_set_project" | "session_steer" | "session_wait" | "sessions_list" | "set_other_session_title" | "set_session_title" | "slack_bot_channel_history" | "slack_bot_delete_message" | "slack_bot_file_content" | "slack_bot_file_info" | "slack_bot_list_channels" | "slack_bot_list_files" | "slack_bot_list_users" | "slack_bot_post_message" | "slack_bot_search" | "slack_bot_thread_replies" | "social_connections_list" | "social_daily_analysis_context" | "social_mentions_live" | "social_post_reply" | "social_posts_recent" | "social_posts_sync" | "social_search_live" | "social_thread_fetch" | "task_note_archive" | "task_note_promote_instruction_policy" | "task_note_promote_knowledge" | "task_note_promote_preference" | "task_note_replace" | "task_note_save" | "task_notes_list" | "variable_set_get_variable" | "variable_set_list" | "variable_set_set_variable" | "wait_for_input" | "work_claim_release" | "work_claim_upsert" | "x_accounts_list" | "x_mentions_live" | "x_post_reply" | "x_posts_sync" | "x_search_live" | "x_thread_fetch")[];
|
|
51
51
|
firstPartyMcpPermissions: ("account:admin" | "account:read" | "api_keys:manage" | "artifacts:publish" | "artifacts:read" | "billing:manage" | "billing:read" | "capabilities:manage" | "codemode:call" | "connections:read" | "connections:write" | "documents:manage" | "documents:search" | "enrollments:manage" | "enrollments:read" | "environments:manage" | "environments:use" | "files:read" | "files:upload" | "files:write" | "github:manage" | "github:use" | "goals:manage" | "mcp_servers:attach" | "members:manage" | "rigs:manage" | "rigs:use" | "scheduled_tasks:manage" | "scheduled_tasks:run" | "secrets:list" | "secrets:read" | "secrets:write" | "sessions:control" | "sessions:create" | "sessions:read" | "stream:acknowledge" | "stream:control" | "stream:view" | "terminal:attach" | "variable-sets:attach" | "variable-sets:list" | "variable-sets:manage" | "variable-sets:read" | "variable-sets:use" | "variable-sets:write" | "workspace:admin" | "workspace:create" | "workspace:read")[];
|
|
52
52
|
model: string | null;
|
|
53
53
|
reasoningEffort: "high" | "low" | "max" | "medium" | "minimal" | "none" | "xhigh" | null;
|
|
@@ -134,7 +134,7 @@ export declare const prReviewAutomationAdapter: {
|
|
|
134
134
|
eager?: boolean | undefined;
|
|
135
135
|
optional?: boolean | undefined;
|
|
136
136
|
}[];
|
|
137
|
-
firstPartyMcpTools: ("artifacts_archive" | "artifacts_create" | "artifacts_get_source" | "artifacts_list" | "artifacts_prepare_upload" | "artifacts_publish" | "artifacts_restore" | "artifacts_rollback" | "atlassian_get" | "atlassian_search" | "atlassian_sources_list" | "browser_act" | "browser_auth" | "browser_clipboard" | "browser_debug" | "browser_identity" | "browser_lifecycle" | "browser_observe" | "browser_open" | "browser_publish" | "browser_read" | "browser_screenshot" | "browser_tabs" | "capability_authorization_request" | "capability_catalog_search" | "command_read" | "command_wait" | "company_profile_confirm" | "company_profile_propose" | "computer_act" | "computer_clipboard" | "computer_lifecycle" | "computer_observe" | "computer_open" | "computer_targets" | "connected_machine_enroll_token" | "connected_machine_remove" | "
|
|
137
|
+
firstPartyMcpTools: ("artifacts_archive" | "artifacts_create" | "artifacts_get_source" | "artifacts_list" | "artifacts_prepare_upload" | "artifacts_publish" | "artifacts_restore" | "artifacts_rollback" | "atlassian_get" | "atlassian_search" | "atlassian_sources_list" | "browser_act" | "browser_auth" | "browser_clipboard" | "browser_debug" | "browser_identity" | "browser_lifecycle" | "browser_observe" | "browser_open" | "browser_publish" | "browser_read" | "browser_screenshot" | "browser_tabs" | "capability_authorization_request" | "capability_catalog_search" | "command_read" | "command_wait" | "company_profile_confirm" | "company_profile_propose" | "computer_act" | "computer_clipboard" | "computer_lifecycle" | "computer_observe" | "computer_open" | "computer_targets" | "connected_machine_enroll_token" | "connected_machine_remove" | "editable_artifact_apply" | "editable_artifact_create" | "editable_artifact_export" | "editable_artifact_export_status" | "editable_artifact_get" | "editable_artifact_import" | "editable_artifact_inspect" | "editable_artifact_list" | "environment_list" | "environment_set_variable" | "fiken_bank_accounts_list" | "fiken_companies_list" | "fiken_contact_create" | "fiken_contacts_list" | "fiken_invoice_draft_create" | "fiken_invoice_get" | "fiken_invoices_list" | "fiken_products_list" | "fiken_purchases_list" | "fiken_sales_list" | "github_connect_link" | "github_repositories_list" | "goal_complete" | "goal_pause" | "goal_progress" | "goal_resume" | "goal_set" | "goal_update" | "instruction_policy_get" | "instruction_policy_propose" | "instruction_policy_save" | "interaction_discover" | "interaction_request_human" | "knowledge_archive" | "knowledge_browse" | "knowledge_correct" | "knowledge_get" | "knowledge_prepare_save" | "knowledge_propose" | "knowledge_retain_file" | "knowledge_retain_message" | "knowledge_save" | "knowledge_search" | "memory_correct" | "memory_save" | "memory_search" | "preference_propose" | "preference_registry_get" | "preference_registry_summary" | "project_create" | "project_delete" | "project_get" | "project_list" | "project_reorder" | "project_update" | "reddit_accounts_list" | "reddit_mentions_live" | "reddit_post_reply" | "reddit_posts_sync" | "reddit_search_live" | "reddit_thread_fetch" | "remember" | "remember_confirm" | "rig_get" | "rig_list" | "rig_promote" | "rig_propose_change" | "rig_verify" | "run_on" | "sandbox_attach" | "sandbox_file_publish" | "sandbox_provision" | "sandbox_swap" | "sandboxes_list" | "scheduled_task_runs_list" | "scheduled_tasks_create" | "scheduled_tasks_delete" | "scheduled_tasks_get" | "scheduled_tasks_list" | "scheduled_tasks_pause" | "scheduled_tasks_resume" | "scheduled_tasks_trigger" | "scheduled_tasks_update" | "session_create" | "session_events" | "session_get" | "session_human_input_respond" | "session_pause" | "session_resume" | "session_send_message" | "session_set_project" | "session_steer" | "session_wait" | "sessions_list" | "set_other_session_title" | "set_session_title" | "slack_bot_channel_history" | "slack_bot_delete_message" | "slack_bot_file_content" | "slack_bot_file_info" | "slack_bot_list_channels" | "slack_bot_list_files" | "slack_bot_list_users" | "slack_bot_post_message" | "slack_bot_search" | "slack_bot_thread_replies" | "social_connections_list" | "social_daily_analysis_context" | "social_mentions_live" | "social_post_reply" | "social_posts_recent" | "social_posts_sync" | "social_search_live" | "social_thread_fetch" | "task_note_archive" | "task_note_promote_instruction_policy" | "task_note_promote_knowledge" | "task_note_promote_preference" | "task_note_replace" | "task_note_save" | "task_notes_list" | "variable_set_get_variable" | "variable_set_list" | "variable_set_set_variable" | "wait_for_input" | "work_claim_release" | "work_claim_upsert" | "x_accounts_list" | "x_mentions_live" | "x_post_reply" | "x_posts_sync" | "x_search_live" | "x_thread_fetch")[];
|
|
138
138
|
firstPartyMcpPermissions: ("account:admin" | "account:read" | "api_keys:manage" | "artifacts:publish" | "artifacts:read" | "billing:manage" | "billing:read" | "capabilities:manage" | "codemode:call" | "connections:read" | "connections:write" | "documents:manage" | "documents:search" | "enrollments:manage" | "enrollments:read" | "environments:manage" | "environments:use" | "files:read" | "files:upload" | "files:write" | "github:manage" | "github:use" | "goals:manage" | "mcp_servers:attach" | "members:manage" | "rigs:manage" | "rigs:use" | "scheduled_tasks:manage" | "scheduled_tasks:run" | "secrets:list" | "secrets:read" | "secrets:write" | "sessions:control" | "sessions:create" | "sessions:read" | "stream:acknowledge" | "stream:control" | "stream:view" | "terminal:attach" | "variable-sets:attach" | "variable-sets:list" | "variable-sets:manage" | "variable-sets:read" | "variable-sets:use" | "variable-sets:write" | "workspace:admin" | "workspace:create" | "workspace:read")[];
|
|
139
139
|
model: string | null;
|
|
140
140
|
reasoningEffort: "high" | "low" | "max" | "medium" | "minimal" | "none" | "xhigh" | null;
|
package/dist/index.js
CHANGED
|
@@ -4205,7 +4205,6 @@ import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/
|
|
|
4205
4205
|
import { isDeepStrictEqual } from "util";
|
|
4206
4206
|
import { withLockedCapabilityInstallation } from "@opengeni/db/capability-reconciliation";
|
|
4207
4207
|
import { environmentsEncryptionKeyBytes as environmentsEncryptionKeyBytes2 } from "@opengeni/config";
|
|
4208
|
-
import { pinnedFetch } from "@opengeni/network";
|
|
4209
4208
|
import {
|
|
4210
4209
|
CapabilityCatalogItem,
|
|
4211
4210
|
capabilityCatalogItemIsTrustedForExposure,
|
|
@@ -4479,12 +4478,7 @@ async function prepareCapabilityEnable(input) {
|
|
|
4479
4478
|
assertRequiredMcpCredentialHeaders(item, headers, connectionRef);
|
|
4480
4479
|
installationMetadata = {
|
|
4481
4480
|
...installationMetadata,
|
|
4482
|
-
...connectionRef && !headers ? authDeferredMcpConnectivity() : await validateMcpCapabilityConnection(
|
|
4483
|
-
item,
|
|
4484
|
-
input.probeMcpServer,
|
|
4485
|
-
headers ?? void 0,
|
|
4486
|
-
input.settings
|
|
4487
|
-
)
|
|
4481
|
+
...connectionRef && !headers ? authDeferredMcpConnectivity() : await validateMcpCapabilityConnection(item, input.probeMcpServer, headers ?? void 0)
|
|
4488
4482
|
};
|
|
4489
4483
|
if (connectionRef) {
|
|
4490
4484
|
installationConfig.connectionRef = connectionRef;
|
|
@@ -4731,7 +4725,7 @@ function requireCapabilityHeaderEncryption(settings) {
|
|
|
4731
4725
|
}
|
|
4732
4726
|
return key;
|
|
4733
4727
|
}
|
|
4734
|
-
async function validateMcpCapabilityConnection(item, probe = probeStreamableHttpMcpServer, headers
|
|
4728
|
+
async function validateMcpCapabilityConnection(item, probe = probeStreamableHttpMcpServer, headers) {
|
|
4735
4729
|
if (item.kind !== "mcp") {
|
|
4736
4730
|
return {};
|
|
4737
4731
|
}
|
|
@@ -4746,8 +4740,7 @@ async function validateMcpCapabilityConnection(item, probe = probeStreamableHttp
|
|
|
4746
4740
|
name: item.name,
|
|
4747
4741
|
url: item.endpointUrl,
|
|
4748
4742
|
timeoutMs: mcpCapabilityProbeTimeoutMs,
|
|
4749
|
-
...headers ? { headers } : {}
|
|
4750
|
-
...settings ? { settings } : {}
|
|
4743
|
+
...headers ? { headers } : {}
|
|
4751
4744
|
});
|
|
4752
4745
|
return {
|
|
4753
4746
|
mcpConnectivity: {
|
|
@@ -4763,8 +4756,6 @@ async function validateMcpCapabilityConnection(item, probe = probeStreamableHttp
|
|
|
4763
4756
|
}
|
|
4764
4757
|
}
|
|
4765
4758
|
async function probeStreamableHttpMcpServer(input) {
|
|
4766
|
-
const settings = input.settings;
|
|
4767
|
-
if (!settings) throw new Error("Network policy is unavailable for MCP validation");
|
|
4768
4759
|
const controller = new AbortController();
|
|
4769
4760
|
const timeout = setTimeout(() => controller.abort(), input.timeoutMs);
|
|
4770
4761
|
const client = new Client(
|
|
@@ -4776,11 +4767,7 @@ async function probeStreamableHttpMcpServer(input) {
|
|
|
4776
4767
|
requestInit: {
|
|
4777
4768
|
signal: controller.signal,
|
|
4778
4769
|
...input.headers ? { headers: input.headers } : {}
|
|
4779
|
-
}
|
|
4780
|
-
fetch: (url, init) => pinnedFetch(url, init, settings, {
|
|
4781
|
-
label: "MCP capability probe",
|
|
4782
|
-
requireHttpsOutsideLocalTest: true
|
|
4783
|
-
})
|
|
4770
|
+
}
|
|
4784
4771
|
});
|
|
4785
4772
|
await client.connect(transport, {
|
|
4786
4773
|
timeout: input.timeoutMs,
|
|
@@ -10284,39 +10271,6 @@ async function acceptSessionUserMessageWithOutcome(...args) {
|
|
|
10284
10271
|
return withSessionRlsActorContext4(actor, () => acceptSessionUserMessageInFileScope(...args));
|
|
10285
10272
|
}
|
|
10286
10273
|
|
|
10287
|
-
// src/domain/session-native-connection-replacement.ts
|
|
10288
|
-
import { connectionMetadataMatchesBinding } from "@opengeni/db/session-mcp-credential-rotation";
|
|
10289
|
-
function nativeSessionConnectionReplacement(input) {
|
|
10290
|
-
const connection = input.connections.find(
|
|
10291
|
-
(candidate) => candidate.id === input.nativeConnectionId
|
|
10292
|
-
);
|
|
10293
|
-
if (!connection || connection.accountId !== input.accountId || connection.status !== "active" || (connection.subjectId === null ? connection.workspaceId !== input.workspaceId : !input.subjectId || connection.subjectId !== input.subjectId || !connection.authorityId)) {
|
|
10294
|
-
throw new Error("native connection unavailable");
|
|
10295
|
-
}
|
|
10296
|
-
const {
|
|
10297
|
-
authoritySource: _authoritySource,
|
|
10298
|
-
hostBinding: _hostBinding,
|
|
10299
|
-
accountSelection: _accountSelection,
|
|
10300
|
-
...retained
|
|
10301
|
-
} = input.currentRef ?? {};
|
|
10302
|
-
if (input.currentRef && input.currentRef.providerDomain.toLowerCase() !== connection.providerDomain.toLowerCase())
|
|
10303
|
-
throw new Error("native connection provider mismatch");
|
|
10304
|
-
const ref = {
|
|
10305
|
-
...retained,
|
|
10306
|
-
...!input.currentRef?.resource && typeof connection.metadata.resource === "string" ? { resource: connection.metadata.resource } : {},
|
|
10307
|
-
connectionId: connection.id,
|
|
10308
|
-
providerDomain: connection.providerDomain,
|
|
10309
|
-
kind: connection.kind,
|
|
10310
|
-
subjectScope: connection.subjectId === null ? "workspace" : "subject"
|
|
10311
|
-
};
|
|
10312
|
-
const destination = input.replacementServerUrl ?? input.serverUrl;
|
|
10313
|
-
if (input.replacementServerUrl && (typeof connection.metadata.mcpUrl !== "string" || !connection.metadata.mcpUrl.trim()))
|
|
10314
|
-
throw new Error("native connection destination unavailable");
|
|
10315
|
-
if (!connectionMetadataMatchesBinding(connection, ref, destination))
|
|
10316
|
-
throw new Error("native connection binding mismatch");
|
|
10317
|
-
return ref;
|
|
10318
|
-
}
|
|
10319
|
-
|
|
10320
10274
|
// src/application/session-mcp-credential-rotation.ts
|
|
10321
10275
|
function sessionMcpRotationFingerprint(key, scope, request) {
|
|
10322
10276
|
return {
|
|
@@ -10348,14 +10302,9 @@ async function rotateSessionMcpCredentialsForRequest(deps, authorization, sessio
|
|
|
10348
10302
|
id: update.id,
|
|
10349
10303
|
expectedCredentialVersion: update.expectedCredentialVersion,
|
|
10350
10304
|
expectedServerUrl: update.expectedServerUrl,
|
|
10351
|
-
|
|
10352
|
-
|
|
10353
|
-
|
|
10354
|
-
} : {
|
|
10355
|
-
headers: Object.fromEntries(
|
|
10356
|
-
Object.entries(normalizedSessionMcpCredentialHeaders(update.headers)).map(([name, value]) => [name.toLowerCase(), value]).sort(([left], [right]) => left < right ? -1 : left > right ? 1 : 0)
|
|
10357
|
-
)
|
|
10358
|
-
}
|
|
10305
|
+
headers: Object.fromEntries(
|
|
10306
|
+
Object.entries(normalizedSessionMcpCredentialHeaders(update.headers)).map(([name, value]) => [name.toLowerCase(), value]).sort(([left], [right]) => left < right ? -1 : left > right ? 1 : 0)
|
|
10307
|
+
)
|
|
10359
10308
|
})).sort((left, right) => left.id < right.id ? -1 : left.id > right.id ? 1 : 0)
|
|
10360
10309
|
};
|
|
10361
10310
|
if (new Set(request.updates.map((update) => update.id)).size !== request.updates.length)
|
|
@@ -10371,43 +10320,20 @@ async function rotateSessionMcpCredentialsForRequest(deps, authorization, sessio
|
|
|
10371
10320
|
actorType: grant.principalKind === "service" ? "service" : "human"
|
|
10372
10321
|
};
|
|
10373
10322
|
const externalAuthorize = externalContinuationCommitAuthorizer(authorization);
|
|
10374
|
-
let authorizedGrant = grant;
|
|
10375
10323
|
try {
|
|
10376
10324
|
return await rotateSessionMcpCredentialsAtomically(deps.db, {
|
|
10377
10325
|
...scope,
|
|
10378
10326
|
operationKey: request.operationKey,
|
|
10379
10327
|
...sessionMcpRotationFingerprint(encryptionKey, scope, request),
|
|
10380
|
-
updates: request.updates.map(
|
|
10381
|
-
|
|
10382
|
-
|
|
10383
|
-
|
|
10384
|
-
|
|
10385
|
-
|
|
10386
|
-
|
|
10387
|
-
|
|
10388
|
-
|
|
10389
|
-
])
|
|
10390
|
-
)
|
|
10391
|
-
}
|
|
10392
|
-
),
|
|
10393
|
-
resolveNativeConnection: async (tx, server, nativeConnectionId, replacementServerUrl) => {
|
|
10394
|
-
const connections = await listOwnConnectionAccountsForGrant(tx, authorizedGrant);
|
|
10395
|
-
const source = personalConnectionDelegationSourceForGrant(authorizedGrant);
|
|
10396
|
-
try {
|
|
10397
|
-
return nativeSessionConnectionReplacement({
|
|
10398
|
-
accountId: grant.accountId,
|
|
10399
|
-
workspaceId: grant.workspaceId,
|
|
10400
|
-
subjectId: source.kind === "subject" ? source.subjectId : null,
|
|
10401
|
-
serverUrl: server.url,
|
|
10402
|
-
...replacementServerUrl ? { replacementServerUrl } : {},
|
|
10403
|
-
currentRef: server.connectionRef,
|
|
10404
|
-
nativeConnectionId,
|
|
10405
|
-
connections
|
|
10406
|
-
});
|
|
10407
|
-
} catch {
|
|
10408
|
-
throw new SessionMcpCredentialRotationError("connection_unavailable");
|
|
10409
|
-
}
|
|
10410
|
-
},
|
|
10328
|
+
updates: request.updates.map(({ headers, ...update }) => ({
|
|
10329
|
+
...update,
|
|
10330
|
+
headersEncrypted: Object.fromEntries(
|
|
10331
|
+
Object.entries(headers).map(([name, value]) => [
|
|
10332
|
+
name,
|
|
10333
|
+
encryptVariableSetValue3(encryptionKey, value)
|
|
10334
|
+
])
|
|
10335
|
+
)
|
|
10336
|
+
})),
|
|
10411
10337
|
authorize: async (tx) => {
|
|
10412
10338
|
await externalAuthorize?.(tx);
|
|
10413
10339
|
const fresh = await reauthorize(tx);
|
|
@@ -10430,7 +10356,6 @@ async function rotateSessionMcpCredentialsForRequest(deps, authorization, sessio
|
|
|
10430
10356
|
operation: "session.mcp.credentials.rotate",
|
|
10431
10357
|
surface: "http"
|
|
10432
10358
|
});
|
|
10433
|
-
authorizedGrant = fresh;
|
|
10434
10359
|
}
|
|
10435
10360
|
});
|
|
10436
10361
|
} catch (error) {
|
|
@@ -10441,7 +10366,7 @@ async function rotateSessionMcpCredentialsForRequest(deps, authorization, sessio
|
|
|
10441
10366
|
if (error instanceof SessionAuthorizationUnavailableError)
|
|
10442
10367
|
throw new HTTPException16(503, { message: "credential rotation authorization unavailable" });
|
|
10443
10368
|
if (error instanceof SessionMcpCredentialRotationError) {
|
|
10444
|
-
const status = error.code === "receipt_key_unavailable" ? 503 : error.code === "authority_revoked" ? 403 : error.code === "not_found" ? 404 : error.code === "invalid_request" || error.code === "brokered_server"
|
|
10369
|
+
const status = error.code === "receipt_key_unavailable" ? 503 : error.code === "authority_revoked" ? 403 : error.code === "not_found" ? 404 : error.code === "invalid_request" || error.code === "brokered_server" ? 422 : 409;
|
|
10445
10370
|
throw new HTTPException16(status, { message: `credential_rotation_${error.code}` });
|
|
10446
10371
|
}
|
|
10447
10372
|
throw new HTTPException16(503, { message: "credential rotation unavailable" });
|
|
@@ -10882,7 +10807,7 @@ function sha256Hex2(bytes) {
|
|
|
10882
10807
|
}
|
|
10883
10808
|
|
|
10884
10809
|
// src/domain/skill-search.ts
|
|
10885
|
-
import { pinnedFetch
|
|
10810
|
+
import { pinnedFetch, readResponseJsonBounded } from "@opengeni/network";
|
|
10886
10811
|
var PublicSkillSearchError = class extends Error {
|
|
10887
10812
|
constructor(code, message, retryAfterSeconds = null) {
|
|
10888
10813
|
super(message);
|
|
@@ -10897,7 +10822,7 @@ var maxResponseBytes = 256 * 1024;
|
|
|
10897
10822
|
var maxResults = 20;
|
|
10898
10823
|
var ownerPattern = /^[a-z0-9](?:[a-z0-9-]{0,38})$/iu;
|
|
10899
10824
|
var segmentPattern = /^[a-z0-9](?:[a-z0-9._-]{0,98}[a-z0-9])?$/iu;
|
|
10900
|
-
function createPublicSkillSearchClient(settings, fetcher =
|
|
10825
|
+
function createPublicSkillSearchClient(settings, fetcher = pinnedFetch) {
|
|
10901
10826
|
return {
|
|
10902
10827
|
async search(input) {
|
|
10903
10828
|
const query = input.query.trim();
|
|
@@ -11024,7 +10949,7 @@ function parseRetryAfter(value) {
|
|
|
11024
10949
|
|
|
11025
10950
|
// src/domain/github-skill-source.ts
|
|
11026
10951
|
import { HTTPException as HTTPException19 } from "hono/http-exception";
|
|
11027
|
-
import { pinnedFetch as
|
|
10952
|
+
import { pinnedFetch as pinnedFetch2, readResponseJsonBounded as readResponseJsonBounded2, readResponseTextBounded } from "@opengeni/network";
|
|
11028
10953
|
import {
|
|
11029
10954
|
PORTABLE_SKILL_MAX_FILES as PORTABLE_SKILL_MAX_FILES2,
|
|
11030
10955
|
PORTABLE_SKILL_MAX_FILE_BYTES as PORTABLE_SKILL_MAX_FILE_BYTES2,
|
|
@@ -11125,7 +11050,7 @@ function createGitHubSkillSourceClient(settings, requestJson = (path, maxBytes,
|
|
|
11125
11050
|
}
|
|
11126
11051
|
async function downloadSkillSnapshot(settings, owner, repository, slug) {
|
|
11127
11052
|
const signal = AbortSignal.timeout(githubRequestTimeoutMs);
|
|
11128
|
-
const response = await
|
|
11053
|
+
const response = await pinnedFetch2(
|
|
11129
11054
|
`https://skills.sh/api/download/${[owner, repository, slug].map(encodeURIComponent).join("/")}`,
|
|
11130
11055
|
{ headers: { accept: "application/json" }, credentials: "omit", redirect: "manual", signal },
|
|
11131
11056
|
settings,
|
|
@@ -11160,7 +11085,7 @@ async function githubJson(settings, path, maxBytes, label) {
|
|
|
11160
11085
|
const controller = new AbortController();
|
|
11161
11086
|
const timeout = setTimeout(() => controller.abort(), githubRequestTimeoutMs);
|
|
11162
11087
|
try {
|
|
11163
|
-
const response = await
|
|
11088
|
+
const response = await pinnedFetch2(
|
|
11164
11089
|
`${githubApiBase}${path}`,
|
|
11165
11090
|
{
|
|
11166
11091
|
method: "GET",
|