Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/boostryjp/ibet-prime
Advanced API Toolkit for Digital Securities Issuance and Management on the ibet Network 🚀
https://github.com/boostryjp/ibet-prime
fastapi ibet pydantic python web3py
Last synced: 14 days ago
JSON representation
Advanced API Toolkit for Digital Securities Issuance and Management on the ibet Network 🚀
- Host: GitHub
- URL: https://github.com/boostryjp/ibet-prime
- Owner: BoostryJP
- License: apache-2.0
- Created: 2020-11-30T05:02:23.000Z (about 4 years ago)
- Default Branch: dev-25.3
- Last Pushed: 2025-01-06T10:54:29.000Z (21 days ago)
- Last Synced: 2025-01-06T17:07:26.529Z (21 days ago)
- Topics: fastapi, ibet, pydantic, python, web3py
- Language: Python
- Homepage: https://ibet.jp/ibet-for-fin
- Size: 6.24 MB
- Stars: 11
- Watchers: 8
- Forks: 1
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# ibet-Prime
English | [日本語](./README_JA.md)
**The ibet-Prime security token management system for ibet network.**
## Features
- ibet-Prime is an API service that enables the issuance and management of security tokens on the [ibet network](https://github.com/BoostryJP/ibet-Network).
- It supports tokens and various smart contracts developed by the [ibet-SmartContract](https://github.com/BoostryJP/ibet-SmartContract) project.
- As a security token ledger management system, ibet-Prime provides a variety of functions required under Japanese regulations.
- By integrating the ibet-Prime API into your front-end application, you can easily build a security token management service.## Dependencies
- [Python3](https://www.python.org/downloads/release/python-3811/) - version 3.12
- [PostgreSQL](https://www.postgresql.org/) - version 16
- [GoQuorum](https://github.com/ConsenSys/quorum)
- We support the official GoQuorum node of [ibet-Network](https://github.com/BoostryJP/ibet-Network).
- We use [hardhat network](https://hardhat.org/hardhat-network/) for local development and unit testing, and we use the latest version.## Supported ibet smart contract version
* ibet-SmartContract: Supports the latest version of contract specifications.
* See [details](./contracts/contract_version.md).## Setup
### Prerequisites
- A Python runtime environment must be set up.
- The database must be created on PostgreSQL beforehand.
- By default, the following settings are required:
- User: issuerapi
- Password: issuerapipass
- Database: issuerapidb
- Test database: issuerapidb_test
- The TokenList and E2EMessaging contracts from the ibet-SmartContract project must be deployed in advance.### Install packages
Create virtual environment with:
```bash
$ uv venv
```Install python packages with:
```bash
$ uv sync --frozen --no-install-project --no-dev --all-extras
```### Install pre-commit hook
```bash
$ uv run pre-commit install
```### Install hardhat
```bash
$ npm install
```### Setting environment variables
The main environment variables are as follows.
Variable Name
Required
Details
Example
DATABASE_URL
False
Database URL
postgresql+psycopg://issuerapi:issuerapipass@localhost:5432/issuerapidb
TEST_DATABASE_URL
False
Test database URL
postgresql+psycopg://issuerapi:issuerapipass@localhost:5432/issuerapidb
DATABASE_SCHEMA
False
Database schema
WEB3_HTTP_PROVIDER
False
Web3 provider
http://localhost:8545
CHAIN_ID
False
Blockchain network ID
1010032
TOKEN_LIST_CONTRACT_ADDRESS
True
TokenList contract address
0x0000000000000000000000000000000000000000
E2E_MESSAGING_CONTRACT_ADDRESS
True
E2EMessaging contract address
0x0000000000000000000000000000000000000000
BC_EXPLORER_ENABLED
False
Whether to use the BC Explorer
0(not use) / 1(use)
TZ
False
Timezone
Asia/Tokyo
Other environment variables that can be set can be found in `config.py`.
### DB migrations
See [migrations/README.md](migrations/README.md).
## Starting the Server
You can start the API server with:
```bash
$ ./run.sh server (Press CTRL+C to quit)
```Open your browser at [http://0.0.0.0:5000](http://0.0.0.0:5000).
You will see the JSON response as:
```json
{"server":"ibet-Prime"}
```### API docs
#### Swagger UI
Now go to [http://0.0.0.0:5000/docs](http://0.0.0.0:5000/docs).
You will see the automatic interactive API documentation provided by Swagger UI:
![swagger](https://user-images.githubusercontent.com/963333/146362141-da0fc0d2-1518-4041-a274-be2b743966a1.png)
#### ReDoc
And now, go to [http://0.0.0.0:5000/redoc](http://0.0.0.0:5000/redoc).
You will see the alternative automatic documentation provided by ReDoc:
![redoc](https://user-images.githubusercontent.com/963333/146362775-c1ec56fa-f0b0-48a4-8926-75c2b7159c90.png)
## Branching model
This repository is version controlled using the following flow.
![branching_model](https://user-images.githubusercontent.com/963333/153910560-2c67f8ad-73ae-4aaa-9e9f-9242643f6098.png)
## License
ibet-Prime is licensed under the Apache License, Version 2.0.
## Contact information
We are committed to open-sourcing our work to support your use cases.
We want to know how you use this library and what problems it helps you to solve.
We have two communication channels for you to contact us:* A [public discussion group](https://github.com/BoostryJP/ibet-Prime/discussions)
where we will also share our preliminary roadmap, updates, events, and more.* A private email alias at
[[email protected]](mailto:[email protected])
where you can reach out to us directly about your use cases and what more we can
do to help and improve the library.
Please refrain from sending any sensitive or confidential information.
If you wish to delete a message you've previously sent, please contact us.## Sponsors
[BOOSTRY Co., Ltd.](https://boostry.co.jp/)