$apikey, "contractaddress" => $contractaddress, "from" => $from, "to" => $to, "password" => $password, "amount" => $amount) ); curl_setopt( $ch, CURLOPT_POSTFIELDS, $payload ); curl_setopt( $ch, CURLOPT_HTTPHEADER, array("Content-Type:application/json")); # Return response instead of printing. curl_setopt( $ch, CURLOPT_RETURNTRANSFER, true ); # Send request. $result = curl_exec($ch); curl_close($ch); # Decode the received JSON string $resultdecoded = json_decode($result, true); # Print the transaction id of the transaction echo $resultdecoded["txid"]; ?>