kean / Get

Web API client built using async/await
MIT License
937 stars 74 forks source link

Problem with sending post requests #76

Closed fklingenberg closed 1 year ago

fklingenberg commented 1 year ago

Hey, I have a problem with the API client. I can't send requests with a post budy if one of the values is a boolean. Am I doing something wrong? Bildschirm­foto 2023-03-03 um 00 04 11

kean commented 1 year ago

Hi, body has to be Encodable, and the heterogeneous dictionary isn't. I would suggest either passing a dictionary of type [String: String], which is Encodable, or creating a custom Encodable struct to represent these parameters (recommended).