Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Bitcart is an open-source, self-hosted all-in-one solution for Bitcoin and other cryptocurrencies.
You can use it in a variety of ways: from payment processing via our ready tools to custom applications via our SDK.
If you have trouble using Bitcart, consider joining the communities listed on the official website to get help from Bitcart community members. Only file Github issue for technical issues you can't resolve through other channels or feature requests you've validated with other members of community.
Please check out our official website, our complete documentation and FAQ for more details.
Direct, peer-to-peer cryptocurrency payments
No transaction fees (other than those for the crypto networks)
No processing fees
No middleman
No KYC
User has complete control over private keys (in fact, private keys aren't required at all)
Enhanced privacy
Enhanced security
Self-hosted
SegWit support
Lightning Network support
Opt-in Altcoin integrations
Easy to use API and SDK
Process payments for others
Powerful ready to use admin panel
Ready store to get your first customers
Many integrations available
Extendable the right way
In layman's terms, Bitcart is a solution for anything you might need to do in cryptocurrencies ecosystem.
If you need to process payments as a merchant, Bitcart can serve either as a full invoicing system, or just as a payment processor for cryptocurrencies' payment methods. When checking out, the customer will be presented with an invoice. The invoice is a fresh address from your wallet that wasn't used before. This way, by avoiding address re-use, your privacy is enhanced. Bitcart is using Electrum wallet protocol and it's SPV (Simple Payment Verification) feature to verify sent payments. After successful payment, your Bitcart instance can automate most of the work needed to fulfill the order safely. You are provided with ready solutions for your store, your company or application. Anything is possible with Bitcart.
But if you just need a way to check the blockchain, or a way to create transactions (for tipping bot, for example), Bitcart provides ready developer tools for the most comfortable experience: ready and well-documented SDK, Merchants API (see it's swagger documentation here) and various plugins.
Bitcart is a completely open source project. Every feature added, every change is documented and is publicly visible. There is no third-party between a merchant and a customer. Each merchant can set up their own individual instance, not dependent on other instances, or any third-party. Every action is under control of the merchant. As Bitcart is self-hosted, of course there are no processing or subscription fees.
As Bitcart is open source, everyone is welcome to read it's code, help in finding bugs and suggest new features! Security auditors can always inspect the quality of our code, and they have a secure way to report vulnerabilities to make them fixed before they were used for bad
There are a few projects existing in the cryptocurrencies sphere targeting payment processing, but Bitcart is way more than just that. Payment processing is just one of the possible use-cases, but the user can always choose which parts of Bitcart to use.
As Bitcart contains many features, it is modular (while most other projects aren't). That means, for example, that if you only need to use the SDK for custom apps-just enable our daemons only. If you also need to have a ready Merchants API to use in a store-like application, enable it too. If you need a powerful admin panel, you can enable it. And so on, Bitcart consists of individual independent parts, which are easy to customize and use.
Another key difference is that, we are open to community ideas, and the project is built by the community and is influenced by the community. Every important decision taken is decided via a public poll. We are building a positive community having fun and making use of Bitcart, with the same goal: to make it even better.
Payments via Bitcart are direct, peer to peer. The merchant receives the coins directly to their wallet, with no intermediary.
How it works? For each invoice, Bitcart generates a new address, belonging to the xpub entered, and this address is presented to the user. As this address is your wallet's address, you receive the funds directly. Bitcart just watches the payments, it can't modify anything along the way, as when configuring the wallet, you only need to enter a watch-only master public key.
That way, you have complete control of the funds received.
The data is shared only between two parties - the buyer and a seller. Only the data required for the app operation is saved, nothing else. The concept of decentralization is followed-if there are lots of indendent instances, there can't be a central server for anything. There are no data leaks in any operations, and all the information stored can only be viewed by the server owner (usually, the merchant)
Self-hosted
Can be run everywhere, from low-powered device like Raspberry Pi at home to enterprise-grade servers
No third-party
Can easily be re-deployed
Bitcart does not have a central point of failure since nobody is controlling it except for the user running it. If run on the cloud server, the hosting providers can potentially censor users by suspending hosting accounts or disabling access to virtual machines. This is always a risk for anyone using a hosting provider. Since no private keys are stored on the server, a censored individual can easily re-deploy the Bitcart with another host. Your coins are always inside your wallet. If an invoice is paid while your Bitcart instance on the server is down, the software will automatically determine and notify the merchant of offline invoice payments when your server is back up. If a hosting provider suspends the server, and there was no proper backup, server settings and invoice data may be lost, but on-chain payments are always in your wallet. For ultimate censorship-resistance, users should run Bitcart on their own hardware.
Bitcart is not only a payment processor for merchants. It is called all-in-one crypto solution because it can be used for anything you want. It abstracts a lot of complex components into simple and easy to use interfaces, APIs and SDKs. Developers can build entire businesses and projects on top of the stack. Enterprises can use it as scalable and secure back-end of their infrastructure without ever having to put a trust in a third-party. Bitcart is a toolbox with lots of tools you can use, it's up to you how you want to use it.
Most new merchants will likely only consider the price of the service. Since Bitcart is free, that may have led you here and if so, welcome.
First of all, as said above, Bitcart is fully free, fully opensource and has no limitations. You are your own bank.
The second main difference is that other services are usually providing only one thing - rate-limited API or a web interface. But Bitcart, as opposed to others, is a full-featured solution, all-in-one crypto solution. It can satisfy needs of any audience:
Merchants, providing ready solutions for your stores to accept cryptocurrency payments with the simplest setup
Server maintainers, providing simplest setup with a diversity of deployment options, with automatic updates (github release -> docker hub -> end machines)
Anyone else wanting to try out cryptocurrencies
Bitcart is a light self-hosted solution. It is as safe(even safer than most) as other solutions, but is light, easy to use and install.
The approximate system requirements differ, but almost any server is fine, less than 1 GB RAM and less than 10 GB disk.
Bitcart is made with extensibility in mind, so adding something new is easy. Written in Python, it's code is easy to review and read, adding new features is faster than in other projects.
Bitcart is also a great source of learning. We use many different technologies, creating the best User Experience. During the process of development, we met many different problems and solved them in elegant ways. You can learn those ways, and the technologies used, and become a professional developer.
The list of the reasons why you should use Bitcart can go on and on. Now some features of it as a payment processor:
Every payment processor has features, here are some Bitcart features:
Free - No merchant processing fees.
Bitcoin - Accepting Bitcoin is the first step.
Altcoins - Accept cryptocurrency alternatives to Bitcoin.
Lightning - Rapid Bitcoin microtransactions using the Lightning Network.
Integrations - Wordpress & WooCommerce and custom integrations.
Point Of Sale - POS Interfaces for physical stores.
Unlimited Stores - Merchants can process payments for their own stores, or for others.
Payment Requests - Create & send a long-lived invoice requesting payment for goods or services.
Ready solutions for starting merchants - your own store and admin panel.
Solutions for checkout flow automation - you can create scripts to process the order for you.
It's important to note that payments made using the Bitcoin Network always require a transaction (miner) fee for it to be included in the blockchain. The Bitcoin Network determines if the transaction is authorized and when it is confirmed.
Bitcart creates direct payment invoices for merchants to provide to their customers. It also monitors the blockchain and stores the confirmation status of each payment or donation. To do this Bitcart requires hosting on a server which merchants can deploy on their own hardware, purchase a VPS (less than $3.5/mo), or use someone else's Bitcart instance to host your account (free or paid options).
If you deploy Bitcart using a VPS, the following types of fees are never charged:
Merchant fees
Subscription fees
Transfer fees
Software fees
First rule of Bitcoin is always keep your private keys private. Using a secure wallet is recommended for new merchants as the only provider (creator) of private keys. If there is a chance that someone else (such as a website) knows, stores, or provides your private keys to you, it's generally accepted that they are not actually private.
Secondly, there is another area of security to consider on the applications layer where you have two main options:
Many wallets do not allow payments to BIP 70 invoice urls.
Bitcart will never ask a merchant for any personal identification.
Typically, when converting to or from fiat on behalf of a merchant, payment processors are required to collect personal information for Know Your Customer (KYC) and Anti-money laundering (AML) banking requirements. This may include personal information such as passport ID, phone number, address, bank account, etc.
Fortunately, the Bitcoin Network does not use or collect these types of personal information, and therefore neither does Bitcart. How Bitcart ensures privacy:
No middleman involved.
Information is shared between customer and seller only.
No address re-use.
Any non-decentralized solutions are avoided, instances are self-contained.
Many payment processors claim to have no middleman. They claim that funds go directly to your wallet or that they offer instant settlement. However, if the processor makes any of the following claims, they are most likely operating as a middleman:
Waiting time for a merchant to receive payment is longer than sufficient blockchain confirmation.
The payment processor combines customer payments before sending to the merchant's wallet.
If there are any kind of limits on transaction volume for the merchant.
If the payment processor can decline, reject or alter a payment after being sent from a customer's wallet.
If the payment processor has terms and conditions stating they can hold or freeze your account.
Fees for using the payment processor are automatically taken out from the customer's payment to the merchant.
Payment processors are able act as middlemen by using custodial wallets. A payment processor can use an internal custodial wallet for altering customer payments before routing them to merchants. This is how they can collect fees, hold payments for verification and processing, etc. This type of wallet is an intermediary between the merchant wallet and the customer wallet. It's the middleman wallet.
The payment processor may also provide a custodial wallet for the merchant to use. As mentioned above, this is advised against because your private keys may be compromised. If they claim to not save your private keys after giving them to you, it's likely you will not know the truth until it's too late. Centralized services may seem like an easier solution for the merchant. Unfortunately the trade-off is sacrifices in privacy, security and self-sovereignty which is normally obtained using the Bitcoin Network.
That's one of the reasons why Bitcart was created. To help merchants remove third party dependencies and simply use the Bitcoin Network freely and securely. Merchants have their own copy of the Bitcart software which runs on their own server or VPS of their choice and validates their own payments using their own node. It's a self-hosted Peer-to-Peer all-in-one crypto solution. There shouldn't be any trade-offs as setup is the simplest possible and we wanted to make this software user friendly.
As the Bitcart community continues to grow, more deployment methods, use cases and tutorials are continually being added to make it easier for non-technical users. Bitcart is completely open source. Anyone can join the community to suggest or create improvements, features, guides, etc. Feedback is always welcome.
Currently, Bitcart is a processor without fiat conversion capabilities. As a merchant, this may be a difficult if business costs require fiat. Not providing fiat conversion allows Bitcart merchants to avoid KYC and AML identification verification. This also allows Bitcart to be free and available for anyone to use.
However, a fiat conversion feature is on the roadmap for Bitcart. Since merchants are always the owners of their private keys, they can always freely convert their coins manually, but for now there's no instant-fiat conversion.
It's probably a feature not a bug!
All of this information should be available to merchants.
Developers, having daemons for bitcoin and other coins, and sharing same APIs for any coin, easy to create any kind of app(for example atomic )
How did we achieve this? Bitcart is using the electrum wallet internally(see for more information). Electrum wallet is one of the oldest and the most secure and feature-wide wallets. It is using SPV(Simple Payment Verification) to verify everything and it makes electrum and so Bitcart secure and light. If you're not satisfied with the way it works, you can host your own electrumx server and make Bitcart use only your own server. We will provide easy setup for that in near future.
Due to it's lightness, you can host Bitcart on a minimal server, with minimal costs! Current lunanode 1-click installer would cost you 3.5$ a month to host Bitcart with all components(admin, store) and from 1 to 5 cryptocurrencies for the same price, still being light. Or you can find even cheaper hosting providers and host it even cheaper! In fact, all Bitcart demos (, , ) run on 1 GB server with only 25 GB disk.
Bitcart provides a ready full-featured merchants solution - Bitcart . You can get up and running without any technical knowledge for minimal ever price(depending on VPS provider you have selected).
Option 1: Most payment processors (including Bitcart) use the standard.
Option 2: Others use variations of the standard.
Note: .
Self-hosted users run a secure Bitcart core or .
Checkout the
If you have more questions about Bitcart, read our .
This section goes through the process of creating an account and store on our public Bitcart instance. (For evaluation purpose)
First let's create a new store:
Go to the demo website
In the login form click on Sign up here to create an account
Let's use Electrum to create a mainnet wallet for your store:
Download Electrum
Run Electrum
Click through the wizard and create a test wallet, using the default settings Electrum proposes
After the wallet is set up, go to "Wallet" > "Information" in the Electrum menu.
Copy the "Master Public Key" string (starting by *pub...
)
Let's configure the store so it uses your Electrum wallet:
Go to Wallets page and create a new wallet with your copied xpub
Go to Stores page and create a new store with your new wallet connected
After that your test wallet should appear on the Wallets page of your Bitcart account
Then you can create an invoice, either through
the Invoices page on the website or
the process documented on the Custom integration
or the store POS, if you are the owner of the instance
To see Bitcart in action, visit our demo apps and stores or check out some of the stores using Bitcart in production.
In this article, we will walk you through the Bitcart admin panel user interface and show you how to navigate through different options.
When creating an account, if you're the first user registered on the instance, you'll be granted superuser rights (full control over the server). On third-party hosts it is usually not so, but if you're hosting your own instance you'll of course become the full owner of it.
After you created the account on the Bitcart instance hosted by yourself or a third-party, you'll see a lot of information cards.
Note about the night mode of the panel. By default, admin panel uses day mode, but if in your local time it is from 8 pm to 6 am, night mode will be enabled automatically 😉 You can configure it by clicking the moon icon in the top right corner of the page.
Each information card contains summary about something in your account: wallets, stores, products, invoices, etc.
By clicking Details button in any of the cards you will be able to see full information about specific unit.
Note, wallets balance is displayed not in BTC, but in abstract currency. It is a sum of all your balances in different currencies.
If you're a superuser, you can click on profile icon in the top right corner of the page to visit server settings page.
From server settings page, you can control the users of your server, and many more. For more information, check Server Settings FAQ
Now, to the other common settings.
Each page basically contains one common thing - a datatable.
It is a feature-rich datatable, supporting searching, ordering, create/edit/delete actions, batch actions, and some additional actions depending on what page you're on. For example, on stores page, you can configure email settings for a store by clicking email icon in actions column.
The core of Bitcart is creating a wallet. In Bitcart, one wallet represents one currency.
Default currency is btc, you can change that. When creating wallet, just select currency code from the ones available on your instance (btc,ltc etc.). Wallets may have a name and their xpub.
The nice feature of Bitcart is that it does not require your private keys, but it supports many different formats.
You can enter (x/y/z)pub - public key, (x/y/z)prv - private key, or even electrum seed - providing easiest migration possible from many wallets, especially electrum. If you don't have an xpub yet, we recommend you create a wallet somewhere. Electrum wallet provides the best integration with Bitcart, check Architecture page for more information.
When creating a wallet, it will get synced very fast (depends on the size of the wallet, but shouldn't take too long), and Bitcart will fetch it's balance and display it.
By clicking arrow near any of the rows, you can view some additional details, like wallet xpub.
You can create unlimited amount of stores in Bitcart.
Each store can contain any amount of products and associated invoices. Store is a base entrypoint for anything related to checkout.
Store may have multiple wallets connected. That way, connecting different wallets with different base currencies, you can achieve multicurrency checkout.
Selecting multiple wallets of the same currency is NOT recommended. On invoice creation, Bitcart will pick the first wallet of that currency, returned by database(they might be returned in any order).
If you want to send customers invoices on successful checkout, you should configure email server.
To do that, click on email icon in actions column, and enter SMTP server details.
Store email is the email used to send messages from, and the display email in Bitcart POS store.
Email host, port, login and password are credentials for your SMTP server. Email host shouldn't include any http:// or https:// parts. If your SMTP server requires TLS, turn on SSL/TLS switch.
When done(you should click save button first), click on Test ping button to see if your setup is working.
Note for gmail SMTP servers, you should enable access by turning on less secure apps (it is still secure, gmail apps aren't the requirement). You might also need to allow access on a new account.
From the email settings pop-up, you will also be able to load a ready preset for some popular email server providers.
Your store is the main configuration point for all the further actions with it, like invoice creation.
You can configure different policies from your store settings.
By clicking on settings icon, you will be presented with the store checkout settings pop-up, where you can change different settings affecting the checkout.
Invoice expiration time, in minutes. It affects the timer displayed in the checkout. It is the time in which the customer must send the payment, otherwise invoice is marked as expired
Use HTML templates - whether to render templates of email message sent to customer as html or as plain text. For more information, see this guide.
It is optional page for your initial setup, you may skip it for now.
In many cases you might want to add some discounts to your store. New year discounts, other holidays? Limited time promocode discounts? Discount when paying in your preferred currency? Anything is possible with Bitcart.
Just provide a percent(integer) for your discount, and discount apply conditions:
promocode(optional, when not provided discount is always applied when other conditions succeed)
end date
currencies(comma separated list of currency to apply to, or empty to apply to all currencies)
You can link discounts to products in the products page.
When one invoice at creation time has matched multiple discounts, Bitcart will pick the best discount(by percent).
Products are your base selling unit. Create your products, link them to your stores, add product details - and they will get displayed in your store POS!
Bitcart supports many different information for creating products:
Amount, displayed in store POS in USD
quantity(how many products of the same kind available)
product category(used for filtering in store POS to classify your products)
Discounts applied to the product(see previous section)
Product status(like in stock, not available, up to you)
Download url(for digital content, will be sent to customer in email)
Store, from which to take wallets and other information
Date of creation(auto-filled)
Product image(supports cropping, rotating and many more!)
Product description
This page can be used to monitor your paid invoices, create new invoices and send them to friends, or to pay an invoice.
Supported information:
Price is the price in store's default currency, which will be converted to payment method's currency when generating payment URL
Currency, used to override store's default currency if needed
Store, from which to take wallets and other information
Connected products(for store POS, optional)
Promocode, if customer entered it during checkout process (auto-filled)
Notification URL where to send IPN notifications on invoice status change (more below)
Redirect URL, customer will be redirected to it after successful checkout.
Buyer email, if customer entered it during checkout process(auto-filled)
Order ID, used by external integrations like woocommerce, track your orders by searching for order id(auto-filled)
Discount - ID of the discount applied during invoice creation(auto-filled)
Invoice status, more below
Date of creation (auto-filled)
Payment methods - not editable fields, displaying checkout information
If your invoice contains connected products, you'll be able to know which products were bought by the customer. The name of the store will be used on checkout.
When converting to payment method's currency, destination currency's maximum decimal points is taken in mind, and the price is being formatted as per currency settings. The convert, the exchange rate is used. See this page for more information.
If you fill in notification URL, Bitcart instance will send IPN notifications to that URL via a POST request.
It will send the following json data:
{"id": invoice_id, "status": new_status}
When invoice status changes(Pending->complete, Pending->expired, etc.), notification will be sent.
It's up to you how to process that IPN notification. You should also verify that data sent is correct, as theoretically, anyone can send that POST request if they know your IPN handler URL. So, check that sent status is the same as the one got from get invoice request.
Invoices statuses can be one of the following:
Pending (in progress)
complete (invoice paid)
invalid (unexpected error)
expired
In progress (lightning network status)
Failed (lightning network status)
After invoice creation, you'll be able to view checkout information by clicking show button in payment methods column. It will display a so-called "invoice preview", it is not a fully functional checkout, but just an information dialog to display payment methods(it ignores invoice status).
By clicking open checkout you'll be redirected to full checkout, respecting invoice statuses and other things. Invoice URL can be safely shared with others and used for checkout right from your admin panel.
On this page you can configure your notification providers, to later connect them to your stores.
Supported information:
Notification provider name for display
Provider to use, you can choose of many available ones
Provider options, differing from provider to provider
Each notification provider has different settings. Refer to their documentation about how to get certain settings. After that, select needed provider, fill in the settings and save changes.
Then you can reuse notification providers by connecting them to needed stores!
When notification provider is connected, on each successful order it will be run to deliver a notification to you.
On templates page you can override global server templates, or create custom ones.
Available fields:
Name of template, you can select from built-in ones or type in a new one
Template text
All templates in Bitcart are rendered via Jinja2.
Read about it's syntax in their template designer documentation.
Read more about example usages of templates in Bitcart here
When a template is being requested to render (for example, when sending notification via notification providers, or composing email message), it is selected in the following order:
If this product or store has template connected, it will be used
If it has no template connected, default global store or product template will be used (named store or product), if exists
If none of templates above are customized, default templates are used
On some pages, for example, stores or products pages, you will be able to edit templates per each item (per each product, per each store, etc.) If so, on such pages you will see the following icon:
By clicking on it, you will be able to override default templates for this item. Such templates are always used the first if they are set.
Note that in the example image above it is not necessary to connect default templates for each store, as the template we created is named notification, therefore overriding default ones for each store.
Bitcart supports sending funds from your connected wallets to outside sources. This can be useful for refunds for example, or in case you don't want to open a separate wallet for each currency and use universal Bitcart interface.
Just enter:
Destination
Amount to send (in fiat currency, defaults to default currency of the store, for this screenshot it would be 1 USD)
Store to use (used for setting some defaults like currency)
Wallet to send from. Whether it's a smart contract or not will automatically be determined via wallet settings
(Optional) notification url where to send IPN notifications on payout status updates (a HTTP POST request with data in format {"id": "payout id", "status": "new status"}
(Optional) Maximum fee (in fiat currency selected). If predicted fee exceeds the max fee, the payout will halt.
When saving a payout, it won't be sent automatically. It will be set to pending status, waiting for your approval. There are a few statuses for you to use:
pending (just created), approved (manual approval by you, not sent yet), cancelled (manual cancel by you, not sent), sent (payout is sent, tx hash is available, transaction not confirmed yet), complete (payout is sent and confirmed, used fee is available in payout details), failed (something failed during payout sending)
By default, all wallets in Bitcart are watch-only. We typically only require an address or xpub for payment processing needs. Private key is never required. In case you use the payouts feature, you will be able to connect relevant wallets used with their private keys. Signing will be done in a special "diskless" mode, where all operations will be performed in memory, with no data saved to disk.
But in case your wallet was created as a hot wallet, it will be used automatically without the need to supply it (note that in this case, as per regular wallet loading operations, the keys will be saved on disk)
Bitcart is extremely easy to deploy on your own server!
We have the minimal requirements ever possible:
1 GB RAM (2 GB if enabling ETH)
10 GB disk
Unix-based operating systems (something common like ubuntu is recommended)
Please refer to this diagram to choose your deployment method (you can see their descriptions in navigation sidebar at left):
In case you're not yet ready to choose where or how to host (it can cost as little as 3.5$ a month), you can try using Bitcart using our demo or third-party hosts.
If you want to try out Bitcart on your local machine, it is also possible. If you don't have a domain name, Bitcart provides a way to test in a local-only deployment.
Here and later we assume that you've cloned the bitcart-docker repository, entered that directory and entered root shell by using sudo su -
(note that minus at the end, it's important!). If you're on mac os, use the scripts as your current user and don't enter root shell.
It is even possible to combine both ways to be able to access both locally and from anywhere!
Bitcart Configurator allows you to easily deploy new Bitcart instances, or re-configuring existing ones, with ease and no technical skills.
Configurator demo is accessible at https://configurator.bitcart.ai
You can access it from your admin by clicking the configurator button.
It allows you to easily deploy a new instance by just answering a few questions.
There are 3 deployment destinations available: remote, manual, and current instance.
By entering the server credentials, the Configurator will automagically connect to your server and deploy the instance, while you drink a cup of coffee!
For an example of successful deployment, watch the video above.
If you don't trust the configurator's server, or you just need a copiable script you can run yourself, you can use the manual mode. It generates a script for you to copy, based on selected settings.
If you are the server admin, you will have access to the current instance mode. You can change settings of your current instance without logging in to your server. By clicking current instance button Bitcart loads all current settings which you can customize.
On this page you can configure and enable all the coins you want. For each coin you may enable lightning with just one click, or change network settings. Note that you must select at least one coin.
On the additional page, you may enable additional plugin packs, for example, Tor support.
On this page you can configure advanced parameters. If you don't need to edit them, skip to the next page.
You can choose an installation pack (all, backend, frontend or none), and add more custom components, or edit the bitcart-docker repository URL.
On this page you can preview settings used. If something is wrong, you will see warnings.
When you are ready, click continue.
After clicking continue, you will either see a ready script, or a progress bar, while configurator is deploying a new instance. Refer to each deployment destination for more details.
The setup is almost the same as always (see ), the catch is: the domain name must end with .local. Bitcart then modifies your host machines' /etc/hosts file to make it work.
You will get the admin panel running at http://bitcart.local/admin, store at http://bitcart.local and api at http://bitcart.local/api. Good for testing locally/developing without all the hassles of . Note that if you don't use , it will still work.
It isn't even required to set BITCART_HOST
if tor is enabled. You can get onion addresses generated from the compose_tor_servicesdir
docker volume. For more details check our .
Configurator is designed for ease of onboarding and works only with .
If you have more complex setup, check out full .
On this page you can enter your domain where to deploy (using ), and optionally disable https support. If you don't have a domain, you can enable tor support in the later pages.
Sometimes you might want to run Bitcart on your own hardware. This is a bit more complicated than using a VPS. But in the end you will get way better security and control over your data.
Note that no matter where you host Bitcart, as your private keys are never required, your data is always safe, you can export and move the data to any server. So if you started on a VPS, you can use our backups feature to create a backup of all your data and restore on your own hardware.
Here are the requirements for running Bitcart on your own hardware:
High-speed internet connection. The faster the better. This is to ensure the speed of invoice detection
Any hardware ever. Yes, that's right! You can use your old PC or basically anything for that. Our minimal requirements are 1 GB RAM and around 10 GB disk. AMD64 hardware is the most tested one, but if needed, refer to our raspberry pi guide
Any linux-based OS would suffice, but using something like Ubuntu 20.04 is the most common choice.
(Optional) Static ip - that's required only if your setting up with your own domain name. If you only plan to use bitcart locally/via tor, this is not needed
(Optional) Domain name - see the note above
This guide assumes that you have static ip set up and your own domain name. If not, refer to the local setup guide.
Configure static IP in ubuntu via something like this guide
If you have a domain name, create a DNS A record pointing to your static ip address (tip: you can get it if you type whatsmyip
in google)
Set up port forwarding on your router for ports 80 and 443 to your machine ip address. Every router is different, usually there are guides existing on any model
Recommended: install ssh server, configure firewall and fail2ban (to prevent excessive failed logins from random ips on the internet):
Clone and install Bitcart (replace bitcart.yourdomain.com with the actual domain name):
All done! Enjoy your Bitcart instance! If needed, check out backups support on how to restore the data from your previous instance.
Raspberry Pi is a good low-power solution to host Bitcart at home. It is quite cheap and you can use it to build a lot of custom stuff.
We recommend using the latest RPI4, but RPI3 would be good too.
What's good is: Bitcart can work with any RPI flavour, even 1 GB RAM is enough to run Bitcart. Though we recommend picking up a bit more (2 GB) just to avoid slowdowns.
As for the disk, SD card, USB memory or SSD - it doesn't matter, just know that SSD is usually faster. Basically any disk on the market should have enough space (10 GB)
It is recommended that you install 64-bit version of raspberry pi OS, as it is tested natively via our CI systems. 32 bit version is obsolete and is no longer officially supported. But if you want to stay 32 bits, note that on debian modern docker images may fail to start, although we try to fix that bug in our setup scripts.
We won't provide the details of how to install OS on your RPI, but raspbian should work fine. Check those guides for getting started and downloading an OS image
Open a terminal on your RPI if you have connected a display to it, or ssh to your RPI.
Start a root shell: sudo su -
Upgrade your system, install firewall and secure your pi from unnecessary ssh spam:
Clone and install Bitcart
Ensure that your local computer you'll be accessing your Bitcart from /etc/hosts entry for raspberry pi matches BITCART_HOST. Or instead set BITCART_HOST to your raspberry pi ip address directly.
That's it! You can now access Bitcart store at http://raspberrypi.local, admin at http://raspberrypi.local/admin, api at https://raspberrypi.local/api. For other ways of deployment (your own domain/tor) check docker deployment and tor support
A third-party host is someone who runs Bitcart instance and enables registration for other users. They might be free (but could accept donations) or with paid access.
Sometimes it's hard for users to deploy a new instance, but they want to try right away. That's what third-party hosts are for.
In general, it's not recommended to use them especially if you plan to scale your business, but it's great for testing.
Our demo at https://admin.bitcart.ai showcases all coins Bitcart supports, but we don't recommend using it for commercial purposes.
There are some hosts ran by others
admin.bsty.business (BTC, BSTY, free)
You can contact us in one of our communities. Your server should have enabled server registration in server management settings.
The only limitation is that you won't be able to access server management pages. Other than that, it's pretty much the same unless server owner has forked Bitcart. Check this guide for details on server management settings.
Well, in most cases yes, but you should be aware of scams! People might fork Bitcart and customize it to be malicious. We never intercept the payment process and never require a private key (except for lightning network). Also, watch your wallet to check if the host replaced your public key with their own! Some public hosts also handle a lot of customers of different services, so if you self-host one yours won't be that loaded.
Bitcart uses docker for deployment. This allows us to simplify the installation and make Bitcart installable in almost any environment.
Currently Bitcart runs on 2 architectures: amd64 (most PC and servers), arm64 (raspberry pi). Arm32 is not supported officially anymore.
Almost every docker deployment starts like that:
Note the minus sign after su
. It is required. If you are deploying on mac os, you don't need to enter the first command. This is to load all settings
There are different environment variables available in order to customize the deployment
Environment variables are set like so:
Here are the main ones:
BITCART_HOST
configures on which domain Bitcart should run. It is required unless you use any of the methods from local deployment. It works in one domain mode. Your Bitcart Store will be accessible at BITCART_HOST
, admin panel at /admin and Merchants API at /api. For other ways of configuration (for example different servers), check the one domain guide
BITCART_CRYPTOS
configures which coins to enable. It is a list of coin symbols separated by commas. By default only btc is enabled. For example, to enable btc and eth, you would run export BITCART_CRYPTOS=btc,eth
BITCART_REVERSEPROXY
- configures the reverse proxy used. By default nginx-https
is used (with automatic ssl certificates generation). It might be useful to disable it to access your services directly or you can set it to nginx
to disable ssl
BITCART_ADDITIONAL_COMPONENTS
- you can add additional components to your deployment. For example, using export BITCART_ADDITIONAL_COMPONENTS=tor
enables tor.
There are also quite a few settings related to configuring coins in Bitcart. Each coin has the same set of settings you can configure:
COIN_NETWORK
changes on which network the coin runs. For example: export BTC_NETWORK=testnet
would enable testnet in BTC coin with no other changes required!
COIN_LIGHTNING
enables lightning network for coins which support it (BTC-based). For BTC you would do: export BTC_LIGHTNING=true
COIN_DEBUG
enables debug mode for daemons to log more information. For example export BCH_DEBUG=true
COIN_SERVER
configures the daemon to use exact server you specify instead of connecting to many servers at once. For example export BNB_SERVER=https://bsc-dataseed.binance.org
For btc-based coins, you can set up your own ElectrumX or Fulcrum server with your own full node. For eth-based coins, server is your full node's RPC url.
For the complete list of configuration settings you can use (to e.g. open some ports, change networks used or anything else), check out full configuration description at bitcart-docker github.
This document explains how to connect a desktop Electrum Wallet to Bitcart.
Electrum wallet is recommended, as Bitcart is tightly integrated with it, providing the best user experience and speed.
Register an account in your Bitcart instance
​Download and install Electrum Wallet
After the installation, open Electrum Wallet by clicking on the icon on your desktop.
Create a new Electrum Wallet
In Electrum, Wallet > Information - copy the Master Public Key.
In Bitcart, Wallets > Create wallet > Paste the Extended Public Key in xpub field
The following setup guides you through setting up an entirely new Bech32 (SegWit) Wallet in Electrum. If you already have a wallet skip to the Extended Public Key copying.
Firstly, give your wallet a name, for example, Bitcart Wallet
and click Next
.
Choose Standard wallet
and proceed by clicking the Next
button.
Since we're creating a brand-new wallet,choose Create a new seed
and Next
From the multiple choice menu, select SegWit
and Next
IMPORTANT NOTE: If you're a merchant, instead of SegWit (Bech32), it's recommended to use SegWit wrapped (P2SH) format. This guide explains how to create P2SH wallet in Electrum that's more suited for merchants, due to compatibility with legacy wallets customers use.
IMPORTANT NOTE 2: Write down your recovery words in the order you see them on the screen. Write them down a piece of paper and store it somewhere secure. Take your time and triple check each word. Do not store your seed in a digital format (photograph, text document). Whoever has the access to your seed can access your funds. Confirm that the seed has been properly backed up by re-entering it in the same order. Once the seed is validated, proceed to the next step.
It's highly recommended that you encrypt your wallet. Select a password that you can easily remember and mark make sure Encrypt Wallet File
is marked. Proceed by clicking Next
.
When the wallet loads (it may take few moments), in the top menu, click on the Wallet
and thenInformation
.
Select and copy the Master Public Key
. This is the public key from which Bitcart will derive addresses.
Return to your Bitcart. Click on the Details
button in the Wallets
card and click on the New Wallet
button. Enter your wallet name and Paste the Master Public Key from electrum to xpub field. Click Save
.
In the top menu, click on the View
and thenShow Console
.
Enter following commands in Electrum console and press enter
on your keyboard.
If you are running a version older than Electrum 4, also enter the following command and press enter
Restart your Electrum and verify that the newly set gap limit is correct by entering in the console:
There's no good answer to how much you should set the gap limit to. Most merchants set 100-200. If you're a big merchants with high transaction volume, you can try with even higher gap limit.
For more details about the Gap Limit, check the FAQ.
Electrum and Bitcart are now connected. Any payments received to your Bitcart will be visible in Electrum, where you can further spend them.
ETH payments plugin allows to improve payments UX of ETH-based coins (currently ETH, TRX, BNB, POL) and all their tokens (USDT, USDC and more on those chains) by disabling address prompt and accepting payments from exchanges. This allows you to boost your sales massively as this plugin allows you to accept all currencies Bitcart supports + ETH-based coins with the best UX possible while still remaining non-custodial, with minimum security risks and by saving on network fees (using just 1 transfer instead of the usual 2 to withdraw tokens from your pool addresses)
First of all, to buy the plugin, ensure you are running Bitcart v0.9.0.0 or later
Open your plugins page and click on purchase button:
After that you will be able to choose monthly or yearly billing.
Ensure the email address you enter is not a disposable one, it will be used to send you license key, billing invoices and plugin updates
After successful payment you will receive an email with your license key and plugin download URL. There is no need to download the plugin unless you have some custom setup, everything can be done in admin panel UI.
Next, head to plugins page and enter your license key there
After you have added the key, purchase button will turn into install button. Just press it to install the plugin.
Don't forget to click the reload plugins button to apply changes. It will take a few minutes for plugin to build as it applies updates to the admin panel which take more time to build.
After that, address prompt should be removed automatically. If after 10+ minutes it doesn't disappear, please contact us
For native coins (like ETH, TRX and others), when payment is received to the wallet pool address, it is sent to your primary address automatically, because when we have a native coin on address, we can just send all of it minus network fees to the primary address.
For tokens (like USDT, USDC and others), it can't send payment to your primary address without paying network fees. As for tokens it is needed to pay network fee in native coin, and wallet pool addresses don't have it, that's why it is needed.
That's where the plugin shines in, it allows us to cut network fees by using only 1 transfer instead of 2.
First, you need to create a fresh wallet, which will be used only for paying network fees. Ensure to not deposit too much to it, as this is the only private key that is inserted into the system and has higher risks of being compromised if e.g. the server gets hacked. But your primary wallet is always safe as you just enter it's address.
Let's create a fresh wallet in let's say, trust wallet:
You can use the seed directly, or if you really want to have a private key specifically, you can do it for example with Bitcart cli by running this on server:
The plugin adds a new page for wallets: address pool management. It is accessible by clicking an icon near any of your eth-based wallets.
This page is another key feature of the plugin: you can view all your addresses used in invoices from one page
Status has the following values:
Free - ready to be re-used in upcoming invoices
In invoice - attached to a currently active invoice. It is freed when invoice gets either expired or paid
Pending payout - invoice with this address was paid, so it will be attempted to do a withdrawal. Actual withdrawal will happen only if it meets min withdrawal and network fee criteria, and for tokens, if fee private key was set and has enough balance
In payout - payout is being performed right now
Init Status indicates whether the fee wallet is authorized to send payments to your primary wallet from this pool's address in just 1 transfer:
Uninitialized - address is new and hasn't been set up yet. Ensure you have your fee private key set and that fee wallet has balance
Initializing - address is in the process of being initialized
Initialized - address is fully set up and ready to use. For non-token payments, this is always the case as no fee wallet is required.
If needed, you can trigger withdrawal manually if you click on withdraw button. Also batch withdraw and delete actions are available.
If you want to view debug logs of the plugin, click on profile icon->server management->policies
And enable the debug checkbox near eth_payments plugin:
You will then be able to view debug logs in server logs of your instance.
The main difference is that, existing solutions are custodial and they store all information about your payments, customers and anything else they can get. Also custodial means money gets sent from your customers to their intermediate addresses, and only then sent to you. Which means if they want they can lock you out of your funds.
Bitcart on the other hand, operates by accepting payments directly to your wallet. Private key is never required either. For plugin to work it does require generating unique deposit addresses, but private keys for all addresses in your wallet pool are stored in your local database and not stored anywhere else. Which means, even in worst case you always have private keys to withdraw the funds, and the plugin automatically sends payments from pool addresses to your primary address without any manual intervention.
Also as everything is hosted on your own server, you have full control over your data: order information is never shared with anyone, everything is stored on your server only.
And another key feature is: when sending tokens from pool addresses where no native coin is present, the usual flow is 2 transfers: first, estimate the approximate amount of network fee needed for a token transfer, and send that to the pool address, wait for some time when it gets confirmed, and then send the tokens.
The plugin on the other hand requires only 1 transfer: if pool address is initialized, the fee wallet is able to send tokens from pool address to your primary address utilizing it's native coins, avoiding the second transfer. This makes it way more reliable and allows to save on network fees.
The plugin collects minimal information possible for accurate billing and abuse control:
Monthly volume done by using the plugin only (this is sent as a dictionary where key is invoice currency, value is total). No order information leaves your server, plugin uses database query to collect aggregate numbers only and send to license server for accurate billing
Plugin version
Machine ip + machine id. Used for abuse control, by default only 1 server can use the plugin at the same time. If you switch servers, wait 6 hours for the old plugin to stop sending license checks, then a new server can be switched to automatically. If you need it faster contact us and we'll reset machine binding
The plugin collects aggregate sum of paid invoices where payment method used is created by the plugin (so ETH-based coins only, coins untouched by the plugin are not billed) over the last month
The information is sent to license server where it uses it's exchange rates to combine it into one final USD amount.
Yes, but only if you exceed the monthly 2000$ unbilled volume. The plugin price itself will be billed once a year, and each month where you do exceed the thresold, you will be billed only on the excess amount.
Yes, we don't intervene in your invoice generation or payouts at all. Everything is processed by your server. At the end of the month (your billing period), you will receive an email with bitcart invoice to pay. It is calculated based on your billing cycle and monthly volume stat. You have 7 days to pay the invoice until the plugin gets deactivated. If it does, you have to contact us and we can re-issue the invoice
The process is basically the following:
Install OS required libraries
Install python3 (3.9+)
Install nodejs (20) and yarn
Install postgresql
Install redis (6.2.0+)
Clone and run all parts of Bitcart
(Optional) Open Firewall Ports and Access the Sites
Manual installation is NOT recommended in production. It should be only used for learning purpose.
Instead you should use the docker deployment.
The docker deployment will provide you easy update system and make sure that all moving parts are wired correctly without any technical knowledge. It will also setup HTTPS for you.
This steps have been done on ubuntu 22.04, adapt for your own install.
Or the equivalent for your os package manager
More info on libsecp256k1 in electrum docs or bitcoin core docs
Usually it might have already been installed, but we also need pip3 and dev packages, so:
Using a nodejs version higher than specified way work, but we officially support only 1 release series (usually current LTS)
Note, replace REPLACEME
with your new postgres password.
For any other daemon(coin) you want to use, run:
Where coin_name is coin code(btc, ltc, etc.).
Create a file conf/.env
It contains all the settings. For now, we just need to set database password and enabled cryptos.
Apply database migrations:
Start daemons from the bitcart
repo directory:
For any other coin, do the similar procedure:
Start api:
Start background worker:
If you want to run a specific coin on a test network or change other environment settings you can update the
.env
file in the bitcartconf/
directory
The Bitcart API runs on port 8000
.
Daemons on ports 5000-500X
The Bitcart Admin panel runs on port 3000
The Bitcart Store runs on port 4000
.
If you are running Bitcart on your local machine - you will not need to do these steps. You can go ahead and access the system with:
Bitcart Admin Panel: http://127.0.0.1:3000/
Bitcart Store: http://127.0.0.1:4000/
Bitcart Merchants API: http://127.0.0.1:8000/
If you are running Bitcart on a remote machine, you will need to do additional things to access them.
This option is recommended to proxy secure incoming requests to the correct bitcart process.
Install Nginx
Add configuration for each component: bitcart-store, bitcart and bitcart-admin
Enable the config
Add DNS records for your server names to point to your VM's ip
Check the config and reload nginx
Add TLS certificates with the letsencrypt CA for the sites
Now you should be able to access the components over TLS. You can then also enable http2
in your nginx configuration if you want.
You might want to look at the FAQ for more detailed info on the Nginx configuration options
If you have a firewall, you will want to open ports 3000
, 4000
and 8000
. Using ufw
as an example:
yarn
is listening on localhost127.0.0.1
by default and you won't be able to access it over the internet unless you reverse proxy it withnginx
. If you want to expose it without reverse proxy, use the environment variable:NUXT_HOST=0.0.0.0
to listen on all interfaces.
The store and admin site need public access to the bitcart api (URL should be resolvable both client and server side).
Using the manual method you need to set that with environment variables. The complete setup of the Bitcart Admin Panel and Store may look like this:
Note: The above is the minimum to make it work and not a production grade solution. We still recommend to use docker deployment unless you really know what you're doing.
Access the site remotely
Bitcart Admin Panel: http://my-bitcart-admin-ip:3000/
Bitcart Store: http://my-bitcart-store-ip:4000/
Bitcart Merchants API: http://my-bitcart-store-ip:8000/
Continue with: Your first invoice
If you want the procaesses: bitcart api, daemons, worker and frontend (bitcart admin and bitcart store) to be managed with automatic startup, error reporting etc then consider using supervisord or systemd to manage the processes.
Note: it is recommended to use docker deployment for easy upgrades.
To upgrade manually, follow the following steps:
Merchants API, workers, daemons, Admin panel and Store should be stopped
Run :
For every Bitcart component directory (Merchants API, Admin Panel, Store).
Bitcart admin
Bitcart store
In Bitcart core(daemons) & Merchants API directory, run:
For Bitcart Admin Panel and Store, run:
Follow instructions here
Built with extensibility in mind, Bitcart is a feature-rich software with plenty of use-cases that can solve problems for different types of users.
In this guide, we will show you some of the use-cases of Bitcart, but it is by no means limited to the groups of users we mentioned.
So let's have a look at what you can do with Bitcart and what the benefits are of using it.
By choosing Bitcart to process payments, you are:
Saving money (no fees, no subscriptions)
Cutting out the middle-man (Payments go directly to your wallet)
Enhancing privacy for you and your customers (no address re-use, no IP leaks to third parties)
Saving time (easy integration and installation)
Protecting yourself from interference in your business (self-sovereignty)
Reducing the costs for the server running your instance (lightweight but secure)
Decreasing the development time as we have ready solutions available for any kind of store
To enjoy most of these benefits, you don't even need to run a Bitcart instance yourself, you could just create an account on someone else's instance. It will be even easier to set up for free or a fee depending on the host's choice. Downside is that you will rely on the server admin to keep it functional and up-to-date.
With the growth of your business it will eventually become important to set-up your own server to be really independent.
Want to give it a try? Here is an up-to-date list of third-party hosts.
If you're a merchant running an e-commerce business, you can easily deploy Bitcart and connect it to your store via integration plugins in just a few clicks. Or, if you don't have a store yet, you can use Bitcart's built-in store which is a ready solution which might be enough for your use case. You can start selling even without any programming!
Bitcart checkout is no different to any other payment gateway. Your customer gets an invoice. They pay it by scanning a QR code or by copy-pasting the amount and the address. When their payment is confirmed, you will be notified via your e-commerce CMS and additional configured actions will be executed, and you can ship the item. Take a look at our demo online store.
For physical stores, Bitcart has a web-based Point of Sale (POS) store which can be customized. Similarly to the online store, your customer is presented with an invoice that they can pay on the spot. You can create a watch-only wallet on your phone to be notified of the payments through the POS, without the need of any additional software. The POS store can be run on any web-connected device.
Send anyone a request for payment by creating an invoice with custom amount in your admin panel (demo). With or without expiry, users can pay the invoice at any time.
Merchants or freelancers can use this for bill pay services. You can even use your admin panel to quickly request money from friends.
No matter the kind of business you run, Bitcart offers a very easy way to get started on the Lightning Network. You can use and experiment with this innovative second-layer solution build on top of Bitcoin by following this guide. Both merchants and customers can use Bitcart to receive or make payments off-chain with instant confirmations and neglectable network fees.
Charities, non-profits, content creators, and other organizations that want to accept cryptocurrency donations in a more private way than the traditional single bitcoin address method can utilize the Admin panel, and POS store for a better user experience.
Benefits of using Bitcart for accepting donations:
Saving money (no fees, no subscriptions)
Cutting out the middle-man (Payments go directly to your wallet)
Enhancing privacy for you and your customers (no address re-use, no IP leaks to third parties)
It is particularly important to mention that Bitcart prevents address reuse, as many people has been reusing address for donations in the past. Here is why you SHOULD NOT reuse Bitcoin(or any other cryptocurrency) address:
Privacy: reusing the same address for donations not only makes it incredibly easy to link it to your identity, it also compromises the privacy of your donators and every person that interacts with you
Security: by compromising your privacy, address reuse increases your attack surface, as people that want to steal from you or harm you would have A LOT of information about you and your donators
High fees: fees for a Bitcoin transaction are calculated according to the "size" of a transaction (which has nothing to do with the amount being sent). By reusing addresses, you are building huge transactions involving many inputs, that will cost you a lot in fees when you want to move them
You can read more about address reuse on the Bitcoin Wiki.
When you deploy a self-hosted Bitcart instance, you can attach and create an unlimited number of stores and apps. This means when you launch Bitcart, you can become a payment processor for your family members, friends or your local community. You can do that to promote Bitcoin or other cryptocurrencies amongst people you know or to help out people that can't rely on other solutions.
While you're allowing them to rely on your Bitcart core instance, the payments go directly to their wallets, and you have zero control over their funds at any point in the transaction, and cannot charge a processing fee. You can, however, develop a registration paywall and charge monthly fees.
Take a look at the list of third-party hosts.
The number of merchants using Bitcart grows each day, and cryptocurrency exchanges could benefit from it by developing integration with Bitcart and allow instant conversion of cryptocurrency payments into local fiat currencies.
Being an open source project, Bitcart doesn't have the power to impose anything on exchanges, meaning that any of them could build on top of it, regardless of their size or the country they operate.
Hosting providers can (and some already did) create easy 1-click Bitcart deployment solutions for their customers. With the growing interest in Bitcart, hosting companies can tap into this source of new customers and make money by hosting easily-deployable Bitcart instances for merchants.
Bitcart community is amiable and open-minded. Developers can not only learn a lot and get their name out by working on an open-source project, but also participate in transforming the payment processing business.
Bitcart source code is a great source of learning, as it utilizes the modern and demanded tech stack. It has already helped many people in learning something: testing and TDD, docker, APIs building, and many more! Join us and discover many great things in tech world!
These are some of the many ways in which you can use Bitcart. Unleash your creativity and feel free to build your own solutions to solve problems.
Bitcart plugins are modular components that can extend the functionality of your Bitcart instance. A plugin can consist of one or more of the following components:
Backend: Server-side logic, database models, and API endpoints
Admin: Extensions to the admin panel UI
Store: Customizations for the store frontend
Docker: Docker compose deploy customizations
This will guide you through creating a new plugin by asking for:
Plugin name
Author
Description
Component types to include
To install plugin to develop alongside bitcart, you can use bitcart-cli plugin install .
It is recommended to pass --dev
flag to install plugin in development mode. It uses symlinks to link the plugin to the bitcart source code, so when you make changes to the plugin, they are reflected immediately.
It asks for paths where you cloned bitcart, bitcart-admin and other repositories. You can pass --save
flag to save paths to config, so that it is never asked again.
After you are done developing and want to remove it from codebase:
A backend plugin must have a plugin.py
file which as a Plugin
class that implements the BasePlugin
class from api.plugins
. The basic structure is:
To add custom database tables:
Create a models.py
file in your plugin directory
Define SQLAlchemy models
Manage migrations using alembic:
Basically same commands as alembic, but you provide your plugin name.
This will create a new migration in the versions/
directory. Migrations are automatically applied when the plugin is loaded.
Bitcart provides two extension mechanisms:
Hooks: Execute actions at specific points
Filters: Modify data as it flows through the system
To find hooks and filters, you can search the codebase for apply_filters
and run_hook
.
For example, db_modify_wallet
would be called right after wallet is saved in db.
So you can use it like this:
And in filters first argument you receive is the value which you can return unmodified or modify. Other arguments are optional data
Example:
To add custom settings for your plugin:
Settings are automatically available in the admin panel and can be accessed via:
If you need to add backend dependencies, create a requirements.txt file in your plugin directory, it will be installed automatically.
Register custom components in extends.js
:
Add custom routes in routes.js
:
Add dependencies to package.json
Store plugins follow a similar structure to admin plugins but are specifically for the store frontend. They can:
Add custom pages
Extend existing components
Add new payment methods
Customize the checkout process
To package your plugin:
This creates a .bitcart
file that can be installed on any Bitcart instance.
Use descriptive names for hooks and filters
Document your plugin's requirements and dependencies
Handle errors gracefully
Clean up resources in the shutdown method
Follow the existing code style
Test your plugin thoroughly before distribution
Plugin discovery and loading
Database migrations
Plugin initialization (startup)
Hook/filter registration
Settings registration
UI component registration (if applicable)
Background worker setup (if needed)
Shutdown cleanup on server stop
You may have a question: which servers does Bitcart use by default? It depends on the coin!
If using BTC-based coins where we use Electrum or it's forks, it is connected to a network of electrumx/fulcrum servers, which are indexers of the blockchain. It connects to multiple servers, verifying with SPV (Simple Payment Verification) that the results acquired are valid. It is reliable enough and can handle any load. This is the same list you would see if you downloaded Electrum wallet yourself and connected to the network
For other coins we don't have something like electrum existing, and we also don't have a network of blockchain indexers.
That's why for those coins Bitcart daemons require at least 1 full node RPC to be configured. In coins like ETH free RPCs are widespread and have good rate limits. So the defaults will always use some free RPCs which should be good enough for Bitcart to run
Defaults are usually set in docker compose components.
NOTE: Since Bitcart v0.9.0.0, seed server feature was launched. Servers are no longer hardcoded in yml files, so in case some RPC breaks, users won't need to update each of their instances, we can edit it in the seed server and the daemon will update links at maximum in 1 hour. This is the default behaviour inside docker deployments now. To disable it, set COIN_SERVER
to some specific server, just as it was done before.
If you want to view the current list of servers used for each specific coin, you can call seed server directly, for example:
Then you can point Bitcart to it via COIN_SERVER
. You can force to connect to only your server and not others via COIN_ONESERVER
.
Just run the full node of the coin you selected, and then set COIN_SERVER
to the RPC url of your node.
Lightning network support is experimental, as the lightning network itself.
Process with caution, and don't put large amounts in your lightning channels.
Before enabling lightning, please read all the warnings.
Lightning network in Bitcart is supported via Electrum's lightning network implementation
It has some limitations, please read the most up-to-date version at your admin panel.
To enable lightning network, for each coin, run:
Where COIN
is coin symbol (i.e. BTC
, LTC
)
Note that it will utilize a bit more server resources, but not by much.
When enabled, you will be able to enable lightning on the wallets page.
Currently lightning is only supported in the native segwit wallets.
When opening a non-supported wallet (or if lightning is disabled in the daemon), you will see the following page:
If lightning is supported, by clicking on the lightning icon and accepting all warnings, it will be enabled for the wallet.
If lightning is enabled for a wallet, then, along with the regular coin payment method, a lightning one will be created.
As your Bitcart daemons are standalone lightning nodes, you will need to open lightning channels from scratch. You can use the lightning management page for this
From the lightning management page, you will see your lightning balance, your node id, list of open channels, and you will be able to close, force-close or open new channels.
You can also pay lightning invoices from that page via your node.
From the checkout page, customers will be able to scan either the lightning invoice, or your node id.
That way they can open a channel with you
One domain mode is an opt-out feature, enabled by default, which simplifies the configuration of domains.One domain mode allows running all Bitcart services under one domain.
If you are deploying a new instance from the Bitcart Configurator, it is the default mode enabled.
But this was not always the case, one domain mode was added in Bitcart version 0.3.0.0.
You only need to set one environment variable to run Bitcart: BITCART_HOST
.
All the services will run either under the root domain, or the suburls on that domain.
One domain mode is enabled, when the following settings are unset:
BITCART_ADMIN_HOST
BITCART_ADMIN_URL
BITCART_STORE_HOST
BITCART_STORE_URL
Depending on the configuration, the service that will run on the root domain is selected in the following order (if available): store, admin, api.
So, if all 3 components are enabled, and BITCART_HOST
is bitcart.mydomain.com
, then:
The store will run at https://bitcart.mydomain.com
The admin will run at https://bitcart.mydomain.com/admin
The Merchants API will run at https://bitcart.mydomain.com/api
Or, if only the Merchants API is enabled, then it will run right at https://bitcart.mydomain.com
.
Because despite having the easy-to-use one-domain mode, we also support advanced use cases.
For example, you may need to run Merchants API on one server, and admin and store on another one.
It is completely possible.
On one server (with api), you would run:
And on another one (with admin and store), you would run:
What does transaction speed mean?
First of all, transaction speed applies only to on-chain invoices. All lightning invoices are instantly marked as complete.
To understand why transaction speed setting is needed, you need to understand the invoice statuses in Bitcart:
When invoice has just been created, it has pending
status.
If no payment has been sent within the invoice time frame (expiration time), invoice is marked expired
. Expired invoices no longer listen for incoming payments, but you may manually mark it complete.
If a payment has been sent within the invoice time frame (expiration time), invoice status is set to paid
.
With paid
status, customer is redirected to the redirect URL, and checkout page shows paid. But all the notifications, emails and custom scripts aren't executed yet.
When payment has been confirmed (has >= 1 confirmations), invoice status is set to confirmed
.
When payment's number of confirmations is >= transaction speed, invoice status is set to complete
, and all the postorder actions are executed (like notifications).
So, transaction speed controls how fast you want your invoice to be complete. Default value of 0 provides the fastest checkout, but it is not always good for your use case, it might be not safe.
Value of 1 means waiting for one confirmation, which is enough in most cases.
You can set transaction speed to any value between 0 and 6 (there is no point in waiting past 6 confirmations).
Bitcart supports backing up it's data on one server and restoring it on another.
It is available via both UI and terminal.
To enter backups management page, go to profile->server management->backups
From there you can start a backup right away, it uses settings from this page to do it.
You can select which backup provider to use. All of them, except for local, require setting environment variables as you can see on the screen above.
Local provider just saves the backup on your current machine.
It is saved to /var/lib/docker/volumes/backup_datadir/_data/
Backups are named YYYYMMDD-HHMMSS-backup.tar.gz
SCP provider copies the file from your server to SCP_TARGET
and deletes backup locally
Required settings:
SCP_TARGET: for example username@ip/where/to/put/backups
S3 provider sends your file to amazon S3 and then deletes it locally
Required settings:
S3_BUCKET: in which bucket to save the backup
S3_PATH: where exactly in the bucket to save the backup
It is possible schedule backups to run automatically.
For backups to work, your settings must be valid (otherwise it will just fail every time), and you need to tick the scheduled backups checkbox. The timer will be saved even after server restarts.
Settings are saved automatically, and if you had existing schedule configured and change frequency/turn off and then on again backups, the timer will be reset
Restoring backups is as easy as just uploading backup file to your instance!
Backup settings are configured via environment variables
If you need to run backup for scp provider, you would run:
Assuming that your file is named backup.tar.gz
, just run:
The first step in setting up your Bitcart instance is creating a user account. The first created account on a newly-deployed Bitcart instance is automatically - admin.
To register, visit your Bitcart URL and fill in the account registration form. Input your password, password confirmation, e-mail and click "Register". You will automatically be logged in.
Inside Bitcart, you can setup and manage an unlimited number of wallets. Each wallet has its own xpub (BTC-based blockchains) or a single wallet address (ETH-based blockchains), and currency. One wallet holds one currency.
Bitcart is a non-custodial software, which means that all the funds received to your store, will end up directly into your connected wallet.
You need to have your blockchain wallets created beforehand to specify their details in Bitcart! (more on this below)
To manage the funds received to your Bitcart wallet, you can use an external wallet.
We recommend that you use the wallet which:
Allows connection to a full node
Allows custom gap limit
You can use any ETH-compatible wallets (e.g. MetaMask, or Mycellium) to create your ETH or BSC wallets. Copy-paste your wallet address from wallet software to Bitcart into "Wallet / Xpub" input.
To setup wallets, make sure you're logged in into your account, and go to > Wallets by clicking Details button on the card. Click on the create wallet button and fill in the wallet name, currency(optional, default btc) and xpub (or wallet address for ETH-based blockchains).
Inside Bitcart, you can create and manage an unlimited number of stores. Each store has its own wallet or wallets (it allows multicurrency checkout), can create products, invoices or be connected with external e-commerce software through one of the integrations.
To create a store, make sure you're logged in into your account, and go to > Stores page by clicking on Details in it's card. Click on the New Store button. Enter the store name, and select this store's wallets.
You can always edit your store by clicking the edit icon.
To configure email servers, click on email icon in actions column.
You can create your invoice in a variety of different ways
This method is one of the most obvious. You can create invoices from the panel, manage your orders and send links to checkout pages to your customers. Click on the show button in the payment methods column to view the checkout page.
Depending on the CMS you're using, you can easily connect Bitcart to your online store. Currently, Bitcart offers following integrations :
That's it, your first invoice was created with ease!
To create a new plugin, use the :
Admin plugins can extend the UI using the our plugin system based on . The basic structure is in e.g. admin/your_plugin_name
:
In order to run your own node, first you need to run the actual full node, like .
Then you need to run an indexer compatible with Electrum protocol, so either or (recommended).
This document describes the whole process you should do after to get your first invoice in your store!
Server admins have the same access to features as the regular users, but they are also provided with some like server upgrade or server policies management.
Note: A (xprv) is never required for receiving money on-chain to a Bitcart wallet. The software needs a public key (xpubkey) which is a watch-only wallet token. The xpubkey allows Bitcart to generate a new address each time a new invoice is generated. It enables users to observe the wallet balance and transactions without having to share their private key.
The most recommended wallet for use with Bitcart is the , as Bitcart uses electrum internally, which makes it perfectly integrated.
For more information, check .
Bitcart provides a ready to use store POS. You can manage your products and invoices right from the admin panel! Check out the
If you have questions, try searching our FAQ Section or join the and share questions and ideas for improvement.
If you are a developer take a look at the and help us with any on Github. If you would like to contribute to Bitcart in other ways, check out the for ideas.
It is possible to customize the look and feel of Bitcart UI by overriding some CSS variables.
Currently it is supported for store POS only.
A list of possible css variables: https://github.com/bitcart/bitcart-store/blob/master/assets/bulma-generated/generated-bulma-vars.sass
Guide to customizing the theme:
Create a css file changing some theme variables
Upload theme file to file storage of your instance
Copy download URL and use it in store theme URL setting in stores page
Enjoy updated theme colors!
Templates in Bitcart are powered by the Jinja2 templating engine. It means that you have the full flexibility of the templating engine.
There are currently 3 different templates you able to customize in Bitcart: notification
, product
and shop
. Plus you are able to create custom-named templates for use with our future scripting language.
Check the example templates here
For each of the objects, you are able to select a custom template.
The templates for an object are selected as per template selection rules
In some places of Bitcart, it is possible to render templates as html files instead of plain text.
For example, in emails sent to customer on successful checkout, you could use default templates (or customized a bit) which are plain text, or instead, you could enable html template rendering and send your customers a beautiful email.
Currently html template rendering is available only in store emails sent to customer
Note: if you enable html template rendering, default templates or any plain text templates will now render incorrectly, without new lines. So ensure to check that template rendering templates match the templates themselves.
If you have a decimal field that needs to be formatted properly using currency data (e.g. price), you can use the format_decimal
filter to format it properly, passing key of field on the model.
You can check html templates examples here.
Notification template is used when building the message to be sent via all configured notification providers to the merchant notifying of successful order (to start shipping, for example).
The are two variables passed:
store
, containing the store this notification belongs to
invoice
, containing the invoice that has been paid
You can use those two variables to build whatever message that fits the best for you.
The default template is the following:
An up-to-date version can always be found at this link
Shop template is used when building the base message for a successful payment associated with a store. It may optionally include paid invoice products' templates.
The are two variables passed:
store
is the store the invoice is associated with
products
is a list of already rendered individual product's templates
You can use this template to provide some design for the order confirmation message sent to the buyer.
The default template is the following:
An up-to-date version can always be found at this link
Product template is used when building the message for each individual product. Normally it is included as part of the main store message sent to the customer upon successful payment.
There are 3 variables passed:
store
is the store the product is associated with
product
is the current product being processed
quantity
is the quantity the customer has selected to buy
Note that, you can configure different templates for each product, or use the same template for all products.
The default template is the following:
An up-to-date version can always be found at this link
The following document guides you through setting up Bitcart with Shopify.
Shopify account
Bitcart - self-hosted or run by a third-party host v0.6.7.0 or later.
In Shopify, go to Apps > and at the bottom of the page click on the Develop apps for your store
.
If prompted, click on Allow custom app development
Create an app
and name it
On the app page, in Overview
tab, click on the Configure Admin API scopes
In the filter admin access scopes type in Orders
In Orders
enable read_orders
and write_orders
and then click Save
Click on the Install App
in the top right corner and when pop-up window appears click Install
Reveal Admin API access token
and copy
it.
In your Bitcart, go to Stores page and click on shopify integration icon.
Enter your shop name
In secret key field paste the Admin API access token
In the api key field paste the API key
from Shopify.
In Shopify's Store Settings > Checkout > Order status page > Additional Scripts
paste the script provided by Bitcart in Shopify Integration dialog when you click the copy script button (including the opening and closing tag </script>
.
In Shopify's Store Settings > Payments > Manual payment methods
add manual payment method
then click create custom payment method
In Custom payment method name
fill in Bitcart
, optionally you can fill in other fields, but it's not required. Please see the message below about naming of a custom payment method
Hit Activate
and you've set up Shopify and Bitcart successfully.
WHMCS integration provides an easy way to use Bitcart as a payment gateway in your whmcs instance
This plugin requires the following:
WHMCS 7.x
Copy the archive on your server
Extract the archive to your whmcs root, so that in your whmcs root, in modules/gateways there is a file named bitcartcheckout.php
At whmcs panel, go to setup > payments > payment gateways
On the next screen, click on the All Payment Gateways tab and click on Bitcart Checkout to enable the plugin. The next step will be to configure it.
After you have enabled the Bitcart plugin, the configuration steps are:
This plugin also includes an IPN (Instant Payment Notification) endpoint that will update your WHMCS invoice status.
Initially the WHMCS invoice will be in a Unpaid status when it is initially created.
After the invoice is paid by the user, it will change to a Payment Pending status.
When Bitcart finalizes the transaction, it will change to a Paid status, and your order will be safe to ship, allow access to downloadable products, etc.
Your store POS is a ready-to-use store, which you can use in online or physical stores.
It is enabled by default in the full docker deployment.
Categories are built from all of the selected product's categories, plus the all
category to show all products
The Contact Us text shows the store's email. It is configured in the email settings of the store
At the header, store name is displayed.
Before checkout, customer will be able to enter their email, and optionally, a promocode.
Bitcart supports automatic conversion from fiat currencies to payment method's currency upon invoice creation.
It is done via cached pre-fetched exchange rates, got from configured provider.
The default fiat currency used for prices is USD.
The default exchange rate provider is CoinGecko, as it provides a big list of fiat currencies to select from, as well as the historical rates, plus it is free of charge and has generous limits.
Bitcart's default exchange rate is the same as Electrum's one.
All the exchange rate providers available in Electrum are also available in Bitcart.
To change fiat currency used in your store, change it's default currency field:
You can override invoice default currency when creating it:
Currently, you can configure the exchange rate provider only via an environment variable passed to the daemon, and it is not accessible in the docker deployment. We want to improve that in the future.
Set the COIN_FIAT_EXCHANGE
variable to the name of exchange you want to use, like so:
Bitcart supports Tor as an additional service. When enabling it, all the services (admin, merchants API, store) will also be available as Tor hidden services.
When enabling Tor hidden services, nginx will automatically be configured to serve requests from .onion domains. But if using a custom reverse proxy or just not the built-in nginx, ensure to set up server records for each hidden service. More information below.
Enabling Tor doesn't give absolute security. And if used incorrectly, it may even lead to bigger problems. It is very hard to make every component of Bitcart and it's dependencies use the onion network only, and we don't guarantee that.
When enabling tor, the components of Bitcart will be communicating via the onion URLs if accessed from the onion network too, and all the daemons will be connecting to the onion servers more often than regular ones.
So, Tor support is mostly to be used to access Bitcart components when running it at home, or behind a complex firewall.
To enable tor support, you will need to add additional component to the deployment.
Re-configure your instance like so:
Note, if you have already had some additional components enabled before, separate them with comma.
When enabled, the admin panel and store will have an onion icon.
Also, if opening any of the components in Tor browser, you will be automatically suggested to open the hidden service version of your site.
But if you need to get the hostname of some service without using the clearnet version of the site, you can run this command:
Where compose
is the name of your deployment, by default it is indeed compose
, and service
is the service name you want to check, where spaces are replaced with -
symbol.
Examples:
From the admin panel, you will also be able to check all the hidden services links for all services. Click on the services button to the right of the dashboard button.
Bitcart has a few server management settings available.
They are accessible only by the superusers.
Superusers are the users of the instance with admin privilege.
The first registered user is the super user, then they can add new ones from server management settings.
The server management settings don't leak the privacy of other users, super users can't view other users stores or wallets.
If you are the super user, you will be able to enter the settings by clicking on the profile icon->server management settings
From the user management page, you will be able to view all users registered on your instance, create new users or delete existing ones. Also, you can change a user's password and optionally make someone a superuser.
Note that, when editing user, it is not possible to view their existing password.
It is because, Bitcart is secure and doesn't store plain text passwords. Only hashed passwords are stored.
You can click on the switch to make someone a superuser or make someone a regular user instead.
IMPORTANT: do NOT switch your own user, it will make you loose the superuser rights. The only way to recover will be via the database. It will be disallowed in the future versions of admin panel to avoid confusion.
From the server logs page, you will be able to check server logs.
The logs are ordered by their date-the latest log displayed the first.
Logs are aggregated by day.
It is possible to delete logs (except for the today's log, as it is used by the instance).
You can also download the log, to send it for troubleshooting purposes for example.
From the maintenance commands page, you can execute common actions-upgrade your server or clean up it.
It will start the update process. During it your instance might be unavailable, and the page won't automatically reload after the update.
The update process will upgrade the cloned bitcart-docker
repository, upgrade the docker-compose generator image, generate new configuration file from saved settings (from .env
file), upgrade all the used docker images, recreate the modified containers and clean up the now unused images
It will start the restart process. During restart your instance might be unavailable. Use restart feature to fix some possible bugs, if you met some.
See more below
This process does the same as after upgrade-cleans up all unused bitcart images from previous upgrades
This command deletes all logs except for the currently used one.
The policies allow you to control some server-wide important settings.
If you check this on, users will not be able to register on your instance. Register link will be removed from the login page, register page will not be accessible and the API will discard any register attempts. Turn it off to enable registration back.
By enabling this setting, your instance will tell the search engines to stop indexing your site. It should disappear from search results. Note that it might not work with some search engines.
When enabled, your instance will check github for new Bitcart releases, and display a notification in the admin panel that a new update is available.
Enter the id of the store that will be displayed by the store POS. It will display this store's products and use this store's settings.
By default it is on. When enabled, users must enter their email on store POS to continue to checkout, otherwise they can continue without email.
This page is purely informational. You will see a list of connected daemons and some of their settings.
Running Bitcart instance:
Open and download the zip archive with the plugin
Enter your admin panel URL (for example, ) without slashes
Enter your merchants API URl (for example, ) without slashes
It is enabled in the frontend
or all
installation groups (see BITCART_INSTALL
setting at )
The store POS displays the information for the store configured by server admin. It can display one store at once. It is controlled from
The price slider will automatically adjust to the maximum price of the products in the store. The currency for all products in the store is determined by the of selected store
The Only Sale setting shows only products that have an active connected to them.
Tor icon is added if is enabled.
Store default currency is the one displayed in the , and the one used by default for invoice creation.
The cleanup process will do two actions: and .
By default it is on. When enabled, users can access https://admin.yourbitcart.ai/configurator
, and deploy their instance from there via the .
On the store policies page, you are able to configure some settings related to all the stores on the server or the
Bitcart supports multiple deployments on one server.
Note that it is an advanced topic, and use it only if you know what you are doing.
When setting up multiple deployments on the same server, the services that export their ports to outside can't be run twice.
It means that you will need to set up nginx reverse proxy manually, and disable nginx in each of the deployments.
When disabling nginx, all the services will expose ports to outside, to be able to use them from nginx installed globally on the server.
To run multiple deployments, pass the deployment name via --name
argument. The default deployment name is compose
.
Note that you should use different clones of the bitcart-docker
for each deployment, as the setup script creates .env
file with all your settings, and .deploy
file with configuration name, and if you run different deployments in the same directory the configuration files will be overwritten.
Do it like so:
To disable reverse proxy, run:
Note that when running multiple deployments, the Merchants API, the admin and the store will have the same ports. You need to change that.
To change ports, run export BITCART_SERVICE_PORT=port
Where SERVICE
is the component name, and port
is the port, for example:
You should configure nginx yourself. The only recommendation is: it is easy to configure nginx via certbot.
Instead of disabling nginx, you may also leave it running at different ports, see this guide.
Run:
And it will create nginx config records for you, and then edit the location /
config, by using proxy_pass http://localhost:port
Note: when using multiple deployments on one server, environment variables may be loaded incorrectly on login (due to same environment variable names).
To ensure that you have loaded the correct environment for your deployment, in your deployment directory, run:
It will load the correct settings.
Integrate Bitcart into your self-hosted FOSSBilling instance easily!
This version requires the following:
FOSSBilling instance
Running Bitcart instance: deployment guide
From your FOSSBilling panel, go to configuration > payment gateways -> New payment gateway
Upload Bitcart.php to the directory suggested by your deployment. Download it from this repository
Enable it by clicking on the button near Bitcart, fill in all settings and save.
After you have enabled the Bitcart plugin, the configuration steps are:
Enter your admin panel URL (for example, https://admin.bitcart.ai) without slashes. If deployed via configurator, you should use https://bitcart.yourdomain.com/admin
Enter your merchants API URL (for example, https://api.bitcart.ai) without slashes. If deployed via configurator, you should use https://bitcart.yourdomain.com/api
Enter your store ID (click on id field in Bitcart's admin panel to copy id)
Enjoy!
To install the woocommerce plugin for Bitcart, please follow the steps below
WordPress > Plugins > Add New.
In Search, type "Bitcart for WooCommerce"
Install and activate.
Download the latest plugin release, upload it in the .zip format to your wordpress instance and active it.
Refer to our deployment guide
Go to your store dashboard. WooCommerce > Settings > Payments. Click Bitcart.
Enter your Bitcart URL (URL of the Merchants API, like https://api.bitcart.ai)
Enter your Bitcart Admin Panel URL (for example, https://admin.bitcart.ai)
Change the store id used if needed
Save changes
Bitcart will only be visible on the WooCommerce checkout page if you are using the Classic Checkout. This is no longer the default option, so Bitcart will not appear as a payment method unless you activate it. For instructions on how to enable the Classic Checkout, please visit: WooCommerce.com - Reverting to the classic Cart and Checkout
If you have successfully configured your plugin, you will be able to checkout via cryptocurrency.
That's it!
Atomic Tip Bot is a bot which allows you to tip other users on telegram. It is a great example of Bitcart usage.
But also, users are able to withdraw their funds. It is also possible with the SDK, while this feature isn't available in many other payment processors, as Bitcart is not just a payment processor.
You can use add_request
SDK method to create a new invoice.
To process payments, we should register an event handler on our APIManager
to handle the new_payment
event, which is fired when a request was completed.
We can use manager.start_websocket()
to start listening for new events.
Templates are a powerful way to customize your store's checkout flow.
Here are some examples of ready templates.
Note: the templates contain a lot of boilerplate code to workaround different email clients rendering issues. All examples are self-contained and are ready to be used in production.
This template is just a simple example of how to use html in your templates for better design. This example utilizes a table with some custom styles to display bought items.
product.html
is the template that renders each individual product.
We use some of the available variables to show the product price, quantity selected, and final calculated price. store.default_currency
can be used to get product's currency.
And in shop.html
template (containing most of the design), we just use:
To include all products' rendered templates.
And we also use {{store.name}}
to display store name at the top.
Bitcart is a 100% free and open-source software. We do not charge you anything. However, to run it, you should host it. You can run it as a self-hosted solution on your own local server, or use a cloud hosting provider, which is what a majority of users do.
Hosting prices differ, but even a minimal server would suffice.
The system requirements depend on the components you have chosen, but a typical full installation (with all essential components enabled, and btc daemon):
1 GB RAM (if using 1 GB RAM, adding a bit of swap space is recommended, due to the OS using some resources too)
~= 10 GB disk (way less actually, but just to be sure)
Docker support by the OS (Ubuntu should work)
Note that, adding new coins typically don't increase the requirements a lot.
As of Bitcart 0.3.1.0 (March 8 2021), the system requirements to run Bitcart with all supported coins enabled are the same as the minimal requirements (maybe with a bit more swap space allocated).
After deployment, you need to register on your instance. The first registered user is the server admin.
So click on the register link, and create your admin account.
There are a few possible cases why this happens. But in almost all cases it is because it is having trouble connecting to the Merchants API.
If that's not what you want, unset those variables:
If that's what you want, then maybe the BITCART_ADMIN_URL
or BITCART_STORE_URL
is set to an incorrect value. Ensure that it starts with the protocol (http:// or https://), and that that URL is accessible.
If merchant API is not running, you can check it's logs for possible issues:
You need to run:
Tor for Bitcart is intended more as an improvement of the setup process, and allows for more flexibility for hosting on one's own device at home or in an office.
Having Tor activated would allow for simpler, plug-and-play usage of Bitcart, as it suppress the need for the following configuration steps:
Opening multiple ports on the firewall
Configuring the NAT for port redirection to your device on your local network
Setting up a DNS entry to get a HTTPS certificate
And any other difficulties you may face
While these steps are usually not a problem when Bitcart is hosted on a VPS, it can be difficult to solve for non-technical users on home or office networks.
Of course, you may use .local domain, but it will only be accessible from your local PC.
Tor just solves all these issues in one shot, all you have to do is plug your device on the local network. It is especially useful for POS application.
But if you're looking for perfect privacy and security, activating Tor with your Bitcart just won't do it.
Tor is a really tricky software to use for developers, as the slightest mistake can tear down the anonymity it provides. As Bitcart is evolving into a rather complex service and adding more and more plugins, even if we tried to route all this traffic through Tor, we couldn't guarantee that there would never be leaks of data in clear. There are many different requests we can't fully control or guarantee we control. When enabling Tor support, we do route the electrum and exchange rate requests through Tor, but that's the best we can do.
We think that the illusion of security is more dangerous that no security, or at least security we know is imperfect. So be aware that activating Tor doesn't prevent others to connect to your instance website, your bitcoin or lightning node in clear, it doesn't make you anonymous at all.
Bitcart is configured via environment variables.
You can always set some environment variable like so:
Running ./setup.sh
will apply new settings.
For example, let's say I want to deactivate Tor:
Similarly if you are adding a new component, the export command would instead look like this:
There is no such term as "testnet Bitcart". Bitcart is modular, and what you can do instead is, enable testnet on certain coins (daemons), but not on every one. So it is possible, let's say, to have bitcoin daemon running in mainnet, bitcoin cash in testnet, and litecoin in regtest.
To change the network of a coin, run:
Replace COIN
with the coin symbol (BTC, LTC, etc.), and network
with the actual network name (mainnet,testnet,regtest).
So, for example, to enable testnet on bitcoin, run:
Theoretically it's possible, but it is not recommended.
Due to the nature of electrum networking, it is possible. But if you receive a payment when Bitcart is offline, it will only be processed when Bitcart is back up.
Yes, it is possible.
The recommended way though is, to use the Merchants API, which handles many edge cases.
But if you need to connect to your daemon directly, you can either:
You can add a custom component to the deployment stack via the BITCART_ADDITIONAL_COMPONENTS
setting, and then, when running inside docker, you can always connect to daemons via their docker-compose name. For example, for bitcoin, the URL will be http://bitcoin:5000
.
Note: it is not recommended, as it might be a security risk! The daemon default credentials can be viewed from the source code, so you should either change them, or make sure daemon can not be accessed by anyone but your services.
For that, run:
The coin will now be accessible from the outside network.
The SSL certificates are automatically refreshed. But it something is not working, you can always restart your instance by running:
Yes you can! Just make sure to use the proper configuration.
Create an extra config file for your vhost in /etc/nginx/sites-available/bitcart
and create a symlink for this file at /etc/nginx/sites-enabled/bitcart
The contents of this vhost file should look like this:
Also, put the following in your main Nginx config file at /etc/nginx/nginx.conf
:
Now test your Nginx config with nginx -t
and reload the config with service nginx reload
.
Then, you need to make sure that Bitcart does not try to handle HTTPS on its side, you can do this by disabling it on your Bitcart instance.
Similar to the requirements for hosting a website, a web server is required for a Bitcart instance. While it is possible to run Bitcart locally on your PC, it would have to meet the minimal requirements and also run 24/7 if you don't want interruptions of service. You might also not want to expose your home IP address for the activity related to Bitcart payments. For all these reasons, while local hosting is suitable for testing, it's not a viable solution for production. A Virtual Private Server (VPS) is commonly used to address these problems.
But if you really need to do so, you have two options:
If the BITCART_HOST
variable ends with .local, then local mode will be activated. The setup script will automatically edit /etc/hosts. Note that, the reverse proxy must be set to nginx
, and not default nginx-https
.
The downside of this method is that it requires modifying /etc/hosts
, and that the instance will only be accessible from your own PC.
You can enable Tor support, and then your instance will be available from anywhere via .onion
domain.
Shutdown Bitcart with ./stop.sh
and cleanup the install with ./cleanup.sh
.
Delete all volumes in /var/lib/docker/volumes/
with:docker-compose -f compose/generated.yml down --v
Remove other Bitcart system files with: rm /etc/systemd/system/bitcart.service && rm /etc/profile.d/bitcart-env.sh
Remove your Bitcart installation folder with rm -r "$BITCART_BASE_DIRECTORY"
Just to make sure, run docker system prune
after a reboot to get rid of any other docker related artifacts.
First, you need to make sure that bitcart and docker is not running
Now, you need to format your drive. If you have already done it, you can skip this step.
The second lsblk
should show the drive you just plugged in. (of TYPE disk
) Make sure you don't make a mistake as the next command will erase all the data on this disk.
For the sake of this example, let's suppose it has the NAME /dev/sdd
.
Now we can partition the disk and format the partition:
Then we need to mount the partition on the linux filesystem.
Then, we need to make sure that docker won't start before the mount.
Now, imagine you want to transfer all the docker volume data to the new partition.
Now restart docker and bitcart
Note: We use mount bind instead of symbolic link because docker would complain when running docker volume rm
.
Since nginx gets the IP address in the request instead of raspberrypi.local it does not know where to route that request and returns:
You can fix this by forcing nginx to route the HTTP request to Bitcart even if the request domain name is not recognized. Simply, re-run the setup script like this:
Now putting local IP in the web-browser works.
To check, run:
Press "q" to quit out of less.
The output should contain:
jrcs/letsencrypt-nginx-proxy-companion
bitcart/bitcart
And the status should be "Up"
If the docker container is not running, then check the reason for crash like this:
Where compose-backend-1
is the container name that is having issues.
# Cause 4: Other
To get some funds to tip, user needs to deposit, which means generating an address and checking status of payment. We can use Bitcart for that.
See the full
See the full
If you are interested, read the full explanation at github or try the atomic tip bot yourself in
Please read the first.
As plain text templates are pretty simple, we show complex html examples. Ensure to enable .
They were generated by this and modified to be actual templates.
This document covers the most common questions, errors, and issues you may encounter prior and during the installation of the software. For a detailed list of deployment methods and instructions for each, please see .
Advanced users can run Bitcart on .
If you do not wish to host your own server, you can use a free .
Visit our for more information on the various ways in which you can run Bitcart.
Hosting your own instance might make it a bit harder to start using Bitcart, but it is worth it, to get a , with no third-party.
For a self-hosted solution, we recommend using our to easily deploy instances, without any technical skills required. You may also use the Lunanode Web deployment.
For just trying out, you can use our or a .
Please refer to page to view comparison of different deployment methods
Yes, the installation instructions almost don't differ. Refer to guide.
It might be possible that admin panel tries to access the merchants API via https:// URL, but there is no SSL certificate available yet, which causes SSL error. Just wait a bit, and usually the problem is resolved. If not, try .
When using , it should always work. But if you have accidentally set any of BITCART_ADMIN_HOST
, BITCART_ADMIN_URL
, BITCART_STORE_HOST
, BITCART_STORE_URL
, then one domain mode is disabled.
If some error is unexpected, please .
Refer to the for more details.
See this .
If you need to figure out which environment variable you need to modify, have a look at .
Check the list of URLs to connect to .
It is way easier to use built-in reverse proxy, but in cases when you are running , it is required.
Notice: If your Bitcart install has more than one domain (for example, when is off) you will need to modify your config for each domain name. The example above only covers 1 domain name called bitcart.domain.com
.
See the for more details.
See this .
Your nginx config is set to route the HTTP request to a particular container based on the domain name of the request. For example, the official said to setup the source domain name to http://raspberrypi.local/ yet getting automatic local domain raspberrypi.local does not always work. You are probably in this situation and trying to type the IP address of your Bitcart into the web-browser.
There could be many causes for 5XX HTTP errors. Please create an and when cause becomes known add it here in the doc.
An xpub is a key, which can provide a read-only access to your wallet. It can only be used to watch transactions in your wallet, but not to send them on your behalf. In general, using xpub in some software is safer than using your seed or xprv, but it can leak your privacy if you share your xpub publicly (watching your wallet).
Bitcart provides a variety of ways to integrate into your application.
Do you need something completely custom, like atomic tip bot?
Then you can use our SDK
It is a python library simplifying the usage of our core daemons (refer to Architecture page for more information). If you are coding in python, you have the best development experience ever, as SDK supports everything daemon supports.
If coding in another language, you can either create a similar library for your language, or use the daemon directly.
The daemon follows the JSON-RPC 2.0 specification, with two extensions:
Arguments may be passed either by position, or by name, or by position AND by name (in that case, args are a list, the last element of which is a dictionary containing by-name arguments)
Xpub, if needed, is passed as part of the by-name argument
The Merchants API is used to simplify the usage of multiple daemons at once and suits the best for the case when you need to receive payments.
To create an invoice, just send a POST request to /invoices
.
You can pass many arguments, but the only required ones are price
and store_id
.
Check out the swagger documentation for more information.
To easily integrate a ready checkout page in your website, you may use a script that comes with your admin panel. You can create the invoice, and use that script to show a checkout modal on your page.
Example of usage to add the modal to your website:
Include the bitcart.js
script in your html page
Call the invoice API to generate an invoice (example code). This is sample backend code as it contains an auth token that should not be exposed in your front-end.
Use the invoiceId
to pop up the modal
You'll often want to do something like refresh the state of your page when the invoice is paid, or note some kind of state before the modal pops up. You can attach event listeners like this:
Facing a problem is never fun. This document explains the most common workflow and steps you should take to identify the issue you're having more easily and hopefully solve it yourself or with community help.
Identifying the problem is crucial.
First and foremost, try to determine when the issue happens. Try to replicate the problem. Try to update and restart your server to verify you can reproduce your issue. If you think it will describe your issue better, take a screenshot.
Check your version of Bitcart. If it is much older than the latest version, updating your server may resolve the issue.
Restarting your server is an easy way to solve many of the most common Bitcart issues. You may need to SSH into your server to restart it.
Some issues you may only need to restart a particular service in your deployment. Such as restarting the lets encrypt container to renew the SSL certificate.
Use docker ps
to find the name of a different service you would like to restart.
Logs can provide an essential piece of information. In the next few paragraphs, we will describe how to get the log information for various parts of Bitcart.
You can easily access Bitcart logs from the front-end. If you are a server admin, go to Server Management > Server logs (guide) and open the logs file. If you don't know what a particular error in the logs means, make sure to mention it when troubleshooting.
If you would like more detailed logs and you're using a Docker deployment, you can view logs of specific Docker containers using the command line.
Use docker ps
to get the name of container you need. Usually it is the docker component name with deployment name prepended to it.
Run the commands below to print logs by container name. Replace the container name to view other container logs.
Even though setups differ, the chances that someone else experienced the same issue as yours are pretty high. Take a few moments, Google around and see if you can solve it yourself.
We try to document the most common issues on the Frequently Asked Questions page. Take a look there and see if your question is recorded.
When there's an advanced technical issue, users usually open an issue on GitHub. Take a look at the Bitcart GitHub repository and browse search the closed issues
Our Telegram group is great for similar issues, other users experienced before you. Search messages for your question
If you're unable to solve the problem yourself, do not worry. There's an amid community ready to help you.
The better you describe the problem, the higher are the chances of getting a timely fix. Be concise and provide as much relevant information as possible. Be sure to include the version you're using and describe your deployment setup. Try to explain what you're trying to do and what's the issue. If you can provide the logs. If you think it's relevant, feel free to include a screenshot.
Here's a good example of how to ask a question.
I'm having a problem with XYZ. I can replicate the problem. My Bitcart version is A.B.C.D, and I deployed my server on Digital Ocean by following Docker deployment guide. I've searched through the FAQ and closed GitHub issues, but there's no solution to my problem. My Bitcart Setup is XYZ, and the issue is occurring when I do XYZ. Here are the logs I was able to get from my Bitcart instance. You can see the error in the image I attached.
WARNING
The community will not provide extensive support for custom deployments. I.e. Variations of Manual Deployments are expected to be used only for development purposes and by users with technical literacy with the ability to resolve deployment and maintenance issues on their own.
For quick answers to fundamental problems, it's best to post a question in one of our communities.
If you have a custom build setup and are facing a complex problem, open an issue on GitHub so that developers can help you out.
Some community members provide paid support. If you want a quicker help, check out the list of members providing premium support.
Bitcart is built and maintained entirely by volunteer contributors around the internet. We welcome and appreciate new contributions.
If you're a developer looking to help, but you're not sure where to begin, check the good first issue label, which contains small pieces of work that have been specifically flagged as being friendly to new contributors.
Contributors looking to do something a bit more challenging, before opening a pull request, please create an issue or join our community chat to get early feedback, discuss best ways to tackle the problem and to ensure there is no work duplication.
You can help Bitcart even if you're not a developer.
The easiest way is to use the software as a business or individual, provide feedback and report any bugs or issues you or your customers encounter.
Translating Bitcart, helping us with documentation, making videos, writing articles and spreading the word are ways in which you can help, even if you're not a developer or tech-savvy.
We need more VPS hosting providers to implement 1-Click Bitcart deployment and make the installation of software more accessible, decentralized and widely-available.
We are actively looking for developers who can take on and resolve GitHub issues and help with development. If you would like to help us, but need some guidance, our community chat is the place to ask questions. Also, take a look at our contributing guidelines.
This project is open source, and is not a company. Instead we rely on a network of contributors and users to provide support.
Problem? Don't worry, someone else has probably been through that before you.
First have a look at our user documentation and Frequently Asked Questions.
If your issue is not referenced there, or you want to request a new feature, please open a github issue.
If you have more general questions about Bitcart, the way it works and why you should use it, you're welcome on our Telegram
Getting a proper support also depends on how you formulate your questions. Read our troubleshooting guidelines.
Do you have some complex project where you want to integrate Bitcart and not sure how to do it? Do you need to add some custom feature to Bitcart just for your project and you want professional help?
Some of our team members can assist you with paid support:
The author of Bitcart, he knows everything about the project. Able to customize any part of the project in any way to provide support.
Skills: Python (experience in various backend frameworks), Vue (Nuxt.js, UI frameworks Bulma (Buefy) and Vuetify), Docker (and docker-compose, building various stacks and building docker-compose generators), Bash (custom scripts), Git and more
You can find him in Bitcart Telegram or just in telegram at username @MrNaif_bel.
Integrate Bitcart into Odoo and bridge your company's management system with Bitcart as a way to process payments!
This version requires the following:
Your Odoo instance
Running Bitcart instance: deployment guide
Add payment_bitcart
directory to your addons directory (You can take the latest release, unzip it and get payment_bitcart
from there)
From your Odoo apps page, activate "Bitcart Payments" app
Configure the plugin (see details below)
After you have enabled the Bitcart plugin, the configuration steps are:
Enter your admin panel URL (for example, https://admin.bitcart.ai) without slashes. If deployed via configurator, you should use https://bitcart.yourdomain.com/admin
Enter your merchants API URL (for example, https://api.bitcart.ai) without slashes. If deployed via configurator, you should use https://bitcart.yourdomain.com/api
Enter your store ID (click on id field in Bitcart's admin panel to copy id)
Enjoy!
Underpaid percentage is a store checkout setting, which can be in range from 0 to 99, indicating that the payment may be that percent less than expected, and it will still be accepted as paid. For example, if customer sends from an exchange wallet and the fees are deducted from the sent amount, the payment will still be accepted if you set underpaid percentage to a small non-zero value.
When enabling this store checkout setting, the checkout page will always be served in dark mode. Ensure to check that your logo is suitable for dark mode.
To keep consistent branding, you can change the default Bitcart logo to your own logo. For that, it must be accessible via the URL provided. Note that, no matter what resolution the image is, it will be fit into maximum height of 40.
Show recommended fee setting enables showing recommended fee for all onchain (i.e. not lightning) payment methods.
To configure it, you need to set the recommended fee confirmation target blocks setting, which configures the fee displayed. If you set it to 2, it would mean it will show the recommended fee for the customer to pay for his payment to be confirmed in 2 blocks. Default value is 1.
By default Bitcart uses currency symbol as method name, and if there are multiple wallets of the same currency connected it adds an index to it (BTC(1), BTC(2)).
In some cases you may want to have a custom label for your payment methods, for example to indicate if some payment method is for legacy payments, and another is for segwit payments.
To do that, just add a label to your wallet:
Any wallet (payment method) may have a hint which will be displayed on checkout page. First of all, the default Bitcart hints are displayed (recommended fee unless disabled, and about sending exact amounts in eth). Your custom hint will be displayed below.
Usually when you have multiple wallets of same currency (currency+contract pair) connected, it would be displayed like BTC (1)
, BTC (2)
or with a custom label. But it is now possible to randomize wallet used. This is useful to either distribute funds across multiple wallets for even better privacy, or in case of ETH to improve UX of checkouts page. You will no longer see each method, but only one, selected randomly.
That's because, for store POS and custom integrations from different sites to work, it can't get an authorization token in a way which is not seen to the user. Currently all integrations work same way.
But it is possible to make authorization mandatory on a per-store basis in store settings:
Please note that, when disallowing anonymous invoice creation, all plugins and store POS will break. Use this only if you have a custom integration where you are able to create invoices server-side only for authorized users only (otherwise, it is working same way as Bitcart works, but with another unnecessary layer of complexity added)
Bitcoin (and the original electrum) is the primary focus of the developers. When developing, we usually test two currencies just to check that multicurrency checkout works, but we don't check every coin frequently. Each coin's communities should maintain their coins.
As Bitcart is made with extensibility in mind, it's usually not a hard process, but it depends on the coin you are adding
It all depends on whether there is an electrum fork for that coin
If so, the process is easy. If that electrum fork is maintained, usually the process is the following:
Add the coin to our docker deployment:
As Bitcart consists of many components, each component has it's individual installation instructions.
Our central repository contains the list of most of the repositories where you can contribute:
We recommend using Visual Studio Code, as our project has many programming languages involved, and VS Code fits the best, but you are free to use whatever editor you like.
This project is nothing without its community!
Join us:
Bitcart is a complex project, and this page contains a detailed description of Bitcart structure.
Check the diagram, it shows that Bitcart is modular, as it consists of many independent components. The only required component is Bitcart Core, everything else is optional.
Bitcart core are essentially the Bitcart daemons for different currencies.
Bitcart daemon is just a wrapper around electrum wallet, extending existing daemon functionality and providing more methods, wallet loading on the fly (by passing xpub as part of the JSON-RPC request), better events delivery (supports polling, websocket) and a specification for better exceptions to improve development time.
So, all the networking and essential crypto parts are managed by electrum, which is battle-tested.
How does the networking work and why is it so light?
It's because electrum is an SPV (Simple Payment Verification) wallet, connecting to multiple public servers and verifying them, selecting only the valid ones. That way it is still secure but also lightweight.
If you want to add Merchants API, it will also add in PostgreSQL for data storage, and Redis for cache and inter-process communication, plus the background worker to process background tasks (check for updates, check hidden service availability) and to check invoices' payments.
The background worker estabilishes a websocket connection to the daemon, one for each currency enabled.
Upon successful payment, electrum networking and wallet functionality detects that payment request was paid, and fires an event. Our daemon is configured to preprocess the event (to get maximum possible data), and to send it to configured sources. In this case, new event data is sent via websocket.
Websocket data is received by the worker via Bitcart SDK, and a corresponding event handler is called.
The worker finds a payment method and an invoice related to that payment method having the address sent, and it marks the invoice as complete. When marking invoice as complete, multiple actions are done:
Paid currency is set
Email message is built by configured templates and is sent to the customer, if email server is configured and there was buyer email specified
All connected notification providers are used to notify the merchant
And other tasks to be added in the future, like executing custom scripts
In case of a temporary connection failure, on successful re-connect to websocket, the worker will fetch and check pending invoices to process missed events.
Background tasks are ran periodically by the worker, like, checking updates once a day, refreshing hidden services every 15 minutes, etc.
The Merchants API provides an easy way of managing common data in store-like applications, so you don't need to re-create it all from scratch. But you are free to use just the daemons with the SDK.
Optionally, you may also add the admin panel. It is a convenience UI built around the Merchants API, so it requires Merchants API to be enabled if using local one.
It provides ultimate editing features, and is very powerful as it's built in material design.
Optionally, you may also add our ready store (POS).
It also depends on the Merchants API, and it is a lightweight UI to accept payments in an online store without need in developing a custom store. It has it's own checkout page and is independent of the admin panel
Tor support is optional, but if you enable it, all the services (merchants API, admin, store) will also be accessible via the onion network.
Nginx is serving all the incoming requests, from multiple configured domains, and is forwarding traffic to different components of the ecosystem. It is essential for production setup.
Optionally, you may enable ssl support via let's encrypt. It works via a small docker container, automatically refreshing your certificates once in a while
Please do not announce of the vulnerability publicly until the fix is released. Thank you.
The following keys may be used to communicate sensitive information to developers:
You can import a key by running the following command with that individual’s fingerprint: gpg --recv-keys "<fingerprint>"
Ensure that you put quotes around fingerprints containing spaces.
After the initial reply to your report, you will be informed of the progress towards a fix and full announcement. You may be asked to provide additional information or guidance.
We appreciate your efforts to responsibly disclose your findings, and will make every effort to acknowledge your contributions.
For more information, checkout the page.
Add new daemon file, daemons/coin.py
, in the main bitcart
repository, where coin
is your coin's code. Copy the code from the daemons/btc.py
file and edit some metadata. Note that the default port for the coin must be in 5XXX range, and that you should increment it by one with each added coin. So find the latest port used, and use the next port number available. Check this for an example, but make sure to check the most up-to-date files.
Add a requirements file (requirements/daemons/coin.txt
), and pin electrum of that coin to some specific release. See this
Add the coin's decimal formatting settings, edit the api/ext/moneyformat/currencies.json
and add settings related to your currency. See the example crypto settings at the bottom of that file.
Add the coin to our SDK. Create a file bitcart/coins/coin.py
, and edit some metadata. See this .
Create a docker file for that coin (base on the btc one), a docker-compose component and edit the setup scripts. See this . Ensure to add COIN_HOST=component
line to this , where COIN
is the coin symbol, and component
is the name of the docker-compose component you have created
That's where things get a little bit more complex. You have two ways: either fork the electrum yourself and make it work for your coin, or, if your coin is completely different from btc-like coins, try to create an electrum-compatible daemon. If you do it correctly, you just need to implement the daemons/coin.py
file in a completely custom way, plus make sure to have all the daemons dependencies in the requirements file, but otherwise, the process is the same as when for that coin.
Please follow our main , and the guidelines specific to the repository you are contributing to.
The admin panel also provides a universal checkout page, and a script which can be used to launch on any site
Check for more information
To report security issues send an email to .
Name
Fingerprint
MrNaif2018
AB22 4F6F 2ED1 1812 47E7 1D83 5CDE 5043 6C3D B40C