getPrompt

View as MarkdownOpen in Claude

Retrieve the fully rendered main prompt text. Returns the assembled prompt string from either setPromptText() or POM sections.

Parameters

None.

Returns

string — The assembled prompt string.

Example

1import { AgentBase } from '@signalwire/sdk';
2
3const agent = new AgentBase({ name: 'support', route: '/support' });
4agent.setPromptText('You are a customer support agent for Acme Corp.');
5const prompt = agent.getPrompt();
6console.log(prompt);