I'm not sure you can do this so easily.
But even if you manage to use the android.os.Bundle on your server, you really should not, because you are stuck in the Android format, which may eventually change.
Aside from the Android app, it really is a matter of decoupling your decision. And you can do this using a neutral format to transfer data through a socket connection. Thus, a change in the Android API does not necessarily lead to a change in your PC server implementation.
I would recommend using XML, JSON or YAML format.
Thus, you probably have to turn the translator from android.os. Put in a neutral format of your choice in your Android application, but you will have the opportunity to unleash your decision.
Another advantage is that if tomorrow you need to connect a new application to your server, you do not have to deal with the Android API in the new application.
source share