Yaniv Inbar의 GData
클라이언트를 사용하여 Android 앱에서 Picasa 앨범에 액세스하고 있습니다. 나는Picasa 피드를 가져올 수 있으며 업로드 및 다운로드가 가능합니다. 삭제할 수 없습니다.
AccountManager.getAuthToken(account, "lh2", null, activity, null, null);
를 통해 를 인증하고 사용자가 얻을 수있는 앨범 피드, 다운로드하고 사진을 업로드 할 수 있습니다. 내가 무엇 할 수 없다는 PicasaClient.executeDelete(Entry)
입니다 - 그것은 getFeed 및 업로드/다운로드 작업과 동일한 인증을 사용에도 불구하고 나에게 403 오류를주고 유지합니다.
삭제를 위해 client_id
및 client_secret
을 설정해야하나요. 가져 오기/가져 오기를 설정하지 않아도됩니까? 그렇다면 어디에서? Authenticating to OAuth2 Services는
URL url = new URL("https://www.googleapis.com/tasks/v1/users/@me/lists?key=" + your_api_key);
URLConnection conn = (HttpURLConnection) url.openConnection();
conn.addRequestProperty("client_id", your client id);
conn.addRequestProperty("client_secret", your client secret);
conn.setRequestProperty("Authorization", "OAuth " + token);
을 보여줍니다하지만 난 스택 어디서나 URLConnection
표시되지 않습니다. 나는 는 후크 authToken = authBundle.getString(AccountManager.KEY_AUTHTOKEN);
ClientLogin.Response clientLogin = new ClientLogin.Response();
clientLogin.auth = authToken;
어딘가에있을 것이다 같은데요 ...하지만 그것은 정확한 위치를 분명 아니다.
대단히 감사합니다. 내 하루를 저장합니다. – user854301
* 의원 성 * 의미, 진단 과정 중에 당신이 한 일 때문에 생긴 것입니까? 그것은 유용한 단어입니다! – LarsH