About Script Network

With television progressively turning into a cord-cutting, digital experience, Script.TV is focused on delivering a unique, industry-defining experience, using blockchain technology.

Although there are multiple options to consume content globally, Script.TV is the first to bring live television to the blockchain, with on-chain rewards through NFTs, gifts, and tokens by watching content every hour.

In this documentation, we have explained the functionalities, working mechanisms, and benefits of Script TV.

Introduction

Script.tv powers linear TV shows.

Linear TV is a visualization format where, contrary to on-demand TV, content is watched by many at the same time.

We combine it with web3, the new paradigm based on decentralized peer-2-peer networks returns the power to users, allowing the seamlessly integration of token cryptoeconomies and content delivery.

Furthermore we improve the experience with live NFT marketplace and watch-to-earn concept.

Script TV is a decentralized video delivery network that furnishes an expansive range of blockchain-enabled solutions to the problems related to the traditional video-streaming sector. The platform offers high-quality video streaming as well as multiple incentive mechanisms for decentralized bandwidth and content-sharing at a reduced cost as compared to conventional service providers. Script Network Defined

Script Network is the leading video delivery network powered by blockchain technology.

Script Network allows users to simultaneously watch video content and earn token rewards for relaying video to other users who are also watching the same content.

In the same vein as other sharing economy models, users opt-in to volunteering their spare bandwidth and computing resources to relay video to other users and earn token rewards for their contributions. Users can contribute to Script Network on any PC or Server. For video platforms, integrating Script Network into their video delivery stack enables them to reduce video delivery costs, deepen viewer engagement, and drive incremental revenues. By spending less on video delivery infrastructure, and more on rewarding their users, Script-enabled video platforms can grow their user base and gain market share. About Script Blockchain

The Script Blockchain is a purpose-built blockchain designed for video and data relaying from the ground up. Script’s unique multi-BFT consensus design combines a committee Validator Nodes with a second layer of community-run Validator Nodes. Validator Nodes propose and produce new blocks in the chain, while Lightning Nodes seal blocks and act as a check on malicious or non-functional Validator Nodes.

The Script blockchain mainnet enables the support for Turing-complete smart contracts. Smart contracts open up a new set of user experiences and attribution models for DApps built on the Script network.

For example, leveraging smart contracts on the Script network could enable fully digitized item ownership, innovative payment-consumption models, transparent royalty distributions, trustless crowdfunding mechanisms, and much more. This provides an additional layer of social and economic interactivity that supplements the core functionality of video and data delivery and significantly increases the engagement and retention of platform users.

In addition to the Validator and Lightning Nodes, the Script community members also host the Script Node, which forms the Script Network, a fully decentralized network for data delivery and, more generally, computing. This new fully decentralized technology stack adds the ability to capture live video, transcode it in real-time, cache and relay live stream video data to users globally - all through Script’s P2P network run by thousands of community members. Not a single central server or service is used in this pipeline. This is a huge challenge and a huge accomplishment.

The Script Token (SCPT) is the governance token of the Script protocol. SCPT is used to stake as a Validator and Lightning Nodes, contributing to block production and the protocol governance of the Script Network. By staking and running a node, users will earn a proportional amount of the new SCPT generated. The supply of SCPT is fixed at 1 billion and will never increase. SCPT is used for on-chain operations like payments to relayers for sharing a video stream, or for deploying or interacting with smart contracts. Relayers earn SCPT for every video stream they relay to other users on the network.

General Info

Script TV is built on the Script blockchain – a reliable, affordable, high-quality video publishing platform that utilizes purpose-built novel technology to operate efficiently and effectively—using decentralized infrastructure, Script.TV provides a video platform designed to radically improve the experience of using streaming platforms for users, content creators, and advertisers. Script.TV will be the first linear TV and film experience on the blockchain.

Using a decentralized blockchain for Script.TV, we solve the many shortcomings of the centralized media space, such as low CPMs as a consequence of intermediaries, sluggish payout times, launch delays, and a lack of analytical data for content partners. For users, there is no ability to get paid for what they watch and no opportunity to connect with community or content partners. The TV and film experience and their associated industries are disengaged and broken. Script.TV will mend this disconnection forever.

In simple terms, Script.TV is a two-sided platform: one side for content partners whose shows and films will be streamed on the platform, and one side for the viewer who will be able to view this content from anywhere in the globe. Film and TV on the Blockchain

The Script.tv protocol can also help tv stations combat the decline in viewership by offering a convenient bridge for mainstream and independent news, sports, and entertainment tv stations to move into the blockchain. Large media companies can safely introduce their content and live programming onto the blockchain, reaching new audiences, reducing hosting costs, and creating new streams of revenue through crypto and NFTs.

Script.tv aims to modernize live television for users, enabling them to interact through a live chat, thus adding a social element to television and creating financial incentives for watching ads. In essence, Script is the blockchain built for media streaming.

It is a decentralized solution that will help usher in the web 3.0 paradigm, providing the necessary infrastructure for the future of television, video hosting, and streaming. Interoperability & Scalability

Script Network is focused on developing NFTs, rewards, and content that can live in multiple worlds – either on the Script.TV platform, in the metaverse or even offline in the physical world. Script TV platform focuses on a geographical and interest-targeted approach for its users, brands, and partners. NFTs can be bought and traded within the Script Platform.

Metaverse: With a range of incumbent metaverse apps, Script Network will connect and collaborate to create an experience that offers NFTs purchased to be used in the metaverse. This gamified option brings even more potential use cases to Script NFTs.

Physical World: Script Network was built with a vision to help educate and bring millions of current content viewers over to blockchain. Part of this process will include being able to trade and stake and convert specific Script NFTs for real-world cinema tickets, access to events, and more.

Tokens

Script.TV will be a first-of-its-kind online TV platform in which both users and content publishers earn valuable tokens through video streaming. Script.TV will be a feature-rich application that provides users with round-the-clock entertainment through a range of exciting channels.

The network will use the blockchain-based Script token (SCPT) as a direct incentive for users to not only watch and discover great new content but also to contribute their computers’ bandwidth and memory to the network. Fundamentally this incentive mechanism is what powers the network and allows Script.TV to avoid the problems currently plaguing traditional streaming platforms.

Content partners earn SPAY tokens for every minute their content is watched on Script.TV and users earn SPAY tokens every time they watch programs on Script.TV. By operating and utilizing the Script. TV web app, any device can become a Script node able to earn users additional rewards for caching and distributing video data. $SCPT & $SPAY Storage

SCPT & SPAY are the two tokens on the Script Blockchain. To begin with, to ensure instant liquidity, ease of trading, and a platform to perform swapping with popular pairs at scale, SCPT will launch as an BEP-20/ SCR-20 token. This means that SCPT (and SPAY in the future) can be stored in popular wallets such as Metamask and Trustwallet.

Further down the line in our roadmap, we will perform a 1:1 conversion for SCPT and SPAY to the Script Blockchain. Users and content partners will have further flexibility on where to store SCPT and SPAY. Users and content partners can store, send and receive their tokens securely within their wallets on the Script Network. And as SCPT and SPAY are listed on more exchanges (both CEX & DEX), these will provide further storage options for users. Should users or content partners wish to store their tokens away offline, they will eventually be able to hold their tokens on hardware wallets.

Script NFTs About NFTs

Non-Fungible Tokens are digital proof of ownership connected to some content or asset. Each is unique and cannot be replaced by another or forged. Each NFT contains identifying information recorded within one or multiple smart contract/s. As NFTs are minted on blockchains, all information about them is publicly available and reliable. Popular objects for NFT tokenization include art objects (digital and real), items from virtual and game universes (characters, clothing, artifacts, weapons, equipment), collectibles, copyright, licensing, and certification. Script NFTs: How Will It Work?

For Script Network, NFTs will be used to create a piece of content that can be purchased, traded, and stored for value and will all be directly connected to the films and shows on Script.TV. Users will have an opportunity to claim and earn time-based rewards, stake valuable NFTs, earn off-chain rewards and gain access to events, screenings, and cinema tickets through the accumulation of SPAY tokens and Script NFTs.

For the development of most non-interchangeable tokens, several ERC standards are used on Ethereum. Script.TV will use Solidity smart contracts that allow users to mint Ethereum-based NFTs for heavily reduced fees via SPAY tokens. Later down the line, Script.TV will launch NFTs with cross-chain accessibility. A mechanism allowing content partners to create, trade, and use their own NFTs will be implemented into the Script.TV platform.

Script TV will allow content partners to use these NFTs to interact with their audience. During the broadcast, competitions, quizzes or gift giveaways may be held among the audience. And after the launch of the NFT marketplace, users will be able to sell the received tokens and NFTs at will.

Transactions

Transactions and payments to both content partners and users will be executed automatically through smart contracts. These contracts will also be used for verification and on-chain monitoring.

Through this, the network will maintain a public record of information on our immutable blockchain. Information about all the transactional operations of Script.TV will be available in our block explorer, which will function similarly to EtherScan.

This explorer will allow users to conveniently find data on transactions and tokens, information about smart contracts and reports, and will be used to track the latest actions and changes in the blockchain.

Wallet

Once you reach the Script Wallet site, take your device offline / put it in airplane mode, then click “Create Wallet.” Next, you will download an encrypted keystore file and create a wallet password. This encrypted keystore file on your computer will be used to unlock your wallet any time you want to access it. You will then need to copy down the mnemonic/seed phrase (and private key, if you choose to) and store them in a safe place.

Your mnemonic/seed phrase and private key are the only way to restore your Script wallet if you lose your keystore file and/or wallet password! Make sure you save them correctly and store them offline in a safe place (never online or in the cloud!).

Once your wallet has been created, you can re-connect your device and unlock your new Script Wallet.

If you are unlocking an existing wallet, we recommend you take your device offline while uploading your keystore or enter your mnemonic phrase or private key. Once the wallet has been unlocked, you’ll see a screen that says “you’re offline!” and will have the opportunity to connect to the internet before you continue to the wallet.

Once you’re in your Script wallet, you can check the balance of your Script Tokens.

Smart Contracts

The lack of transparency and red tape has frustrated users and content partners for decades within the media industry. To solve this, our smart contracts can be adapted by Script.TV content creators to distribute royalties fairly, transparently, and without reliance on costly intermediaries.

Smart contracts for content partners and platforms also enable more payment-consumption models than traditional TV services can offer their users, such as per-use or pay-as-you-go models. Instead of paying for annual or monthly subscriptions, viewers can now earn for viewing content. Our Turing-complete smart contracts enable numerous usage scenarios not exclusive to video streaming.

For example, the distribution of rewards between the platform, content partners, and users can be automated, NFTs can be traded, various wallets can be integrated, and new tokens can be minted. The Script.TV Virtual Machine is fully compatible with the Ethereum Virtual Machine (EVM), making it simple to migrate existing Ethereum-based contracts, and smart contract developers can seamlessly migrate to Script.TV.

By merging linear TV programming with blockchain technology, Script TV can manage all its services and offerings using smart contracts. The smart contracts are self-executing, require no middlemen, and can be swiftly executed after stipulated conditions for performance are met by the contracting parties. Plus, smart contracts can be used for games, polls, airdrops, reward programs, community engagement initiatives, and content acquisition. Overall, using smart contracts streamlines the process of getting things done and is cost-effective.

Turing-complete smart contracts open the door to numerous use cases in video streaming and beyond, from token investments in streamers, to automated splits of SCPT rewards between platform/streamers/users, to non-fungible tokens (NFTs) representing top content creators.

The Script Virtual Machine is compatible with Ethereum Virtual Machine (EVM).

Porting over existing Ethereum-based contracts is simple and thousands of smart contract developers can easily jump to building on Script.

Between the Script Labs team and Script community, many projects are already in the works including decentralized exchanges (DEXs), staking pools, and more.

Developers can deploy Smart Contracts to the Script Blockchain by compiling Solidity code (using favourite compiler toolchain) into bytecode and using then to call node’s RPC function. .

Users can deploy and interact with the smart contracts through the Script Web Wallet or programmatically via the Script Blockchain SDK.

On the Script Blockchain, SCPT token regulates execution of smart contracts.

Supported TV visualization platofrms

  • Browser. desktop / laptop
  • Mobile.

Landing page

https://script.tv

Menu

screenshot__main_menu

Shortcuts (links) to most-used features or important pages:

Token

Opens in a new window information about our crypto tokens SCPT and SPAY.

Watch. TV player. https://script.tv/watch

TV player

Space where the selected channel is dispalyed for visualization. Includes volume control and full-screen mode.

As you scroll down, the TV player will automatically shift into a mini window. Scrollin all the way up will close the mini-window and the projection will be shown in its original space in the page.

screenshot__watch_tv

Live chat

A place to exchange instant messages with other TV watchers.

Scrolling down we find the Electronic Programme Guide (EPG):

Electronic Programme Guide (TV Schedule)

screenshot__epg

Switch channels among the listed. Channels offer a time-line view with information about current/next TV programs. Times are shown local for your timezone.

Channels

Find channels to watch by category.

screenshot__menuitem_channels

Help

Access to documentation, whitepaper, FAQs and links,

screenshot__menuitem_help

Community

Scrolls down to community links.

screenshot__menuitem_community

Testnet

The testnet P2P network is a place for experimenting with the script network, its features and its tokens at no cost.

Test coins (play-money) SCPT and SPAY can be obtained for free from our faucet, a wallet feature representing an unlimited source of tokens that can transfer tokens to your wallet upon request.

The menu Provides access to our wallet, blockchain explorer and the downloads section.

The testnet P2P network is a network made by the public for the public. Run a testnet node following the link!.

screenshot__menuitem_testnet

Mainnet

The functional difference between both networks testnet and mainnet is the presence of a faucet available only in testnet. Testnet nodes have a faucet function for which they can obtain free tSCPT and tSPAY, the sister tokens in testnet, to be able to access test versions of all the script.tv functions, from node licensing and staking to watching “test-TV”.

Marketplace

The marketplace is where NFT trading occurs.

screenshot__header_buttons

Script TV User account

Registering a free account on script.tv is the way to obtain benefits and perks.

Click the button sign in/up shown at the top bar and select a convenient method for loginng in among the available options. screenshot__login button screenshot__login_method

Sign-in/Register via script wallet

When you select this method you would be using your script wallet.

Sign-in/Register via metamask wallet

When you select this method you would be using your Metamask wallet.

Follow the instructions shown in your Metamask installation until you command it to connect.

Sign-in/Register via Google account

When you select this method you would be using your Google account.

Sign-in/Register via email

When you select this method you would be using your e-mail account.

Registering a new account

Register a new account clicking the Sign up via Email Address link

screenshot__signup_email_form

Fill all the fields and save changes to continue.

Sign-in/Register via Metamask wallet

screenshot__sign_in__additional_data

As last step, provide a password for accessing your script.tv account associated with this metamask address:

screenshot__signin_last_step

P2P INFRASTRUCTURE: Script Network V4: Mainnet / Testnet

script_p2p_network

About Web-3

The new internet, based on empowering the invividual with privacy tools operating in high trustability and resiliency distributed networks, leveraging blockchain technology.

About Web-3 wallets

Wallets are privacy-first programs that manage your “secrets”, among them are your keys, used to unlock addresses and needed to move tokens around.

Script Network / Script Node

Script.tv crypto network is based on nodes and made only by the aggregation of more and more nodes, we call them lightning nodes because they are responsible for block finalization and blockchain settlement.

The accountability is trusted because the network is resilient against attacks or games executed by evil nodes without single-points-of-failure.

Blockchain implies nascent technology that leverages untrusted nodes that are publicly executing a distributed consensus algorithm in order to amazingly form a trustable, resilient and censorship resistant settlement system.

Benefits of running nodes: * Node runners are the real actors in web3. * Nodes are your tool for participating in consensus rounds, obtaining rewards based on staked amounts. * Nodes can accept delegation requests, for which users that are not running nodes can participate in consensus in a profit-share model. * Control/automate anything. * Use/customize your own wallet backend/frontend, e.g. automating interations with other’s wallets. * Use/customize your own blockchain explorer backend/frontend.

For improved privacy run your node in trusted hardware, e.g. the preferred choice for privacy-exigent users is to run the node in dedicated hardware. A VM in a datacenter or computer at home is a good-enough option for many.

Node Hardware/OS requirements

  • 16 Gb HD, 2 cores, 8 GB Ram
  • Debian 12 GNU/Linux Operating System.

Get your node running

The Easiest way: NaaS

Using a Node-as-a-Service (NaaS) service provider consists in delegating all technical aspects to a service provider.

Nodeops providers who support Script Network nodes:

    * [https://nodeops.xyz](https://nodeops.xyz)

The 1liner Installer

You would allocate a debian Operating system and run the 1-liner installer, converting it into a node in minutes.

The downloads screen provides access to different method for running a node.

Support for node installations has been discontinued for platforms Windows and Mac.

Here are the steps: https://download.script.tv

screenshot__downloads_1liner

This is the sequence of steps for a manual installation:

  • 1.- get a debian-12 VM in a datacentre or as a raspberry pi or headless computer. (e.g linode.com, digitalocean.com)
  • 2.- ssh as root. (Priviledged access to the VM command shell).
  • 3.- paste the 1-liner installer you copied from downloads page. Press Enter.
  • 5.- wait for a few minutes… Voila! your node is up and running!.
  • 6.- Follow on-screen instructions on further step like licensing and staking your node.

stv - The CLI interface

stv is the command you’d use to operate the node.

Have a detailed explanation of its functions in the sysop manual, available at

sysop_manual

script_tv__stvtool_manual.pdf

A walkthrough video is also available at

https://x.com/manic_beret/status/1865704546011377953

More on stv below.

Developer node

  • Build it all from sources. for devs and devops.

Follow instructions at our github page: https://github.com/scriptnetwork/script-4

You have successfully completed your node setup.

All following items check out:

  • ssh as root to your node. This action is perfomed ideally by muscle memory, but much better providing seamless experience is to set up passwordless authentication

      linux/Mac: `ssh root@<your node>`
              Windows: `putty` [download](https://www.chiark.greenend.org.uk/~sgtatham/putty/latest.html)
screenshot__user_node_root_login
  • switch to user ‘stv’ and go to home directory /home/stv (stv)
  • run the program stv
screenshot__user_node_stv_scriptcli

Automatic software updates

Automatic software updates feature is enabled by default. It can be disabled deleting the file /etc/cron.d/script_tv_updates and restating cron: systemctl restart cron

Check the Release Notes.

The document can also be found in the node at /var/script_tv/release_notes.md

Node bash shell

About GNU/Linux

Main SYSOP interface: Text Command-line console, also known as shell.

Linux prompts. Line Prefixes is given by the computer to indicate us context: user and path

        root:~$

SYSOP role operates under user root, and can control all aspects of the operating system. This prompt indicates that our path in the filesystem is /root (root home directory)

        root:/home/stv

This prompt indicate we are SYSOP, although our current path in the filesystem is /home/stv (stv user’s home directory again)

        stv:~$ 

Finally, this prompt indicates our hat is Script-Network user and that our current directory is home (/home/stv)

SYSOP/nodeop Role/hat: user root

Available commands for SYSOPs:

        * script_tv__uninstall.sh           # uninstalls the node software.
                * script_tv__test.sh                # subsystem health checks 
                * script_tv__ctl stop               # stops all services for node maintenance
                * script_tv__ctl start              # resume all services after node maintenance
                * cat /var/script_tv/data_sheet     # Prints Operational Data sheet detailing daemons, URLs and ports used among other technical data.

SCRIPT P2P Network. Nodeops the linux user stv

Changing to user stv from root

        root$ stv                # change to user stv

Returning back to root user (SYSOP mode)

        stv:~$ exit
                root$ 

stv - the CLI Command-Line-Interface to the script network

the stv command is an alias to the program bin/stvtool. It must always been executed as user stv.

Some of the commands are mentioned here below, but the full documentation for stv with all its functions can be found at

sysop_manual [script_tv__stvtool_manual.pdf](https://download.script.tv](https://download.script.tv/files/script_tv__stvtool_manual.pdf)

check the status:

stv:~$ stv -a status
        address                        0x8a95c6C85A4eB294c4dCB764867717C7CDf1f072
        chain_id                       testnet
        current_epoch                  10876
        current_height                 10874
        current_hash                   0x6e4dd911a67b4ae487149f293ca25420034c0b7355eb9b8bd1fb82e1c451f579
        current_time                   1734190399
        eth_chain_id                   42854
        genesis_block_hash             0x42a81f3f7ef0a5297997c8428ae945d5176f07082224b006f1979a5ebbe2744c
        latest_finalized_block_epoch   10874
        latest_finalized_block_hash    0x7dd26a35e3072be28419fcbd2cebbb1024ba095ee6991722bf6a7760982f430c
        latest_finalized_block_height  10874
        latest_finalized_block_time    1734190387
        peer_id                        0x8a95c6C85A4eB294c4dCB764867717C7CDf1f072
        snapshot_block_hash            0x7375fa6eeb782e5534b879ec5243e2bd549223a0ac077cd3c5ae32ec405c34eb
        snapshot_block_height          4397
        syncing                        false
        tip_hash                       0x1079b1f24757f1900d2c6b3e7d6aa0aab213953791aec442dc7f2433c8a9b8b5
        explorer_progress_height       10873

From the returned information we learn:

  • Our node address is 0x8d1F3236d790415d631d554091dE7A25913FB561
  • we are on testnet network
  • our peer_id is our node address, for node-node communications.
  • The genesis block hash 0x42a81f3f7ef0a5297997c8428ae945d5176f07082224b006f1979a5ebbe2744c must match on all nodes of this network.
  • Other information about the chain: block height, last block (current_hash).
  • Syncing indicates the type of activity that is going on. true/false indicates whether an sync activity is ongoing or not.

Your keys are stored in directory /home/stv/script4/wallet/keys/plain

        stv:~$ find script4/wallet/keys/plain -exec cat {} \;
                {"address":"8d1f3236d790415d631d554091de7a25913fb561","privatekey":"d8604ad2430cd7292c1374838c4ffee8edb5a6723f4ca3cb8d1e8e8bab28c905","id":"0fc641f5-18c3-47ea-ba7d-83126ea0e32

As protection against loss, we encourage you to backup the keys directory.

Backup

Use stv backup to produce a downloadable file with your keys: It provides with scp commands ready to be executed in remote computers to fetch the backup, either from inside the LAN or from internet (WAN).

stv:~$ stv backup
        Deleting previous backup files
        find: unknown predicate `-maxdepth=1'
        Copying gov key from /home/stv/script4/gov/key/
        Copying wallet keys from /home/stv/script4/wallet/keys/
        Backup file available at /tmp/keys_0x8a95c6C85A4eB294c4dCB764867717C7CDf1f072_testnet_user_20241214153540.tgz.
        =============================================================================================
        Backup file is ready for download:
        Retrieve from remote computer using either command:
        from LAN: scp root@555.31.13.144:/tmp/keys_0x8a95c6C85A4eB294c4dCB764867717C7CDf1f072_testnet_user_20241214153540.tgz .
        from WAN: scp root@555.134.4.199:/tmp/keys_0x8a95c6C85A4eB294c4dCB764867717C7CDf1f072_testnet_user_20241214153540.tgz .
        Restore directory (gov key): /home/stv/script4/gov
        Restore directory (wallet keys): /home/stv/script4/wallet
        =============================================================================================

testnet Faucet:

Obtain testnet tokens from our faucet at script.tv

Every script node has a faucet service that would -kindly- transfer you funds on request. The objective of testnet is to give users the opportunity to test the system using ‘play money’.

However if we run a mainnet node we would use an exchange and buy tokens instead.

Using stv CLI tool you would invoke faucet this way:

stv:~$ stv faucet
        Tx 0x0c91f018443240fc69cc438e793045966ef350da22bf19eca9ba6a1746e3b68c
        Explorer link: https://explorer-user-testnet.mm.cto.script.tv/txs/0x0c91f018443240fc69cc438e793045966ef350da22bf19eca9ba6a1746e3b68c
        Funds will arrive in seconds, check balance.

And seconds after verify balance:

stv:~$ stv balance
        Address 0x8a95c6C85A4eB294c4dCB764867717C7CDf1f072
            SCPT: 1000.000000000000000000
            SPAY: 100.000000000000000000

The command can be repeated as many times as wished up to a balance limit of 1M. We can easy earn tokens this way.

By feeding with tokens your node address your faucet is automatically enabled using it as source of funds and making the faucet service available to other participants in the script network.

Lightning node. Main setup workflow.

Lightning nodes are nodes that cooperate securing and guaranteeing its resilience and reliability, forming a trustable network of untrusted nodes, following the breakthrough by Satoshi Nakamoto.

In order to become one your just installed node must be upgraded.

The steps for upgrading the software are:

  • acquire 20.000 SCPT (or tSCPT for testnet)
  • purchase a Lightning license.
  • stake the node.

With the stv interface:

stv:~$ stv --lightning faucet      #only on testnet
        stv:~$ stv --lightning buy_license
        stv:~$ stv --lightning stake

An example of such run is:

stv@:~$ stv --lightning faucet
        Faucet for lightning.
        Tx 0x14f85252c2175e1290c1924b0d4630df6333fa45d22ea5d505128b34a318cb93
        Explorer link: https://explorer-user-testnet.mm.cto.script.tv/txs/0x14f85252c2175e1290c1924b0d4630df6333fa45d22ea5d505128b34a318cb93
        Funds will arrive in seconds, check balance.
stv@ip-172-31-13-144:~$ stv --lightning buy_license
        =========================================
        License Purchase
        =========================================
        You are about to purchase a lightning license for the node address: 0x8a95c6C85A4eB294c4dCB764867717C7CDf1f072.
        The license fee of 20000 SCPT will be paid from the address: 0x8a95c6C85A4eB294c4dCB764867717C7CDf1f072.
        The transaction will be sent to the Script Network node address: ad5448ab1687f6473715fcb789a2208d14eb9d5e.
        continue? [yes|ctrl-c]
        yes
        Sending 20000 SCPT to ad5448ab1687f6473715fcb789a2208d14eb9d5e
        Waiting for transaction to be included in a block
        Payment transaction link: https://explorer-user-testnet.mm.cto.script.tv/txs/0x462ff44d189a639e95f1ee69eb92204b142af62ffd8540bae5492c205380eb4d
        Waiting 100 seconds...
        (Please be patient. Don't cancel the process there are steps needed to be done)
        License purchased successfully
        Transfer refund in progress. Transaction id: 0x684fe71463e5a4ba12297d0c2002c05bb9e69f857c835a0c8511e0dec39f2c62
        Link to the refund transaction: https://explorer-user-testnet.mm.cto.script.tv/txs/0x684fe71463e5a4ba12297d0c2002c05bb9e69f857c835a0c8511e0dec39f2c62
stv:~$ stv print_license
        =========================================
               LICENSE FOR 0x8a95c6c85a4eb294c4dcb764867717c7cdf1f072 
        =========================================
        | Licensee Address      | 0x8a95c6c85a4eb294c4dcb764867717c7cdf1f072 |
        | License Type          | LN |
        | Issuer Address        | 0xad5448ab1687f6473715fcb789a2208d14eb9d5e |
        | Valid From            | 1734192846 |
        | Valid To              | 4889866446 |
        | License Items         | LN |
        =========================================
        Total Licenses: 1
        
stv:~$ stv --lightning stake
        Upgrading node to lightning
        Transaction broadcast was successful.
        TxHash: 0xc69494cc3e22d1a97132463e2369c4388a586f3777c91dd64230206cf9c4b433
        Link to transaction: https://explorer-user-testnet.mm.cto.script.tv/txs/0xc69494cc3e22d1a97132463e2369c4388a586f3777c91dd64230206cf9c4b433
stv@:~$ stv node_status
        Node is lightning with 20000.000000000000000000 SCPT staked.
        Node status summary: Node is a lightning.

Lightning node. Alternative setup workflow. Node Sale - FlowHale/easeFlow

screenshot__nodesale

For those who have purchased a license via https://nodesale.script.tv

the steps for upgrading the node to lighning are:

stv:~$ stv redeem
        stv:~$ stv --lightning stake

The redeem function will give you a personalized URL you would use to prove the ownership of the wallet with which you did the purchase. Once verified you would obtain a lighniung license for the node.

stv:~$ stv redeem
        ==================================================================================
        Script Network - Lightning node licensing

        Redeem easeFlow Purchase - https://easeflow.io
        (Purchase portal link: https://nodesale.script.tv)
        ==================================================================================

        Script Network - Lightning node licensing
        =========================================

        Its time to redeem your purchase making this node a licensed lightning node staked with 20K SCPT.
        A special URL has been generated for you, which is associated with this node. 
        Please continue the redeem process on the following URL:
        https://redeem-mainnet.script.tv/?ssid=XXeinGjNKa2e1aNRBzbObIIdf0vqZ3fKQQ3Kg1yA7nQflg4K2Ke8nzfMUUNgjwDAoj&msg2=yb2niry46wg6b34j5b9p7v

bring the given URL to the browser holding your wallet (the same wallet you used to purchase) https://redeem-mainnet.script.tv/?ssid=XXeinGjNKa2e1aNRBzbObIIdf0vqZ3fKQQ3Kg1yA7nQflg4K2Ke8nzfMUUNgjwDAoj&msg2=yb2niry46wg6b34j5b9p7v

Follow these 3 steps * connect wallet * sign message to prove ownership * back to stv with further steps explained on screen

screenshot__redeem1 * connect wallet

screenshot__redeem2 * sign message to prove ownership

screenshot__redeem3 * back to stv with further steps explained on screen

stv:~$ stv balance
        Address 0x8a95c6C85A4eB294c4dCB764867717C7CDf1f072
            SCPT: 21000.000000000000000000
            SPAY: 200.000018000000000000
stv:~$ stv print_license
        =========================================
               LICENSE FOR 0x8a95c6c85a4eb294c4dcb764867717c7cdf1f072 
        =========================================
        | Licensee Address      | 0x8a95c6c85a4eb294c4dcb764867717c7cdf1f072 |
        | License Type          | LN |
        | Issuer Address        | 0xad5448ab1687f6473715fcb789a2208d14eb9d5e |
        | Valid From            | 1734193852 |
        | Valid To              | 4889867452 |
        | License Items         | LN |
        =========================================
        Total Licenses: 1
stv:~$ stv --lightning stake
        Upgrading node to lightning
        Transaction broadcast was successful.
        TxHash: 0xc69494cc3e22d1a97132463e2369c4388a586f3777c91dd64230206cf9c4b433
        Link to transaction: https://explorer-user-testnet.mm.cto.script.tv/txs/0xc69494cc3e22d1a97132463e2369c4388a586f3777c91dd64230206cf9c4b433
stv@:~$ stv node_status
        Node is lightning with 20000.000000000000000000 SCPT staked.
        Node status summary: Node is a lightning.

[Advanced]: Build from sources

For developers, code enthusiasts and those who might not trust our pre-compiled distribution consider visiting our github repository.

RPC API

The following endpoints are available for testnet nodes:

        ## Subsystem URLS by function:
                ## Front end
                ## 1  web-wallet                     https://wallet-testnet.script.tv
                ## 2  blockchain explorer            https://explorer-testnet.script.tv
                ##
                ## Back end
                ## 1  L1 ethereum bridge             https://eth-node-testnet.script.tv/rpc
                ## 2  L1 script Ledger daemon        https://node-testnet.script.tv/rpc
                ## 3  L1 wallet backend              https://backend-wallet-testnet.script.tv/api
                ## 4  explorer backend               https://backend-explorer-testnet.script.tv/api

Subsystem ethereum bridge

        endpoint: https://eth-node-testnet.script.tv/rpc

script.CallSmartContract

Simulates the smart contract execution locally without submitting the smart contract transaction to the blockchain. It is useful to evaluate the execution result, calculate the gas cost, etc.

        RPC Method: script.CallSmartContract
                Query Parameters
                    sctx_bytes: the signed transaction bytes
                Returns
                    contract_address: the address of the corresponding smart contract
                    gas_used: amount of gas used for the smart contract execution
                    vm_error: error returned by the virtual machine.

Subsystem backend wallet - be/wallet

API RPC function Spec:

        {
                  "swagger": "2.0",
                  "info": {
                    "title": "be/wallet",
                    "description": "script wallet backend",
                    "version": "1.0.0"
                  },
                  "host": "https://backend-wallet-testnet.script.tv/api",
                  "basePath": "/api/",
                  "schemes": [
                    "http"
                  ],
                  "paths": {
                    "/api/": {
                      "get": {
                        "description": "",
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/cli": {
                      "post": {
                        "description": "",
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/node": {
                      "post": {
                        "description": "",
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/get-history": {
                      "get": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "wallet",
                            "in": "query",
                            "type": "string"
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/upload": {
                      "post": {
                        "description": "",
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/send": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "params": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/transfer": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "to": {
                                  "example": "any"
                                },
                                "amount": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          },
                          "400": {
                            "description": "Bad Request"
                          }
                        }
                      }
                    },
                    "/api/send-token": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "noofremetron": {
                                  "example": "any"
                                },
                                "to": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/new-key": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "password": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/unlock-wallet": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "address": {
                                  "example": "any"
                                },
                                "password": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/iswalletExists": {
                      "get": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "address",
                            "in": "query",
                            "type": "string"
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          },
                          "400": {
                            "description": "Bad Request"
                          }
                        }
                      }
                    },
                    "/api/lock-wallet": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "address": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/save-stake-history": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "from": {
                                  "example": "any"
                                },
                                "to": {
                                  "example": "any"
                                },
                                "amount": {
                                  "example": "any"
                                },
                                "wallet": {
                                  "example": "any"
                                },
                                "SCPTWei": {
                                  "example": "any"
                                },
                                "fee": {
                                  "example": "any"
                                },
                                "type": {
                                  "example": "any"
                                },
                                "height": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/get-stake-history": {
                      "get": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "wallet",
                            "in": "query",
                            "type": "string"
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/check-withdraw": {
                      "get": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "wallet",
                            "in": "query",
                            "type": "string"
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/remove-stack-history": {
                      "get": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "height",
                            "in": "query",
                            "type": "string"
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/get-dasboard-count": {
                      "get": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "wallet",
                            "in": "query",
                            "type": "string"
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/withdraw-Rametron": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "params": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/deposit-Rametron": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "params": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    },
                    "/api/smart-contract/call": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "data": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          },
                          "400": {
                            "description": "Bad Request"
                          }
                        }
                      }
                    },
                    "/api/offlineSend": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "receiver": {
                                  "example": "any"
                                },
                                "amount": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          },
                          "400": {
                            "description": "Bad Request"
                          },
                          "500": {
                            "description": "Internal Server Error"
                          }
                        }
                      }
                    },
                    "/api/maticHash": {
                      "get": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "hash",
                            "in": "query",
                            "type": "string"
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          },
                          "400": {
                            "description": "Bad Request"
                          }
                        }
                      }
                    },
                    "/api/lightning-faucet": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "receiver": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          },
                          "400": {
                            "description": "Bad Request"
                          },
                          "500": {
                            "description": "Internal Server Error"
                          }
                        }
                      }
                    },
                    "/api/request-faucet": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "receiver": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          },
                          "400": {
                            "description": "Bad Request"
                          },
                          "403": {
                            "description": "Forbidden"
                          },
                          "500": {
                            "description": "Internal Server Error"
                          }
                        }
                      }
                    },
                    "/api/transfer-erc20": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "senderAddress": {
                                  "example": "any"
                                },
                                "amount": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          },
                          "400": {
                            "description": "Bad Request"
                          }
                        }
                      }
                    },
                    "/api/request-faucet-web": {
                      "post": {
                        "description": "",
                        "parameters": [
                          {
                            "name": "body",
                            "in": "body",
                            "schema": {
                              "type": "object",
                              "properties": {
                                "receiver": {
                                  "example": "any"
                                }
                              }
                            }
                          }
                        ],
                        "responses": {
                          "200": {
                            "description": "OK"
                          },
                          "400": {
                            "description": "Bad Request"
                          },
                          "500": {
                            "description": "Internal Server Error"
                          }
                        }
                      }
                    },
                    "/api/getLightningNodeInfo": {
                      "post": {
                        "description": "",
                        "responses": {
                          "200": {
                            "description": "OK"
                          }
                        }
                      }
                    }
                  }
                }

Subsystem backend explorer - be/explorer

API RPC function Spec:

{
          "swagger": "2.0",
          "info": {
            "title": "be/explorer",
            "description": "script explorer backend",
            "version": "1.0.0"
          },
          "host": "https://backend-explorer-testnet.mm.cto.script.tv/api",
          "basePath": "/api/",
          "schemes": [
            "http"
          ],
          "paths": {
            "/api/accounting": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "wallet",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "start",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "end",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/account/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/account/update/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/account/total/number": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/account/top/{tokenType}/{limit}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "tokenType",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "limit",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/account/tokenTxNum/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "type",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/account/tokenTx/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "type",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "pageNumber",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "limit",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/account/tokenTxByDays/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "tokenType",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "days",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "target",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/account/getbalancesum": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/accountTx/history/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "startDate",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "endDate",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/accountTx/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "type",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "isEqualType",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "pageNumber",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "limitNumber",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  },
                  "404": {
                    "description": "Not Found"
                  },
                  "500": {
                    "description": "Internal Server Error"
                  }
                }
              }
            },
            "/api/accountTx/latest/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "startTime",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  },
                  "500": {
                    "description": "Internal Server Error"
                  }
                }
              }
            },
            "/api/supplyData": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "500": {
                    "description": "Internal Server Error"
                  }
                }
              }
            },
            "/api/activeAccount/latest": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/activeAccount/dates": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "startDate",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "endDate",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/block/{id}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "id",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/blocks/top_blocks": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "limit",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "pageNumber",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  }
                }
              }
            },
            "/api/blocks/number/{h}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "h",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/price/all": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  }
                }
              }
            },
            "/api/smartContract/verify/{address}": {
              "post": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/smartContract/abi/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/smartContract/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/smartContract/tokenTx/all": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "pageNumber",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "limit",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/stake/all": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "pageLimit",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "pageNumber",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/stake/totalAmount": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/stake/totalGcpValue": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/stake/totalVcpValue": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/stake/totalHolderAdds": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/stake/{id}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "id",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "hasBalance",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/supply/scpt": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  }
                }
              }
            },
            "/api/supply/spay": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  }
                }
              }
            },
            "/api/tokenSummary/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "tokenId",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/tokenSummaries": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "addressList",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/token/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "tokenId",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "pageNumber",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "limit",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/tokenHolder/{address}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "address",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  },
                  {
                    "name": "tokenId",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/transaction/{hash}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "hash",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "404": {
                    "description": "Not Found"
                  }
                }
              }
            },
            "/api/transactions/range": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "pageNumber",
                    "in": "query",
                    "type": "string"
                  },
                  {
                    "name": "limit",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/transactions/number": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  }
                }
              }
            },
            "/api/transactions/number/{h}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "h",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/transactions/list/{h}": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "h",
                    "in": "path",
                    "required": true,
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  },
                  "400": {
                    "description": "Bad Request"
                  }
                }
              }
            },
            "/api/transactions/history": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  }
                }
              }
            },
            "/api/transactions/historyByHr": {
              "get": {
                "description": "",
                "responses": {
                  "200": {
                    "description": "OK"
                  }
                }
              }
            },
            "/api/transactions/historyByFilter": {
              "get": {
                "description": "",
                "parameters": [
                  {
                    "name": "filterBy",
                    "in": "query",
                    "type": "string"
                  }
                ],
                "responses": {
                  "200": {
                    "description": "OK"
                  }
                }
              }
            }
          }
        }
        

Testnet Node. Browser. Fund new wallet accout from your faucet

We learnt how to fund the node account in the previous section. In this section we will learn to fund a new account from our own faucet.

Go to https://wallet-testnet. and create a new wallet. Save the keystore in a controlled directory and login.

As you unlock the wallet you’ll see the address at the top of your screen besides the label “My address”. In this example we’ll assume it is 0xeeF1966D1b39E35A08975255138A020239Ea30d6.

Rehearsing

        my console-wallet/node address is 0x8d1F3236d790415d631d554091dE7A25913FB561 
                my browser-wallet address is 0xeeF1966D1b39E35A08975255138A020239Ea30d6 

Balances should show up zero.

Click Receive - Faucet, then confirm and wait 15 seconds to see your balance updated.

screenshot__receive_from_own_faucet

We can check the node account has been decreased in the same amounts - off by 0.000001 SPAY fees

        stv:~$ scriptcli query account --address=0x8d1F3236d790415d631d554091dE7A25913FB561
                Using config file: /home/stv/script4/lightning1/wallet/config.yaml
                {
                    "code": "0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
                    "coins": {
                        "scptwei": "11000000000000000000000",
                        "spaywei": "1099999990000000000000"
                    },
                    "last_updated_block_height": "1180",
                    "reserved_funds": [],
                    "root": "0x0000000000000000000000000000000000000000000000000000000000000000",
                    "sequence": "1"
                }

Your node account has payed for your faucet transfer of 1000 SCPT + 100 SPAY, and its balance is now:

        SCPT token: 11000;  SPAY token:1100-fees

Testnet Node. Browser. Send Funds to a given accout.

From your web wallet let’s give back 500 SCPT to anyone, for example our node address (0x8d1F3236d790415d631d554091dE7A25913FB561)

Click Send buttond and fill the fields:

screenshot__send_scpt_own_node

The transaction should be reflected on screen in seconds, and on the recipient account

        stv:~$ scriptcli query account --address=0x8d1F3236d790415d631d554091dE7A25913FB561
                {
                    "code": "0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
                    "coins": {
                        "scptwei": "11500000000000000000000",
                        "spaywei": "1099999990000000000000"
                    },
                    "last_updated_block_height": "1180",
                    "reserved_funds": [],
                    "root": "0x0000000000000000000000000000000000000000000000000000000000000000",
                    "sequence": "1"
                }

We can confirm we received 500 SCPT from the browser wallet.

Testnet Node. Shell. Send Funds from your node wallet (the wallet safeguarding the node key).

In order to make transfers from console you’d need to have available the source and recipient addresses and the sequence number of the source account, the account where source funds sit.

In our case, the source address is our node account (0x8d1F3236d790415d631d554091dE7A25913FB561), and the recipient address is our browser-wallet address (0xeeF1966D1b39E35A08975255138A020239Ea30d6).

We obtain the sequence number using the source address:

        stv:~$ scriptcli query account --address 0x8d1F3236d790415d631d554091dE7A25913FB561
                {
                    "code": "0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
                    "coins": {
                        "scptwei": "11500000000000000000000",
                        "spaywei": "1099999990000000000000"
                    },
                    "last_updated_block_height": "1180",
                    "reserved_funds": [],
                    "root": "0x0000000000000000000000000000000000000000000000000000000000000000",
                    "sequence": "1"
                }

For the sequence value we will take the value of the field “sequence” plus one, as we obtained “1” we will then use sequence number 2.

For the amount we will transfer 10000 SCPT.

        stv:~$ scriptcli tx send --chain="testnet" --from=0x8d1F3236d790415d631d554091dE7A25913FB561 --to=0xeeF1966D1b39E35A08975255138A020239Ea30d6 --script=10000 --seq=2
                Successfully broadcasted transaction:
                {
                    "hash": "0x41ce406895c166145211091afa50f0ae7197b721f1d4e2634e52ea3c72ce5b34",
                    "block": {
                        "ChainID": "testnet",
                        "Epoch": 2844,
                        "Height": 2844,
                        "Parent": "0xfaf4d062abecbc230a34ca45f7e4c68d9f3e2ad512eb213a6710d6e4b611dd07",
                        "HCC": {
                            "Votes": [
                                {
                                    "Block": "0xfaf4d062abecbc230a34ca45f7e4c68d9f3e2ad512eb213a6710d6e4b611dd07",
                                    "Height": 2843,
                                    "Epoch": 2843,
                                    "ID": "0x99b009e8a5257772ac07c9b370b2bdb389e3b46a",
                                    "Signature": "0xc288ef07aef45c008340f4189959d90d0f64fb326c4f218633ce1466efdec4421af3d3e4840a92e84bc7b91c7b18e739bd89db9319949eac0320a17cc3c5d7fd01"
                                }
                            ],
                            "BlockHash": "0xfaf4d062abecbc230a34ca45f7e4c68d9f3e2ad512eb213a6710d6e4b611dd07"
                        },
                        "LightningVotes": null,
                        "EliteEdgeNodeVotes": null,
                        "TxHash": "0xc8bd1399466df192645f836f806cdf94ff6dc5619092c6e4786ec074deea6034",
                        "StateHash": "0x40291b0c95fa8573fee4c7b15b7b73ed0adf97cdfc78a42e4aec9fd2210ebeca",
                        "Timestamp": 1721823113,
                        "Proposer": "0x99b009e8a5257772ac07c9b370b2bdb389e3b46a",
                        "Signature": "0xae52ab043504345a77aca34c77ba3888431e609ea37c7233c6cbfcdb43ea4e972869c014539253a68dae77a6cf32999dfd155f9d72b48a4081381bfaa913672500"
                    }
                }

At this point your browser wallet should show this balances:

screenshot__browser_wallet_ready2stake

With a balance of 10000 SCPT you can stake your lightning node from the browser wallet.

Testnet Node. Browser. Stake your lightning node.

Click on On-Chain Stakes, then Deposit Stake and then continue with Lightning Node.

screenshot__browser_wallet_stakes_io

In the following screen click on the helper button labeled This node to autofill the node fingerprint with the one corresponding to this node (double check URL to make sure which node you’re operating with and which one you want to stake).

Enter 10000 SCPT.

The node fingetprint can alternatively be obtained on the shell in the field “Summary” of the response.

        stv:~$ scriptcli query lightning
                {
                    "Address": "0x8d1F3236d790415d631d554091dE7A25913FB561",
                    "BlsPubkey": "8322dc548cef749a20f276c3106054ac4fd59081191e87128683c4a8b6c00547fc53b242ec79d9c49ce12176efda4658",
                    "BlsPop": "875aa8ce47ecae78e8076c9163bdca6757036a8fe70f46869010bdf3c2dafdcd2dd7eac5484bad57733b5210efa1c717118fa57addc1c31c810c23bfe8b1c1c54c3940e43e3670c3e9b32f551986fedc670f897e92392f3309cdad41d0031866",
                    "Signature": "dc141c86b5d5059969eba9d6e795d5f9fd4715922ddc1a24417da974ca1c3c8327edf11f18ccbe13ee297cee70a6a69801bd92f0d0ed472087f7bdf78b41785800",
                    "Summary": "0x8d1F3236d790415d631d554091dE7A25913FB5618322dc548cef749a20f276c3106054ac4fd59081191e87128683c4a8b6c00547fc53b242ec79d9c49ce12176efda4658875aa8ce47ecae78e8076c9163bdca6757036a8fe70f46869010bdf3c2dafdcd2dd7eac5484bad57733b5210efa1c717118fa57addc1c31c810c23bfe8b1c1c54c3940e43e3670c3e9b32f551986fedc670f897e92392f3309cdad41d0031866dc141c86b5d5059969eba9d6e795d5f9fd4715922ddc1a24417da974ca1c3c8327edf11f18ccbe13ee297cee70a6a69801bd92f0d0ed472087f7bdf78b41785800"
                }
screenshot__browser_wallet_stake_deposit_form

Confirm

screenshot__browser_wallet_stake_confirm

You will verify after a few seconds that sadly your balance has dropped, as it can be seen on your explorer:

We can pay a visit to the explorer to do some verifications.

You can use either your explore (serviced by your node) or any other node including the one behind script.tv. https://explorer-testnet.<your domain|script.tv>/account/0xeeF1966D1b39E35A08975255138A020239Ea30d6

As a result of your transaction you are queued waiting for inclusion.

If you are like me you would need to access such queue and check my address is reflected there.

We would need first to obtain the current_height of the blockchain:

        stv:~$ scriptcli query status
                { ...
                    "current_height": "3713",
                ... }

With it, we can print the waiting queue querying lcp (Lightning Candidate Pool):

        stv:~$ scriptcli query gcp --height=3713
                {
                    "BlockHashGcpPairs": [
                        {
                            "BlockHash": "0x75c499de22a3ed2852c9f2e9ed7bf92909557e80921a555bcb6874ad1ed50f68",
                            "Gcp": {
                                "SortedLightnings": [
                                    {
                                        "Holder": "0x8d1f3236d790415d631d554091de7a25913fb561",
                                        "Stakes": [
                                            {
                                                "amount": "10000000000000000000000",
                                                "return_height": "18446744073709551615",
                                                "source": "0xeef1966d1b39e35a08975255138a020239ea30d6",
                                                "withdrawn": false
                                            }
                                        ]
                                    }
                                ]
                            }
                        }
                    ]
                }

We can be pleased to find our candidacy included in this list.

screenshot__explorer_browser_wallet_address

Our balance of 500 SCPT, 100 SPAY checks out.

We easily spot our last transaction Deposit Stake.

Node Web2.0 Interface

Script Web Wallet

https://wallet-testnet.script.tv

Wallets are privacy-first programs that manage your “secrets”, among them are your keys, used to unlock addresses and needed to move tokens around.

The Script Wallet can be found on any node. Script Network node provide the following URLs for the wallet service:

Your secrets, represented by the keystore file, are never transmitted throught the wire. and shall be backed up and kept secret by the user.

Access the wallet using the main menu of the desired network, e.g. Testnet -> Testnet wallet.

screenshot__script_wallet_unlock

Creating a new wallet

New users would need to go through the process of creating a new keystore file.

Click the link “create a wallet” that you’d find at the bottom of the unlock-wallet screen.

Complete a set of easy steps following on-screen instructions.

This process will end-up in a keystore file containig your secret keys.

It’s your responsibility to safeguard this file, keeping it backed up and secret being aware that leaked secrets may produce loss of tokens.

Unlocking your wallet

3 methods are available to get access to your funds.

  • keystore

You would normally unlock your wallet using your keystore file. In case this file is lost or not accessible the process can alternativamente be fulfilled using two remaining recovery methods.

  • mnemonics

During the process of creating the keystore a copyable paragraph is also created as an alternative method to unlock the wallet.

  • Private key

Raw secret keys (found in the keystore file) can be used as an alternative method to unlock the wallet.

Main wallet screen

screenshot__wallet__new

Informational fields:

At the top of the window is permanently shown the following information together with copy-to-clipboard buttons.

  • This Node address: is the address of the node providing the backend service.
  • My address: is your address unlocked from your private keystore

Balances

This screen shows your SCPT and SPAY balances and the history of transactions.

screenshot__faucet_transfer

Receive (faucet). (Only Testnet).

screenshot__receive_faucet

Faucet is a testnet-only feature that allows testing applications and mature monet-handling algorithms using play money, instead of risking real-money in the mainnet. Only if your current balance is under 100000 SCP every time to click on Receive button 1000 SCPT and 100 SPAY are transferred to your balances. # 15 seconds after clicling the receive button you balance screen would reflect your new balances and a new entry in the transaction history list.

On-Chain Stakes

Invest in the network. The network will reward you.

Deposit

screenshot__deposit_stake_menu

Select lightning node and continue.

Explorer

screenshot__explorer_home

© 2024 Script.tv. All rights reserved.