miketwenty1 / zebedee-rust

unofficially supported zebedee api rust sdk
8 stars 10 forks source link

Serialize test_get_userid_by_gamertag into a proper struct #16

Closed miketwenty1 closed 1 year ago

miketwenty1 commented 1 year ago

We have a fn: get_userid_by_gamertag

This only returns id, and we are making the response serialized with StdResp<Option<HashMap<String, String>>> is over generic for such a simple response. We should should should create a struct that serializes to grab id

struct UserInfo {
   "id": String
}
miketwenty1 commented 1 year ago

this turned out to be a bit more complicated. https://github.com/miketwenty1/zebedee-rust/commit/e6fc1131372022984d938536b5d32efc1bccd211 closes this.