Créer managedDeviceCertificateState
Espace de noms: microsoft.graph
Important: Les API Microsoft Graph sous la version /beta sont susceptibles d’être modifiées ; l’utilisation de production n’est pas prise en charge.
Remarque : l’API Microsoft Graph pour Intune requiert une licence Intune active pour le client.
Créez un objet managedDeviceCertificateState .
Cette API est disponible dans les déploiements de cloud national suivants.
Service global | Gouvernement des États-Unis L4 | Us Government L5 (DOD) | Chine gérée par 21Vianet |
---|---|---|---|
✅ | ✅ | ✅ | ✅ |
Autorisations
L’une des autorisations suivantes est nécessaire pour appeler cette API. Pour plus d’informations, notamment sur la façon de choisir les autorisations, voir Autorisations.
Type d’autorisation | Autorisations (de celle qui offre le plus de privilèges à celle qui en offre le moins) |
---|---|
Déléguée (compte professionnel ou scolaire) | DeviceManagementConfiguration.ReadWrite.All |
Déléguée (compte Microsoft personnel) | Non prise en charge. |
Application | DeviceManagementConfiguration.ReadWrite.All |
Requête HTTP
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.iosPkcsCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.iosScepCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.androidPkcsCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.androidScepCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.iosImportedPFXCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.androidImportedPFXCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.aospDeviceOwnerPkcsCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.aospDeviceOwnerScepCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.androidDeviceOwnerPkcsCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.androidDeviceOwnerScepCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.androidWorkProfilePkcsCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.androidWorkProfileScepCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.androidForWorkImportedPFXCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.androidDeviceOwnerImportedPFXCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/identityCertificate/microsoft.graph.androidForWorkPkcsCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/identityCertificate/microsoft.graph.androidForWorkScepCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.windowsPhone81VpnConfiguration/identityCertificate/microsoft.graph.windowsPhone81SCEPCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.macOSWiredNetworkConfiguration/identityCertificateForClientAuthentication/microsoft.graph.macOSPkcsCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.macOSWiredNetworkConfiguration/identityCertificateForClientAuthentication/microsoft.graph.macOSScepCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.macOSWiredNetworkConfiguration/identityCertificateForClientAuthentication/microsoft.graph.macOSImportedPFXCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.windowsWifiEnterpriseEAPConfiguration/identityCertificateForClientAuthentication/microsoft.graph.windows10PkcsCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.windowsWifiEnterpriseEAPConfiguration/identityCertificateForClientAuthentication/microsoft.graph.windows81SCEPCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.windowsWifiEnterpriseEAPConfiguration/identityCertificateForClientAuthentication/microsoft.graph.windows10ImportedPFXCertificateProfile/managedDeviceCertificateStates
POST /deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.windowsWifiEnterpriseEAPConfiguration/identityCertificateForClientAuthentication/microsoft.graph.windowsPhone81ImportedPFXCertificateProfile/managedDeviceCertificateStates
En-têtes de demande
En-tête | Valeur |
---|---|
Autorisation | Porteur {token}. Obligatoire. En savoir plus sur l’authentification et l’autorisation. |
Accepter | application/json |
Corps de la demande
Dans le corps de la demande, fournissez une représentation JSON pour l’objet managedDeviceCertificateState.
Le tableau suivant indique les propriétés requises lorsque vous créez l’objet managedDeviceCertificateState.
Propriété | Type | Description |
---|---|---|
id | String | Clé de l’entité. |
devicePlatform | devicePlatformType | Plateforme de l’appareil. Les valeurs possibles sont , android , iOS androidForWork , macOS , windowsPhone81 , windows81AndLater , windows10AndLater androidWorkProfile , unknown , androidAOSP , , androidMobileApplicationManagement , iOSMobileApplicationManagement , unknownFutureValue . windowsMobileApplicationManagement |
certificateKeyUsage | keyUsages | Utilisation de la clé. Les valeurs possibles sont les suivantes : keyEncipherment , digitalSignature . |
certificateValidityPeriodUnits | certificateValidityPeriodScale | Unités de période de validité. Les valeurs possibles sont days , months et years . |
certificateIssuanceState | certificateIssuanceStates | État d’émission. Les valeurs possibles sont : unknown , challengeIssued , challengeIssueFailed , requestCreationFailed , challengeValidationSucceeded requestSubmitFailed , challengeValidationFailed issuePending issueFailed issued , enrollmentSucceeded enrollmentNotNeeded revoked renewVerified responseProcessingFailed responsePending removedFromCollection , installFailed installed , . requested deleteFailed deleted renewalRequested |
certificateKeyStorageProvider | keyStorageProviderOption | Fournisseur de stockage de clés. Les valeurs possibles sont les suivantes : useTpmKspOtherwiseUseSoftwareKsp , useTpmKspOtherwiseFail , usePassportForWorkKspOtherwiseFail , useSoftwareKsp . |
certificateSubjectNameFormat | subjectNameFormat | Format du nom de l’objet. Les valeurs possibles sont les suivantes : commonName , commonNameIncludingEmail , commonNameAsEmail , custom , commonNameAsIMEI , commonNameAsSerialNumber , commonNameAsAadDeviceId , commonNameAsIntuneDeviceId , commonNameAsDurableDeviceId . |
certificateSubjectAlternativeNameFormat | subjectAlternativeNameType | Autre format de nom de l’objet. Les valeurs possibles sont none , emailAddress , userPrincipalName , customAzureADAttribute , domainNameService , universalResourceIdentifier . |
certificateRevokeStatus | certificateRevocationStatus | Révoquez status. Les valeurs possibles sont les suivantes : none , pending , issued , failed , revoked . |
certificateProfileDisplayName | String | Nom complet du profil de certificat |
deviceDisplayName | String | Nom d’affichage de l’appareil |
userDisplayName | String | Nom d’utilisateur complet |
certificateExpirationDateTime | DateTimeOffset | Date d’expiration du certificat |
certificateLastIssuanceStateChangedDateTime | DateTimeOffset | Dernier changement d’état d’émission de certificat |
lastCertificateStateChangeDateTime | DateTimeOffset | Dernier changement d’état d’émission de certificat |
certificateIssuer | String | Émetteur |
certificateThumbprint | String | Empreinte |
certificateSerialNumber | String | Numéro de série |
certificateKeyLength | Int32 | Longueur de clé |
certificateEnhancedKeyUsage | String | Utilisation de la clé étendue |
certificateValidityPeriod | Int32 | Période de validité |
certificateSubjectNameFormatString | String | Chaîne de format de nom d’objet pour les formats de nom d’objet personnalisés |
certificateSubjectAlternativeNameFormatString | String | Chaîne de format de nom alternatif de l’objet pour les formats personnalisés |
certificateIssuanceDateTime | DateTimeOffset | Date d’émission |
certificateErrorCode | Int32 | Code d’erreur |
Réponse
Si elle réussit, cette méthode renvoie un 201 Created
code de réponse et un objet managedDeviceCertificateState dans le corps de la réponse.
Exemple
Demande
Voici un exemple de demande.
POST https://graph.microsoft.com/beta/deviceManagement/deviceConfigurations/{deviceConfigurationId}/microsoft.graph.iosPkcsCertificateProfile/managedDeviceCertificateStates
Content-type: application/json
Content-length: 1517
{
"@odata.type": "#microsoft.graph.managedDeviceCertificateState",
"devicePlatform": "androidForWork",
"certificateKeyUsage": "digitalSignature",
"certificateValidityPeriodUnits": "months",
"certificateIssuanceState": "challengeIssued",
"certificateKeyStorageProvider": "useTpmKspOtherwiseFail",
"certificateSubjectNameFormat": "commonNameIncludingEmail",
"certificateSubjectAlternativeNameFormat": "emailAddress",
"certificateRevokeStatus": "pending",
"certificateProfileDisplayName": "Certificate Profile Display Name value",
"deviceDisplayName": "Device Display Name value",
"userDisplayName": "User Display Name value",
"certificateExpirationDateTime": "2017-01-01T00:02:14.9489247-08:00",
"certificateLastIssuanceStateChangedDateTime": "2017-01-01T00:00:27.7468732-08:00",
"lastCertificateStateChangeDateTime": "2017-01-01T00:01:10.7144639-08:00",
"certificateIssuer": "Certificate Issuer value",
"certificateThumbprint": "Certificate Thumbprint value",
"certificateSerialNumber": "Certificate Serial Number value",
"certificateKeyLength": 4,
"certificateEnhancedKeyUsage": "Certificate Enhanced Key Usage value",
"certificateValidityPeriod": 9,
"certificateSubjectNameFormatString": "Certificate Subject Name Format String value",
"certificateSubjectAlternativeNameFormatString": "Certificate Subject Alternative Name Format String value",
"certificateIssuanceDateTime": "2016-12-31T23:59:41.5044473-08:00",
"certificateErrorCode": 4
}
Réponse
Voici un exemple de réponse. Remarque : l’objet de réponse illustré ici peut être tronqué à des fins de concision. Toutes les propriétés sont renvoyées à partir d’un appel réel.
HTTP/1.1 201 Created
Content-Type: application/json
Content-Length: 1566
{
"@odata.type": "#microsoft.graph.managedDeviceCertificateState",
"id": "d99bc884-c884-d99b-84c8-9bd984c89bd9",
"devicePlatform": "androidForWork",
"certificateKeyUsage": "digitalSignature",
"certificateValidityPeriodUnits": "months",
"certificateIssuanceState": "challengeIssued",
"certificateKeyStorageProvider": "useTpmKspOtherwiseFail",
"certificateSubjectNameFormat": "commonNameIncludingEmail",
"certificateSubjectAlternativeNameFormat": "emailAddress",
"certificateRevokeStatus": "pending",
"certificateProfileDisplayName": "Certificate Profile Display Name value",
"deviceDisplayName": "Device Display Name value",
"userDisplayName": "User Display Name value",
"certificateExpirationDateTime": "2017-01-01T00:02:14.9489247-08:00",
"certificateLastIssuanceStateChangedDateTime": "2017-01-01T00:00:27.7468732-08:00",
"lastCertificateStateChangeDateTime": "2017-01-01T00:01:10.7144639-08:00",
"certificateIssuer": "Certificate Issuer value",
"certificateThumbprint": "Certificate Thumbprint value",
"certificateSerialNumber": "Certificate Serial Number value",
"certificateKeyLength": 4,
"certificateEnhancedKeyUsage": "Certificate Enhanced Key Usage value",
"certificateValidityPeriod": 9,
"certificateSubjectNameFormatString": "Certificate Subject Name Format String value",
"certificateSubjectAlternativeNameFormatString": "Certificate Subject Alternative Name Format String value",
"certificateIssuanceDateTime": "2016-12-31T23:59:41.5044473-08:00",
"certificateErrorCode": 4
}