Hi everyone!

Just made a simple HTTP client. It's based on Nim std/httpclient, has no 
additional dependencies and has nice (at least I think so) API. A couple of 
examples:
    
    
    import yahttp
    
    # Getting HTTP response statuse code
    echo get("https://www.google.com/";).status
    
    # Making request with query params and accessing response body as JSON
    let laptopsJson = get("https://dummyjson.com/products/search";, query = 
{"q": "Laptop"}).json()
    echo laptopsJson["products"][0]["title"].getStr()
    
    
    Run

Check it out if you are interested - <https://github.com/mishankov/yahttp> 
Feedback is appreciated :)

Reply via email to