Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion packages/effect-codex-app-server/scripts/generate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import {
} from "effect/unstable/http";
import { ChildProcess, ChildProcessSpawner } from "effect/unstable/process";

const UPSTREAM_REF = "b39f943a634a6e7ba86c3d6e8cf6d5f35e612566";
const UPSTREAM_REF = "678157acaa819d5510adfe359abb5d0392cfe461";
const USER_AGENT = "effect-codex-app-server-generator";
const GITHUB_API_BASE =
"https://api.github.com/repos/openai/codex/contents/codex-rs/app-server-protocol";
Expand Down Expand Up @@ -349,10 +349,12 @@ function resolveResponseTypeName(
"account/logout": "LogoutAccountResponse",
"account/rateLimits/read": "GetAccountRateLimitsResponse",
"account/usage/read": "GetAccountTokenUsageResponse",
"account/workspaceMessages/read": "GetWorkspaceMessagesResponse",
"config/batchWrite": "ConfigWriteResponse",
"config/mcpServer/reload": "McpServerRefreshResponse",
"config/value/write": "ConfigWriteResponse",
"configRequirements/read": "ConfigRequirementsReadResponse",
"externalAgentConfig/import/readHistories": "ExternalAgentConfigImportHistoriesReadResponse",
};

const override = overrides[method];
Expand Down
44 changes: 43 additions & 1 deletion packages/effect-codex-app-server/src/_generated/meta.gen.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// This file is generated by the effect-codex-app-server package. Do not edit manually.
// Upstream protocol ref: b39f943a634a6e7ba86c3d6e8cf6d5f35e612566
// Upstream protocol ref: 678157acaa819d5510adfe359abb5d0392cfe461

import * as CodexSchema from "./schema.gen.ts";

Expand Down Expand Up @@ -40,7 +40,9 @@ export const CLIENT_REQUEST_METHODS = {
"plugin/share/list": "plugin/share/list",
"plugin/share/checkout": "plugin/share/checkout",
"plugin/share/delete": "plugin/share/delete",
"app/read": "app/read",
"app/list": "app/list",
"app/installed": "app/installed",
"fs/readFile": "fs/readFile",
"fs/writeFile": "fs/writeFile",
"fs/createDirectory": "fs/createDirectory",
Expand Down Expand Up @@ -73,7 +75,9 @@ export const CLIENT_REQUEST_METHODS = {
"account/login/cancel": "account/login/cancel",
"account/logout": "account/logout",
"account/rateLimits/read": "account/rateLimits/read",
"account/rateLimitResetCredit/consume": "account/rateLimitResetCredit/consume",
"account/usage/read": "account/usage/read",
"account/workspaceMessages/read": "account/workspaceMessages/read",
"account/sendAddCreditsNudgeEmail": "account/sendAddCreditsNudgeEmail",
"feedback/upload": "feedback/upload",
"command/exec": "command/exec",
Expand All @@ -83,6 +87,7 @@ export const CLIENT_REQUEST_METHODS = {
"config/read": "config/read",
"externalAgentConfig/detect": "externalAgentConfig/detect",
"externalAgentConfig/import": "externalAgentConfig/import",
"externalAgentConfig/import/readHistories": "externalAgentConfig/import/readHistories",
"config/value/write": "config/value/write",
"config/batchWrite": "config/batchWrite",
"configRequirements/read": "configRequirements/read",
Expand Down Expand Up @@ -122,6 +127,8 @@ export const SERVER_NOTIFICATION_METHODS = {
"thread/name/updated": "thread/name/updated",
"thread/goal/updated": "thread/goal/updated",
"thread/goal/cleared": "thread/goal/cleared",
"thread/environment/connected": "thread/environment/connected",
"thread/environment/disconnected": "thread/environment/disconnected",
"thread/settings/updated": "thread/settings/updated",
"thread/tokenUsage/updated": "thread/tokenUsage/updated",
"turn/started": "turn/started",
Expand All @@ -135,6 +142,7 @@ export const SERVER_NOTIFICATION_METHODS = {
"item/autoApprovalReview/completed": "item/autoApprovalReview/completed",
"item/completed": "item/completed",
"rawResponseItem/completed": "rawResponseItem/completed",
"rawResponse/completed": "rawResponse/completed",
"item/agentMessage/delta": "item/agentMessage/delta",
"item/plan/delta": "item/plan/delta",
"command/exec/outputDelta": "command/exec/outputDelta",
Expand All @@ -152,6 +160,7 @@ export const SERVER_NOTIFICATION_METHODS = {
"account/rateLimits/updated": "account/rateLimits/updated",
"app/list/updated": "app/list/updated",
"remoteControl/status/changed": "remoteControl/status/changed",
"externalAgentConfig/import/progress": "externalAgentConfig/import/progress",
"externalAgentConfig/import/completed": "externalAgentConfig/import/completed",
"fs/changed": "fs/changed",
"item/reasoning/summaryTextDelta": "item/reasoning/summaryTextDelta",
Expand All @@ -161,6 +170,7 @@ export const SERVER_NOTIFICATION_METHODS = {
"model/rerouted": "model/rerouted",
"model/verification": "model/verification",
"turn/moderationMetadata": "turn/moderationMetadata",
"model/safetyBuffering/updated": "model/safetyBuffering/updated",
warning: "warning",
guardianWarning: "guardianWarning",
deprecationNotice: "deprecationNotice",
Expand Down Expand Up @@ -222,7 +232,9 @@ export interface ClientRequestParamsByMethod {
readonly "plugin/share/list": CodexSchema.V2PluginShareListParams;
readonly "plugin/share/checkout": CodexSchema.V2PluginShareCheckoutParams;
readonly "plugin/share/delete": CodexSchema.V2PluginShareDeleteParams;
readonly "app/read": CodexSchema.V2AppsReadParams;
readonly "app/list": CodexSchema.V2AppsListParams;
readonly "app/installed": CodexSchema.V2AppsInstalledParams;
readonly "fs/readFile": CodexSchema.V2FsReadFileParams;
readonly "fs/writeFile": CodexSchema.V2FsWriteFileParams;
readonly "fs/createDirectory": CodexSchema.V2FsCreateDirectoryParams;
Expand Down Expand Up @@ -255,7 +267,9 @@ export interface ClientRequestParamsByMethod {
readonly "account/login/cancel": CodexSchema.V2CancelLoginAccountParams;
readonly "account/logout": undefined;
readonly "account/rateLimits/read": undefined;
readonly "account/rateLimitResetCredit/consume": CodexSchema.V2ConsumeAccountRateLimitResetCreditParams;
readonly "account/usage/read": undefined;
readonly "account/workspaceMessages/read": undefined;
readonly "account/sendAddCreditsNudgeEmail": CodexSchema.V2SendAddCreditsNudgeEmailParams;
readonly "feedback/upload": CodexSchema.V2FeedbackUploadParams;
readonly "command/exec": CodexSchema.V2CommandExecParams;
Expand All @@ -265,6 +279,7 @@ export interface ClientRequestParamsByMethod {
readonly "config/read": CodexSchema.V2ConfigReadParams;
readonly "externalAgentConfig/detect": CodexSchema.V2ExternalAgentConfigDetectParams;
readonly "externalAgentConfig/import": CodexSchema.V2ExternalAgentConfigImportParams;
readonly "externalAgentConfig/import/readHistories": undefined;
readonly "config/value/write": CodexSchema.V2ConfigValueWriteParams;
readonly "config/batchWrite": CodexSchema.V2ConfigBatchWriteParams;
readonly "configRequirements/read": undefined;
Expand Down Expand Up @@ -312,7 +327,9 @@ export interface ClientRequestResponsesByMethod {
readonly "plugin/share/list": CodexSchema.V2PluginShareListResponse;
readonly "plugin/share/checkout": CodexSchema.V2PluginShareCheckoutResponse;
readonly "plugin/share/delete": CodexSchema.V2PluginShareDeleteResponse;
readonly "app/read": CodexSchema.V2AppsReadResponse;
readonly "app/list": CodexSchema.V2AppsListResponse;
readonly "app/installed": CodexSchema.V2AppsInstalledResponse;
readonly "fs/readFile": CodexSchema.V2FsReadFileResponse;
readonly "fs/writeFile": CodexSchema.V2FsWriteFileResponse;
readonly "fs/createDirectory": CodexSchema.V2FsCreateDirectoryResponse;
Expand Down Expand Up @@ -345,7 +362,9 @@ export interface ClientRequestResponsesByMethod {
readonly "account/login/cancel": CodexSchema.V2CancelLoginAccountResponse;
readonly "account/logout": CodexSchema.V2LogoutAccountResponse;
readonly "account/rateLimits/read": CodexSchema.V2GetAccountRateLimitsResponse;
readonly "account/rateLimitResetCredit/consume": CodexSchema.V2ConsumeAccountRateLimitResetCreditResponse;
readonly "account/usage/read": CodexSchema.V2GetAccountTokenUsageResponse;
readonly "account/workspaceMessages/read": CodexSchema.V2GetWorkspaceMessagesResponse;
readonly "account/sendAddCreditsNudgeEmail": CodexSchema.V2SendAddCreditsNudgeEmailResponse;
readonly "feedback/upload": CodexSchema.V2FeedbackUploadResponse;
readonly "command/exec": CodexSchema.V2CommandExecResponse;
Expand All @@ -355,6 +374,7 @@ export interface ClientRequestResponsesByMethod {
readonly "config/read": CodexSchema.V2ConfigReadResponse;
readonly "externalAgentConfig/detect": CodexSchema.V2ExternalAgentConfigDetectResponse;
readonly "externalAgentConfig/import": CodexSchema.V2ExternalAgentConfigImportResponse;
readonly "externalAgentConfig/import/readHistories": CodexSchema.V2ExternalAgentConfigImportHistoriesReadResponse;
readonly "config/value/write": CodexSchema.V2ConfigWriteResponse;
readonly "config/batchWrite": CodexSchema.V2ConfigWriteResponse;
readonly "configRequirements/read": CodexSchema.V2ConfigRequirementsReadResponse;
Expand Down Expand Up @@ -407,6 +427,8 @@ export interface ServerNotificationParamsByMethod {
readonly "thread/name/updated": CodexSchema.V2ThreadNameUpdatedNotification;
readonly "thread/goal/updated": CodexSchema.V2ThreadGoalUpdatedNotification;
readonly "thread/goal/cleared": CodexSchema.V2ThreadGoalClearedNotification;
readonly "thread/environment/connected": CodexSchema.V2EnvironmentConnectionNotification;
readonly "thread/environment/disconnected": CodexSchema.V2EnvironmentConnectionNotification;
readonly "thread/settings/updated": CodexSchema.V2ThreadSettingsUpdatedNotification;
readonly "thread/tokenUsage/updated": CodexSchema.V2ThreadTokenUsageUpdatedNotification;
readonly "turn/started": CodexSchema.V2TurnStartedNotification;
Expand All @@ -420,6 +442,7 @@ export interface ServerNotificationParamsByMethod {
readonly "item/autoApprovalReview/completed": CodexSchema.V2ItemGuardianApprovalReviewCompletedNotification;
readonly "item/completed": CodexSchema.V2ItemCompletedNotification;
readonly "rawResponseItem/completed": CodexSchema.V2RawResponseItemCompletedNotification;
readonly "rawResponse/completed": CodexSchema.V2RawResponseCompletedNotification;
readonly "item/agentMessage/delta": CodexSchema.V2AgentMessageDeltaNotification;
readonly "item/plan/delta": CodexSchema.V2PlanDeltaNotification;
readonly "command/exec/outputDelta": CodexSchema.V2CommandExecOutputDeltaNotification;
Expand All @@ -437,6 +460,7 @@ export interface ServerNotificationParamsByMethod {
readonly "account/rateLimits/updated": CodexSchema.V2AccountRateLimitsUpdatedNotification;
readonly "app/list/updated": CodexSchema.V2AppListUpdatedNotification;
readonly "remoteControl/status/changed": CodexSchema.V2RemoteControlStatusChangedNotification;
readonly "externalAgentConfig/import/progress": CodexSchema.V2ExternalAgentConfigImportProgressNotification;
readonly "externalAgentConfig/import/completed": CodexSchema.V2ExternalAgentConfigImportCompletedNotification;
readonly "fs/changed": CodexSchema.V2FsChangedNotification;
readonly "item/reasoning/summaryTextDelta": CodexSchema.V2ReasoningSummaryTextDeltaNotification;
Expand All @@ -446,6 +470,7 @@ export interface ServerNotificationParamsByMethod {
readonly "model/rerouted": CodexSchema.V2ModelReroutedNotification;
readonly "model/verification": CodexSchema.V2ModelVerificationNotification;
readonly "turn/moderationMetadata": CodexSchema.V2TurnModerationMetadataNotification;
readonly "model/safetyBuffering/updated": CodexSchema.V2ModelSafetyBufferingUpdatedNotification;
readonly warning: CodexSchema.V2WarningNotification;
readonly guardianWarning: CodexSchema.V2GuardianWarningNotification;
readonly deprecationNotice: CodexSchema.V2DeprecationNoticeNotification;
Expand Down Expand Up @@ -502,7 +527,9 @@ export const CLIENT_REQUEST_PARAMS = {
"plugin/share/list": CodexSchema.V2PluginShareListParams,
"plugin/share/checkout": CodexSchema.V2PluginShareCheckoutParams,
"plugin/share/delete": CodexSchema.V2PluginShareDeleteParams,
"app/read": CodexSchema.V2AppsReadParams,
"app/list": CodexSchema.V2AppsListParams,
"app/installed": CodexSchema.V2AppsInstalledParams,
"fs/readFile": CodexSchema.V2FsReadFileParams,
"fs/writeFile": CodexSchema.V2FsWriteFileParams,
"fs/createDirectory": CodexSchema.V2FsCreateDirectoryParams,
Expand Down Expand Up @@ -535,7 +562,9 @@ export const CLIENT_REQUEST_PARAMS = {
"account/login/cancel": CodexSchema.V2CancelLoginAccountParams,
"account/logout": undefined,
"account/rateLimits/read": undefined,
"account/rateLimitResetCredit/consume": CodexSchema.V2ConsumeAccountRateLimitResetCreditParams,
"account/usage/read": undefined,
"account/workspaceMessages/read": undefined,
"account/sendAddCreditsNudgeEmail": CodexSchema.V2SendAddCreditsNudgeEmailParams,
"feedback/upload": CodexSchema.V2FeedbackUploadParams,
"command/exec": CodexSchema.V2CommandExecParams,
Expand All @@ -545,6 +574,7 @@ export const CLIENT_REQUEST_PARAMS = {
"config/read": CodexSchema.V2ConfigReadParams,
"externalAgentConfig/detect": CodexSchema.V2ExternalAgentConfigDetectParams,
"externalAgentConfig/import": CodexSchema.V2ExternalAgentConfigImportParams,
"externalAgentConfig/import/readHistories": undefined,
"config/value/write": CodexSchema.V2ConfigValueWriteParams,
"config/batchWrite": CodexSchema.V2ConfigBatchWriteParams,
"configRequirements/read": undefined,
Expand Down Expand Up @@ -592,7 +622,9 @@ export const CLIENT_REQUEST_RESPONSES = {
"plugin/share/list": CodexSchema.V2PluginShareListResponse,
"plugin/share/checkout": CodexSchema.V2PluginShareCheckoutResponse,
"plugin/share/delete": CodexSchema.V2PluginShareDeleteResponse,
"app/read": CodexSchema.V2AppsReadResponse,
"app/list": CodexSchema.V2AppsListResponse,
"app/installed": CodexSchema.V2AppsInstalledResponse,
"fs/readFile": CodexSchema.V2FsReadFileResponse,
"fs/writeFile": CodexSchema.V2FsWriteFileResponse,
"fs/createDirectory": CodexSchema.V2FsCreateDirectoryResponse,
Expand Down Expand Up @@ -625,7 +657,9 @@ export const CLIENT_REQUEST_RESPONSES = {
"account/login/cancel": CodexSchema.V2CancelLoginAccountResponse,
"account/logout": CodexSchema.V2LogoutAccountResponse,
"account/rateLimits/read": CodexSchema.V2GetAccountRateLimitsResponse,
"account/rateLimitResetCredit/consume": CodexSchema.V2ConsumeAccountRateLimitResetCreditResponse,
"account/usage/read": CodexSchema.V2GetAccountTokenUsageResponse,
"account/workspaceMessages/read": CodexSchema.V2GetWorkspaceMessagesResponse,
"account/sendAddCreditsNudgeEmail": CodexSchema.V2SendAddCreditsNudgeEmailResponse,
"feedback/upload": CodexSchema.V2FeedbackUploadResponse,
"command/exec": CodexSchema.V2CommandExecResponse,
Expand All @@ -635,6 +669,8 @@ export const CLIENT_REQUEST_RESPONSES = {
"config/read": CodexSchema.V2ConfigReadResponse,
"externalAgentConfig/detect": CodexSchema.V2ExternalAgentConfigDetectResponse,
"externalAgentConfig/import": CodexSchema.V2ExternalAgentConfigImportResponse,
"externalAgentConfig/import/readHistories":
CodexSchema.V2ExternalAgentConfigImportHistoriesReadResponse,
"config/value/write": CodexSchema.V2ConfigWriteResponse,
"config/batchWrite": CodexSchema.V2ConfigWriteResponse,
"configRequirements/read": CodexSchema.V2ConfigRequirementsReadResponse,
Expand Down Expand Up @@ -687,6 +723,8 @@ export const SERVER_NOTIFICATION_PARAMS = {
"thread/name/updated": CodexSchema.V2ThreadNameUpdatedNotification,
"thread/goal/updated": CodexSchema.V2ThreadGoalUpdatedNotification,
"thread/goal/cleared": CodexSchema.V2ThreadGoalClearedNotification,
"thread/environment/connected": CodexSchema.V2EnvironmentConnectionNotification,
"thread/environment/disconnected": CodexSchema.V2EnvironmentConnectionNotification,
"thread/settings/updated": CodexSchema.V2ThreadSettingsUpdatedNotification,
"thread/tokenUsage/updated": CodexSchema.V2ThreadTokenUsageUpdatedNotification,
"turn/started": CodexSchema.V2TurnStartedNotification,
Expand All @@ -701,6 +739,7 @@ export const SERVER_NOTIFICATION_PARAMS = {
CodexSchema.V2ItemGuardianApprovalReviewCompletedNotification,
"item/completed": CodexSchema.V2ItemCompletedNotification,
"rawResponseItem/completed": CodexSchema.V2RawResponseItemCompletedNotification,
"rawResponse/completed": CodexSchema.V2RawResponseCompletedNotification,
"item/agentMessage/delta": CodexSchema.V2AgentMessageDeltaNotification,
"item/plan/delta": CodexSchema.V2PlanDeltaNotification,
"command/exec/outputDelta": CodexSchema.V2CommandExecOutputDeltaNotification,
Expand All @@ -718,6 +757,8 @@ export const SERVER_NOTIFICATION_PARAMS = {
"account/rateLimits/updated": CodexSchema.V2AccountRateLimitsUpdatedNotification,
"app/list/updated": CodexSchema.V2AppListUpdatedNotification,
"remoteControl/status/changed": CodexSchema.V2RemoteControlStatusChangedNotification,
"externalAgentConfig/import/progress":
CodexSchema.V2ExternalAgentConfigImportProgressNotification,
"externalAgentConfig/import/completed":
CodexSchema.V2ExternalAgentConfigImportCompletedNotification,
"fs/changed": CodexSchema.V2FsChangedNotification,
Expand All @@ -728,6 +769,7 @@ export const SERVER_NOTIFICATION_PARAMS = {
"model/rerouted": CodexSchema.V2ModelReroutedNotification,
"model/verification": CodexSchema.V2ModelVerificationNotification,
"turn/moderationMetadata": CodexSchema.V2TurnModerationMetadataNotification,
"model/safetyBuffering/updated": CodexSchema.V2ModelSafetyBufferingUpdatedNotification,
warning: CodexSchema.V2WarningNotification,
guardianWarning: CodexSchema.V2GuardianWarningNotification,
deprecationNotice: CodexSchema.V2DeprecationNoticeNotification,
Expand Down
Loading
Loading