-
Notifications
You must be signed in to change notification settings - Fork 14
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
Improve post addresses transactions #568
Conversation
If a tx was associated with 2 addresses and we were requesting the txs of multiple addresses, if the 2 addresses were there, we were returing twice the same tx.
13c80b7
to
5c7c1ff
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
Why this method is |
You can query transactions for multiple addresses, you pass them in the POST body. As we paginate we don't return more transactionos, limit is the same as the |
POST is usually used to create a resource
|
yes, but REST doesn't have a nice way to request multiple items, so it's quite common to use POST for that kind of situation. The other solution is to go with chain of query param: |
I keep forgetting that |
POST /addresses/transactions
was returning duplicate tx if multiple addresses of to the body share some common tx.We also added
fromTs
andtoTs
optional query params to that endpoint to ease the pagination work.