Bitcoin Forum
May 14, 2024, 10:04:00 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: How to decode a raw tx without having a full client?  (Read 509 times)
Kazimir (OP)
Legendary
*
Offline Offline

Activity: 1176
Merit: 1003



View Profile
August 23, 2017, 01:48:46 PM
 #1

Suppose I have a raw tx, let's say in in hex format. Is there a library or piece of code (preferably in javascript, php or python) that allows me to decode the raw tx data into a json representation or "readable" format? I.e. something that shows the transaction's inputs and outputs?

I know there are online tools to do this, such as Smartbit or Blockcypher. But I'm looking for something to do this client side.

In theory, there's no difference between theory and practice. In practice, there is.
Insert coin(s): 1KazimirL9MNcnFnoosGrEkmMsbYLxPPob
1715681040
Hero Member
*
Offline Offline

Posts: 1715681040

View Profile Personal Message (Offline)

Ignore
1715681040
Reply with quote  #2

1715681040
Report to moderator
1715681040
Hero Member
*
Offline Offline

Posts: 1715681040

View Profile Personal Message (Offline)

Ignore
1715681040
Reply with quote  #2

1715681040
Report to moderator
1715681040
Hero Member
*
Offline Offline

Posts: 1715681040

View Profile Personal Message (Offline)

Ignore
1715681040
Reply with quote  #2

1715681040
Report to moderator
Remember that Bitcoin is still beta software. Don't put all of your money into BTC!
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
defined
Hero Member
*****
Offline Offline

Activity: 574
Merit: 500


View Profile
August 23, 2017, 01:58:37 PM
 #2

I think https://coinb.in/#verify can do this offline, it uses javascript to run in your browser only.

I just tested it and it works offline.
TechPriest
Sr. Member
****
Offline Offline

Activity: 377
Merit: 282


Finis coronat opus


View Profile
August 23, 2017, 02:31:25 PM
 #3

You can try Pycoin it has some methods to do such operations.

In science we trust!
pebwindkraft
Sr. Member
****
Offline Offline

Activity: 257
Merit: 343


View Profile
August 23, 2017, 08:07:53 PM
 #4

if you are on unixoide systems, then this is were I started. It is at the shell level: https://github.com/pebwindkraft/trx_cl_suite
devans
Sr. Member
****
Offline Offline

Activity: 528
Merit: 368


View Profile
August 26, 2017, 08:44:51 PM
 #5

BitcoinJS is a JavaScript library for both Node.js and the browser that does what you're looking for.
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!