Skip to main content
The Claude Agent SDK gives you tool use, conversation memory, and streaming out of the box. Combined with Superserve’s durable workspace, the agent retains full context across turns - files it creates persist, and conversation history survives sandbox restarts.
import asyncio
from claude_agent_sdk import ClaudeAgentOptions, ClaudeSDKClient, TextBlock

options = ClaudeAgentOptions(
    model="sonnet",
    system_prompt="You are a helpful assistant.",
    permission_mode="bypassPermissions",
    continue_conversation=True,
)

async def main():
    async with ClaudeSDKClient(options=options) as client:
        while True:
            try:
                user_input = input()
            except EOFError:
                break
            await client.query(prompt=user_input)
            async for msg in client.receive_response():
                for block in getattr(msg, "content", []):
                    if isinstance(block, TextBlock):
                        print(block.text)

asyncio.run(main())
claude-agent-sdk
superserve deploy agent.py     # or agent.ts
superserve secrets set my-agent ANTHROPIC_API_KEY=sk-ant-...
superserve run my-agent
The continue_conversation option enables conversation memory across turns. Combined with Superserve’s workspace persistence, the agent has full context even after the sandbox restarts.

See the full example in Python or TypeScript. Integrate deployed agents into your apps using the Superserve SDK.