Skip to content

feat: export AdkApiServer from @google/adk-devtools package#245

Merged
kalenkevich merged 4 commits into
mainfrom
feat/export_api_server_from_adk_devtools_package
Apr 10, 2026
Merged

feat: export AdkApiServer from @google/adk-devtools package#245
kalenkevich merged 4 commits into
mainfrom
feat/export_api_server_from_adk_devtools_package

Conversation

@kalenkevich
Copy link
Copy Markdown
Collaborator

@kalenkevich kalenkevich commented Apr 8, 2026

Link to Issue or Description of Change

Related to: #238

Problem:
The @google/adk-devtools package did not export AdkApiServer or AdkApiClient for programmatic use, limiting its functionality to CLI usage only. Additionally, the package lacked proper support for dual CommonJS and ESM exports.

Solution:

  • Created dev/src/index.ts to act as the main entry point for programmatic exports, exposing AdkApiServer and AdkApiClient.
  • Updated dev/package.json to support dual exports (ESM and CommonJS) via the "exports" field and added "typings".
  • Updated dev/tsconfig.json to output types to dist/types.
  • Added integration tests in tests/integration/build_setup to verify that AdkApiServer can be successfully imported and used in various environments (Node.js CJS/ESM, TypeScript CJS/ESM).

Testing Plan

Unit Tests:

  • I have added or updated unit tests for my change.
  • All unit tests pass locally.

Summary of passed npm test results:
Added should import devtools successfully and should run devtools CLI successfully tests to build_setup_test.ts.

Manual End-to-End (E2E) Tests:

  • Verified via automated build setup tests running across multiple configurations (JS/TS, ESM/CJS).

Checklist

  • I have performed a self-review of my own code.
  • I have added tests that prove my fix is effective or that my feature works.
  • New and existing unit tests pass locally with my changes.

@kalenkevich kalenkevich self-assigned this Apr 8, 2026
@kalenkevich kalenkevich force-pushed the feat/export_api_server_from_adk_devtools_package branch from 1af8532 to 265bfc2 Compare April 8, 2026 05:30
Copy link
Copy Markdown

@wbyoung wbyoung left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the quick turnaround.

@kalenkevich kalenkevich force-pushed the feat/export_api_server_from_adk_devtools_package branch from 265bfc2 to 284beec Compare April 9, 2026 01:28
@kalenkevich kalenkevich merged commit 0887e40 into main Apr 10, 2026
7 checks passed
@kalenkevich kalenkevich deleted the feat/export_api_server_from_adk_devtools_package branch April 10, 2026 00:09
@kalenkevich kalenkevich mentioned this pull request Apr 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants