Sanket Kachhela
Sanket Kachhela

Reputation: 10856

how to use google Authorization service in our android application?

i am making google calendar application in android and i don't know how to use google Authorization service in our android application?

Upvotes: 2

Views: 1043

Answers (3)

jigspatel
jigspatel

Reputation: 410

HttpClient httpclient = new DefaultHttpClient();
HttpPost httppost = new HttpPost("<URL HERE>");

try {

    List<NameValuePair> parameters = new ArrayList<NameValuePair>(2);
    parameters.add(<name_value_pair>);
    parameters.add(<name_value_pair>); 
    httppost.setEntity(new UrlEncodedFormEntity(parameters));


    HttpResponse response = httpclient.execute(httppost);

    StatusLine returned_status = response.getStatusLine();
    int status_code = returned_status.getStatusCode();


} catch (ClientProtocolException e) {
    // TODO Auto-generated catch block
} catch (IOException e) {
    // TODO Auto-generated catch block
}

Upvotes: 1

Vineet Shukla
Vineet Shukla

Reputation: 24031

This project describes google auth and this tutorial for calendar.

Upvotes: 2

Related Questions