> Fetch clean Markdown by appending `.md` to any page URL under https://signalwire.com/docs or requesting it with the HTTP header `Accept: text/markdown`. The root index at https://signalwire.com/docs/llms.txt lists the available documentation indexes. # promptHasSection > Check whether a named section exists in the agent's prompt. [prompt-add-section]: /docs/server-sdks/reference/typescript/agents/agent-base/prompt-add-section Check whether a named section already exists in the agent's POM (Prompt Object Model) prompt. Useful for conditionally adding content to avoid duplicate sections. ## **Parameters** **`title`** `string` — required The section title to look up. Must match the title passed to [`promptAddSection()`][prompt-add-section]. --- ## **Returns** `boolean` -- `true` if a section with the given title exists, `false` otherwise. ## **Example** ```typescript {6} import { AgentBase } from '@signalwire/sdk'; const agent = new AgentBase({ name: 'assistant', route: '/assistant' }); agent.promptAddSection('Greeting', { body: 'Always greet the caller by name.' }); if (!agent.promptHasSection('Policies')) { agent.promptAddSection('Policies', { body: 'Follow company guidelines.' }); } await agent.serve(); ``` > Check whether a named section exists in the agent's prompt.