コンテンツにジャンプ

Getting Started

インストール

Installのセクション
ターミナル画面
bun add @capgo/capacitor-intune
bunx cap sync
import { IntuneMAM } from '@capgo/capacitor-intune';

Microsoftサインインフローを表示し、承認トークンとアカウントメタデータを返します。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.acquireToken({} as AcquireTokenOptions);

MSAL キャッシュから前回サインインしたユーザーからトークンを取得します。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.acquireTokenSilent({} as AcquireTokenSilentOptions);

Intuneと連携して前回認証済みのアカウントを登録し、エンロールを開始します。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.registerAndEnrollAccount({} as RegisterAndEnrollAccountOptions);

Intuneに認証とエンロールを要求する前にアプリトークンを要求せずにユーザーをエンロールするように求めます。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.loginAndEnrollAccount();

現在利用可能なIntuneアカウントを返します。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.enrolledAccount();

アカウントを Intune から削除し、適切な場合に選択的な削除をトリガーします。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.deRegisterAndUnenrollAccount({} as IntuneMAMUser);

MSAL からユーザーをサインアウトすることなく、Intune アカウントをアンインストールせずにします。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.logoutOfAccount({} as IntuneMAMUser);

管理されたアカウントの Intune アプリのリモート設定を取得します。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.appConfig({} as IntuneMAMUser);

管理されたアカウントの Intune アプリ保護ポリシーを取得します。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.getPolicy({} as IntuneMAMUser);

便利なヘルパーが、値が存在する場合の GroupName アプリの設定値を解決します。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.groupName({} as IntuneMAMUser);

このプラグインによってバンドルされたネイティブのIntuneとMSAL SDK バージョンを返します。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.sdkVersion();

ネイティブのIntune診断UIを表示します。

import { IntuneMAM } from '@capgo/capacitor-intune';
await IntuneMAM.displayDiagnosticConsole();

Interactive token acquisition options.

export interface AcquireTokenOptions {
/**
* Scopes to request, for example `https://graph.microsoft.com/.default`.
*/
scopes: string[];
/**
* When true, always show the Microsoft account picker or sign-in UI.
*
* @default false
*/
forcePrompt?: boolean;
/**
* Optional login hint for the interactive sign-in flow.
*/
loginHint?: string;
}

IntuneMAMAcquireToken

IntuneMAMAcquireToken
export interface IntuneMAMAcquireToken {
accountId: string;
accessToken: string;
accountIdentifier: string;
idToken?: string;
username?: string;
tenantId?: string;
authority?: string;
}

AcquireTokenSilentOptions

AcquireTokenSilentOptions

__CAPGO_KEEP_0__

export interface AcquireTokenSilentOptions {
/**
* Scopes to request, for example `https://graph.microsoft.com/.default`.
*/
scopes: string[];
/**
* Microsoft Entra object ID returned by `acquireToken` or `enrolledAccount`.
*/
accountId: string;
/**
* When true, bypass the cached access token and request a fresh one.
*
* @default false
*/
forceRefresh?: boolean;
}

RegisterAndEnrollAccountOptions

__CAPGO_KEEP_0__
export interface RegisterAndEnrollAccountOptions {
/**
* Microsoft Entra object ID returned by `acquireToken`.
*/
accountId: string;
}

IntuneMAMUser

__CAPGO_KEEP_0__
export interface IntuneMAMUser {
accountId: string;
accountIdentifier?: string;
username?: string;
tenantId?: string;
authority?: string;
}

IntuneMAMAppConfig

__CAPGO_KEEP_0__
export interface IntuneMAMAppConfig {
accountId: string;
fullData: Record<string, string>[];
values: Record<string, string>;
conflicts: string[];
}
export interface IntuneMAMPolicy {
accountId: string;
isPinRequired?: boolean;
isManagedBrowserRequired?: boolean;
isScreenCaptureAllowed?: boolean;
isContactSyncAllowed?: boolean;
isAppSharingAllowed?: boolean;
isFileEncryptionRequired?: boolean;
notificationPolicy?: string;
}
export interface IntuneMAMGroupName {
accountId: string;
groupName?: string;
}
export interface IntuneMAMVersionInfo {
platform: 'ios' | 'android';
intuneSdkVersion: string;
msalVersion?: string;
}
export interface IntuneMAMChangeEvent {
accountId?: string;
}

このページはプラグインから生成されています src/definitions.ts. upstream の API が変更されたときに、再度 sync を実行してください。

Getting Started から続けてください。

Getting Started から続けてください。

「Getting Started から続けてください。」というセクションがあります。 Capgo を使用している場合、 Capgo を使用してダッシュボードと API の操作を計画する場合、 Capacitor のネイティブ機能を使用するには、@capgo/capacitor-intune を使用してください。 Capacitor のネイティブ機能を使用するには、@capgo/capacitor-intune を使用してください。 API の概要 API の実装詳細については、API Overview を参照してください。 __CAPGO_KEEP_0__ の実装詳細については、__CAPGO_KEEP_0__ Overview を参照してください。 Capacitor の概要 API キー API キーに関する実装詳細、そして デバイス デバイスに関する実装詳細、そして