7

I am new to the world of Blockchain and Ethereum has indeed become a second name for open source Blockchain.

Right now I am trying to grasp the concepts and there are really many wonderful blogs but I could not find a thread which explains the following problem :

Suppose, I as a developer want to make a smart contract on any blockchain(say Ethereum for now),now the execution, processing of that smart contract in Ethereum is done in its blockchain, which might have APIs exposing it.

So if say, I have an hybrid app and want my app users to see and modify the blockchain through the smart contract then what all things will the developer has to consider in mind while developing that kind of app.

And in general I want a detailed explanation on how can the smart contract executed on a web app or any app. This explanation might also be useful for many looking for answers in this field.

6

To interact with an Ethereum blockchain one

  • Has to have a private key to an address

  • Has to have ETH balance there

  • Has to be able to access Ethereum node to push out a transaction

In your case this might go either as a custodian party providing a blockchain service to your users

  • Your mobile app backend or service runs an Ethereum node (Parity/geth) or you subscribe an API service (etherscan)

  • You hold private keys and ETH balance for the users

  • Your mobile app calls your mobile app backend through your REST API or similar, then backend performs the transaction for the user

or without custodian risk:

  • Your mobile app directly communicates with a read only/sendRawTransaction Ethereum node

  • Users gets private keys generated in the mobile app

  • Users need to deposit or buy ETH and send them to the address inside the mobile app to have interaction balance

  • Transactions are completely generated on the client side

  • Mobile app pushes out a client side signed transaction using sendRawTransaction

For creating client side transactions you can take a look on this tutorial.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.