Skip to content

Conversation

@fmenezes
Copy link
Collaborator

@fmenezes fmenezes commented Nov 10, 2025

Proposed changes

fixes the case where the openapi spec was not updating given the operation IDs changed

Checklist

@fmenezes fmenezes marked this pull request as ready for review November 10, 2025 11:30
@fmenezes fmenezes requested a review from a team as a code owner November 10, 2025 11:30
Copilot AI review requested due to automatic review settings November 10, 2025 11:30
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR updates API client method names to align with the latest MongoDB Atlas OpenAPI specification's operation IDs. The changes ensure consistency between the client-side API wrapper and the server's OpenAPI contract.

  • Updates method names in ApiClient to match new OpenAPI operation IDs (e.g., listProjectslistGroups, listOrganizationslistOrgs)
  • Updates all call sites across test files and tool implementations to use the new method names
  • Updates the OpenAPI operation filter list to allow only the renamed operations

Reviewed Changes

Copilot reviewed 19 out of 20 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/common/atlas/apiClient.ts Renames API client methods to match updated OpenAPI operation IDs
src/common/atlas/accessListUtils.ts Updates call to renamed createAccessListEntry method
src/common/atlas/performanceAdvisorUtils.ts Updates calls to renamed drop index and slow query methods
src/tools/atlas/create/createAccessList.ts Updates call to renamed createAccessListEntry method
src/tools/atlas/create/createProject.ts Updates calls to renamed listOrgs and createGroup methods
src/tools/atlas/read/inspectAccessList.ts Updates call to renamed listAccessListEntries method
src/tools/atlas/read/listClusters.ts Updates calls to renamed listClusterDetails and getGroup methods
src/tools/atlas/read/listOrgs.ts Updates call to renamed listOrgs method
src/tools/atlas/read/listProjects.ts Updates calls to renamed listOrgs, getOrgGroups, and listGroups methods
tests/unit/common/apiClient.test.ts Updates test calls to use renamed listGroups method
tests/integration/common/apiClient.test.ts Updates test calls to use renamed listOrgs method
tests/integration/tools/atlas/accessLists.test.ts Updates test calls to use renamed deleteAccessListEntry and listAccessListEntries methods
tests/integration/tools/atlas/atlasHelpers.ts Updates test helper to use renamed createGroup, deleteGroup, listOrgs, and createAccessListEntry methods
tests/integration/tools/atlas/clusters.test.ts Updates test calls to use renamed listAccessListEntries and createAccessListEntry methods
tests/integration/tools/atlas/dbUsers.test.ts Updates test call to use renamed listAccessListEntries method
tests/integration/tools/atlas/projects.test.ts Updates test calls to use renamed listGroups, deleteGroup, and listOrgs methods
scripts/filter.ts Updates allowed operations list to include renamed operation IDs
scripts/cleanupAtlasTestLeftovers.test.ts Updates cleanup script calls to use renamed listOrgs, getOrgGroups, and deleteGroup methods
package.json Splits generate script into separate api and arguments generation steps

@fmenezes fmenezes marked this pull request as draft November 10, 2025 11:32
}

// eslint-disable-next-line @typescript-eslint/explicit-function-return-type
async createProjectIpAccessList(options: FetchOptions<operations["createProjectIpAccessList"]>) {
Copy link
Member

Choose a reason for hiding this comment

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

[q] what happened to all these delete ones, are they unused?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I'm checking

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

this is to do with x-xgen-operation-id-override

@fmenezes fmenezes marked this pull request as ready for review November 10, 2025 12:50
@fmenezes fmenezes enabled auto-merge (squash) November 10, 2025 12:53
@fmenezes fmenezes merged commit 0771380 into main Nov 10, 2025
19 checks passed
@fmenezes fmenezes deleted the fix_operation_ids branch November 10, 2025 14:16
@coveralls
Copy link
Collaborator

coveralls commented Nov 10, 2025

Pull Request Test Coverage Report for Build 19232052581

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 36 of 43 (83.72%) changed or added relevant lines in 9 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.03%) to 80.131%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/tools/atlas/read/listClusters.ts 1 2 50.0%
src/common/atlas/performanceAdvisorUtils.ts 0 2 0.0%
src/common/atlas/apiClient.ts 26 30 86.67%
Totals Coverage Status
Change from base Build 19225655084: -0.03%
Covered Lines: 6477
Relevant Lines: 7976

💛 - Coveralls

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