名前空間: microsoft.graph
重要
Microsoft Graph の /beta
バージョンの API は変更される可能性があります。 実稼働アプリケーションでこれらの API を使用することは、サポートされていません。 v1.0 で API を使用できるかどうかを確認するには、Version セレクターを使用します。
ユーザーが、指定した期間中にMicrosoft Entra MFA クラウド サービスを使用して対話型 MFA サインインを正常に完了した回数を取得します。
アクセス許可
この API の最小特権としてマークされているアクセス許可またはアクセス許可を選択します。
アプリで必要な場合にのみ、より高い特権のアクセス許可またはアクセス許可を使用します。 委任されたアクセス許可とアプリケーションのアクセス許可の詳細については、「アクセス許可の種類」を参照してください。 これらのアクセス許可の詳細については、「アクセス許可のリファレンス」を参照してください。
アクセス許可の種類 |
最小特権アクセス許可 |
より高い特権のアクセス許可 |
委任 (職場または学校のアカウント) |
Reports.Read.All |
注意事項なし。 |
委任 (個人用 Microsoft アカウント) |
サポートされていません。 |
サポートされていません。 |
アプリケーション |
Reports.Read.All |
注意事項なし。 |
重要
職場または学校アカウントを使用した委任されたシナリオでは、サインインしているユーザーに、サポートされているMicrosoft Entraロールまたはサポートされているロールのアクセス許可を持つカスタム ロールを割り当てる必要があります。 この操作では、次の最小特権ロールがサポートされています。
- グローバル閲覧者
- レポート閲覧者
- セキュリティ閲覧者
- セキュリティ管理者
- セキュリティ オペレーター
HTTP 要求
GET /reports/serviceActivity/getMetricsForMfaSignInSuccess
関数パラメーター
要求 URL で、次のクエリ パラメーターに値を指定します。
パラメーター |
型 |
説明 |
inclusiveIntervalStartDateTime |
DateTimeOffset |
開始時刻を UTC で設定します。 許可される最も早い開始時刻は、過去 30 日間です。 必須です。 |
exclusiveIntervalEndDateTime |
DateTimeOffset |
終了日時を UTC で設定します。 必須です。 |
aggregationIntervalInMinutes |
Int32 |
集計間隔 (分単位)。 既定値は 15 で、集計するデータを 15 分セットに設定します。 使用できる値は 5、10、15、30 です。 オプション。 |
名前 |
説明 |
Authorization |
ベアラー {token}。 必須です。
認証と認可についての詳細をご覧ください。 |
要求本文
このメソッドには、要求本文を指定しません。
応答
成功した場合、この関数は応答コード 200 OK
と、応答本文に serviceActivityValueMetric コレクションを返します。
例
要求
次の例は要求を示しています。
GET https://graph.microsoft.com/beta/reports/serviceActivity/getMetricsForMfaSignInSuccess(inclusiveIntervalStartDateTime=2023-01-01T00:00:00Z,exclusiveIntervalEndDateTime=2023-01-01T00:20:00Z,aggregationIntervalInMinutes=10)
// 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.Reports.ServiceActivity.GetMetricsForMfaSignInSuccessWithInclusiveIntervalStartDateTimeWithExclusiveIntervalEndDateTime(DateTimeOffset.Parse("{exclusiveIntervalEndDateTime}"),DateTimeOffset.Parse("{inclusiveIntervalStartDateTime}")).GetAsGetMetricsForMfaSignInSuccessWithInclusiveIntervalStartDateTimeWithExclusiveIntervalEndDateTimeGetResponseAsync();
mgc-beta reports service-activity get-metrics-for-mfa-sign-in-success(inclusive-interval-start-date-time={inclusive-interval-start-date-time},exclusive-interval-end-date-time={exclusive-interval-end-date-time},aggregation-interval-in-minutes=@aggregation-interval-in-minutes) get
// 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
inclusiveIntervalStartDateTime , err := time.Parse(time.RFC3339, "{inclusiveIntervalStartDateTime}")
exclusiveIntervalEndDateTime , err := time.Parse(time.RFC3339, "{exclusiveIntervalEndDateTime}")
getMetricsForMfaSignInSuccess, err := graphClient.Reports().ServiceActivity().GetMetricsForMfaSignInSuccessWithInclusiveIntervalStartDateTimeWithExclusiveIntervalEndDateTimeWithAggregationIntervalInMinutes(&inclusiveIntervalStartDateTime, &exclusiveIntervalEndDateTime, &aggregationIntervalInMinutes).GetAsGetMetricsForMfaSignInSuccessWithInclusiveIntervalStartDateTimeWithExclusiveIntervalEndDateTimeGetResponse(context.Background(), nil)
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
var result = graphClient.reports().serviceActivity().getMetricsForMfaSignInSuccessWithInclusiveIntervalStartDateTimeWithExclusiveIntervalEndDateTime(OffsetDateTime.parse("{exclusiveIntervalEndDateTime}"), OffsetDateTime.parse("{inclusiveIntervalStartDateTime}")).get();
const options = {
authProvider,
};
const client = Client.init(options);
let getMetricsForMfaSignInSuccess = await client.api('/reports/serviceActivity/getMetricsForMfaSignInSuccess(inclusiveIntervalStartDateTime=2023-01-01T00:00:00Z,exclusiveIntervalEndDateTime=2023-01-01T00:20:00Z,aggregationIntervalInMinutes=10)')
.version('beta')
.get();
<?php
use Microsoft\Graph\Beta\GraphServiceClient;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$result = $graphServiceClient->reports()->serviceActivity()->getMetricsForMfaSignInSuccessWithInclusiveIntervalStartDateTimeWithExclusiveIntervalEndDateTime(new \DateTime('{exclusiveIntervalEndDateTime}'),new \DateTime('{inclusiveIntervalStartDateTime}'))->get()->wait();
Import-Module Microsoft.Graph.Beta.Reports
Get-MgBetaReportServiceActivityMetricForMfaSignInSuccess
# 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.reports.service_activity.get_metrics_for_mfa_sign_in_success_with_inclusive_interval_start_date_time_with_exclusive_interval_end_date_time("{exclusiveIntervalEndDateTime}","{inclusiveIntervalStartDateTime}").get()
応答
次の例は応答を示しています。
注: ここに示す応答オブジェクトは、読みやすさのために短縮されている場合があります。
HTTP/1.1 200 OK
Content-Type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/networkAccess/reports/$metadata#Collection(serviceActivityValueMetric)",
"value": [
{
"intervalStartDateTime": "2023-01-10T00:00:00Z",
"value": 4
},
{
"intervalStartDateTime": "2023-01-10T00:10:00Z",
"value": 5
},
{
"intervalStartDateTime": "2023-01-10T00:20:00Z",
"value": 4
}
]
}