For wholesalers
A grosir (wholesaler) sells to many warungs at once. On Koelakan the warungs pool their demand into one round, and you win it by bidding the lowest price. One round, one big order, one delivery run.
How a grosir wins a round
- Sealed bid
- You submit a hash of your unit price, so nobody sees it until the reveal phase. The lowest valid revealed price wins the whole round.
- 5% bond
- With the commit you lock a bond of 5% of the round's maximum value in tIDR. It protects buyers from bidders that vanish.
- Forfeited if not revealed
- Skip the reveal and the bond is split among the buying warungs. There is no way to withdraw a bid quietly.
- Paid on delivery
- Buyers' payments sit in escrow. Each one is released when that owner confirms delivery, or automatically when the delivery window ends without a dispute.
Grosir agents running now
These are the service's own test grosirs. Their costs are assumptions (0.85 to 0.97 times HET, the government ceiling price), not real wholesale prices. A real grosir would set its own costs in pricing.json.
Run your own grosir agent
Create a testnet account and get tIDR.
Fund it with a little NEAR for gas, then call the tIDR faucet for the bond. Keep tIDR in the wallet, not in the market balance.
Write your price list.
costis your cost per unit in tIDR;margin_bpsis your margin in basis points (500 = 5%). Your bid is cost plus margin, and the agent never bids above a round's maximum price.{ "beras-medium": { "cost": 12000, "margin_bps": 500 }, "gula-pasir": { "cost": 15500, "margin_bps": 400 } }Start the agent.
git clone https://github.com/amantajatii/koelakan && cd koelakan/agents pnpm install export ACCOUNT_ID=your-grosir.testnet export PRIVATE_KEY=ed25519:... # full-access key of that account export PRICING_FILE=./pricing.json pnpm grosirOr with Docker:
git clone https://github.com/amantajatii/koelakan && cd koelakan docker build -f agents/deploy/Dockerfile -t koelakan-agent . docker run -d --name my-grosir --restart unless-stopped \ -e ACCOUNT_ID=your-grosir.testnet \ -e PRIVATE_KEY=ed25519:... \ -e PRICING_FILE=/pricing/pricing.json \ -v "$PWD/pricing.json:/pricing/pricing.json:ro" \ -v my-grosir-data:/data \ koelakan-agent node dist/agents/src/cli/grosir.jsWatch it work.
The agent commits and reveals on every open round for items you priced. Follow rounds on the rounds page, and withdraw your earnings from the market balance once buyers confirm delivery.
Full options (MIN_BID, MAX_BOND, salts, keys) are in agents/README.md, section "Run your own grosir agent".