Q-Sandbox is a developer-focused repository designed to help you explore and experiment with various qortalRequests for Qortal. This sandbox environment allows you to become familiar with the Qortal API, providing a practical space to test and understand its capabilities.
- Test a wide range of
qortalRequests. - Experiment in a controlled environment without needing to build your own Q-App.
- Learn the Qortal API in a hands-on way.
- Build confidence and skills for developing on the Qortal ecosystem.
-
Clone the Repository:
git clone https://github.com/JustinReact/q-sandbox.git cd q-sandbox -
Install Dependencies: Ensure you have all necessary dependencies installed:
npm install
-
Run the Sandbox: Start the sandbox environment:
npm run dev
-
Access the Qortal API: Open the project in your preferred editor, and explore preconfigured API requests in the
src/qortalRequestsdirectory.
- Navigate to the
App.jsxfile to find examples of different API requests. - Customize these requests to fit your use case or create new ones to explore the full power of the Qortal API.
- View responses and debug in real time using the Chrome dev console or Qortal Hub console.
- Qortal Node: A running Qortal node is required for API requests to work, unless you are using a gateway node.
Here are a few examples of what you can do in Q-Sandbox:
-
Fetch user account details:
let account = await qortalRequest({ action: "GET_USER_ACCOUNT", });
-
Join a group:
const response = await qortalRequest({ action: "JOIN_GROUP", groupId: groupId, });
-
Send QORT coin:
const response = await qortalRequest({ action: "SEND_COIN", coin: "QORT", destinationAddress: destinationAddress, amount: amount, // 1 LTC fee: 20, // 0.00000020 LTC per byte });
Contributions are welcome! If you have ideas for improving the sandbox or additional qortalRequests you'd like to see, feel free to open an issue or submit a pull request.
This repository is open-source.