Skip to main content

A library to read/write data to bitcoin transactions as nulldata outputs.

Installation

pip install btctxstore

CLI usage

Write data to bitcoin transaction as nulldata new output. Prints new raw transaction with added output.

python -m btctxstore write_bin <unsigned rawtx hex> <data hex>

Read data from bitcoin transaction with nulldata output. Prints hex data from output.

python -m btctxstore read_bin <rawtx hex>

python usage

Write data to bitcoin transaction as nulldata new output. Prints new raw transaction with added output.

from btctxstore import BtcTxStore
api = BtcTxStore()

# using hex data
outputrawtx = api.write_bin(unsignedrawtx, hexdata)

# using pycoin tx and binary data
api.write(pycointx, bindata)

Read data from bitcoin transaction with nulldata output. Prints hex data from output.

from btctxstore import BtcTxStore
api = BtcTxStore()

# using hex data
hexdata = api.read_bin(rawtx)

# using pycoin tx and binary data
bindata = api.read(pycointx)

json-rpc usage

Starting the rpc server.

python -m btctxstore startserver --hostname=<hostname> --port=<port>

Write data to bitcoin transaction as nulldata new output. Prints new raw transaction with added output.

import pyjsonrpc
rpc = pyjsonrpc.HttpClient(url = "http://localhost:8080")

# using hex data
outputrawtx = rpc.write_bin(unsignedrawtx, hexdata)

Read data from bitcoin transaction with nulldata output. Prints hex data from output.

import pyjsonrpc
rpc = pyjsonrpc.HttpClient(url = "http://localhost:8080")

# using hex data
hexdata = rpc.read_bin(rawtx)

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

btctxstore-0.1.0.tar.gz (2.7 kB view details)

Uploaded Source

File details

Details for the file btctxstore-0.1.0.tar.gz.

File metadata

  • Download URL: btctxstore-0.1.0.tar.gz
  • Upload date:
  • Size: 2.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for btctxstore-0.1.0.tar.gz
Algorithm Hash digest
SHA256 ae22de1e90e6268b389a90ec2d37cbfb4527cb526ecba651f738e22cc4e997ac
MD5 f21c8a8b1a7b02da3dacbfe3f80b7292
BLAKE2b-256 58d97d8bfac220ec36f865420def52e20f5066f260ec398fce38e1554ae0176f

See more details on using hashes here.

Release history Release notifications | RSS feed

4.8.0

1 file

4.7.1

1 file

4.7.0

1 file

4.6.1

1 file

4.6.0

1 file

4.5.0

1 file

4.4.0

1 file

4.3.0

1 file

4.2.1

1 file

4.2.0

1 file

4.1.2

1 file

4.1.1

1 file

4.1.0

1 file

4.0.0

1 file

3.0.0

1 file

2.2.0

1 file

2.1.2

1 file

2.0.2

1 file

2.0.1

1 file

2.0.0

1 file

1.1.1

1 file

1.0.1

1 file

1.0.0

1 file

0.1.1

1 file

This release

0.1.0 This release

1 file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page