Accept Bitcoin donations on Twitch, and integrate them into your alerts!

Overview

The system in action

Check out how seamlessly the project works!

Support the project

You can tip me with some sats here!
This is, and always will be, entirely free to use of course!

Rough test setup guide

This is currently intended for testing only.
You need to have git, python, and it's virtualenv module installed.

  1. Clone the repo and cd into it
  2. Create and enable a virtualenv
  3. In the venv, run pip install -r requirements.txt
  4. Get an lntxbot wallet
  5. Get an API key from lntxbot by messaging it /api full
  6. Log in to https://streamlabs.com/
  7. Register an App
    As this is an app just for you, you can fill the name, description
    phone, and email fields with whatever you want. They are not relevant.
    In the "Whitelist Users" field, enter your Twitch username.
    In "Redirect URI", enter "http://localhost:6969".
  8. After hitting "Create", leave this page open for now, as it contains
    your Client ID and Secret, which you will need in the next step
  9. Run python initial_setup.py and follow the instructions (enter localhost as the IP for now)
  10. Run python wait_for_token.py and leave this running
  11. On the Streamlabs App page, click the link that says "Sample Authentication URL"
    towards the bottom of the page
  12. Click "Approve"; this should redirect you to a plain text page that tells you to stop the server
  13. Go back to the terminal that is running wait_for_token.py,
    and hit ctrl+c to stop the server
  14. You should now be able to run . ./start_lnbits.sh, which should launch
    LNbits in the background, making it reachable at http://localhost:5000/
  15. Run python webhook.py and leave it running in the background
  16. In LNbits, create a wallet, and enable the SatsPayServer extension under "Manage extensions"
  17. In SatsPayServer, hit "NEW CHARGE," and fill out all the required fields
    In the "webhook" field, enter http://localhost:5001/
  18. Pay the charge with any lightning wallet
    (After hitting "CREATE CHARGE," the charge should appear in a list after
    an automatic refresh. On the very left side of that list entry is a small
    grey button that will open the payment link in a new tab.)

If everything worked, you should see a new donation pop up here (remember to refresh).
If something went wrong, please submit an issue!

Contributing

I want this to be a project that allows streamers on Twitch to integrate Bitcoin donations
into their on-stream alerts with as little setup as possible.
Things you can help with:

  • Clarifying steps in the guide, or linking to/writing more detailed guides to get non-technical users up to speed
  • Writing scripts that would make this run on Windows (in case a streamer opts for self-hosting on Windows)

I'm not at all used to maintaining projects with other contributors, so I don't know, just follow the
common etiquette or whatever if you wanna help :)
I would especially appreciate help with just making things cleaner and more efficient (I'm not a professional),
as well as potentially integrating services other than Streamlabs (not sure if there are any
that are widely used like Streamlabs and actually have an API for this).

Comments
  • Create LNbits extension

    Create LNbits extension

    Optimally, parts of this repo should become an LNbits extension:

    • Most of what is currently in settings.json could be set via UI
    • API endpoint that serves as redirect for Streamlabs access_token (essentially wait_for_token.py)
    • webhook.py as background service

    The extension should also allow modification of the donation format that is sent here.

    The extension's front end would ideally be a simple tipping form that asks for "Name," "Message," and "Amount" in either sats or any of the supported currencies, converting the amount to sats to create an invoice.
    Another option that would be great to have available is a Twitch login button that auto-fills the "Name" field, and sets the identifier to a unique ID value, like the Twitch User ID (see here).

    I've created a branch to work on this: https://github.com/Fittiboy/lnbits/tree/TwitchAlerts Will be closed by lnbits/lnbits#227

    enhancement help wanted 
    opened by Fittiboy 5
  • Your tip link doesn't work from BLW

    Your tip link doesn't work from BLW

    Hi,

    I tried to send tip from the BLW wallet (@btcontract - author of the LNURL) but I got the error:

    "requirement failed: Action domain mismatch"

    From the Blixt wallet - there is everything OK.

    I think your chain URLs from LNURL communication has different domains but the LNURL protocol requires to have the same domains (#6 point - "url domain must be the same as callback domain at step 3" in example comment)

    Is it your the bug or the BLW?

    opened by Perlover 3
  • Integreate StreamElements API

    Integreate StreamElements API

    It appears that StreamElements is currently working on providing a nice API. They have a WIP API reference which includes an endpoint to post tips, exactly what is needed to integrate this.

    Would be great to have this!

    documentation enhancement help wanted 
    opened by Fittiboy 1
  • Sovereign

    Sovereign

    This PR adds a guide on how to cut out all middlemen and run this in self-sovereign mode.
    The Bitcoin way.
    Closes #5

    • [ ] How to set up your own node (Just link to Raspiblitz)
    • [ ] How to change the funding source of LNbits
    documentation enhancement 
    opened by Fittiboy 0
  • Enable full self-sovereignty

    Enable full self-sovereignty

    The original purpose of this project was to cut out all middlemen.
    To this end, the only change that has to be made is the LNbits funding source.
    Two short guides are required for this:

    • [ ] How to set up your own node (Just link to Raspiblitz)
    • [ ] How to change the funding source of LNbits

    It should also be considered to potentially use Raspiblitz' LNbits

    documentation enhancement 
    opened by Fittiboy 0
  • Automate Bitclouds.sh Setup

    Automate Bitclouds.sh Setup

    A lot of the setup required for Bitclouds.sh hosting can be automated.

    • [ ] Purchasing a Bitclouds VPS instance
    • [ ] Checking remaining balance
      • [ ] Low balance alerts
        • [ ] Discord webhook?
        • [ ] Telegram bot?
        • [ ] Email?
    • [ ] Getting a top-up invoice
    • [ ] Installing git and python3-venv
    • [ ] Caddy
      • [ ] Adding the repo
      • [ ] Installing caddy
      • [ ] Creating the Caddyfile
    documentation enhancement 
    opened by Fittiboy 0
  • Add hosting guides for #2

    Add hosting guides for #2

    This PR adds guides on how to actually host this publicly.
    Closes #2

    • [ ] Purchasing a Bitclouds VPS instance
    • [ ] Checking remaining balance
      • [ ] Low balance alerts
        • [ ] Discord webhook?
        • [ ] Telegram bot?
        • [ ] Email?
    • [ ] Getting a top-up invoice
    • [ ] Installing git and python3-venv
    • [ ] Caddy
      • [ ] Adding the repo
      • [ ] Installing caddy
      • [ ] Creating the Caddyfile
    documentation enhancement 
    opened by Fittiboy 0
  • Create guide on how to deploy publicly

    Create guide on how to deploy publicly

    Currently, the system is fully functional, but does not yet include a guide on how to publicly deploy.

    • [ ] Acquiring a domain
      • [ ] Full domain name
      • [ ] Duck DNS
    • [ ] Guide on how to self-host
      • [ ] Setting up nginx
        • [ ] SSL cert via certbot
        • [ ] Enabling reverse-proxy
        • [ ] Opening the necessary port (443)
      • [ ] Setting up Cloudflare
        • [ ] Creating an account
        • [ ] Adding domain to Cloudflare
        • [ ] Hiding behind Cloudflare
        • [ ] Whitelisting Cloudflare IP range
    • [ ] Guide on how to host via Bitclouds
      • [ ] Basic Bitclouds setup guide
      • [ ] Keeping Bitclouds instance up (keep funding it!)
      • [ ] Installing git, python3-venv, and Caddy
      • [ ] Creating a Caddyfile
    documentation enhancement 
    opened by Fittiboy 0
Releases(v1.0.2)
  • v1.0.2(Aug 4, 2021)

  • v1.0.1(Aug 3, 2021)

    This small update adds user whitelisting! The whitelist_user.py script allows users to add their user ID to the LNBITS_ALLOWED_USERS environment variable, preventing people from creating wallets on their LNbits instance. This change is reflected in the guide as well.

    Source code(tar.gz)
    Source code(zip)
  • v1.0.0(Aug 3, 2021)

A simple program written in python to convert: USD, EUR & BTC to BRL

CoinsPrice This is a simple program written in python to convert: USD EUR BTC to BRL, and I used an API to get coins price. Take a look at the window

Luiz Henrique 1 Feb 09, 2022
Bridge between L1 (Ethereum) and L2 (cheapETH)

The ETH chain and the cheapETH chain. We can assume the ETH chain has ~1000x more value than the cheapETH chain.

107 Oct 12, 2022
The leading native Python SSHv2 protocol library.

Paramiko Paramiko: Python SSH module Copyright: Copyright (c) 2009 Robey Pointer 8.1k Jan 08, 2023

Python FFI bindings for libsecp256k1 (maintained)

secp256k1-py Python FFI bindings for libsecp256k1 (an experimental and optimized C library for EC operations on curve secp256k1). Previously maintaine

Rusty Russell 29 Dec 29, 2022
SVSHI - Secure and Verified Smart Home Infrastructure

The SVSHI (Secure and Verified Smart Home Infrastructure) (pronounced like "sushi") project is a platform/runtime/toolchain for developing and running formally verified smart infrastructures, such as

Dependable Systems Laboratory 3 Oct 28, 2022
Buckley 2 Jul 24, 2022
Message Encrypt and decrypt software // allows you to encrypt the secrete message and decrypt Another Encryption Message. |

Message-Encrypy-Decrypt-App Message Encrypt and decrypt software // allows you to encrypt the secrete message and decrypt Another Encryption Message.

Abdulrahman-Haji 2 Dec 16, 2021
Generate Random ETH addresses and Private Keys and Saved to file.

ethgen.py Generate Random ETH addresses and Private Keys and Saved to file. ETH address the file is stored in ETH-address.txt. ETH private keys the fi

deanondroid 2 Dec 21, 2021
SDU experiment of introduction to the cryptography

Lab 01 (2 hrs): Programming Basics Program 1: Type Hint, String, Bytes, Hex, Base64 Lab 02 (4 hrs): Classical Cryptography Part 1 (3 hrs): Program 1:

1 Jan 03, 2022
Active github repos of all cryptocurrencies

This repo is to maintain the list of active repositories for all cryptocurrencies that https://codemask.org uses. The active list will be automaticall

CodeMask 5 May 20, 2022
GreenDoge is a modern community-centric green cryptocurrency based on a proof-of-space-and-time consensus algorithm.

GreenDoge Blockchain Download GreenDoge blockchain GreenDoge is a modern community-centric green cryptocurrency based on a proof-of-space-and-time con

40 Sep 11, 2022
Generate simple encrypted messages!

Premio's Shift is a very simple text encryption, you can use it to send secret messages to your friends. Table of Content Table of Content How it work

Peterson Adami Candido 3 Aug 06, 2021
Bot to trade crypto trading ranges

crypto-trading-bot Crypto bot with DCA or GRID trading strategy Sends notifictions to telegram chat Crypto bot with webhook feature which can be used

3 Jun 18, 2021
This python module can analyse cryptocurrency news for any number of coins given and return a sentiment. Can be easily integrated with a Trading bot to keep an eye on the news.

Python script that analyses news headline or body sentiment and returns the overall media sentiment of any given coin. It can take multiple coins an

185 Dec 22, 2022
Recover bitcon brainwallet

Bitcoin brainwallet recovery tool If you like it give it a star Programmed in Python | PySimpleGUI How it works From seed phrase create bitcoin privat

Adrijan 20 Dec 15, 2022
Connects to an active BitCoin Peer and communicates in order to locate a specific block number (height)

BitCoin-Peer-Client Connects to an active BitCoin Peer, and locates a predetermined block number (height) by downloading block headers. Once required

Henry Song 1 Jan 16, 2022
⚡ Automatically decrypt encryptions without knowing the key or cipher, decode encodings, and crack hashes ⚡

⚡ Automatically decrypt encryptions without knowing the key or cipher, decode encodings, and crack hashes ⚡

11.2k Jan 09, 2023
The (Python-based) mining software required for the Nintendo Switch mining project.

ntgbtminer - Nintendo Switch edition This is a version of ntgbtminer that works with the Nintendo Switch bitcoin miner. ntgbtminer ntgbtminer is a no

4 Jun 03, 2021
📊Python implementation of the Colin Talks Crypto Bitcoin Bull Run Index (CBBI).

Colin Talks Crypto Bitcoin Bull Run Index (CBBI) This is a Python implementation of the Colin Talks Crypto Bitcoin Bull Run Index (CBBI). It makes use

Kamil Monicz 86 Jan 02, 2023