stacks-blockchain-api icon indicating copy to clipboard operation
stacks-blockchain-api copied to clipboard

Incorrect units on Namespace price API

Open bilalanees98 opened this issue 2 years ago • 3 comments

Describe the bug The response returned by the API dictates that units=STX, however the actual amount returned is in Micro Stacks. To Reproduce Steps to reproduce the behavior:

  1. Hit the API: https://api.mainnet.hiro.so/v2/prices/namespaces/something
  2. Check response

Expected behavior I think the response should return 'uSTX' as the unit and the documentation should be updated to reflect this.

Screenshots Screenshot 2023-04-19 at 1 57 02 PM

Additional context Link to documentation: https://hirosystems.github.io/stacks-blockchain-api/#tag/Names/operation/get_namespace_price

bilalanees98 avatar Apr 19 '23 08:04 bilalanees98

This would be a big breaking change to complete. It's probably a Won't Fix unless a new endpoint would be better here. Would updating our documentation be helpful for this instead?

smcclellan avatar Apr 20 '23 15:04 smcclellan

Yes I think that would work as a short-term fix.

bilalanees98 avatar Apr 21 '23 05:04 bilalanees98

@smcclellan: Feel free to move this over to Docs repo along with the context/guidance on what needs to be updated.

sabbyanandan avatar Jul 31 '23 16:07 sabbyanandan