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

[Bug]: Invoice > List status filter not working as expected #19

Open
tiagof opened this issue May 31, 2023 · 0 comments
Open

[Bug]: Invoice > List status filter not working as expected #19

tiagof opened this issue May 31, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@tiagof
Copy link
Member

tiagof commented May 31, 2023

What happened?

When listing invoices and filtering by status, the status final is not accepted, instead to get only invoices in with status="Final"we must use the value sent in the status filter (query parameter)

Possible Invoice statuses are
draft, settled, deleted, canceled, final

Possible values for the status query parameter in the Invoices > List endpoint
draft, settled, canceled, second_copy, sent.

Get da invoice:

curl --request GET
--url 'https://integrislda.app.invoicexpress.com/invoices/188888315.json?api_key=be4axxxxxxxxxxxxxxxxxxxxxxxxx'
--header 'accept: application/json'
--header 'content-type: application/json'

{"invoice":{"id":188888315,"status":"final","archived":false,"....}}

List, filtrando o status por "final", obtemos nada:

curl --request GET
--url 'https://integrislda.app.invoicexpress.com/invoices.json?api_key=be4xxxxxxxxxxxxxxxxxxxxxxxxx&status%5B%5D= final '
--header 'accept: application/json'
--header 'content-type: application/json'

{"invoices":[],"pagination":{"total_entries":0,"current_page":1,"total_pages":0,"per_page":10}

List, filtrando o status por "sent", obtemos as "final":

curl --request GET
--url 'https://integrislda.app.invoicexpress.com/invoices.json?api_key=be4dxxxxxxxxxxxxxxxxxxxxxxxxx&status%5B%5D= sent'
--header 'accept: application/json'
--header 'content-type: application/json'

{"invoices":[{"id":188888315,"status":"final","archived":false,"type":"Invoice",.......,"pagination":{"total_entries":5,"current_page":1,"total_pages":1,"per_page":10}}

@tiagof tiagof added the bug Something isn't working label May 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant