iTwin / access-control-client

https://developer.bentley.com/apis/access-control/
MIT License
1 stars 1 forks source link

Return types for `Role` and `Member` in some API requests could be improved #9

Open veekeys opened 1 year ago

veekeys commented 1 year ago

We started to use the client package and its great! Thank you for that.

We have noticed some of the types could be improved, though. Mostly it is about interfaces of Member and Role.

Role:

Member

My suggestion would be to review every api call and update the types returned. We could have single Member and Role interfaces declaration and then just use typescript utility types to adjust the interface depending on the request. I think it would improve the quality of the package and we could fully trust the types to ensure better code in an application too.

I would consider contribution if you agree, just not sure about timeline.

davidhjones commented 5 months ago

Great suggestion. I'm happy to accept contribution, or if we get to it first, we can try to knock it out. Will also depend on timeline :) -- lets keep the dialog open, and as someone jumps on this issue we'll assign accordingly.