title: Is it possible to upload files to multiple google drive accounts synchronously using Drive API in Android?
body: <p>Details:- I want to synchronously upload three files to three different google drive accounts from my Android Application.My current implementation is uploading all the three files in just one (last logged-in) account.So i want to know whether is it technically possible to do so?</p>
  
  <p>1> Right now,I have three different classes for three Drive accounts.I am using Drive API and GooglePlay services gms:play-services:11.4.2 .
  Code snippet for initializing mGoogleApiClient:-</p>
  
  <pre><code> public void init(Activity context, final ICDCallback&lt;String&gt; cb) {
      if (this.mGoogleApiClient == null) {
          this.mGoogleApiClient = new Builder(context).addOnConnectionFailedListener(new OnConnectionFailedListener() {
              public void onConnectionFailed(@NonNull ConnectionResult connectionResult) {
                  cb.failure(connectionResult.getErrorMessage());
              }
          }).addConnectionCallbacks(new ConnectionCallbacks() {
              public void onConnected(@Nullable Bundle bundle) {
                  cb.success("");
              }
  
              public void onConnectionSuspended(int i) {
                  cb.progress(0);
              }
          }).addApi(Drive.API).addApi(Auth.GOOGLE_SIGN_IN_API, new GoogleSignInOptions.Builder(GoogleSignInOptions.DEFAULT_SIGN_IN).requestScopes(new Scope("https://www.googleapis.com/auth/drive.file"), new Scope[0]).requestEmail().build()).build();
      }
      if (this.mGoogleApiClient != null &amp;&amp; this.mGoogleApiClient.isConnected())
      {
          cb.success("");
      } else {
          connect();
      }
  }
  </code></pre>
  
  <p>2> Result:- This method is called each time the user is logged in and file uploading. But the mGoogleApiClient has always last logged-in google drive Account because of which I think,files are uploaded in the last logged-in account instead of three different accounts.</p>
  
  <p>3>So please what should i do in this case?
  i) Is it possible to save the user account info in respective class in current implementation and use it while uploading? Or is there any other better way to do that?
  ii) Can Google OAuth2.0 library help if i try to save any user specific account information in corresponding drive classes?</p>
  
  <p>Please suggest pointers to go ahead.</p>