1
0
mirror of https://github.com/bigchaindb/site.git synced 2024-11-28 23:06:20 +01:00
site/_src/_guide/_setup.md

43 lines
1005 B
Markdown
Raw Normal View History

# Setup
2018-08-29 12:52:10 +02:00
Start by installing the official BigchainDB [JavaScript driver](https://github.com/bigchaindb/js-bigchaindb-driver), [Python driver](https://github.com/bigchaindb/bigchaindb-driver) or [Java driver](https://github.com/bigchaindb/java-bigchaindb-driver):
```bash
2018-08-29 12:52:10 +02:00
# JavaScript driver
npm i bigchaindb-driver
```
2018-08-29 12:43:10 +02:00
```bash
2018-08-29 12:52:10 +02:00
# Python driver
2018-08-29 12:43:10 +02:00
pip install -U bigchaindb-driver
```
2018-08-29 12:52:10 +02:00
```xml
<!-- Java driver, in pom.xml for Maven users -->
<dependency>
<groupId>com.bigchaindb</groupId>
<artifactId>bigchaindb-driver</artifactId>
<version>1.0</version>
</dependency>
```
Then, include that as a module and connect to any BigchainDB node.
```js
const BigchainDB = require('bigchaindb-driver')
const API_PATH = '{{ site.bigchaindb_api_url }}/api/v1/'
const conn = new BigchainDB.Connection(API_PATH)
```
2018-08-29 12:43:10 +02:00
```python
from bigchaindb_driver import BigchainDB
conn = BigchainDB('{{ site.bigchaindb_api_url }}')
2018-08-29 12:52:10 +02:00
```
```java
BigchainDbConfigBuilder
.baseUrl("{{ site.bigchaindb_api_url }}/").setup();
2018-08-29 12:43:10 +02:00
```