@@ -631,7 +631,7 @@ export interface ClaudeAgentSdkLoggedQueryOptions {
631631 readonly cwd ?: ClaudeAgentSdkQueryOptions [ "cwd" ] ;
632632 readonly allowedTools ?: ClaudeAgentSdkQueryOptions [ "allowedTools" ] ;
633633 readonly disallowedTools ?: ClaudeAgentSdkQueryOptions [ "disallowedTools" ] ;
634- readonly settings ?: ClaudeAgentSdkQueryOptions [ "settings" ] ;
634+ readonly settingKeys ?: ReadonlyArray < string > ;
635635 readonly effort ?: ClaudeAgentSdkQueryOptions [ "effort" ] ;
636636 readonly includePartialMessages ?: true ;
637637 readonly pathToClaudeCodeExecutable ?: ClaudeAgentSdkQueryOptions [ "pathToClaudeCodeExecutable" ] ;
@@ -770,7 +770,10 @@ export function loggedClaudeQueryOptions(
770770 ...( options . cwd === undefined ? { } : { cwd : options . cwd } ) ,
771771 ...( options . allowedTools === undefined ? { } : { allowedTools : options . allowedTools } ) ,
772772 ...( options . disallowedTools === undefined ? { } : { disallowedTools : options . disallowedTools } ) ,
773- ...( options . settings === undefined ? { } : { settings : options . settings } ) ,
773+ // Settings can carry the user's --settings values, such as an env block with credentials.
774+ ...( typeof options . settings === "object" && options . settings !== null
775+ ? { settingKeys : Object . keys ( options . settings ) }
776+ : { } ) ,
774777 ...( options . effort === undefined ? { } : { effort : options . effort } ) ,
775778 ...( options . includePartialMessages === true ? { includePartialMessages : true } : { } ) ,
776779 ...( options . pathToClaudeCodeExecutable === undefined
0 commit comments