1

I have the following requirement: I have 2 apps with the same sign key.

  1. Login app A and get token(this toke is just a string)
  2. From app A open and pass the token to B <- HOW TO DO THIS
  3. Receive the token and login in B and none other app.

I'm reading this: https://developer.android.com/training/sharing/index.html and I can't find how send data from one app to an specific app.

I don't want the chooser(https://stackoverflow.com/a/41185310/2139691) let the user send the token to any other app.

Phantômaxx
  • 37,352
  • 21
  • 80
  • 110
Ricardo
  • 7,143
  • 11
  • 57
  • 100

1 Answers1

2

You can try find passing data through intent?

Intent launchIntent = 
getPackageManager().getLaunchIntentForPackage("com.package.address");

launchIntent.putExtra("data", data);

startActivity(launchIntent);
Joshua Best
  • 246
  • 1
  • 13