***
title: Add AI request blocks to your notebook
updated: 2026-02-20T00:00:00.000Z
slug: >-
docs/postman-api-network/showcase/publish/notebooks/draft/add-ai-request-blocks
max-toc-depth: 2
----------------
Add an AI chat interface to your notebook to create an interactive experience. For example, you can [add a request block](/docs/postman-api-network/showcase/publish/notebooks/draft/add-request-blocks/) and [reference its response](/docs/postman-api-network/showcase/publish/notebooks/draft/add-request-blocks#reference-your-request-block) to analyze it with an AI model of your choice.
You can also reference an AI request block's prompts and responses elsewhere in your notebook.
## Add an AI request block
To add an AI request block, do the following:
1. Open your notebook or [create a new one](https://www.postman.com/notebook/new).
2. Place your cursor where you want to add the AI request block. Then, enter a forward slash ("/"). Postman displays a block menu.
3. Choose
**AI Request**.
4. Name your AI request block.
5. Choose a model provider and model, and (optional) add an MCP server.
6. Add your API key.
7. Enter your user prompt.
8. (Optional) Click
**Settings**, enter your system prompt, and adjust your settings.
9. Click
**Send message**.
Postman adds your message and the model's response to the conversation.
## Reference your AI request block
Reference your AI request block by name. For example, if you name your AI request block "welcomeChatBot", you can reference its interactions with the syntax `{{welcomeChatBot}}` in text, an [input block](/docs/postman-api-network/showcase/publish/notebooks/draft/add-input-blocks/), a [request block](/docs/postman-api-network/showcase/publish/notebooks/draft/add-request-blocks/), or another AI request block.
Or you can reference it with the syntax `$welcomeChatBot` in a [script runner block](/docs/postman-api-network/showcase/publish/notebooks/draft/add-script-runner-blocks/).
Furthermore, you can use dot notation to reference data within the interactions. Each interaction is an object in an array, where each object represents a prompt or response. For example, in a request block, you can reference your first prompt with the syntax `{{welcomeChatBot.0}}`. Or in a script runner block, you can reference the same value with the syntax `$welcomeChatBot[0]`.
To reference your AI request block, do the following:
1. Open your notebook or [create a new one](https://www.postman.com/notebook/new).
2. Get your AI request block's name.
3. Reference your AI request block:
* To reference your AI request block in text, an input block, a request block, or another AI request block, use the syntax `{{aiRequestBlockName}}` or `{{aiRequestBlockName.path.to.data}}`.
* To reference your AI request block in a script runner block, use the syntax `$aiRequestBlockName` or `$aiRequestBlockName.path.to.data`.