Twetch Developer

Twetch Developer

    ›Protocol

    Protocol

    • Introduction
    • Posting
    • Likes
    • Follows
    • Votes
    • Purchases
    • Feature requests
    • Authentication
    • Twetch API

    twetch-js

    • Overview
    • Library
    • Storage
    • Wallet
    • CLI

    Twetch Pay

    • Overview

    Encryption

    • Overview
    • Create a conversation
    • Send a message
    • Read messages

    Purchases

    Purchasing features

    Twetch features can be purchases by broadcasting a Bitcoin transaction adhering to the ABI schema for that action.

    Each purchase implements a custom Bitcom prefix address.

    To get the amount to pay for each feature, use the payees endpoint detailed here.

    Twetch Chat

    Action: twetch/chat@0.0.1

    PositionExample valueDescriptionNotes
    00OP_FALSE opcode
    1OP_RETURNOP_RETURN opcode
    21chatYSaPVVSQ6TwtpASbQQQcKqS1DnMfTwetch Chat purchase protocol prefix
    3twetchDefault twetch
    4d11a0816-74da-4ac5-9ca6-fc1bec34d9f5Invoice
    5Pipe characterProtocol boundary
    615PciHG22SNLQJXMoSUaWVi7WSqc7hCfvaAIP protocol prefix
    7BITCOIN_ECDSABITCOIN_ECDSA
    818fmsWS5DHQ2ZsV54RDxTfQd2cM8vYGQMPSigning address
    9IL3LpSk7Ci3Dj1i84NyT4R3RQO9UyoxfK6FcRkQO+ZGOIElhx8Wgh0PJpExN5T4U8KIXj3quqtqs+rFUZ8dRJ+U=Signature of hash of a Buffer of an array of fields 2-6**

    Example Twetch Chat purchase transaction:

    https://bitcoinfiles.org/tx/f154c90c39791e9040e0cbaaee37c759d830b6f7b0d515824a74ebd2eddcbb1f

    Dark Mode

    Action: twetch/dark-mode@0.0.1

    PositionExample valueDescriptionNotes
    00OP_FALSE opcode
    1OP_RETURNOP_RETURN opcode
    21darkqXvZeAMCq7e3TEks9tVGTqcxpar1Twetch Dark Mode purchase protocol prefix
    3twetchDefault twetch
    49477e97e-a284-45d3-8edc-ea5549e410faInvoice
    5Pipe characterProtocol boundary
    615PciHG22SNLQJXMoSUaWVi7WSqc7hCfvaAIP protocol prefix
    7BITCOIN_ECDSABITCOIN_ECDSA
    817p7ht4QxtuF5wUkfd5zGn2g3rMCei9oZFSigning address
    9INrKRlkMA9cMwK0kg5Ic6IH3eeyWJWOBHyoDxDqCewWjAEaqIyo08g08aKD3h1PLLpRFA54LpooQfVNkYzn4sgk=Signature of hash of a Buffer of an array of fields 2-6**

    Example Dark Mode purchase transaction:

    https://bitcoinfiles.org/tx/4760753ea49861aa9a35f6fade92f9b722a8fca436418068c1b3a6e2d786749b

    Tweet from Twetch

    Action: twetch/tweet-from-twetch@0.0.1

    PositionExample valueDescriptionNotes
    00OP_FALSE opcode
    1OP_RETURNOP_RETURN opcode
    21rektHxYCXnfS5v8mUqKrLNK1szY8F3MRTweet from Twetch purchase protocol prefix
    3twetchDefault twetch
    4ed361106-2f2a-4a3a-afe2-ea1c6954337aInvoice
    5Pipe characterProtocol boundary
    615PciHG22SNLQJXMoSUaWVi7WSqc7hCfvaAIP protocol prefix
    7BITCOIN_ECDSABITCOIN_ECDSA
    81A6NKk4RHHDR35NvoPWqcC8tfSnXJgG3w5Signing address
    9IEo8ogWpJRiTHdcnCsffEmQ3nm9ORpuP8zYy41BA5ckTdVcvsolHGDxNSvlmgjZXQ0gr07ME/GLmbc4A9IthegI=Signature of hash of a Buffer of an array of fields 2-6**

    Example Tweet from Twetch purchase transaction:

    https://bitcoinfiles.org/tx/48190fcc7b3392666a233bd65c935cb09bd4526e848b56d09725067fd845e9f1

    Custom Invites

    Action: twetch/invites@0.0.1

    PositionExample valueDescriptionNotes
    00OP_FALSE opcode
    1OP_RETURNOP_RETURN opcode
    21nvitebtM2ttv4wqyBXKm4XtYjke79F9KInvites purchase protocol prefix
    3twetchDefault twetch
    4bdd5f6a8-3c77-4052-8900-51178f7b800cInvoice
    5Pipe characterProtocol boundary
    615PciHG22SNLQJXMoSUaWVi7WSqc7hCfvaAIP protocol prefix
    7BITCOIN_ECDSABITCOIN_ECDSA
    81sNJWUrAYfdxAKN1zGq3t9hwyR6ynQwasSigning address
    9IPcQtNrUWLxjINkYcEPTgYQoiAN1HtFtIdGQ1vPnsxuBI3EcL4Tk1NPNahK9KC70NkTzTMNZNL0zRRotlZr1om0=Signature of hash of a Buffer of an array of fields 2-6**

    Example Invites purchase transaction:

    https://bitcoinfiles.org/tx/46820b6fbb638498840bc21d32b3e3393fec148748544c92db8794334c2c8e56

    Advanced Search

    Action: twetch/search@0.0.1

    PositionExample valueDescriptionNotes
    00OP_FALSE opcode
    1OP_RETURNOP_RETURN opcode
    21Looky2yvbjWiXE61Ehb9S33wE2wDSLVjDAdvanced Search purchase protocol prefix
    3twetchDefault twetch
    4191c4888-552f-40b3-9c7a-9940e66f40a6Invoice
    5Pipe characterProtocol boundary
    615PciHG22SNLQJXMoSUaWVi7WSqc7hCfvaAIP protocol prefix
    7BITCOIN_ECDSABITCOIN_ECDSA
    81MJUq4FFES23UVnBfnQnopAnjtDA68aa2tSigning address
    9H0UY87Pp6df4vPWgbGkR3e/fT/GlDou/fd9Gd7DN+cC+IN38ckQrPjAbTz4bbnSmw6egSW0xjjtUEHxKuvAuQt0=Signature of hash of a Buffer of an array of fields 2-6**

    Example Advanced Search purchase transaction:

    https://bitcoinfiles.org/tx/97b4a5b93510a69ac5958f332f629f18fe5244f074492927d8845882edb41ea2

    **The process outlining how to sign Twetch data is detailed here.

    ← VotesFeature requests →
    • Purchasing features
      • Twetch Chat
      • Dark Mode
      • Tweet from Twetch
      • Custom Invites
      • Advanced Search