> For the complete documentation index, see [llms.txt](https://docs.devolutions.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.devolutions.net/powershell-universal/fr/get-started.md).

# Démarrage

## Installer PowerShell Universal

Vous devez installer le serveur PowerShell Universal. [Il existe plusieurs façons de le faire,](/powershell-universal/fr/getting-started.md) mais vous pouvez utiliser la ligne de commande ci-dessous pour démarrer rapidement :

{% tabs %}
{% tab title="Windows" %}
Vous pouvez installer PowerShell Universal en tant que service. Assurez-vous que PowerShell s'exécute en tant qu'administrateur, sinon le service ne s'installera pas correctement.

```powershell
Install-Module Devolutions.PowerShellUniversal
Install-PSUServer
```

{% endtab %}

{% tab title="Linux" %}
Vous pouvez installer PowerShell Universal à l'aide du script shell suivant :

```powershell
Install-Module Devolutions.PowerShellUniversal
Install-PSUServer
```

{% endtab %}

{% tab title="Mac OS X" %}
Vous pouvez installer PowerShell Universal à l'aide du module Universal PowerShell :

```powershell
Install-Module Devolutions.PowerShellUniversal
Install-PSUServer -AddToPath
Start-PSUServer -Port 5000
```

{% endtab %}

{% tab title="Raspberry PI OS" %}

```
wget https://imsreleases.blob.core.windows.net/universal/production/2.4.0/Universal.linux-arm.2.4.0.zip
unzip Universal.linux-arm.2.3.2.zip -d ./PSU
chmod +x ./PSU/Universal.Server
./PSU/Universal.Server

```

{% endtab %}
{% endtabs %}

## Ouvrir PowerShell Universal

Par défaut, PowerShell Universal s'exécute sur le port 5000 de localhost. Ouvrez un navigateur web et accédez à `http://localhost:5000`.

### Se connecter avec un compte Devolutions

La première fois que vous accédez à PowerShell Universal, vous pouvez vous connecter avec un [compte Devolutions](https://docs.devolutions.net/fr/portal/profile/create-devolutions-account/) afin de recevoir une licence développeur gratuite. Cette licence active toutes les fonctionnalités et est destinée aux flux de travail hors production.

Ce processus de licence développeur est conçu pour le développement local et nécessite un accès local à l'hôte PowerShell Universal. Si les utilisateurs accèdent à PSU uniquement depuis des navigateurs distants via Docker, IIS ou un proxy inverse, ils doivent plutôt utiliser l'un des parcours de licence standard.

### Assistant de première exécution

Vous pouvez également choisir d'exécuter l'assistant de configuration de première exécution au lieu de vous connecter avec un compte Devolutions et de fournir une clé de licence.

## Créer une API

Les API vous permettent d'appeler des scripts PowerShell via HTTP. Pour créer une API, cliquez sur API \ Points de terminaison, puis sur Créer un nouveau point de terminaison. Spécifiez une URL. Désactivez l'authentification pour ce point de terminaison.

Ensuite, cliquez sur Détails sur votre nouvelle API et entrez la commande suivante dans l'éditeur :

```powershell
Get-ComputerInfo
```

Enregistrez le script, puis cliquez sur le bouton Exécuter pour le tester.

Vous pouvez également exécuter l'API via `Invoke-RestMethod`.

```powershell
PS C:\Users\adamr> Invoke-RestMethod http://localhost:5000/hello-world

WindowsBuildLabEx                                       : 22000.1.amd64fre.co_release.210604-1628
WindowsCurrentVersion                                   : 6.3
WindowsEditionId                                        : Professional
WindowsInstallationType                                 : Client
WindowsInstallDateFromRegistry                          : 8/6/2021 4:05:12 PM
WindowsProductId                                        : 00330-52452-93139-AAOEM
WindowsProductName                                      : Windows 10 Pro
WindowsRegisteredOrganization                           :
```

## Créer un script

Pour créer un script, cliquez sur Automation \ Scripts, puis sur Créer un nouveau script.

Entrez le script suivant dans l'éditeur et enregistrez :

```powershell
Read-Host "What should I say?"

1..100 | ForEach-Object {
    Write-Progress -PercentComplete $_ -Activity "Processing..."
}

Get-Service
```

Une fois le script enregistré, cliquez sur Exécuter.

## Créer une application

Pour créer une nouvelle interface utilisateur basée sur PowerShell (application), vous pouvez cliquer sur Interfaces utilisateur \ Applications, puis sur Créer une nouvelle application.

Après avoir cliqué sur Ok, cliquez sur le bouton Détails pour modifier le script PowerShell. Ajoutez le script suivant dans l'éditeur :

```powershell
New-UDApp -Title "Hello, World!" -Content {
    New-UDButton -Text "Click Me" -OnClick {
        Show-UDToast -Message 'Success!!'
    }
}
```

Enregistrez l'application, cliquez sur le bouton Redémarrer, puis sur le bouton Afficher. Cliquez sur le bouton Click Me.

Pour en savoir plus sur les différentes fonctionnalités de PowerShell Universal :

* [APIs](/powershell-universal/fr/api/about.md)
* [Automation](/powershell-universal/fr/automation/about.md)
* [Applications](/powershell-universal/fr/apps/building-dashboards.md)


---

# 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:

```
GET https://docs.devolutions.net/powershell-universal/fr/get-started.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
