Skip to content

A minimal HTTP Request library for Android

Notifications You must be signed in to change notification settings

alimogh/http-request

 
 

Repository files navigation

http-request

A minimal opinionated http request library for Android

Supported Android versions: Android 14

Usage

POST example

new HttpRequestTask(
        new HttpRequest("http://httpbin.org/post", HttpRequest.POST, "{ \"some\": \"data-æøå\" }" ),
        new HttpRequest.Handler() {
            @Override
            public void response(HttpResponse response) {
                if (response.code == 200) {
                    textView.setText(response.body);
                }
            }
        }).execute();

Install

compile 'com.apptakk.http_request:http-request:0.3.0'