Las API de la versión /beta de Microsoft Graph están sujetas a cambios. No se admite el uso de estas API en aplicaciones de producción. Para determinar si una API está disponible en la versión 1.0, use el selector de Versión.
Lo usa un proveedor de aprendizaje para ingerir o actualizar los metadatos de su contenido en Viva Learning. Si el contenido de aprendizaje especificado aún no existe para el proveedor especificado, esta operación crea los metadatos para el nuevo contenido. De lo contrario, esta operación reemplaza los metadatos del contenido existente.
Elija el permiso o los permisos marcados como con privilegios mínimos para esta API. Use un permiso o permisos con privilegios superiores solo si la aplicación lo requiere. Para obtener más información sobre los permisos delegados y de aplicación, consulte Tipos de permisos. Para obtener más información sobre estos permisos, consulte la referencia de permisos.
Tipo de permiso
Permisos con privilegios mínimos
Permisos con privilegios más altos
Delegado (cuenta profesional o educativa)
No admitida.
No admitida.
Delegado (cuenta personal de Microsoft)
No admitida.
No admitida.
Aplicación
LearningContent.ReadWrite.All
No disponible.
Solicitud HTTP
Para un contenido de aprendizaje específico basado en su identificador (clave principal):
En el cuerpo de la solicitud, proporcione solo los valores de las propiedades que se van a actualizar. Las propiedades existentes que no se incluyen en el cuerpo de la solicitud mantienen sus valores anteriores o se recalculan en función de los cambios realizados en otros valores de propiedad.
En la tabla siguiente se especifican las propiedades que se pueden actualizar.
Propiedad
Tipo
Descripción
additionalTags
Colección string
Palabras clave, temas y otras etiquetas asociadas al contenido de aprendizaje. Opcional.
contentWebUrl
Cadena
Dirección URL web de contenido del contenido de aprendizaje. Obligatorio.
colaboradores
Colección de cadenas
Los autores, creadores o colaboradores del contenido de aprendizaje. Opcional.
createdDateTime
DateTimeOffset
Fecha y hora en que se creó el contenido de aprendizaje. El tipo de marca de tiempo representa la información de fecha y hora con el formato ISO 8601 y está siempre en hora UTC. Por ejemplo, la medianoche en la zona horaria UTC del 1 de enero de 2014 sería 2014-01-01T00:00:00Z. Opcional.
description
Cadena
Descripción o resumen del contenido de aprendizaje. Opcional.
duration
Duración
Duración del contenido de aprendizaje en segundos. El valor se representa en formato ISO 8601 para las duraciones. Opcional.
externalId
Cadena
Identificador de contenido externo único para el contenido de aprendizaje. Obligatorio.
format
Cadena
Formato del contenido de aprendizaje. Por ejemplo, Course, Video, Book, , Book Summary, Audiobook Summary. Opcional.
nivel
Nivel
Nivel de dificultad del contenido de aprendizaje. Los valores posibles son: Beginner, Intermediate y Advanced. Opcional.
isActive
Booleano
Indica si el contenido está activo o no. El contenido inactivo no aparece en la interfaz de usuario. El valor predeterminado es true. Opcional.
isPremium
Booleano
Indica si el contenido de aprendizaje requiere que el usuario inicie sesión en la plataforma del proveedor de aprendizaje o no. El valor predeterminado es false. Opcional.
isSearchable
Booleano
Indica si el contenido de aprendizaje se puede buscar o no. El valor predeterminado es true. Opcional.
languageTag
Cadena
Idioma del contenido de aprendizaje, por ejemplo, en-us o fr-fr. Obligatorio.
lastModifiedDateTime
DateTimeOffset
Fecha y hora en que se modificó por última vez el contenido de aprendizaje. El tipo de marca de tiempo representa la información de fecha y hora con el formato ISO 8601 y está siempre en hora UTC. Por ejemplo, la medianoche en la zona horaria UTC del 1 de enero de 2014 sería 2014-01-01T00:00:00Z. Opcional.
numberOfPages
Int32
Número de páginas del contenido de aprendizaje, por ejemplo, 9. Opcional.
skillTags
Colección de cadenas
Etiquetas de aptitudes asociadas al contenido de aprendizaje. Opcional.
sourceName
Cadena
Nombre de origen del contenido de aprendizaje, como LinkedIn Learning o Coursera. Opcional.
thumbnailWebUrl
Cadena
Dirección URL de la imagen en miniatura del contenido de aprendizaje. Opcional.
title
Cadena
Título del contenido de aprendizaje. Obligatorio.
Respuesta
Si se ejecuta correctamente, este método devuelve un 202 Accepted código de respuesta y un objeto learningContent actualizado en el cuerpo de la respuesta.
Ejemplos
Ejemplo 1: Actualización de los metadatos de un contenido de aprendizaje en función de su identificador
En el ejemplo siguiente se muestra una solicitud que actualiza los metadatos de un contenido de aprendizaje en función de su identificador (clave principal).
PATCH https://graph.microsoft.com/beta/employeeExperience/learningProviders/13727311-e7bb-470d-8b20-6a23d9030d70/learningContents/77029588-a660-46b6-ba58-3ce4d21d5678
Content-Type: application/json
{
"title": "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle",
"description": "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.",
"contentWebUrl": "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/",
"sourceName": "MsLearn",
"thumbnailWebUrl": "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF",
"languageTag": "en-us",
"numberOfPages": 9,
"duration": "PT20M",
"format": "Book",
"level": "Beginner",
"createdDateTime": "2018-01-01T00:00:00Z",
"lastModifiedDateTime": "2021-04-01T04:26:06.1995367Z",
"contributors": ["Scott Simpson"],
"additionalTags": [
"Create private or public teams",
"Add members to teams"
],
"skillTags": [
"Create teams",
"Teams channels",
"Teams members"
],
"isActive": true,
"isPremium": false,
"isSearchable": true
}
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Beta.Models;
var requestBody = new LearningContent
{
Title = "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle",
Description = "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.",
ContentWebUrl = "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/",
SourceName = "MsLearn",
ThumbnailWebUrl = "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF",
LanguageTag = "en-us",
NumberOfPages = 9,
Duration = TimeSpan.Parse("PT20M"),
Format = "Book",
Level = Level.Beginner,
CreatedDateTime = DateTimeOffset.Parse("2018-01-01T00:00:00Z"),
LastModifiedDateTime = DateTimeOffset.Parse("2021-04-01T04:26:06.1995367Z"),
Contributors = new List<string>
{
"Scott Simpson",
},
AdditionalTags = new List<string>
{
"Create private or public teams",
"Add members to teams",
},
SkillTags = new List<string>
{
"Create teams",
"Teams channels",
"Teams members",
},
IsActive = true,
IsPremium = false,
IsSearchable = true,
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.EmployeeExperience.LearningProviders["{learningProvider-id}"].LearningContents["{learningContent-id}"].PatchAsync(requestBody);
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
mgc-beta employee-experience learning-providers learning-contents patch --learning-provider-id {learningProvider-id} --learning-content-id {learningContent-id} --body '{\
"title": "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle",\
"description": "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.",\
"contentWebUrl": "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/",\
"sourceName": "MsLearn",\
"thumbnailWebUrl": "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF",\
"languageTag": "en-us",\
"numberOfPages": 9,\
"duration": "PT20M",\
"format": "Book",\
"level": "Beginner",\
"createdDateTime": "2018-01-01T00:00:00Z",\
"lastModifiedDateTime": "2021-04-01T04:26:06.1995367Z",\
"contributors": ["Scott Simpson"],\
"additionalTags": [\
"Create private or public teams",\
"Add members to teams"\
],\
"skillTags": [\
"Create teams",\
"Teams channels",\
"Teams members"\
],\
"isActive": true,\
"isPremium": false,\
"isSearchable": true\
}\
'
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
// Code snippets are only available for the latest major version. Current major version is $v0.*
// Dependencies
import (
"context"
"time"
abstractions "github.com/microsoft/kiota-abstractions-go"
msgraphsdk "github.com/microsoftgraph/msgraph-beta-sdk-go"
graphmodels "github.com/microsoftgraph/msgraph-beta-sdk-go/models"
//other-imports
)
requestBody := graphmodels.NewLearningContent()
title := "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle"
requestBody.SetTitle(&title)
description := "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application."
requestBody.SetDescription(&description)
contentWebUrl := "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/"
requestBody.SetContentWebUrl(&contentWebUrl)
sourceName := "MsLearn"
requestBody.SetSourceName(&sourceName)
thumbnailWebUrl := "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF"
requestBody.SetThumbnailWebUrl(&thumbnailWebUrl)
languageTag := "en-us"
requestBody.SetLanguageTag(&languageTag)
numberOfPages := int32(9)
requestBody.SetNumberOfPages(&numberOfPages)
duration , err := abstractions.ParseISODuration("PT20M")
requestBody.SetDuration(&duration)
format := "Book"
requestBody.SetFormat(&format)
level := graphmodels.BEGINNER_LEVEL
requestBody.SetLevel(&level)
createdDateTime , err := time.Parse(time.RFC3339, "2018-01-01T00:00:00Z")
requestBody.SetCreatedDateTime(&createdDateTime)
lastModifiedDateTime , err := time.Parse(time.RFC3339, "2021-04-01T04:26:06.1995367Z")
requestBody.SetLastModifiedDateTime(&lastModifiedDateTime)
contributors := []string {
"Scott Simpson",
}
requestBody.SetContributors(contributors)
additionalTags := []string {
"Create private or public teams",
"Add members to teams",
}
requestBody.SetAdditionalTags(additionalTags)
skillTags := []string {
"Create teams",
"Teams channels",
"Teams members",
}
requestBody.SetSkillTags(skillTags)
isActive := true
requestBody.SetIsActive(&isActive)
isPremium := false
requestBody.SetIsPremium(&isPremium)
isSearchable := true
requestBody.SetIsSearchable(&isSearchable)
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
learningContents, err := graphClient.EmployeeExperience().LearningProviders().ByLearningProviderId("learningProvider-id").LearningContents().ByLearningContentId("learningContent-id").Patch(context.Background(), requestBody, nil)
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
LearningContent learningContent = new LearningContent();
learningContent.setTitle("Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle");
learningContent.setDescription("A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.");
learningContent.setContentWebUrl("https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/");
learningContent.setSourceName("MsLearn");
learningContent.setThumbnailWebUrl("https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF");
learningContent.setLanguageTag("en-us");
learningContent.setNumberOfPages(9);
PeriodAndDuration duration = PeriodAndDuration.ofDuration(Duration.parse("PT20M"));
learningContent.setDuration(duration);
learningContent.setFormat("Book");
learningContent.setLevel(Level.Beginner);
OffsetDateTime createdDateTime = OffsetDateTime.parse("2018-01-01T00:00:00Z");
learningContent.setCreatedDateTime(createdDateTime);
OffsetDateTime lastModifiedDateTime = OffsetDateTime.parse("2021-04-01T04:26:06.1995367Z");
learningContent.setLastModifiedDateTime(lastModifiedDateTime);
LinkedList<String> contributors = new LinkedList<String>();
contributors.add("Scott Simpson");
learningContent.setContributors(contributors);
LinkedList<String> additionalTags = new LinkedList<String>();
additionalTags.add("Create private or public teams");
additionalTags.add("Add members to teams");
learningContent.setAdditionalTags(additionalTags);
LinkedList<String> skillTags = new LinkedList<String>();
skillTags.add("Create teams");
skillTags.add("Teams channels");
skillTags.add("Teams members");
learningContent.setSkillTags(skillTags);
learningContent.setIsActive(true);
learningContent.setIsPremium(false);
learningContent.setIsSearchable(true);
LearningContent result = graphClient.employeeExperience().learningProviders().byLearningProviderId("{learningProvider-id}").learningContents().byLearningContentId("{learningContent-id}").patch(learningContent);
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
const options = {
authProvider,
};
const client = Client.init(options);
const learningContent = {
title: 'Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle',
description: 'A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.',
contentWebUrl: 'https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/',
sourceName: 'MsLearn',
thumbnailWebUrl: 'https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF',
languageTag: 'en-us',
numberOfPages: 9,
duration: 'PT20M',
format: 'Book',
level: 'Beginner',
createdDateTime: '2018-01-01T00:00:00Z',
lastModifiedDateTime: '2021-04-01T04:26:06.1995367Z',
contributors: ['Scott Simpson'],
additionalTags: [
'Create private or public teams',
'Add members to teams'
],
skillTags: [
'Create teams',
'Teams channels',
'Teams members'
],
isActive: true,
isPremium: false,
isSearchable: true
};
await client.api('/employeeExperience/learningProviders/13727311-e7bb-470d-8b20-6a23d9030d70/learningContents/77029588-a660-46b6-ba58-3ce4d21d5678')
.version('beta')
.update(learningContent);
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
<?php
use Microsoft\Graph\Beta\GraphServiceClient;
use Microsoft\Graph\Beta\Generated\Models\LearningContent;
use Microsoft\Graph\Beta\Generated\Models\Level;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new LearningContent();
$requestBody->setTitle('Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle');
$requestBody->setDescription('A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.');
$requestBody->setContentWebUrl('https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/');
$requestBody->setSourceName('MsLearn');
$requestBody->setThumbnailWebUrl('https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF');
$requestBody->setLanguageTag('en-us');
$requestBody->setNumberOfPages(9);
$requestBody->setDuration(new \DateInterval('PT20M'));
$requestBody->setFormat('Book');
$requestBody->setLevel(new Level('beginner'));
$requestBody->setCreatedDateTime(new \DateTime('2018-01-01T00:00:00Z'));
$requestBody->setLastModifiedDateTime(new \DateTime('2021-04-01T04:26:06.1995367Z'));
$requestBody->setContributors(['Scott Simpson', ]);
$requestBody->setAdditionalTags(['Create private or public teams', 'Add members to teams', ]);
$requestBody->setSkillTags(['Create teams', 'Teams channels', 'Teams members', ]);
$requestBody->setIsActive(true);
$requestBody->setIsPremium(false);
$requestBody->setIsSearchable(true);
$result = $graphServiceClient->employeeExperience()->learningProviders()->byLearningProviderId('learningProvider-id')->learningContents()->byLearningContentId('learningContent-id')->patch($requestBody)->wait();
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph_beta import GraphServiceClient
from msgraph_beta.generated.models.learning_content import LearningContent
from msgraph_beta.generated.models.level import Level
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = LearningContent(
title = "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle",
description = "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.",
content_web_url = "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/",
source_name = "MsLearn",
thumbnail_web_url = "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF",
language_tag = "en-us",
number_of_pages = 9,
duration = "PT20M",
format = "Book",
level = Level.Beginner,
created_date_time = "2018-01-01T00:00:00Z",
last_modified_date_time = "2021-04-01T04:26:06.1995367Z",
contributors = [
"Scott Simpson",
],
additional_tags = [
"Create private or public teams",
"Add members to teams",
],
skill_tags = [
"Create teams",
"Teams channels",
"Teams members",
],
is_active = True,
is_premium = False,
is_searchable = True,
)
result = await graph_client.employee_experience.learning_providers.by_learning_provider_id('learningProvider-id').learning_contents.by_learning_content_id('learningContent-id').patch(request_body)
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
Nota: Se puede acortar el objeto de respuesta que se muestra aquí para mejorar la legibilidad.
HTTP/1.1 202 Accepted
Content-Type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#learningProviders('13727311-e7bb-470d-8b20-6a23d9030d70')/learningContents/$entity",
"id": "77029588-a660-46b6-ba58-3ce4d21d5678",
"externalId": "LP4471",
"title": "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle",
"description": "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.",
"contentWebUrl": "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/",
"sourceName": "MsLearn",
"thumbnailWebUrl": "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF",
"languageTag": "en-us",
"numberOfPages": 9,
"duration": "PT20M",
"format": "Book",
"level": "Beginner",
"createdDateTime": "2018-01-01T00:00:00",
"lastModifiedDateTime": "2021-04-01T04:26:06.1995367Z",
"contributors": [
"Lina Wagner",
"Lisa Richter"
],
"additionalTags": [
"Create private or public teams",
"Add members to teams"
],
"skillTags": [
"Create teams",
"Teams channels",
"Teams members"
],
"isActive": true,
"isPremium": false,
"isSearchable": true
}
Ejemplo 2: Actualización de los metadatos de un contenido de aprendizaje en función de su identificador externo
En el ejemplo siguiente se muestra una solicitud que actualiza los metadatos de un contenido de aprendizaje en función de su identificador externo (clave secundaria).
PATCH https://graph.microsoft.com/beta/employeeExperience/learningProviders/13727311-e7bb-470d-8b20-6a23d9030d70/learningContents(externalId='LP4471')
Content-Type: application/json
{
"title": "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle",
"description": "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.",
"contentWebUrl": "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/",
"sourceName": "MsLearn",
"thumbnailWebUrl": "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF",
"languageTag": "en-us",
"numberOfPages": 9,
"duration": "PT20M",
"format": "Book",
"level": "Beginner",
"createdDateTime": "2018-01-01T00:00:00",
"lastModifiedDateTime": "2021-04-01T04:26:06.1995367Z",
"contributor": "Scott Simpson",
"additionalTags": [
"Create private or public teams",
"Add members to teams"
],
"skillTags": [
"Create teams",
"Teams channels",
"Teams members"
],
"isActive": true,
"isPremium": false,
"isSearchable": true
}
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Beta.Models;
var requestBody = new LearningContent
{
Title = "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle",
Description = "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.",
ContentWebUrl = "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/",
SourceName = "MsLearn",
ThumbnailWebUrl = "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF",
LanguageTag = "en-us",
NumberOfPages = 9,
Duration = TimeSpan.Parse("PT20M"),
Format = "Book",
Level = Level.Beginner,
CreatedDateTime = DateTimeOffset.Parse("2018-01-01T00:00:00"),
LastModifiedDateTime = DateTimeOffset.Parse("2021-04-01T04:26:06.1995367Z"),
AdditionalTags = new List<string>
{
"Create private or public teams",
"Add members to teams",
},
SkillTags = new List<string>
{
"Create teams",
"Teams channels",
"Teams members",
},
IsActive = true,
IsPremium = false,
IsSearchable = true,
AdditionalData = new Dictionary<string, object>
{
{
"contributor" , "Scott Simpson"
},
},
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.EmployeeExperience.LearningProviders["{learningProvider-id}"].LearningContentsWithExternalId("{externalId}").PatchAsync(requestBody);
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
mgc-beta employee-experience learning-providers learning-contents-with-external-id patch --external-id {external-id} --learning-provider-id {learningProvider-id} --body '{\
"title": "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle",\
"description": "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.",\
"contentWebUrl": "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/",\
"sourceName": "MsLearn",\
"thumbnailWebUrl": "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF",\
"languageTag": "en-us",\
"numberOfPages": 9,\
"duration": "PT20M",\
"format": "Book",\
"level": "Beginner",\
"createdDateTime": "2018-01-01T00:00:00",\
"lastModifiedDateTime": "2021-04-01T04:26:06.1995367Z",\
"contributor": "Scott Simpson",\
"additionalTags": [\
"Create private or public teams",\
"Add members to teams"\
],\
"skillTags": [\
"Create teams",\
"Teams channels",\
"Teams members"\
],\
"isActive": true,\
"isPremium": false,\
"isSearchable": true\
}\
'
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
// Code snippets are only available for the latest major version. Current major version is $v0.*
// Dependencies
import (
"context"
"time"
abstractions "github.com/microsoft/kiota-abstractions-go"
msgraphsdk "github.com/microsoftgraph/msgraph-beta-sdk-go"
graphmodels "github.com/microsoftgraph/msgraph-beta-sdk-go/models"
//other-imports
)
requestBody := graphmodels.NewLearningContent()
title := "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle"
requestBody.SetTitle(&title)
description := "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application."
requestBody.SetDescription(&description)
contentWebUrl := "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/"
requestBody.SetContentWebUrl(&contentWebUrl)
sourceName := "MsLearn"
requestBody.SetSourceName(&sourceName)
thumbnailWebUrl := "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF"
requestBody.SetThumbnailWebUrl(&thumbnailWebUrl)
languageTag := "en-us"
requestBody.SetLanguageTag(&languageTag)
numberOfPages := int32(9)
requestBody.SetNumberOfPages(&numberOfPages)
duration , err := abstractions.ParseISODuration("PT20M")
requestBody.SetDuration(&duration)
format := "Book"
requestBody.SetFormat(&format)
level := graphmodels.BEGINNER_LEVEL
requestBody.SetLevel(&level)
createdDateTime , err := time.Parse(time.RFC3339, "2018-01-01T00:00:00")
requestBody.SetCreatedDateTime(&createdDateTime)
lastModifiedDateTime , err := time.Parse(time.RFC3339, "2021-04-01T04:26:06.1995367Z")
requestBody.SetLastModifiedDateTime(&lastModifiedDateTime)
additionalTags := []string {
"Create private or public teams",
"Add members to teams",
}
requestBody.SetAdditionalTags(additionalTags)
skillTags := []string {
"Create teams",
"Teams channels",
"Teams members",
}
requestBody.SetSkillTags(skillTags)
isActive := true
requestBody.SetIsActive(&isActive)
isPremium := false
requestBody.SetIsPremium(&isPremium)
isSearchable := true
requestBody.SetIsSearchable(&isSearchable)
additionalData := map[string]interface{}{
"contributor" : "Scott Simpson",
}
requestBody.SetAdditionalData(additionalData)
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
externalId := "{externalId}"
learningContents, err := graphClient.EmployeeExperience().LearningProviders().ByLearningProviderId("learningProvider-id").LearningContentsWithExternalId(&externalId).Patch(context.Background(), requestBody, nil)
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
LearningContent learningContent = new LearningContent();
learningContent.setTitle("Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle");
learningContent.setDescription("A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.");
learningContent.setContentWebUrl("https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/");
learningContent.setSourceName("MsLearn");
learningContent.setThumbnailWebUrl("https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF");
learningContent.setLanguageTag("en-us");
learningContent.setNumberOfPages(9);
PeriodAndDuration duration = PeriodAndDuration.ofDuration(Duration.parse("PT20M"));
learningContent.setDuration(duration);
learningContent.setFormat("Book");
learningContent.setLevel(Level.Beginner);
OffsetDateTime createdDateTime = OffsetDateTime.parse("2018-01-01T00:00:00");
learningContent.setCreatedDateTime(createdDateTime);
OffsetDateTime lastModifiedDateTime = OffsetDateTime.parse("2021-04-01T04:26:06.1995367Z");
learningContent.setLastModifiedDateTime(lastModifiedDateTime);
LinkedList<String> additionalTags = new LinkedList<String>();
additionalTags.add("Create private or public teams");
additionalTags.add("Add members to teams");
learningContent.setAdditionalTags(additionalTags);
LinkedList<String> skillTags = new LinkedList<String>();
skillTags.add("Create teams");
skillTags.add("Teams channels");
skillTags.add("Teams members");
learningContent.setSkillTags(skillTags);
learningContent.setIsActive(true);
learningContent.setIsPremium(false);
learningContent.setIsSearchable(true);
HashMap<String, Object> additionalData = new HashMap<String, Object>();
additionalData.put("contributor", "Scott Simpson");
learningContent.setAdditionalData(additionalData);
LearningContent result = graphClient.employeeExperience().learningProviders().byLearningProviderId("{learningProvider-id}").learningContentsWithExternalId("{externalId}").patch(learningContent);
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
<?php
use Microsoft\Graph\Beta\GraphServiceClient;
use Microsoft\Graph\Beta\Generated\Models\LearningContent;
use Microsoft\Graph\Beta\Generated\Models\Level;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new LearningContent();
$requestBody->setTitle('Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle');
$requestBody->setDescription('A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.');
$requestBody->setContentWebUrl('https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/');
$requestBody->setSourceName('MsLearn');
$requestBody->setThumbnailWebUrl('https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF');
$requestBody->setLanguageTag('en-us');
$requestBody->setNumberOfPages(9);
$requestBody->setDuration(new \DateInterval('PT20M'));
$requestBody->setFormat('Book');
$requestBody->setLevel(new Level('beginner'));
$requestBody->setCreatedDateTime(new \DateTime('2018-01-01T00:00:00'));
$requestBody->setLastModifiedDateTime(new \DateTime('2021-04-01T04:26:06.1995367Z'));
$requestBody->setAdditionalTags(['Create private or public teams', 'Add members to teams', ]);
$requestBody->setSkillTags(['Create teams', 'Teams channels', 'Teams members', ]);
$requestBody->setIsActive(true);
$requestBody->setIsPremium(false);
$requestBody->setIsSearchable(true);
$additionalData = [
'contributor' => 'Scott Simpson',
];
$requestBody->setAdditionalData($additionalData);
$result = $graphServiceClient->employeeExperience()->learningProviders()->byLearningProviderId('learningProvider-id')->learningContentsWithExternalId('{externalId}', )->patch($requestBody)->wait();
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph_beta import GraphServiceClient
from msgraph_beta.generated.models.learning_content import LearningContent
from msgraph_beta.generated.models.level import Level
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = LearningContent(
title = "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle",
description = "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.",
content_web_url = "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/",
source_name = "MsLearn",
thumbnail_web_url = "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF",
language_tag = "en-us",
number_of_pages = 9,
duration = "PT20M",
format = "Book",
level = Level.Beginner,
created_date_time = "2018-01-01T00:00:00",
last_modified_date_time = "2021-04-01T04:26:06.1995367Z",
additional_tags = [
"Create private or public teams",
"Add members to teams",
],
skill_tags = [
"Create teams",
"Teams channels",
"Teams members",
],
is_active = True,
is_premium = False,
is_searchable = True,
additional_data = {
"contributor" : "Scott Simpson",
}
)
result = await graph_client.employee_experience.learning_providers.by_learning_provider_id('learningProvider-id').learning_contents_with_external_id("{externalId}").patch(request_body)
Importante
Los SDK de Microsoft Graph usan la versión v1.0 de la API de manera predeterminada y no admiten todos los tipos, propiedades y API disponibles en la versión beta. Para obtener más información sobre cómo acceder a la API beta con el SDK, consulte Uso de los SDK de Microsoft Graph con la API beta.
Nota: Se puede acortar el objeto de respuesta que se muestra aquí para mejorar la legibilidad.
HTTP/1.1 202 Accepted
Content-Type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#learningProviders('13727311-e7bb-470d-8b20-6a23d9030d70')/learningContents/$entity",
"id": "77029588-a660-46b6-ba58-3ce4d21d5678",
"externalId": "LP4471",
"title": "Manage classes, resources, assessment, and planning in Microsoft Teams with Beedle",
"description": "A module to guide users through the various teaching and learning enhancements that Beedle provides within Microsoft Teams, with many examples of everyday application.",
"contentWebUrl": "https://learn.microsoft.com/learn/modules/manage-classes-resources-assessment-planning-beedle/",
"sourceName": "MsLearn",
"thumbnailWebUrl": "https://syndetics.com/index.aspx?isbn=9783319672175/LC.GIF",
"languageTag": "en-us",
"numberOfPages": 9,
"duration": "PT20M",
"format": "Book",
"level": "Beginner",
"createdDateTime": "2018-01-01T00:00:00",
"lastModifiedDateTime": "2021-04-01T04:26:06.1995367Z",
"contributors": [
"Lina Wagner",
"Lisa Richter"
],
"additionalTags": [
"Create private or public teams",
"Add members to teams"
],
"skillTags": [
"Create teams",
"Teams channels",
"Teams members"
],
"isActive": true,
"isPremium": false,
"isSearchable": true
}