Skip to content

Conversation

@nameless-mc
Copy link
Contributor

Why

To align the interface with AppClient.getStatistics. Currently, AppClient uses the method name getStatistics, while SpaceClient uses the redundant name getSpacesStatistics. Since the scope is already clear from the client name, there's no need to include Spaces in the method name.

What

  • Rename SpaceClient.getSpacesStatistics to SpaceClient.getStatistics
  • Update documentation (packages/rest-api-client/docs/space.md)
  • Update test cases

How to test

Checklist

  • Read CONTRIBUTING.md
  • Updated documentation if it is required.
  • Added tests if it is required.
  • Passed pnpm lint and pnpm test on the root directory.

@nameless-mc nameless-mc self-assigned this Nov 19, 2025
@nameless-mc nameless-mc requested a review from a team as a code owner November 19, 2025 02:16
@nameless-mc nameless-mc requested review from chihiro-adachi, Copilot and tasshi-me and removed request for a team November 19, 2025 02:16
@github-actions github-actions bot added the pkg: rest-api-client @kintone/rest-api-client label Nov 19, 2025
Copilot finished reviewing on behalf of nameless-mc November 19, 2025 02:18
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 renames SpaceClient.getSpacesStatistics to SpaceClient.getStatistics to align with the existing AppClient.getStatistics method naming convention. Since the client name already indicates the scope (Space), the redundant "Spaces" qualifier in the method name is removed for consistency.

  • Renamed method from getSpacesStatistics to getStatistics in SpaceClient
  • Updated all test cases to use the new method name
  • Updated documentation to reflect the method name change

Reviewed Changes

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

File Description
packages/rest-api-client/src/client/SpaceClient.ts Renamed the public method getSpacesStatistics to getStatistics for consistency with AppClient
packages/rest-api-client/src/client/tests/SpaceClient.test.ts Updated test suite describe block and all method calls to use the new getStatistics name
packages/rest-api-client/docs/space.md Updated documentation table of contents and section header to reference the new method name getStatistics

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Member

@tasshi-me tasshi-me left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pkg: rest-api-client @kintone/rest-api-client

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants