Posting to Google Plus from Android app -


hi have problem when i'm trying post info android app google plus, code have share following:

public void shareongoogleplus(activity activity, string caption) {     plusshare.builder builder = new plusshare.builder(activity);      // set call-to-action metadata.     builder.addcalltoaction(             "create_item", /** call-to-action button label */             uri.parse("http://plus.google.com/pages/create"), /** call-to-action url (for desktop use) */             "/pages/create" /** call action deep-link id (for mobile use), 512 characters or fewer */);      // set content url (for desktop use).     builder.setcontenturl(uri.parse("https://plus.google.com/pages/"));     // set target deep-link id (for mobile use).     builder.setcontentdeeplinkid("/pages/", null, null, null);      // set share text.     builder.settext(caption);      activity.startactivityforresult(builder.getintent(), 0)  } 

this method called when button sharing pressed showing following dialog:

enter image description here

and when press share appears following dialog:

enter image description here

at androidmanifest have following permissions:

    <uses-permission android:name="android.permission.internet" /> <uses-permission android:name="android.permission.get_accounts" /> <uses-permission android:name="android.permission.use_credentials" /> 

and well:

<meta-data android:name="com.google.android.gms.version" android:value="@integer/google_play_services_version" /> 

finally @ android console i've found following message:

    03-10 16:00:51.033    2012-2017/? e/mp-decision﹕ num online cores: 2 reqd : 3 available : 4 rq_depth:3.300000 hotplug_avg_load_dw: 54 03-10 16:00:51.033    2012-2017/? e/mp-decision﹕ cpu:1 core_idx:1 nw:1.900000 tw:140 total_time_up:0.000000 03-10 16:00:51.033    2012-2017/? e/mp-decision﹕ cpu:2 core_idx:2 nw:2.700000 tw:90 total_time_up:98.000000 03-10 16:00:51.673    1463-2123/? e/volley﹕ [90] sm.a: unexpected response code 400 https://www.googleapis.com/plus/v1whitelisted/people/me/activities?language=en-au&notifycircles=false&preview=false&shareongoogleplus=true 03-10 16:00:51.673   1463-18889/? e/insertactivityoperation﹕ null     sg             @ sm.a(sourcefile:145)             @ rq.run(sourcefile:105) 03-10 16:00:51.783     696-1212/? e/enterprisecontainermanager﹕ containerpolicy service not yet ready!!! 

thanks in advance!

if you're having problems debugging issues while writing app activities, should try enabling debug googleplusplatform:

adb shell setprop log.tag.googleplusplatform verbose 

after adding more details of following errors.

e/volley﹕ [90] sm.a: unexpected response code 400 https://www.googleapis.com/plus/v1whitelisted/people/me/activities?language=en-au&notifycircles=false&preview=false&shareongoogleplus=true 

and make sure doing wrong in code when requesting google api. know it's not answer more helpful digging out more info errors. response code 400 states request cannot fulfilled due bad syntax.


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -