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

Issues with count response #312

Closed
gsfk opened this issue Apr 11, 2024 · 3 comments
Closed

Issues with count response #312

gsfk opened this issue Apr 11, 2024 · 3 comments

Comments

@gsfk
Copy link
Contributor

gsfk commented Apr 11, 2024

Looking again at the reference implementation after a break of a couple years, thanks for all your work. I had a couple issues with count responses:

  • using GET, there appears to be no way to change the requestedGranularity parameter, api/individuals?requested_granularity=count and similar calls (camelCase, and with and without quotes around "count") all return 404.
  • using POST, the numTotalResults value in the response summary is typically incorrect for a count response if the request happens to include pagination values. I offer up a fix here.
@costero-e
Copy link
Collaborator

Hi @gsfk,
it's a pleasure to have you here again. Thanks for your feedback.
For the first question, I'm afraid that requested_granularity is not in the specs as a get request parameter:

paths:
  /individuals:
    get:
      parameters:
        - $ref: '#/components/parameters/requestedSchema'
        - $ref: '#/components/parameters/skip'
        - $ref: '#/components/parameters/limit'
        - $ref: '#/components/parameters/includeResultsetResponses'
        - $ref: '#/components/parameters/filters'

For the second issue you are commenting, you are absolutely right, I reviewed your PR and I will accept it now, thank you very much!
Oriol

@gsfk
Copy link
Contributor Author

gsfk commented Apr 11, 2024

Huh... I'm often surprised how far apart the GET and POST parts of the spec are.

Thanks for this!

@costero-e
Copy link
Collaborator

You are welcome!

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

No branches or pull requests

2 participants