microsoftgraph / msgraph-metadata

Microsoft Graph metadata captured and used for generating client library code files.
https://graph.microsoft.com
MIT License
107 stars 33 forks source link

Microsoft.Graph.User deprecated "as of 2024-07/PrivatePreview:copilotExportAPI" #680

Open jamesgurung opened 2 months ago

jamesgurung commented 2 months ago

I am using the Microsoft Graph Beta SDK for .NET. However, this issue seems to be caused by commit https://github.com/microsoftgraph/msgraph-beta-sdk-dotnet/commit/7c5cfba8e32d7e89ccdc507192ab5eb01c96e313 which was generated from the metadata.

This code should send an email:

<PackageReference Include="Microsoft.Graph.Beta" Version="5.79.0-preview" />
var client = new GraphServiceClient(credential, scopes);
await client.Me.SendMail.PostAsync(new SendMailPostRequestBody { Message = message });

It has started showing deprecation warnings:

'MeRequestBuilder.SendMail' is obsolete: ' as of 2024-07/PrivatePreview:copilotExportAPI'

'SendMailRequestBuilder.PostAsync(SendMailPostRequestBody, Action<RequestConfiguration>?, CancellationToken)' is obsolete: ' as of 2024-07/PrivatePreview:copilotExportAPI'

This appears to come from the metadata:

<Annotations Target="microsoft.graph.user">
  <Annotation Term="Org.OData.Capabilities.V1.ChangeTracking">
    <Record>
      <PropertyValue Property="Supported" Bool="true"/>
    </Record>
  </Annotation>
  <Annotation Term="Org.OData.Core.V1.Revisions">
    <Collection>
      <Record>
        <PropertyValue Property="Date" Date="2024-07-02"/>
        <PropertyValue Property="Kind">
          <EnumMember>Org.OData.Core.V1.RevisionKind/Deprecated</EnumMember>
        </PropertyValue>
        <PropertyValue Property="RemovalDate" Date="2025-07-02"/>
        <PropertyValue Property="Version" String="2024-07/PrivatePreview:copilotExportAPI"/>
      </Record>
    </Collection>
  </Annotation>
</Annotations>

However, I cannot see this deprecation listed in the Microsoft Graph changelog.