---
sourceDocument: Australia Conversational Interfaces
sourceDocumentLink: https://servicenow-prod.fluidtopics.net/r/pt-BR/conversational-interfaces

 Release :

    - australia

ft:locale :

    - pt-BR

ft:publication_title :

    - Australia Conversational Interfaces

ft:clusterId :

    - convint

bundleId :

    - convint

workflow :

    - Platform


---

# Define script variables for a topic

# Define script variables for a topic {#ariaid-title1}

* Versão de lançamento: Australia
* 
* Atualizado 12 de mar. de 2026
* 
* ![](https://www.servicenow.com/docs/portal-asset/ico-clock) 1 min. de leitura

Use the Variables sidebar to define script variables for a topic. Script variables
can store information that is not found in ServiceNow tables. This
information can then be shared elsewhere in a topic.

## Antes de Iniciar

Role required: virtual_agent_admin or admin

## Por Que e Quando Desempenhar Esta Tarefa

For more information about writing scripts for Virtual Agent, see
[Virtual Agent scripts](https://servicenow-prod.fluidtopics.net/UFTvUOoRHO36gwRPq2A48Q "Use ServiceNow Virtual Agent script methods and variables to write chat scripts, such as response, trigger, and flow scripts. Variables can also provide context for your live support topics and conversations.").

## Procedimento

1. Navigate to AllConversational InterfacesVirtual AgentDesigner.
2. On the home page, open an existing topic or create a new one.  
   The Flow tab displays the conversation flow.
3. In the sidebar, select the Variables tab, then select the Script plus ![Script plus icon.]() icon.
4. On the form, fill in the fields.  
   {#define-script-variables-topic__table_ghd_yyk_12b__entry__2}

   | Field | Description |
   |-|-|
   | Variable name | Name of the variable. The name is case-sensitive. Spaces in the name are replaced with an underscore character. |
   | Default value | Default value for the variable. You can use either a static value or a script that specifies a dynamic value for this variable. |
   [Tabela 1. Add Script Variable dialog box]

   {#define-script-variables-topic__table_ghd_yyk_12b}
5. Select Save.

