Activation
To activate the SL Oracle the user needs to include the following event in their smart contract
root@docker-s-6vcpu-16gb-nyc3-01:~# lightning-cli getroute 02f6725f9c1c40333b67faea92fd211c183050f28df32cac3f9d69685fe9665432 200000000 0
{ "route" :
[
{ "id" : "02f6725f9c1c40333b67faea92fd211c183050f28df32cac3f9d69685fe9665432", "channel" : "505231:2001:1", "msatoshi" : 200000000, "delay" : 9 } ] }
root@docker-s-6vcpu-16gb-nyc3-01:~# lightning-cli decodepay lnbc1712393610p1pdx8n8mpp5c72tc40vzyf9deqm5lzn76404heejady02l494ykke3vm3x44y8qdy2gfkx7cmtwd68yetpd5azqv339cunvgz42dzzqen0wgsyymr0vd4hxarjv4sk6gznv96x2mrvd96x2grnw35kx6m9wgs8sgp5ypskuepqf35kw6r5de5kueeqwd6xjcmtv4ezq7pqxvcqpggq86huylgdcd4st0d8thgdlw67tefjkhrnssyf8zk2s9cu37hdanwm6q96llg5zgjckwe7jamsmxnp4vy4q7vyulv57d9yg0wm7df0cpgwgu2m
{ "currency" : "bc", "timestamp" : 1516489979, "expiry" : 3600, "payee" : "02f6725f9c1c40333b67faea92fd211c183050f28df32cac3f9d69685fe9665432", "msatoshi" : 171239361, "description" : "Blockstream: 21.96 USD for Blockstream Satellite sticker x 4 and Lightning sticker x 3", "payment_hash" : "c794bc55ec111256e41ba7c53f6aafadf39975a47abf52d496b662cdc4d5a90e", "signature" : "30440220400fabf09f4370dac16f69d77437eed79794cad71ce10224e2b2a05c723ebb7b0220376f402ebff45048962cecfa5ddc366986ac2541e6139f653cd2910f76fcd4bf" }
root@docker-s-6vcpu-16gb-nyc3-01:~# lightning-cli connect 02f6725f9c1c40333b67faea92fd211c183050f28df32cac3f9d69685fe9665432 104.198.32.198 9735
{ "id" : "02f6725f9c1c40333b67faea92fd211c183050f28df32cac3f9d69685fe9665432" }
root@docker-s-6vcpu-16gb-nyc3-01:~# lightning-cli getpeers
{ "peers" :
#!/usr/bin/env bash
docker run --rm -v /scratch/bitcoin/mainnet/clightning:/root/.lightning --entrypoint /usr/bin/lightning-cli cdecker/lightningd:master "$@"
root@docker-s-6vcpu-16gb-nyc3-01:~# chmod +x /usr/local/bin/lightning-cli
root@docker-s-6vcpu-16gb-nyc3-01:~# lightning-cli getinfo
{ "id" : "03e71ed1bbedcf41d97e06ef3dfe4cdf79e871e9a3c809ab32b78e71dea45bf78c", "port" : 9735, "address" :
[ ], "version" : "v0.5.2-2016-11-21-1414-g5eceaa7", "blockheight" : 505236 }
root@docker-s-6vcpu-16gb-nyc3-01:~# mkdir -p /scratch/bitcoin/mainnet/clightning
root@docker-s-6vcpu-16gb-nyc3-01:~# docker run --rm --name lightning --network container:bitcoind_mainnet -v /scratch/bitcoin/mainnet/bitcoind:/root/.bitcoin -v /scratch/bitcoin/mainnet/clightning:/root/.lightning --entrypoint /usr/bin/lightningd cdecker/lightningd:master --network=bitcoin --log-level=debug
...
lightningd(1): Hello world from 03e71ed1bbedcf41d97e06ef3dfe4cdf79e871e9a3c809ab32b78e71dea45bf78c aka SLICKERGOPHER #03e71e (version v0.5.2-2016-11-21-1414-g5eceaa7)!
root@docker-s-6vcpu-16gb-nyc3-01:~# cat /usr/local/bin/bitcoin-cli
#!/usr/bin/env bash
docker run --rm --network container:bitcoind_mainnet -v /scratch/bitcoin/mainnet/bitcoind:/data dougvk/bitcoind:latest bitcoin-cli "$@"
root@docker-s-6vcpu-16gb-nyc3-01:~# chmod +x /usr/local/bin/bitcoin-cli
root@docker-s-6vcpu-16gb-nyc3-01:~# bitcoin-cli getinfo
{
root@docker-s-6vcpu-16gb-nyc3-01:~# git clone https://github.com/dougvk/lightning-node.git
root@docker-s-6vcpu-16gb-nyc3-01:~# cd lightning-node
root@docker-s-6vcpu-16gb-nyc3-01:~/lightning-node# docker build . -t dougvk/bitcoind
[{"encrypted": false, "parentPublicKey": "0243a3ff5442367e3efd3d81a9fd9366bb3d0315ceb4e417bdc0c0c27bb30379b7", "token": "eyJhbGciOiJFUzI1NksiLCJ0eXAiOiJKV1QifQ.eyJpc3N1ZWRBdCI6IjIwMTctMTEtMDFUMTA6NTk6MjMuMTM2MTgwIiwiY2xhaW0iOnsid2Vic2l0ZSI6W3sidXJsIjoiaHR0cDovL2Rhbi52b25rb2hvcm4uY29tIiwiQHR5cGUiOiJXZWJTaXRlIn1dLCJhY2NvdW50IjpbeyJpZGVudGlmaWVyIjoiZGFudmsiLCJwcm9vZlVybCI6Imh0dHBzOi8vdHdpdHRlci5jb20vZGFudmsvc3RhdHVzLzkyMzc1MjgyNDQ1ODEzNzYwMSIsIkB0eXBlIjoiQWNjb3VudCIsInNlcnZpY2UiOiJ0d2l0dGVyIiwicHJvb2ZUeXBlIjoiaHR0cCJ9LHsiaWRlbnRpZmllciI6InZvbmtvaG9ybiIsInByb29mVXJsIjoiaHR0cHM6Ly9naXN0LmdpdGh1Yi5jb20vdm9ua29ob3JuLzEyMjA0NTczYjg1OGYwODUxNzI4NTAzZjE5Zjc1NDNjIiwiQHR5cGUiOiJBY2NvdW50Iiwic2VydmljZSI6ImdpdGh1YiIsInByb29mVHlwZSI6Imh0dHAifSx7ImlkZW50aWZpZXIiOiIxNmNhV3lNUEFxZVFVUWl6TnlCWE5qNVNrOWtmaU1wcWh3Iiwicm9sZSI6InBheW1lbnQiLCJAdHlwZSI6IkFjY291bnQiLCJzZXJ2aWNlIjoiYml0Y29pbiJ9XSwibmFtZSI6ImRhbnZrIiwiaW1hZ2UiOlt7ImNvbnRlbnRVcmwiOiJodHRwczovL3ZvbmtvaG9ybi5maWxlcy53b3JkcHJlc3MuY29tLzIwMTcvMDMvZGFuLXZvbi1rb2hvcm4uanBnIiwi |