orchestrator
2024.10
true
UiPath logo, featuring letters U and I in white

Guide de l'API Orchestrator

Automation CloudAutomation Cloud Public SectorAutomation SuiteStandalone
Dernière mise à jour 4 déc. 2024

[Aperçu] Mettre à jour un groupe

Récupère les informations relatives au groupe IAM spécifié.

Point de terminaison de l’API

PUT https://{yourDomain}/identity/api/Group/{groupId}

Étendues

Nécessite les étendues suivantes :

  • PM.Group
  • PM.Group.Write

En-têtes de requête.

--header 'Authorization: Bearer {access_token}'\
--header 'Content-Type: application/json'--header 'Authorization: Bearer {access_token}'\
--header 'Content-Type: application/json'
Remarque : pour obtenir le {access_token}, assurez-vous de vous authentifier via l'une des méthodes décrites ici.

Paramètres de chemin d'accès

Param

Type de données

Description

groupId

(requis)

Chaîne de caractères (string)

L'ID du groupe que vous souhaitez mettre à jour.

Corps de la requête

Le corps de la demande contient l'ID de l'organisation à laquelle appartient le groupe et les informations que vous souhaitez mettre à jour, telles que le nom du groupe et les adhésions.

{
  "partitionGlobalId": "string",
  "name": "string",
  "directoryUserIDsToAdd": [
    "string"
  ],
  "directoryUserIDsToRemove": [
    "string"
  ]
}{
  "partitionGlobalId": "string",
  "name": "string",
  "directoryUserIDsToAdd": [
    "string"
  ],
  "directoryUserIDsToRemove": [
    "string"
  ]
}

Réponses

200 OK

Le groupe personnalisé est mis à jour avec les informations que vous avez fournies.

Exemple de requête

Supposons que vous ayez rassemblé toutes les informations nécessaires pour créer l'appel d'API.

  • Votre {baseURL} est : https://{yourDomain}/{organizationName}/{tenantName}
  • Votre {access_token} est : 1234 (pour des considérations de longueur).
  • Le {partitionGlobalId} est : magic-7
  • Vous conservez le nom du groupe tel quel.
  • Vous souhaitez ajouter les utilisateurs Luna et Neville au groupe. Ces utilisateurs ont les ID utilisateur suivants :

    • Identifiant utilisateur Luna : lun-1302
    • Identifiant utilisateur Neville : nev-3007

L’appel devrait ressembler à l'exemple ci-dessous (cURL) :

curl --location --request PUT 'https://{yourDomain}/{organizationName}/{tenantName}/identity_/api/Group/magic-7/gryff-01' \
--header 'Authorization: Bearer 1234' \
--header 'Content-Type: application/json'
--data-raw '{
    "partitionGlobalId": "magic-7",
    "name": "Gryffindors",
    "directoryUserIDsToAdd": [
        "lun-1302", "nev-3007"
    ],
    "directoryUserIDsToRemove": []
}'curl --location --request PUT 'https://{yourDomain}/{organizationName}/{tenantName}/identity_/api/Group/magic-7/gryff-01' \
--header 'Authorization: Bearer 1234' \
--header 'Content-Type: application/json'
--data-raw '{
    "partitionGlobalId": "magic-7",
    "name": "Gryffindors",
    "directoryUserIDsToAdd": [
        "lun-1302", "nev-3007"
    ],
    "directoryUserIDsToRemove": []
}'

Voici la réponse pour un appel réussi :

{
    "id": "gryff-01",
    "name": "Gryffindors",
    "displayName": "Gryffindors",
    "type": 1,
    "creationTime": "2021-10-19T15:37:49.1853184",
    "lastModificationTime": "2021-10-19T16:46:20.0742901",
    "members": [
        {
            "objectType": "DirectoryUser",
            "firstName": "Hermione",
            "lastName": "Granger",
            "jobTitle": "student",
            "companyName": "Hogwarts",
            "city": "London",
            "department": "magic",
            "displayName": "Hermione Granger",
            "source": "local",
            "identifier": "her-1909",
            "name": "Hermione",
            "email": "hermione@hogwarts.com"
        },
        {
            "objectType": "DirectoryUser",
            "firstName": "Harry",
            "lastName": "Potter",
            "jobTitle": ""student"",
            "companyName": "Hogwarts",
            "city": "London",
            "department": "magic",
            "displayName": "Harry Potter",
            "source": "local",
            "identifier": "har-3107",
            "name": "Harry",
            "email": "harry@hogwarts.com"
        },
        {
            "objectType": "DirectoryUser",
            "firstName": "Luna",
            "lastName": "Lovegood",
            "jobTitle": "student",
            "companyName": "Hogwarts",
            "city": "London",
            "department": "magic",
            "displayName": "Luna Lovegood",
            "source": "local",
            "identifier": "lun-1302",
            "name": "Luna",
            "email": "luna@hogwarts.com"
        },      
        {
            "objectType": "DirectoryUser",
            "firstName": "Ron",
            "lastName": "Weasley",
            "jobTitle": "student",
            "companyName": "Hogwarts",
            "city": "London",
            "department": "magic",
            "displayName": "Ron Weasley",
            "source": "local",
            "identifier": "ron-0103",
            "name": "Ron",
            "email": "ron@hogwarts.com"
        },
        {
            "objectType": "DirectoryUser",
            "firstName": "Neville",
            "lastName": "Longbottom",
            "jobTitle": "student",
            "companyName": "Hogwarts",
            "city": "London",
            "department": "magic",
            "displayName": "Neville Longbottom",
            "source": "local",
            "identifier": "nev-3007",
            "name": "Neville",
            "email": "neville@hogwarts.com"
        }      
    ]
}{
    "id": "gryff-01",
    "name": "Gryffindors",
    "displayName": "Gryffindors",
    "type": 1,
    "creationTime": "2021-10-19T15:37:49.1853184",
    "lastModificationTime": "2021-10-19T16:46:20.0742901",
    "members": [
        {
            "objectType": "DirectoryUser",
            "firstName": "Hermione",
            "lastName": "Granger",
            "jobTitle": "student",
            "companyName": "Hogwarts",
            "city": "London",
            "department": "magic",
            "displayName": "Hermione Granger",
            "source": "local",
            "identifier": "her-1909",
            "name": "Hermione",
            "email": "hermione@hogwarts.com"
        },
        {
            "objectType": "DirectoryUser",
            "firstName": "Harry",
            "lastName": "Potter",
            "jobTitle": ""student"",
            "companyName": "Hogwarts",
            "city": "London",
            "department": "magic",
            "displayName": "Harry Potter",
            "source": "local",
            "identifier": "har-3107",
            "name": "Harry",
            "email": "harry@hogwarts.com"
        },
        {
            "objectType": "DirectoryUser",
            "firstName": "Luna",
            "lastName": "Lovegood",
            "jobTitle": "student",
            "companyName": "Hogwarts",
            "city": "London",
            "department": "magic",
            "displayName": "Luna Lovegood",
            "source": "local",
            "identifier": "lun-1302",
            "name": "Luna",
            "email": "luna@hogwarts.com"
        },      
        {
            "objectType": "DirectoryUser",
            "firstName": "Ron",
            "lastName": "Weasley",
            "jobTitle": "student",
            "companyName": "Hogwarts",
            "city": "London",
            "department": "magic",
            "displayName": "Ron Weasley",
            "source": "local",
            "identifier": "ron-0103",
            "name": "Ron",
            "email": "ron@hogwarts.com"
        },
        {
            "objectType": "DirectoryUser",
            "firstName": "Neville",
            "lastName": "Longbottom",
            "jobTitle": "student",
            "companyName": "Hogwarts",
            "city": "London",
            "department": "magic",
            "displayName": "Neville Longbottom",
            "source": "local",
            "identifier": "nev-3007",
            "name": "Neville",
            "email": "neville@hogwarts.com"
        }      
    ]
}

Cette page vous a-t-elle été utile ?

Obtenez l'aide dont vous avez besoin
Formation RPA - Cours d'automatisation
Forum de la communauté UiPath
Uipath Logo White
Confiance et sécurité
© 2005-2024 UiPath Tous droits réservés.