tokenly/swapbot-op-return

Encodes and Decodes OP_RETURN data used to trigger custom Swapbot actions

Maintainers

Package info

github.com/tokenly/swapbot-op-return

pkg:composer/tokenly/swapbot-op-return

Statistics

Installs: 7

Dependents: 0

Suggesters: 0

Stars: 1

Open Issues: 0

dev-master 2016-01-14 16:52 UTC

This package is not auto-updated.

Last update: 2026-03-11 01:50:45 UTC


README

Encodes and Decodes OP_RETURN data used to trigger custom Swapbot actions.

Usage

Here is an example of how to create Swapbot OP_RETURN data to specify a custom destination for a swap:

$new_destination_address = '1JztLWos5K7LsqW5E78EASgiVBaCe6f7cD';
$encoder = new Tokenly\SwapbotOpReturn\Encoder();
$hex_string = $encoder->buildDestinationInstruction($new_destination_address);

echo $hex_string.PHP_EOL;

// 53574150424f540000c56cb39f9b289c0ec4ef6943fa107c904820fe0980df2772