From 48928fed65b31d13c08b62b99edc98f850abfa66 Mon Sep 17 00:00:00 2001 From: "flyingscorpio@clevo" Date: Fri, 2 Dec 2022 13:34:18 +0100 Subject: [PATCH] Deserialize to json --- src/lib.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 4285ff5..8ccac2d 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,4 +1,5 @@ use reqwest::Url; +use serde_json::Value; mod token; @@ -29,7 +30,7 @@ impl ApiClient { .send() .await .unwrap() - .text() + .json::() .await .unwrap(); println!("{:#?}", res); @@ -52,7 +53,7 @@ impl ApiClient { .send() .await .unwrap() - .text() + .json::() .await .unwrap(); println!("{:#?}", res);