@jrkropp/codex-js 0.1.0 → 0.1.2

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.
@@ -1,3 +1,3 @@
1
- export { AppServerSession, CodexAppServerConnectionSessionState, CodexAppServerMessageProcessor, CodexAppServerRequestError, ConnectionRpcGate, ConnectionRpcGateClosedError, EmptyMcpConnectionManager, InMemoryThreadStore, LiveThread, LocalThreadStore, McpRequestProcessor, ModelClientSession, OutgoingMessageSender, RequestSerializationQueues, ResponsesClient, ResponsesWebsocketClient, ResponsesWebsocketConnection, StaticMcpConnectionManager, ThreadEventPersistenceMode, ThreadEventStore, ThreadHistoryBuilder, ThreadMemoryMode, ThreadRequestProcessor, ThreadScopedOutgoingMessageSender, TurnRequestProcessor, asThreadId, clientRequestExperimentalReason, clientRequestId, clientRequestMethod, clientRequestSerializationScope, createCodexAppServerRuntime, createModelClient, deniedRequestPermissionsResponse, jsonRpcInternalError, jsonRpcInvalidRequestError, jsonRpcParseError, parseClientTransportPayload, parseServerTransportPayload, queuedOutgoingMessage, serializeJsonRpcError, serializeJsonRpcResponse, serializeOutgoingMessage } from '../chunk-TZBLUZ2X.js';
1
+ export { AppServerSession, AuthMode, BaseInstructions, CODEX_CHATGPT_OAUTH_CALLBACK_PATH, CODEX_CHATGPT_OAUTH_CLIENT_ID, CODEX_CHATGPT_OAUTH_FALLBACK_PORT, CODEX_CHATGPT_OAUTH_ISSUER, CODEX_CHATGPT_OAUTH_ORIGINATOR, CODEX_CHATGPT_OAUTH_PRIMARY_PORT, CODEX_CHATGPT_OAUTH_SCOPE, CODEX_PLAN_MODE_INSTRUCTIONS, CodexAppServerClientTransportError, CodexAppServerConnectionSessionState, CodexAppServerMessageProcessor, CodexAppServerRequestError, CodexMcpConnectionManagerAdapter, ConnectionRpcGate, ConnectionRpcGateClosedError, EmptyMcpConnectionManager, InMemoryThreadStore, LiveThread, LocalThreadStore, McpRequestProcessor, ModeKind, ModelClientSession, OutgoingMessageSender, PendingAppServerRequests, RequestSerializationQueues, ResponsesClient, ResponsesWebsocketClient, ResponsesWebsocketConnection, SortDirection, StaticMcpConnectionManager, TUI_VISIBLE_COLLABORATION_MODES, ThreadEventPersistenceMode, ThreadEventStore, ThreadHistoryBuilder, ThreadMemoryMode, ThreadRequestProcessor, ThreadScopedOutgoingMessageSender, ThreadSortKey, TurnRequestProcessor, allowsRequestUserInput, applyCollaborationModeMask, applyEventMsgToRenderedThread, asThreadId, builtinCollaborationModePresets, clientRequestExperimentalReason, clientRequestId, clientRequestMethod, clientRequestSerializationScope, codexAppServerDeferredResponse, builtinCollaborationModePresets as codexBuiltinCollaborationModePresets, collaborationModeForModel, collaborationModePresetForMode, collaborationModeWithUpdates, createCodexAppServerClient, createCodexAppServerRuntime, createModelClient, createRenderedThreadState, defaultModeInstructions, deniedRequestPermissionsResponse, jsonRpcInternalError, jsonRpcInvalidRequestError, jsonRpcParseError, normalizeCollaborationMode, outgoingMessageToAppServerEvent, parseClientTransportPayload, parseCodexAppServerEvent, parseJsonRpcMessage, parseJsonRpcTransportPayload, parseServerTransportPayload, queuedOutgoingMessage, renderThreadFromHistory, requestMethodName, requestSerializationQueueKeyFromScope, requestTyped, serializeJsonRpcError, serializeJsonRpcResponse, serializeOutgoingMessage, serverNotificationRequiresDelivery, serverNotificationThreadTarget, serverRequestThreadId, setRenderedThreadConnectionStatus, threadEventSnapshotHasStarted } from '../chunk-SVK6PLGO.js';
2
2
  //# sourceMappingURL=index.js.map
3
3
  //# sourceMappingURL=index.js.map
@@ -1,4 +1,4 @@
1
- import { aL as ThreadId, aM as AbsolutePathBuf, J as JsonValue, aN as ThreadSource, aO as UserInput, aP as ReasoningEffort, aQ as WindowsSandboxSetupMode, l as RequestId, aR as Thread, aS as Turn, S as ServerNotification, a as ServerRequest } from './thread_event_store-BIS0qzhi.js';
1
+ import { b3 as ThreadId, b4 as AbsolutePathBuf, J as JsonValue, b5 as ThreadSource, aR as UserInput, s as ReasoningEffort, b6 as WindowsSandboxSetupMode, j as RequestId, aH as Thread, aQ as Turn, S as ServerNotification, a as ServerRequest } from './thread_event_store-B9CoQUIA.js';
2
2
 
3
3
  type ClientInfo = {
4
4
  name: string;
@@ -1733,6 +1733,22 @@ type ThreadUnarchiveResponse = {
1733
1733
  thread: Thread;
1734
1734
  };
1735
1735
 
1736
+ /**
1737
+ * EXPERIMENTAL. Captures a user's answer to a request_user_input question.
1738
+ */
1739
+ type ToolRequestUserInputAnswer = {
1740
+ answers: Array<string>;
1741
+ };
1742
+
1743
+ /**
1744
+ * EXPERIMENTAL. Response payload mapping question ids to answers.
1745
+ */
1746
+ type ToolRequestUserInputResponse = {
1747
+ answers: {
1748
+ [key in string]?: ToolRequestUserInputAnswer;
1749
+ };
1750
+ };
1751
+
1736
1752
  type TurnInterruptResponse = Record<string, never>;
1737
1753
 
1738
1754
  type TurnStartResponse = {
@@ -1826,4 +1842,4 @@ declare class AppServerSession {
1826
1842
  rejectServerRequest(requestId: RequestId, error: JSONRPCErrorError): Promise<void>;
1827
1843
  }
1828
1844
 
1829
- export { type AppServerEvent as A, type ThreadSetNameParams as B, type CodexAppServer as C, type ThreadSetNameResponse as D, type ThreadReadParams as E, type ThreadReadResponse as F, type ThreadResumeParams as G, type ThreadResumeResponse as H, type InitializeParams as I, type JSONRPCErrorError as J, type ThreadStartResponse as K, type ListMcpServerStatusParams as L, type McpServerRefreshResponse as M, type ThreadUnarchiveParams as N, type ThreadUnarchiveResponse as O, type TurnInterruptParams as P, type TurnInterruptResponse as Q, type Result as R, type TurnStartResponse as S, type TypedRequestError as T, type TurnSteerParams as U, type TurnSteerResponse as V, type AppServerRequestHandle as a, AppServerSession as b, type ClientRequest as c, type InitializeResponse as d, requestTyped as e, type ThreadStartParams as f, type TurnStartParams as g, type CollaborationModeListParams as h, type CollaborationModeListResponse as i, type McpResourceReadParams as j, type McpResourceReadResponse as k, type McpServerOauthLoginParams as l, type McpServerOauthLoginResponse as m, type ListMcpServerStatusResponse as n, type McpServerToolCallParams as o, type McpServerToolCallResponse as p, type ThreadArchiveParams as q, requestMethodName as r, serverNotificationRequiresDelivery as s, type ThreadArchiveResponse as t, type ThreadCompactStartParams as u, type ThreadCompactStartResponse as v, type ThreadListParams as w, type ThreadListResponse as x, type ThreadMetadataUpdateParams as y, type ThreadMetadataUpdateResponse as z };
1845
+ export { type AppServerEvent as A, type ThreadResumeParams as B, type CodexAppServer as C, type ThreadResumeResponse as D, type ThreadStartResponse as E, type ThreadUnarchiveParams as F, type ThreadUnarchiveResponse as G, type TurnInterruptParams as H, type InitializeParams as I, type JSONRPCErrorError as J, type TurnInterruptResponse as K, type ListMcpServerStatusParams as L, type ModeKind as M, type TurnStartResponse as N, type TurnSteerParams as O, type TurnSteerResponse as P, type CollaborationModeMask as Q, type Result as R, type McpServerStatus as S, type ToolRequestUserInputResponse as T, type AppServerRequestHandle as U, AppServerSession as V, type TypedRequestError as W, requestMethodName as X, requestTyped as Y, serverNotificationRequiresDelivery as Z, type ThreadStartParams as a, type TurnStartParams as b, type ClientRequest as c, type CollaborationModeListParams as d, type CollaborationModeListResponse as e, type InitializeResponse as f, type McpServerRefreshResponse as g, type McpResourceReadParams as h, type McpResourceReadResponse as i, type McpServerOauthLoginParams as j, type McpServerOauthLoginResponse as k, type ListMcpServerStatusResponse as l, type McpServerToolCallParams as m, type McpServerToolCallResponse as n, type ThreadArchiveParams as o, type ThreadArchiveResponse as p, type ThreadCompactStartParams as q, type ThreadCompactStartResponse as r, type ThreadListParams as s, type ThreadListResponse as t, type ThreadMetadataUpdateParams as u, type ThreadMetadataUpdateResponse as v, type ThreadSetNameParams as w, type ThreadSetNameResponse as x, type ThreadReadParams as y, type ThreadReadResponse as z };
@@ -1,4 +1,4 @@
1
- import { C as CreateThreadParams, R as ResumeThreadParams, A as AppendThreadItemsParams, T as ThreadId, L as LoadThreadHistoryParams, b as StoredThreadHistory, c as ReadThreadParams, d as StoredThread, e as ReadThreadByRolloutPathParams, f as ListThreadsParams, g as ThreadPage, U as UpdateThreadMetadataParams, h as ArchiveThreadParams } from './thread_event_store-BIS0qzhi.js';
1
+ import { C as CreateThreadParams, R as ResumeThreadParams, A as AppendThreadItemsParams, T as ThreadId, L as LoadThreadHistoryParams, b as StoredThreadHistory, c as ReadThreadParams, d as StoredThread, e as ReadThreadByRolloutPathParams, f as ListThreadsParams, g as ThreadPage, U as UpdateThreadMetadataParams, h as ArchiveThreadParams } from './thread_event_store-B9CoQUIA.js';
2
2
 
3
3
  interface ThreadStore {
4
4
  createThread(params: CreateThreadParams): Promise<void>;
@@ -1,6 +1,6 @@
1
- import { T as ThreadId, C as CreateThreadParams, $ as RolloutItem, d as StoredThread, R as ResumeThreadParams, A as AppendThreadItemsParams, L as LoadThreadHistoryParams, b as StoredThreadHistory, c as ReadThreadParams, e as ReadThreadByRolloutPathParams, f as ListThreadsParams, g as ThreadPage, U as UpdateThreadMetadataParams, h as ArchiveThreadParams } from '../thread_event_store-BIS0qzhi.js';
2
- export { aT as RenderedThreadState, m as ThreadEventSnapshot, n as ThreadEventStore, aU as createRenderedThreadState, aV as renderThreadFromHistory } from '../thread_event_store-BIS0qzhi.js';
3
- import { T as ThreadStore } from '../store-H2cQxdpe.js';
1
+ import { T as ThreadId, C as CreateThreadParams, O as RolloutItem, d as StoredThread, R as ResumeThreadParams, A as AppendThreadItemsParams, L as LoadThreadHistoryParams, b as StoredThreadHistory, c as ReadThreadParams, e as ReadThreadByRolloutPathParams, f as ListThreadsParams, g as ThreadPage, U as UpdateThreadMetadataParams, h as ArchiveThreadParams } from '../thread_event_store-B9CoQUIA.js';
2
+ export { aD as RenderedThreadState, p as ThreadEventSnapshot, aK as ThreadEventStore, aY as createRenderedThreadState, a_ as renderThreadFromHistory } from '../thread_event_store-B9CoQUIA.js';
3
+ import { T as ThreadStore } from '../store-GYldc9EJ.js';
4
4
 
5
5
  type InMemoryThreadStoreCalls = {
6
6
  archiveThread: number;
@@ -1,3 +1,3 @@
1
- export { InMemoryThreadStore, LocalThreadStore, ThreadEventStore, createRenderedThreadState, renderThreadFromHistory } from '../chunk-TZBLUZ2X.js';
1
+ export { InMemoryThreadStore, LocalThreadStore, ThreadEventStore, createRenderedThreadState, renderThreadFromHistory } from '../chunk-SVK6PLGO.js';
2
2
  //# sourceMappingURL=index.js.map
3
3
  //# sourceMappingURL=index.js.map
@@ -2219,6 +2219,18 @@ type CollaborationMode = {
2219
2219
  mode: ModeKind;
2220
2220
  settings: CollaborationModeSettings;
2221
2221
  };
2222
+ type CollaborationModeMask = {
2223
+ name: string;
2224
+ mode?: ModeKind | null;
2225
+ model?: string | null;
2226
+ reasoning_effort?: ReasoningEffort | null | undefined;
2227
+ developer_instructions?: string | null | undefined;
2228
+ };
2229
+ declare const TUI_VISIBLE_COLLABORATION_MODES: readonly ["default", "plan"];
2230
+ declare function allowsRequestUserInput(mode: ModeKind): boolean;
2231
+ declare function collaborationModeWithUpdates(collaborationMode: CollaborationMode, model?: string | null, effort?: ReasoningEffort | null | undefined, developerInstructions?: string | null | undefined): CollaborationMode;
2232
+ declare function applyCollaborationModeMask(collaborationMode: CollaborationMode, mask: CollaborationModeMask): CollaborationMode;
2233
+ declare function collaborationModeForModel(model: string, effort?: ReasoningEffort | null, mode?: ModeKind, developerInstructions?: string | null): CollaborationMode;
2222
2234
 
2223
2235
  declare const ThreadMemoryMode: {
2224
2236
  readonly Enabled: "Enabled";
@@ -2428,6 +2440,14 @@ type DynamicToolCallResponseEvent = {
2428
2440
  error?: string | null;
2429
2441
  duration: string;
2430
2442
  };
2443
+ type DynamicToolSpecWire = {
2444
+ namespace?: string | null;
2445
+ name: string;
2446
+ description: string;
2447
+ inputSchema: unknown;
2448
+ deferLoading?: boolean;
2449
+ exposeToContext?: boolean;
2450
+ };
2431
2451
 
2432
2452
  type RequestUserInputQuestionOption = {
2433
2453
  label: string;
@@ -3765,8 +3785,13 @@ type RenderedThreadState = {
3765
3785
  last_history_fingerprint: string | null;
3766
3786
  connection_status: RenderedThreadConnectionStatus;
3767
3787
  };
3788
+ type ApplyEventOptions = {
3789
+ event_id?: string;
3790
+ };
3768
3791
  declare function createRenderedThreadState(threadId: ThreadId): RenderedThreadState;
3769
3792
  declare function renderThreadFromHistory(history: StoredThreadHistory): RenderedThreadState;
3793
+ declare function applyEventMsgToRenderedThread(state: RenderedThreadState, msg: EventMsg, options?: ApplyEventOptions): RenderedThreadState;
3794
+ declare function setRenderedThreadConnectionStatus(state: RenderedThreadState, connectionStatus: RenderedThreadConnectionStatus): RenderedThreadState;
3770
3795
 
3771
3796
  type ThreadBufferedEvent = {
3772
3797
  notification: ServerNotification;
@@ -3840,4 +3865,4 @@ declare function serverRequestThreadId(request: ServerRequest): string | null;
3840
3865
  declare function serverNotificationThreadTarget(notification: ServerNotification): ServerNotificationThreadTarget;
3841
3866
  declare function threadEventSnapshotHasStarted(snapshot: ThreadEventSnapshot | null): boolean;
3842
3867
 
3843
- export { type RolloutItem as $, type AppendThreadItemsParams as A, type McpRuntimeEnvironment as B, type CreateThreadParams as C, type DynamicToolCallOutputContentItem$1 as D, type ExecPolicyAmendment as E, type McpServerStatusListOptions as F, type McpServerStatus as G, type McpResourceListParams as H, type McpResourceListResponse as I, type JsonValue as J, type McpResourceTemplateListResponse as K, type LoadThreadHistoryParams as L, type McpServerRefreshConfig as M, type NetworkPolicyAmendment as N, type McpResourceReadParams as O, type McpResourceReadResponse as P, type McpServerToolCallParams as Q, type ResumeThreadParams as R, type ServerNotification as S, type ThreadId as T, type UpdateThreadMetadataParams as U, type McpServerToolCallResponse as V, type McpToolInfo as W, type McpRequestId as X, type McpServerElicitationResponse as Y, type McpResourceInfo as Z, type McpResourceTemplateInfo as _, type ServerRequest as a, ThreadMemoryMode as a0, type ThreadMetadataPatch as a1, type ServiceTier as a2, type ReasoningEffortConfig as a3, type ReasoningSummaryConfig as a4, type Personality as a5, type AskForApproval as a6, type ApprovalsReviewer as a7, type SandboxPolicy as a8, type PermissionProfile as a9, type CompactedItem as aA, type ResponseItem as aB, type RateLimitSnapshot as aC, type TokenUsageInfo as aD, type TurnContextItem as aE, ModeKind as aF, type W3cTraceContext as aG, ThreadEventPersistenceMode as aH, ThreadHistoryBuilder as aI, asThreadId as aJ, deniedRequestPermissionsResponse as aK, type ThreadId$1 as aL, type AbsolutePathBuf as aM, type ThreadSource as aN, type UserInput$1 as aO, type ReasoningEffort$1 as aP, type WindowsSandboxSetupMode as aQ, type Thread as aR, type Turn$1 as aS, type RenderedThreadState as aT, createRenderedThreadState as aU, renderThreadFromHistory as aV, type ActivePermissionProfile as aa, type WindowsSandboxLevel as ab, BaseInstructions as ac, type SessionSource as ad, type TurnEnvironmentSelection as ae, type DynamicToolSpec as af, type TruncationPolicy as ag, type ThreadGoal as ah, ThreadGoalStatus as ai, HookEventName as aj, HookSource as ak, HookRunStatus as al, type HookOutputEntry as am, type HookRunSummary as an, type HookCompletedEvent as ao, type TokenUsage as ap, type RequestUserInputResponse as aq, type DynamicToolResponse as ar, type RequestPermissionsResponse as as, type RequestPermissionProfile as at, type EventMsg as au, type Op as av, type Submission as aw, type NormalizedRequestUserInputArgs as ax, type RequestPermissionsArgs as ay, type McpServerElicitationRequest as az, type StoredThreadHistory as b, type ReadThreadParams as c, type StoredThread as d, type ReadThreadByRolloutPathParams as e, type ListThreadsParams as f, type ThreadPage as g, type ArchiveThreadParams as h, type TextElement as i, type AdditionalNetworkPermissions as j, type AdditionalFileSystemPermissions as k, type RequestId as l, type ThreadEventSnapshot as m, ThreadEventStore as n, type ThreadTokenUsageSnapshot as o, serverRequestThreadId as p, type ToolRequestUserInputQuestion as q, type UserInput as r, serverNotificationThreadTarget as s, threadEventSnapshotHasStarted as t, type UserMessageTurnItem as u, type Turn as v, type CollaborationMode as w, type DynamicToolCallRequest as x, type RequestPermissionsEvent as y, type TurnItem as z };
3868
+ export { type AskForApproval as $, type AppendThreadItemsParams as A, type McpResourceReadResponse as B, type CreateThreadParams as C, type DynamicToolCallRequest as D, type McpServerToolCallParams as E, type McpServerToolCallResponse as F, type McpToolInfo as G, type McpRequestId as H, type McpServerElicitationResponse as I, type JsonValue as J, type McpResourceInfo as K, type LoadThreadHistoryParams as L, type McpServerRefreshConfig as M, type McpResourceTemplateInfo as N, type RolloutItem as O, ThreadMemoryMode as P, type ThreadMetadataPatch as Q, type ResumeThreadParams as R, type ServerNotification as S, type ThreadId as T, type UpdateThreadMetadataParams as U, type CollaborationModeMask as V, ModeKind as W, type ServiceTier as X, type ReasoningEffortConfig as Y, type ReasoningSummaryConfig as Z, type Personality as _, type ServerRequest as a, serverNotificationThreadTarget as a$, type ApprovalsReviewer as a0, type SandboxPolicy as a1, type PermissionProfile as a2, type ActivePermissionProfile as a3, type WindowsSandboxLevel as a4, BaseInstructions as a5, type SessionSource as a6, type TurnEnvironmentSelection as a7, type DynamicToolSpec as a8, type TruncationPolicy as a9, type DynamicToolSpecWire as aA, type RealtimeEvent as aB, type RenderedThreadConnectionStatus as aC, type RenderedThreadState as aD, type ServerNotificationThreadTarget as aE, SortDirection as aF, TUI_VISIBLE_COLLABORATION_MODES as aG, type Thread as aH, type ThreadBufferedEvent as aI, ThreadEventPersistenceMode as aJ, ThreadEventStore as aK, ThreadHistoryBuilder as aL, type ThreadItem as aM, type ThreadPersistenceMetadata as aN, ThreadSortKey as aO, type ThreadTokenUsageSnapshot as aP, type Turn$1 as aQ, type UserInput$1 as aR, allowsRequestUserInput as aS, applyCollaborationModeMask as aT, applyEventMsgToRenderedThread as aU, asThreadId as aV, collaborationModeForModel as aW, collaborationModeWithUpdates as aX, createRenderedThreadState as aY, deniedRequestPermissionsResponse as aZ, renderThreadFromHistory as a_, type ThreadGoal as aa, ThreadGoalStatus as ab, HookEventName as ac, HookSource as ad, HookRunStatus as ae, type HookOutputEntry as af, type HookRunSummary as ag, type HookCompletedEvent as ah, type TokenUsage as ai, type RequestUserInputResponse as aj, type DynamicToolResponse as ak, type RequestPermissionsResponse as al, type RequestPermissionProfile as am, type EventMsg as an, type Op as ao, type Submission as ap, type NormalizedRequestUserInputArgs as aq, type RequestPermissionsArgs as ar, type McpServerElicitationRequest as as, type CompactedItem as at, type ResponseItem as au, type RateLimitSnapshot as av, type TokenUsageInfo as aw, type TurnContextItem as ax, type W3cTraceContext as ay, type DynamicToolCallParams as az, type StoredThreadHistory as b, serverRequestThreadId as b0, setRenderedThreadConnectionStatus as b1, threadEventSnapshotHasStarted as b2, type ThreadId$1 as b3, type AbsolutePathBuf as b4, type ThreadSource as b5, type WindowsSandboxSetupMode as b6, type ExecPolicyAmendment as b7, type NetworkPolicyAmendment as b8, type DynamicToolCallOutputContentItem$1 as b9, type AdditionalNetworkPermissions as ba, type AdditionalFileSystemPermissions as bb, type ReadThreadParams as c, type StoredThread as d, type ReadThreadByRolloutPathParams as e, type ListThreadsParams as f, type ThreadPage as g, type ArchiveThreadParams as h, type TextElement as i, type RequestId as j, type ToolRequestUserInputQuestion as k, type UserInput as l, type UserMessageTurnItem as m, type Turn as n, type CollaborationMode as o, type ThreadEventSnapshot as p, type RequestPermissionsEvent as q, type TurnItem as r, type ReasoningEffort$1 as s, type McpRuntimeEnvironment as t, type McpServerStatusListOptions as u, type McpServerStatus as v, type McpResourceListParams as w, type McpResourceListResponse as x, type McpResourceTemplateListResponse as y, type McpResourceReadParams as z };
package/package.json CHANGED
@@ -1,89 +1,89 @@
1
1
  {
2
- "name": "@jrkropp/codex-js",
3
- "version": "0.1.0",
4
- "description": "Unofficial TypeScript Codex runtime for building Codex-backed web apps.",
5
- "license": "Apache-2.0",
6
- "type": "module",
7
- "sideEffects": [
8
- "**/*.css"
9
- ],
10
- "files": [
11
- "dist",
12
- "README.md",
13
- "CHANGELOG.md",
14
- "LICENSE",
15
- "NOTICE"
16
- ],
17
- "exports": {
18
- ".": {
19
- "types": "./dist/index.d.ts",
20
- "import": "./dist/index.js"
21
- },
22
- "./client": {
23
- "types": "./dist/client/index.d.ts",
24
- "import": "./dist/client/index.js"
25
- },
26
- "./server": {
27
- "types": "./dist/server/index.d.ts",
28
- "import": "./dist/server/index.js"
29
- },
30
- "./react": {
31
- "types": "./dist/react/index.d.ts",
32
- "import": "./dist/react/index.js"
33
- },
34
- "./shadcn": {
35
- "types": "./dist/shadcn/index.d.ts",
36
- "import": "./dist/shadcn/index.js"
37
- },
38
- "./testing": {
39
- "types": "./dist/testing/index.d.ts",
40
- "import": "./dist/testing/index.js"
41
- },
42
- "./styles.css": "./dist/styles.css"
43
- },
44
- "scripts": {
45
- "build": "tsup && node scripts/copy-assets.mjs",
46
- "clean": "rm -rf dist",
47
- "codex:mirror": "node scripts/generate-codex-mirror.mjs",
48
- "pack:dry-run": "npm pack --dry-run",
49
- "publint": "publint",
50
- "typecheck": "tsc -p tsconfig.json --pretty false"
51
- },
52
- "dependencies": {
53
- "@legendapp/list": "^3.0.0-beta.44",
54
- "@lexical/react": "^0.44.0",
55
- "class-variance-authority": "^0.7.1",
56
- "clsx": "^2.1.1",
57
- "cmdk": "^1.1.1",
58
- "lexical": "^0.44.0",
59
- "lucide-react": "^1.11.0",
60
- "radix-ui": "^1.4.3",
61
- "react-markdown": "^10.1.0",
62
- "remark-gfm": "^4.0.1",
63
- "smol-toml": "^1.6.1",
64
- "tailwind-merge": "^3.5.0",
65
- "zustand": "^5.0.13"
66
- },
67
- "peerDependencies": {
68
- "react": "^18.3.0 || ^19.0.0",
69
- "react-dom": "^18.3.0 || ^19.0.0"
70
- },
71
- "devDependencies": {
72
- "@types/react": "19.2.7",
73
- "@types/react-dom": "19.2.3",
74
- "typescript": "5.8.3"
75
- },
76
- "publishConfig": {
77
- "access": "public",
78
- "provenance": true
79
- },
80
- "repository": {
81
- "type": "git",
82
- "url": "git+https://github.com/jrkropp/codex-js.git",
83
- "directory": "packages/codex-js"
84
- },
85
- "bugs": {
86
- "url": "https://github.com/jrkropp/codex-js/issues"
87
- },
88
- "homepage": "https://github.com/jrkropp/codex-js#readme"
89
- }
2
+ "name": "@jrkropp/codex-js",
3
+ "version": "0.1.2",
4
+ "description": "Unofficial TypeScript Codex runtime for building Codex-backed web apps.",
5
+ "license": "Apache-2.0",
6
+ "type": "module",
7
+ "sideEffects": [
8
+ "**/*.css"
9
+ ],
10
+ "files": [
11
+ "dist",
12
+ "README.md",
13
+ "CHANGELOG.md",
14
+ "LICENSE",
15
+ "NOTICE"
16
+ ],
17
+ "exports": {
18
+ ".": {
19
+ "types": "./dist/index.d.ts",
20
+ "import": "./dist/index.js"
21
+ },
22
+ "./client": {
23
+ "types": "./dist/client/index.d.ts",
24
+ "import": "./dist/client/index.js"
25
+ },
26
+ "./server": {
27
+ "types": "./dist/server/index.d.ts",
28
+ "import": "./dist/server/index.js"
29
+ },
30
+ "./react": {
31
+ "types": "./dist/react/index.d.ts",
32
+ "import": "./dist/react/index.js"
33
+ },
34
+ "./shadcn": {
35
+ "types": "./dist/shadcn/index.d.ts",
36
+ "import": "./dist/shadcn/index.js"
37
+ },
38
+ "./testing": {
39
+ "types": "./dist/testing/index.d.ts",
40
+ "import": "./dist/testing/index.js"
41
+ },
42
+ "./styles.css": "./dist/styles.css"
43
+ },
44
+ "dependencies": {
45
+ "@legendapp/list": "^3.0.0-beta.44",
46
+ "@lexical/react": "^0.44.0",
47
+ "class-variance-authority": "^0.7.1",
48
+ "clsx": "^2.1.1",
49
+ "cmdk": "^1.1.1",
50
+ "lexical": "^0.44.0",
51
+ "lucide-react": "^1.11.0",
52
+ "radix-ui": "^1.4.3",
53
+ "react-markdown": "^10.1.0",
54
+ "remark-gfm": "^4.0.1",
55
+ "smol-toml": "^1.6.1",
56
+ "tailwind-merge": "^3.5.0",
57
+ "zustand": "^5.0.13"
58
+ },
59
+ "peerDependencies": {
60
+ "react": "^18.3.0 || ^19.0.0",
61
+ "react-dom": "^18.3.0 || ^19.0.0"
62
+ },
63
+ "devDependencies": {
64
+ "@types/react": "19.2.7",
65
+ "@types/react-dom": "19.2.3",
66
+ "typescript": "5.8.3"
67
+ },
68
+ "publishConfig": {
69
+ "access": "public",
70
+ "provenance": true
71
+ },
72
+ "repository": {
73
+ "type": "git",
74
+ "url": "git+https://github.com/jrkropp/codex-js.git",
75
+ "directory": "packages/codex-js"
76
+ },
77
+ "bugs": {
78
+ "url": "https://github.com/jrkropp/codex-js/issues"
79
+ },
80
+ "homepage": "https://github.com/jrkropp/codex-js#readme",
81
+ "scripts": {
82
+ "build": "tsup && node scripts/copy-assets.mjs",
83
+ "clean": "rm -rf dist",
84
+ "codex:mirror": "node scripts/generate-codex-mirror.mjs",
85
+ "pack:dry-run": "npm pack --dry-run",
86
+ "publint": "publint",
87
+ "typecheck": "tsc -p tsconfig.json --pretty false"
88
+ }
89
+ }
@@ -1,8 +0,0 @@
1
- import { D as DynamicToolCallOutputContentItem } from './thread_event_store-BIS0qzhi.js';
2
-
3
- type DynamicToolCallResponse = {
4
- contentItems: Array<DynamicToolCallOutputContentItem>;
5
- success: boolean;
6
- };
7
-
8
- export type { DynamicToolCallResponse as D };
@@ -1,17 +0,0 @@
1
- /**
2
- * EXPERIMENTAL. Captures a user's answer to a request_user_input question.
3
- */
4
- type ToolRequestUserInputAnswer = {
5
- answers: Array<string>;
6
- };
7
-
8
- /**
9
- * EXPERIMENTAL. Response payload mapping question ids to answers.
10
- */
11
- type ToolRequestUserInputResponse = {
12
- answers: {
13
- [key in string]?: ToolRequestUserInputAnswer;
14
- };
15
- };
16
-
17
- export type { ToolRequestUserInputResponse as T };