> For the complete documentation index, see [llms.txt](https://eaclouddoc.eauditor.eu/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://eaclouddoc.eauditor.eu/eacloud-docs-en/features/it-management/tasks/scripts-and-script-groups.md).

# Scripts and script groups

## Creating a script

A script can contain multiple commands executed sequentially. This allows you to combine interdependent actions within a single task, such as checking the status of a computer, saving the result, and changing the configuration.

{% stepper %}
{% step %}
Go to **IT Management > Tasks**.
{% endstep %}

{% step %}
Click **+Add new script**.

<div align="left"><figure><img src="https://3262380731-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fdzip3GyvGq5q5J3qckWN%2Fuploads%2FzplvHvonE0UAQeVIRGb4%2Fimage.png?alt=media&amp;token=85b39dfa-30b6-4700-b155-d609a4621a1d" alt="+Dodaj nowy skrypt" width="375"><figcaption><p><em>+Add new script</em></p></figcaption></figure></div>
{% endstep %}

{% step %}
Enter the script name and select a script group.
{% endstep %}

{% step %}
Select a language: **PowerShell** or **CMD**.
{% endstep %}

{% step %}
Optionally, add a description that explains the purpose of the script.
{% endstep %}

{% step %}
Enter the script code and click **Create script**.
{% endstep %}
{% endstepper %}

<figure><img src="https://3262380731-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fdzip3GyvGq5q5J3qckWN%2Fuploads%2F0pC2HFYIqtSAohF7wTnJ%2Fimage.png?alt=media&amp;token=61b010b9-d8c4-4311-9853-169d7a015efd" alt="Tworzenie skryptu PowerShell wraz z wyborem grupy i języka." width="375"><figcaption><p><em>Creating a PowerShell script with group and language selection.</em></p></figcaption></figure>

### Generating and editing scripts by eA Intelligence

When creating a script, you can use the **Use eA Intelligence**. Describe what the script should do, and AI will prepare a code proposal in the selected language.

You can continue talking to AI, ask for corrections or code expansion. When the result is ready, click **Copy code** and paste it directly into the script editor.

Code generated by AI does not run automatically. Before saving and deploying it, the administrator should review it.

<figure><img src="https://3262380731-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fdzip3GyvGq5q5J3qckWN%2Fuploads%2FRVCCQ2ZTvFLiO1mcQLxY%2Fimage.png?alt=media&amp;token=1c53b852-5941-4bd1-aa06-e86b535b70ba" alt="Tworzenie i modyfikowanie skryptu za pomocą eA Intelligence." width="375"><figcaption><p><em>Creating and modifying a script using eA Intelligence.</em></p></figcaption></figure>

{% hint style="warning" %}
Test the script on a test computer before deploying it to a larger number of devices. Scripts can change system configuration, delete data, or affect application behavior.
{% endhint %}

### Script groups

Groups help keep the library organized, for example by separating administrative, diagnostic, security, or deployment scripts.

A group is not a task and does not run the scripts assigned to it. You select and run each script separately.

### FAQ

<details>

<summary>Can I edit a script generated by AI?</summary>

Yes. You can modify the code as needed before saving the script. additionally, you can ask AI to edit it.

<div align="left"><figure><img src="https://3262380731-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fdzip3GyvGq5q5J3qckWN%2Fuploads%2FivrMFurkUJ67MpUWUKS0%2Fimage.png?alt=media&amp;token=55fcb48b-b103-44d1-aa51-ce05490199b5" alt="Edycja skryptu przez AI." width="375"><figcaption><p><em>Editing a script by AI.</em></p></figcaption></figure></div>

</details>

<details>

<summary>Does AI automatically run the generated script?</summary>

No. The script will be executed only after it is saved and the task is created by the administrator.

</details>


---

# 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://eaclouddoc.eauditor.eu/eacloud-docs-en/features/it-management/tasks/scripts-and-script-groups.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.
