-1

i would like to use apigee android sdk in android app. By using android sdk, I would like to connect apigee end point proxy but api proxy has got Oauth 2.0 verification. How to access our proxy?


//Create client entity
String ORGNAME = "your-org";
String APPNAME = "your-app";        
ApigeeClient apigeeClient = new ApigeeClient(ORGNAME,APPNAME);
DataClient dataClient = apigeeClient.getDataClient();

String type = "item"; //entity type to be retrieved
Map queryString =  null; //we don't need any additional query parameters, in this case

//call getCollectionAsync to initiate the asynchronous API call    
dataClient.getCollectionAsync(type, queryString, new ApiResponseCallback() {    

//If getEntitiesAsync fails, catch the error
    @Override
    public void onException(Exception e) { 
        // Error
    }

    //If getCollectionAsync is successful, handle the response object
    @Override
    public void onResponse(ApiResponse response) {
        try { 
            if (response != null) {
                // Success
            }
        } catch (Exception e) { //The API request returned an error
                // Fail
        }
    }
}); 


Santanu Dey
  • 2,900
  • 3
  • 24
  • 38
Penguen
  • 16,836
  • 42
  • 130
  • 205

1 Answers1

1

There is currently no support for OAuth in the Android SDK.

Paul Dardeau
  • 2,589
  • 1
  • 13
  • 10