Testing the transaction endpoints

Now that the blockchain network is set up, let's the test the endpoints that we created in the previous sections. 

Let's create a transaction and send it to the /transaction/broadcast endpoint. Go back to Postman and hit the /transaction/broadcast endpoint at the node, which is hosted on port 3001. Here, send some data as a transaction, as shown in the following screenshot:

The transaction data that you're sending can be any random data. All we need is the amount, the sender, and the recipient. Once the transaction data is added, let's send this request by clicking on the Send button. If the transaction is ...

Get Learn Blockchain Programming with JavaScript now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.