Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

[Bug] GetOrganizations is missing from the generated Dataverse service with Power Apps SDK 1.1.1 / CLI 1.0.1

オープン
#462 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
48/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
typescript
領域
tooling

調査の方向性

pa app add data-source の生成パスと AddDataSource.InternalActionsFiltered 診断から始め、src/generated/services/MicrosoftDataverseService.ts と GetOrganizations を含むコネクターメタデータを調査します。ドキュメント化された TypeScript 呼び出しで不足しているメソッドを再現します。生成されたサービスに操作が保持されるか、ドキュメント化されたサポート対象の置き換えと移行ガイダンスが提供されれば完了です。

索引モデルが issue の本文から書いたものです。

説明

bug

Summary

After generating the Microsoft Dataverse connector with pa app add data-source,
MicrosoftDataverseService.GetOrganizations() is no longer available.

An existing code app's previously generated Dataverse service includes this
operation, and the app uses it to retrieve accessible Dataverse organizations
and their friendly names. Generating the connector for a new code app with the
versions below omits the method and causes the existing application code to
fail compilation.

The observed issue is in the generated connector service, not a missing
top-level export from the SDK.

Why this method is important

GetOrganizations is particularly useful for resolving details of the
currently selected environment using the Dataverse connector already connected
to the app.
It returns accessible organizations, allowing the app to identify
the selected environment and obtain its friendly name and organization URL.
It is a discovery operation; the application performs the selected-environment
matching.

This supports an important user experience: showing a recognizable environment
name instead of a GUID, so users can confirm which environment they are working
in. It also supports environment-aware pickers without hardcoding environment
names or introducing a separate connector just to retrieve this metadata.

Please preserve this capability, or provide a supported replacement before
removing access to the method.
Existing applications depend on it, and a
replacement should support retrieving the selected environment's details, not
only its identifier.

Environment

  • @microsoft/power-apps: 1.1.1
  • @microsoft/power-apps-cli: 1.0.1
  • @microsoft/power-apps-vite: 1.0.2
  • Node.js: 24.19.0
  • Operating system: Windows
  • Connector: shared_commondataserviceforapps
  • Exact CLI version that originally generated the working method: not recorded.

Steps to reproduce

  1. Create a React/TypeScript Power Apps code app with the versions above.

  2. Initialize it and add an existing Microsoft Dataverse connection:

    pa app init --display-name "Dataverse reproduction" --environment-id <environment-id>
    pa app add data-source --connector shared_commondataserviceforapps --connection-id <connection-id> --org-url https://<organization>.crm.dynamics.com
    
  3. Inspect src/generated/services/MicrosoftDataverseService.ts.

  4. Attempt to compile the following application code:

    import { MicrosoftDataverseService } from './generated/services/MicrosoftDataverseService';
    
    const result = await MicrosoftDataverseService.GetOrganizations();
    

Expected behavior

The generated service retains GetOrganizations, or the tooling provides a
documented, supported replacement and migration guidance for applications
already using this operation.

Actual behavior

The generated service does not contain GetOrganizations. TypeScript reports:

TS2339: Property 'GetOrganizations' does not exist on type 'typeof MicrosoftDataverseService'.

Relevant diagnostic evidence

The connector-generation log reports:

AddDataSource.InternalActionsFiltered
totalActions: 93
internalCount: 56
internalOperationIds includes: GetOrganizations

This suggests the operation is being excluded by the CLI's internal-action
filter. Please confirm whether this exclusion is intentional or a regression.
The diagnostic numbers above are from the connector metadata returned during
this reproduction.

Impact and current workaround

Existing applications that use GetOrganizations for environment discovery or
friendly environment names cannot compile against the newly generated service.

For the current environment's display name, our workaround is to read
getContext().app.environmentId, add the separate Power Apps for Makers
connector, and match that ID against the results of
PowerAppsforMakersService.Get_Environments().

getContext() supplies the environment ID and Dataverse organization URL, but
does not expose the friendly environment name. The workaround therefore adds
another connector solely for a lookup previously handled through Dataverse.
It is not necessarily a complete replacement for all GetOrganizations use
cases.

We have not manually modified generated files to restore the operation.

Requested guidance and future alternative

If GetOrganizations will remain unavailable in generated services, please
clarify:

  1. What is the recommended, supported alternative for retrieving the selected
    environment's friendly name and organization details in a Power Apps code app?
  2. Can this be done through the existing Dataverse connector or the Power Apps
    SDK context, without adding another connector? Could getContext() expose
    the environment's friendly display name alongside environmentId and
    dataverseOrgUrl?
  3. Is Power Apps for Makers Get_Environments() the recommended long-term
    replacement, and what differences in permissions, licensing, or DLP
    requirements should applications account for?
  4. Please provide a working code sample, the minimum supported SDK/CLI versions,
    and migration guidance so applications can continue to resolve the selected
    environment if this method is not available in future releases.
主要言語
TypeScript
スター
504
フォーク
145
平均マージ
4時間 3分
マージ済み PR(30日)
1

環境構築

このプロジェクトの環境構築ファイルはまだ確認していません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

microsoft/PowerAppsCodeApps のほかの issue

microsoft/PowerAppsCodeApps の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。