> ## Documentation Index
> Fetch the complete documentation index at: https://praison.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Code Config • AI Agent SDK

> CodeConfig: Configuration for CodeAgent.

# CodeConfig

> Defined in the [**Code Agent**](../modules/code_agent) module.

<Badge color="blue">AI Agent</Badge>

Configuration for CodeAgent.

Attributes:
sandbox: Enable sandboxed execution (default: True for safety)
timeout: Execution timeout in seconds
allowed\_languages: List of allowed programming languages
max\_output\_length: Maximum output length in characters
working\_directory: Working directory for code execution
environment: Environment variables for execution

## Properties

<ResponseField name="sandbox" type="bool">
  No description available.
</ResponseField>

<ResponseField name="timeout" type="int">
  No description available.
</ResponseField>

<ResponseField name="allowed_languages" type="List">
  No description available.
</ResponseField>

<ResponseField name="max_output_length" type="int">
  No description available.
</ResponseField>

<ResponseField name="working_directory" type="Optional">
  No description available.
</ResponseField>

<ResponseField name="environment" type="Dict">
  No description available.
</ResponseField>

<Accordion title="Internal & Generic Methods">
  * **to\_dict**: Convert config to dictionary.
</Accordion>

## Source

<Card title="View on GitHub" icon="github" href="https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai-agents/praisonaiagents/agent/code_agent.py#L10">
  `praisonaiagents/agent/code_agent.py` at line 10
</Card>

***

## Related Documentation

<CardGroup cols={2}>
  <Card title="Configuration Overview" icon="gear" href="/docs/configuration/index" />

  <Card title="Agent Config" icon="robot" href="/docs/configuration/agent-config" />

  <Card title="Code Agent" icon="code" href="/docs/features/codeagent" />

  <Card title="Code Feature" icon="terminal" href="/docs/features/code" />
</CardGroup>
