Skip to content
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

feat: raise validation error when object is passed in query. #2999

Open
laststylebender14 opened this issue Oct 12, 2024 · 3 comments · May be fixed by #3086
Open

feat: raise validation error when object is passed in query. #2999

laststylebender14 opened this issue Oct 12, 2024 · 3 comments · May be fixed by #3086
Assignees

Comments

@laststylebender14
Copy link
Contributor

laststylebender14 commented Oct 12, 2024

type Query {
  findEmployees(criteria: Nested): [Employee!]!
    @http(
      baseURL: "http://localhost:8081"
      path: "/family/employees"
      query: [
        { key: "nested", value: "{{.args.criteria}}", skipEmpty: true }
      ]
    )
}

input Nested {
  maritalStatus: MaritalStatus
  hasChildren: Boolean
}

nested is an object it shouldn't be allowed inside query param, throw an validation error like `

Expected Error

Invalid query parameter type. Expected a value to be a Scalar but received an Object.

technical requirements:

  • add unit and integration tests
@tusharmath tusharmath changed the title bug: raise validation error when object is passed in query. feat: raise validation error when object is passed in query. Oct 12, 2024
@tusharmath
Copy link
Contributor

/bounty $100

Copy link

algora-pbc bot commented Oct 12, 2024

💎 $100 bounty • Tailcall Inc.

Steps to solve:

  1. Start working: Comment /attempt #2999 with your implementation plan
  2. Submit work: Create a pull request including /claim #2999 in the PR body to claim the bounty
  3. Receive payment: 100% of the bounty is received 2-5 days post-reward. Make sure you are eligible for payouts

🙏 Thank you for contributing to tailcallhq/tailcall!
🧐 Checkout our guidelines before you get started.
💵 More about our bounty program.

@Niharika0104
Copy link

Niharika0104 commented Oct 21, 2024

@laststylebender14 I see a draft pr.Is this still open?

@ssddOnTop ssddOnTop linked a pull request Oct 29, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants