Répertorier les éléments supprimés (flux de travail de cycle de vie supprimés)
Article
Espace de noms: microsoft.graph
Importante
Les API sous la version /beta dans Microsoft Graph sont susceptibles d’être modifiées. L’utilisation de ces API dans des applications de production n’est pas prise en charge. Pour déterminer si une API est disponible dans v1.0, utilisez le sélecteur Version .
Obtenez la liste des objets de flux de travail supprimés et leurs propriétés.
Dans les scénarios délégués avec des comptes professionnels ou scolaires, l’utilisateur connecté doit se voir attribuer un rôle Microsoft Entra pris en charge ou un rôle personnalisé avec une autorisation de rôle prise en charge.
Lecteur général et Administrateur de flux de travail de cycle de vie sont les rôles les moins privilégiés pris en charge pour cette opération.
Requête HTTP
GET /identityGovernance/lifecycleWorkflows/deletedItems/workflows/
Paramètres facultatifs de la requête
Cette méthode prend en charge les $selectparamètres de requête , $search, $orderbyet $filter OData pour vous aider à personnaliser la réponse. Pour des informations générales, consultez paramètres de la requête OData.
GET https://graph.microsoft.com/beta/identityGovernance/lifecycleWorkflows/deletedItems/workflows
// Code snippets are only available for the latest version. Current version is 5.x
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.IdentityGovernance.LifecycleWorkflows.DeletedItems.Workflows.GetAsync();
// Code snippets are only available for the latest major version. Current major version is $v0.*
// Dependencies
import (
"context"
msgraphsdk "github.com/microsoftgraph/msgraph-beta-sdk-go"
//other-imports
)
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
workflows, err := graphClient.IdentityGovernance().LifecycleWorkflows().DeletedItems().Workflows().Get(context.Background(), nil)
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
com.microsoft.graph.models.identitygovernance.WorkflowCollectionResponse result = graphClient.identityGovernance().lifecycleWorkflows().deletedItems().workflows().get();
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph_beta import GraphServiceClient
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
result = await graph_client.identity_governance.lifecycle_workflows.deleted_items.workflows.get()
Remarque : l’objet de réponse affiché ci-après peut être raccourci pour plus de lisibilité.
HTTP/1.1 200 OK
Content-Type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#identityGovernance/lifecycleWorkflows/deletedItems/workflows",
"value": [
{
"category": "joiner",
"description": "Configure new hire tasks for onboarding employees on their first day",
"displayName": "US Onboard new hire employee",
"lastModifiedDateTime": "2022-08-24T18:25:09.4212828Z",
"createdDateTime": "2022-08-24T18:24:14.4067873Z",
"deletedDateTime": "2022-08-24T18:25:09.5729865Z",
"id": "f1937e0c-c509-4250-ab51-d5e6e35fcbda",
"version": 1
},
{
"category": "joiner",
"description": "Configure new hire tasks for onboarding employees on their first day",
"displayName": "EU Onboard new hire employee",
"lastModifiedDateTime": "2022-08-24T18:25:09.4050443Z",
"createdDateTime": "2022-08-24T18:24:40.0689833Z",
"deletedDateTime": "2022-08-24T18:25:09.5542954Z",
"id": "21d2c0fb-dcaa-4abb-88db-891d76c84e9a",
"version": 1
}
]
}
Exemple 2 : Récupérer des flux de travail supprimés pour les scénarios de « leaver » et retourner uniquement des propriétés spécifiques
GET https://graph.microsoft.com/beta/identityGovernance/lifecycleWorkflows/deletedItems/workflows?$select=id,category,displayName,description,version&$filter=category eq 'leaver'
// Code snippets are only available for the latest version. Current version is 5.x
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.IdentityGovernance.LifecycleWorkflows.DeletedItems.Workflows.GetAsync((requestConfiguration) =>
{
requestConfiguration.QueryParameters.Select = new string []{ "id","category","displayName","description","version" };
requestConfiguration.QueryParameters.Filter = "category eq 'leaver'";
});
// Code snippets are only available for the latest major version. Current major version is $v0.*
// Dependencies
import (
"context"
msgraphsdk "github.com/microsoftgraph/msgraph-beta-sdk-go"
graphidentitygovernance "github.com/microsoftgraph/msgraph-beta-sdk-go/identitygovernance"
//other-imports
)
requestFilter := "category eq 'leaver'"
requestParameters := &graphidentitygovernance.LifecycleWorkflowsDeletedItemsWorkflowsRequestBuilderGetQueryParameters{
Select: [] string {"id","category","displayName","description","version"},
Filter: &requestFilter,
}
configuration := &graphidentitygovernance.LifecycleWorkflowsDeletedItemsWorkflowsRequestBuilderGetRequestConfiguration{
QueryParameters: requestParameters,
}
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
workflows, err := graphClient.IdentityGovernance().LifecycleWorkflows().DeletedItems().Workflows().Get(context.Background(), configuration)
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
com.microsoft.graph.models.identitygovernance.WorkflowCollectionResponse result = graphClient.identityGovernance().lifecycleWorkflows().deletedItems().workflows().get(requestConfiguration -> {
requestConfiguration.queryParameters.select = new String []{"id", "category", "displayName", "description", "version"};
requestConfiguration.queryParameters.filter = "category eq 'leaver'";
});
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph_beta import GraphServiceClient
from msgraph_beta.generated.identity_governance.lifecycle_workflows.deleted_items.workflows.workflows_request_builder import WorkflowsRequestBuilder
from kiota_abstractions.base_request_configuration import RequestConfiguration
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
query_params = WorkflowsRequestBuilder.WorkflowsRequestBuilderGetQueryParameters(
select = ["id","category","displayName","description","version"],
filter = "category eq 'leaver'",
)
request_configuration = RequestConfiguration(
query_parameters = query_params,
)
result = await graph_client.identity_governance.lifecycle_workflows.deleted_items.workflows.get(request_configuration = request_configuration)