> For the complete documentation index, see [llms.txt](https://cortex-docs.paloaltonetworks.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cortex-docs.paloaltonetworks.com/python-development-quick-start-guide/cortex-xsoar-python-development-quick-start-guide/development-tools-and-resources/cortex-xsoar-automation-scripts.md).

# Cortex XSOAR Automation Scripts

Automations are located in the Cortex XSOAR console on the left menu sidebar. You can filter by **Author** and sort the automations list.

![cortex-xsoar-automations.png](/files/aBu1g5RixALgF2iTAV3v)

Selecting an automation brings up the code in the right panel. For example, for the **`AddEvidence`** automation script:

![cortex-xsoar-addevidence-automation.png](/files/I7TYTqfb1OpzwCKzG6sp)

Selecting the **+New Automation** button brings up boilerplate code that can be deleted and replaced with a simpler template.

![cortex-xssoar-automation-template.png](/files/nd0nZPHiGud6JhP6luIa)

Select the **Script Helper** button to display two tabs: **API DOCS** and **HOW TO**.  The  **API DOCS** tab provides reference documentation for each automation, and the **HOW TO**  tab has code examples. In the **API DOCS** tab, the **Showing only** link has two options, **Commands** and **Scripts**, for the two types of automation in Cortex XSOAR.&#x20;

Commands are automations executed by the Cortex XSOAR server or integration and follow the camel case naming convention (commandAutomationName). Script automation names are title case (ScriptAutomationName) and are associated with playbook tasks and fields.

![cortex-xsoar-automation-script-helper.png](/files/PxUxSbZQxosioQVjJBmX)

The **API DOCS** tab shows the arguments for each script or command. Select **Copy to Script** to insert the automation command template into an automation. The **HOW TO** tab provides brief code examples for a number of scripts and commands.

![cortex-xsoar-automation-api-docs-tab.png](/files/nELeA3ADQHRf0KZkgt8K)

#### Automation Conventions

Automations use these conventions to ease readability:

* Python functions are in blue.
* Variables and other Python syntax are in black.
* Cortex XSOAR functions are in green.
* Cortex XSOAR literals when used in functions are in purple.
* Dictionary keys use single quotes.
* All other strings use double quotes.

For example:

![cortex-xsoar-python-code-example.png](/files/TaaPNa3n9OuB49qLKv1T)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://cortex-docs.paloaltonetworks.com/python-development-quick-start-guide/cortex-xsoar-python-development-quick-start-guide/development-tools-and-resources/cortex-xsoar-automation-scripts.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
