Skip to content

Fix/dx 3133 urlencode for query string #186

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
Jun 13, 2025

Conversation

nadeem-cs
Copy link
Contributor

No description provided.

Copy link

@Copilot 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 pull request introduces URL encoding for query parameters in the SDK. Key changes include:

  • Adding an encodeQueryParams utility function for recursive encoding of string values.
  • Adding tests for the new encoding functionality in both unit and API test files.
  • Extending the BaseQuery.find method with a new optional parameter to enable query parameter encoding.

Reviewed Changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
test/unit/utils.spec.ts Added unit tests to verify proper encoding of special and nested characters.
test/api/query-encoding.spec.ts Added API tests to confirm encoding behavior under various query scenarios.
src/lib/utils.ts Introduced the encodeQueryParams function for encoding query parameters.
src/lib/base-query.ts Extended the find method to support an optional encoding flag.
package.json Bumped version to 4.7.1 as part of the changes.
CHANGELOG.md Updated changelog to reflect the changes introduced in 4.7.1.
Comments suppressed due to low confidence (1)

src/lib/base-query.ts:205

  • Consider adding inline documentation for the 'encode' parameter in the find method to clearly explain its purpose and usage.
  async find<T>(encode: boolean = false): Promise<FindResponse<T>> {

@harshithad0703 harshithad0703 changed the base branch from development to main June 13, 2025 07:49
Copy link

We regret to inform you that you are currently not able to merge your changes into the main branch due to restrictions applied by our SRE team. To proceed with merging your changes, we kindly request that you create a pull request from the development branch. Our team will then review the changes and work with you to ensure a successful merge into the main branch.

Copy link

We regret to inform you that you are currently not able to merge your changes into the main branch due to restrictions applied by our SRE team. To proceed with merging your changes, we kindly request that you create a pull request from the development branch. Our team will then review the changes and work with you to ensure a successful merge into the main branch.

Copy link
Contributor

@sunil-lakshman sunil-lakshman left a comment

Choose a reason for hiding this comment

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

LGTM

@cs-raj cs-raj marked this pull request as ready for review June 13, 2025 08:31
@cs-raj cs-raj requested a review from a team as a code owner June 13, 2025 08:31
@harshithad0703 harshithad0703 merged commit 48b66ad into main Jun 13, 2025
7 of 8 checks passed
@harshithad0703 harshithad0703 deleted the fix/DX-3133-urlencode-for-query-string branch June 13, 2025 08:35
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.

5 participants