# 📦 Stake-as-a-Service (SaaS) (/delegation/stake-as-a-service-saas)









The Vault runs a Stake-as-a-Service (SaaS) subscription model for validators receiving [undirected stake](/stake/direct-vs-undirected-stake) delegation from our pool. This system is designed to support the protocol's long-term financial sustainability, align incentives with validators, and provide transparent and recurring revenue.

<img alt="Banner: Two collaborators connect a customizable orange-and-cream vault module to a tidy network of server towers, beside blank modular token discs." src="__img0" />

## Key principles [#key-principles]

* Sustainability: Introduces a fee structure to maintain and grow our operations.
* Fairness: Equal access to stake for [approved](/approved/approved-validators) validators, contingent on consistent subscription payments.
* Transparency: Invoices and payment statuses are tracked through our dApp.
* Simplicity: Fixed-rate system, with a [payment bot](https://github.com/SolanaVault/saas-payment-bot) that pays your invoices automatically.

## Payment terms [#payment-terms]

* Who must pay: Validators who are on the approved list and receive undirected stake.
* Payments: Have [vSOL](/about/vsol) or SOL in your wallet to pay.
* Rate: 25% of validator earnings generated from undirected stake.
* Invoice timing: Issued one epoch after the stake is received.
* Payment deadline: Must be paid within 20 epochs of invoice issuance.

The rate is calculated using the following formula: \[((avg\_mev\_per\_block × validator mev commission) + avg\_rewards\_per\_block) × (stake by the vault ÷ avg\_stake\_per\_leader\_slot) + (stake by the vault × (chain inflation rate ÷ epochs per year) × validator inflation commission)] × 0.25 (Figure 7.18).

<img alt="The SaaS rate scales average MEV per block times validator MEV commission plus average rewards per block by The Vault's stake divided by average stake per leader slot, adds The Vault's stake times chain inflation rate divided by epochs per year times validator inflation commission, then multiplies the total by 0.25." src="__img1" />

Figure 7.18: How the SaaS rate is calculated

## Enforcement [#enforcement]

If an invoice stays unpaid for 20 epochs, the stakebot blocks delegation to your validator from the [Direct Stake Leaders](/delegation/direct-stake-leaders-bucket) and [Elite Performance](/delegation/elite-performance-bucket) buckets until your invoices are settled. Your validator stays on the [approved list](/approved/approved-validators) (Figure 7.19).

<img alt="The SaaS invoice cycle issues an invoice one epoch after a validator receives undirected stake for 25% of the earnings generated from that stake, paid by the SaaS payment bot or manually in vSOL or SOL within 20 epochs of invoice issuance; if unpaid, the stakebot blocks delegation from the Direct Stake Leaders and Elite Performance buckets until settlement while the validator stays on the approved list." src="__img2" />

Figure 7.19: The SaaS invoice cycle

## Pay your fees automatically [#pay-your-fees-automatically]

The Vault's [SaaS payment bot](https://github.com/SolanaVault/saas-payment-bot) pays your invoices for you. It runs once a day on GitHub Actions in your own copy of the repository, checks your validator for outstanding invoices, stakes SOL from a payer wallet for vSOL and pays them. The payer wallet can be any wallet; it doesn't need to be connected to your validator.

<Steps>
  <Step>
    ### Fork the repository [#fork-the-repository]

    Sign in to GitHub and fork [SolanaVault/saas-payment-bot](https://github.com/SolanaVault/saas-payment-bot) to your account.
  </Step>

  <Step>
    ### Add the secrets [#add-the-secrets]

    In your fork, open Settings, then Secrets and variables, then Actions, and add three repository secrets: `RPC_URL` with your RPC URL, `PRIVATE_KEY` with the payer wallet's private key in the `[1,2,3,...]` format, and `VOTE_KEY` with your validator's vote account public key.
  </Step>

  <Step>
    ### Enable the workflow [#enable-the-workflow]

    Open the Actions tab of your fork and enable workflows. GitHub turns them off in new forks until you do.
  </Step>

  <Step>
    ### Keep the payer wallet funded [#keep-the-payer-wallet-funded]

    Keep enough SOL in the payer wallet to cover your invoices and transaction fees. The bot pays from this balance every day.
  </Step>
</Steps>

<Callout type="warn">
  The bot needs the payer wallet's private key. Use a separate wallet that holds only the SOL for your invoices, never a wallet with your validator keys or other funds.
</Callout>

GitHub can pause scheduled workflows in a repository with no activity for 60 days. Check the Actions tab now and then, and push a commit at least every 60 days to keep the bot running. You can also run the bot in your own environment instead of GitHub Actions; the repository's README explains how.

## Pay your fees manually [#pay-your-fees-manually]

You can also pay your invoices yourself on the validator dashboard.

<Steps>
  <Step>
    ### Open the validator dashboard [#open-the-validator-dashboard]

    Visit [The Vault validator dashboard](https://thevault.finance/validators).
  </Step>

  <Step>
    ### Select your validator [#select-your-validator]

    Find your validator in the list and click on it.
  </Step>

  <Step>
    ### Find your outstanding fees [#find-your-outstanding-fees]

    Find any outstanding epoch fees on your dashboard.
  </Step>

  <Step>
    ### Connect your wallet [#connect-your-wallet]

    Connect your wallet to the site.
  </Step>

  <Step>
    ### Pay the fees [#pay-the-fees]

    Click the Pay button. It shows how many invoices it pays, for example Pay 3 invoices.
  </Step>

  <Step>
    ### Sign the transaction [#sign-the-transaction]

    Sign the transaction using your wallet.
  </Step>
</Steps>

<Callout type="info">
  Invoices are quoted in vSOL, but you can pay in either vSOL or SOL. A new invoice can take a few epochs to become payable.
</Callout>

## FAQ [#faq]

### What if I don't pay on time? [#what-if-i-dont-pay-on-time]

If an invoice stays unpaid for 20 epochs, the stakebot blocks delegation to your validator from the Direct Stake Leaders and Elite Performance buckets until your invoices are settled.

### Can I pay my invoices automatically? [#can-i-pay-my-invoices-automatically]

Yes. Set up the [SaaS payment bot](https://github.com/SolanaVault/saas-payment-bot): it checks for outstanding invoices once a day and pays them from a payer wallet you choose. See [Pay your fees automatically](#pay-your-fees-automatically).

### Can an invoice be paid twice by mistake? [#can-an-invoice-be-paid-twice-by-mistake]

No. An invoice can only be paid once, so a second payment for the same invoice doesn't go through. If the payment bot runs twice at the same moment, the second run can still stake SOL for vSOL, and that vSOL stays in your payer wallet.

### Why do some validators have no Stake-as-a-Service invoices? [#why-do-some-validators-have-no-stake-as-a-service-invoices]

The fee applies only to stake from the Direct Stake Leaders and Elite Performance buckets, so a validator with only [gauge](/gauges/gauges) stake or [direct stake](/stake/direct-staking) has nothing to pay. [Validator Board](/stakepool-application/validator-board) members are also exempt from Stake-as-a-Service fees.

### Can I track how much I owe? [#can-i-track-how-much-i-owe]

Yes. Validators can view current and past invoices on the dApp.

### Is this system permanent? [#is-this-system-permanent]

This is a pilot structure. The Vault may adapt the pricing or model based on validator feedback and protocol needs.
