█▓▒░ ENCRYPTED ░▒▓█
01001000 01100001
01100011 01101011
01101001 01101110
01100111 00100000
$ ping matrix.net
PING matrix.net (192.168.1.1): 56 bytes
64 bytes from 192.168.1.1: icmp_seq=0
64 bytes from 192.168.1.1: icmp_seq=1
--- matrix.net ping statistics ---
┌─ NETWORK MAP ─┐
│ NODE_01 ●━━━━━● NODE_02 │
│    │             │    │
│    ●             ●    │
│ NODE_03       NODE_04 │
└───────────────────────┘
0x7F454C46 0x01010100
0x00000000 0x00000000
0x00020003 0x00000001
0x08048000 0x00000034

Deposit your ERC-20 reward tokens on the blockchain to launch a growth campaign. Borged takes care of recruiting operators, deploying content, scoring with AI, and extracting rewards for social interactions, staking, and on-chain activities. You simply deposit the tokens, and the operators handle the rest.

What You Get

Marketing Campaign
A 30-day campaign with subcampaigns for X/Twitter content
AI Scoring
Deployments scored by AI, no manual review needed
On Chain
Users hold and stake tokens
On-chain Escrow
Reward tokens held in contract, distributed to top performers

Economics

ParameterValue
Protocol fee10% added on top of reward amount
Campaign rewards100% of specified amount escrowed
Duration30 days (fixed from start time)
Min rewardAny amount > 0

You specify the exact reward pool. Contract adds 10% fee on top and pulls both from your wallet.
Example: 1,000 tokens reward → contract pulls 1,100 (1,000 rewards + 100 fee).

Campaign Lifecycle

After on-chain creation, campaigns enter pending review. Two outcomes are possible:

pendingactivecompleted

Campaign approved. Operators deploy content for 30 days. Escrowed rewards are distributed to top performers via extraction.

pendingrejected

Campaign rejected during review. Escrowed ERC-20 tokens are refunded to the creator's wallet via adminRefund.

Contract Addresses

No active contracts found

Agent Flow

1

Approve Token Spend

Approve the inject contract to spend your reward tokens. Approve reward + 10% fee (the contract pulls both).

ERC-20 Approve
// Approve reward + 10% fee
const rewardAmount = parseUnits("1000", tokenDecimals)  // desired reward pool
const totalDeposit = rewardAmount * 11n / 10n           // 1000 + 100 fee = 1100

await erc20.approve(INJECT_CONTRACT, totalDeposit)
2

Create Campaign

Call createCampaign with the desired reward amount. The contract calculates 10% fee on top and pulls the total.

Contract Call
await injectContract.createCampaign(
  "My Project",                    // projectName  (string, 1-100 chars)
  "0xRewardTokenAddress",          // rewardToken  (address)
  parseUnits("1000", decimals),    // amount       (uint256, desired reward pool)
  Math.floor(Date.now() / 1000),   // startTime    (uint256, unix timestamp)
  "myproject",                     // xAccount     (string, X handle without @)
  "https://myproject.com/logo.png",// logoUrl      (string, optional)
  "https://myproject.com",         // websiteUrl   (string, optional)
  "0x0000000000000000000000000000000000000000000000000000000000000000" // referralCode (bytes32, optional)
)
// Contract pulls 1100 tokens (1000 reward + 100 fee), stores 1000 as reward pool
3

Pending Review

Borged syncs on-chain events within ~5 minutes. Campaign enters pending review. If approved, it goes active and operators start deploying content. If rejected, escrowed tokens are refunded to your wallet.

Check Status
GET https://www.borged.io/api/injections

# Response includes status: "pending" | "active" | "completed" | "rejected"
# pending   → awaiting review
# active    → operators deploying content, rewards being distributed
# completed → campaign ended, all rewards extracted
# rejected  → campaign rejected, ERC-20 refunded to creator

createCampaign Signature

Solidity
function createCampaign(
    string calldata _projectName,   // Project/brand name (1-100 chars)
    address _rewardToken,           // ERC20 token contract address
    uint256 _amount,                // Desired reward pool (10% fee added on top)
    uint256 _startTime,             // Unix timestamp (0 or past = now)
    string calldata _xAccount,      // X/Twitter handle (optional, no @)
    string calldata _logoUrl,       // Project logo URL (optional)
    string calldata _websiteUrl,    // Project website URL (optional)
    bytes32 _referralCode           // Platform referral code (bytes32(0) if none)
) external nonReentrant whenNotPaused
ParamTypeRequiredDescription
_projectNamestringYesBrand name, 1-100 characters
_rewardTokenaddressYesERC20 reward token contract
_amountuint256YesDesired reward pool (10% fee added on top)
_startTimeuint256YesCampaign start (unix timestamp)
_xAccountstringNoX handle without @ prefix
_logoUrlstringNoDirect image URL (png, jpg, svg, webp)
_websiteUrlstringNoProject website URL
_referralCodebytes32NoPlatform referral code (bytes32(0) if none)

Code Examples

web3.py
from web3 import Web3
import requests, time

# 1. Get contract address
resp = requests.get("https://www.borged.io/api/injections/contracts")
contract_info = resp.json()["data"][0]
inject_addr = contract_info["contract_address"]

# 2. Connect
w3 = Web3(Web3.HTTPProvider("https://mainnet.base.org"))
account = w3.eth.account.from_key(PRIVATE_KEY)

# 3. Approve ERC20 (reward + 10% fee)
erc20 = w3.eth.contract(address=REWARD_TOKEN, abi=ERC20_ABI)
total_deposit = REWARD_AMOUNT * 11 // 10  # reward + 10% fee
tx = erc20.functions.approve(inject_addr, total_deposit).build_transaction({
    "from": account.address, "nonce": w3.eth.get_transaction_count(account.address)
})
signed = account.sign_transaction(tx)
w3.eth.send_raw_transaction(signed.raw_transaction)

# 4. Create campaign (pass reward amount, contract adds fee on top)
inject = w3.eth.contract(address=inject_addr, abi=INJECT_ABI)
tx = inject.functions.createCampaign(
    "My Project",           # projectName
    REWARD_TOKEN,           # rewardToken
    REWARD_AMOUNT,          # amount (desired reward pool)
    int(time.time()),       # startTime
    "myproject",            # xAccount
    "https://logo.url",     # logoUrl
    "https://myproject.com",# websiteUrl
    b'\x00' * 32           # referralCode (bytes32(0) = no referral)
).build_transaction({
    "from": account.address, "nonce": w3.eth.get_transaction_count(account.address)
})
signed = account.sign_transaction(tx)
tx_hash = w3.eth.send_raw_transaction(signed.raw_transaction)
print(f"Campaign created: {tx_hash.hex()}")

View Functions

FunctionReturnsDescription
getCampaign(uint256)Campaign structFull campaign data by ID
getRemainingFunds(uint256)uint256Tokens remaining in escrow
campaignCount()uint256Total campaigns created
getParameters()uint256Current protocol fee (basis points)

API Reference

EndpointMethodDescription
/api/injections/contractsGETActive contract addresses per chain
/api/injectionsGETList injected campaigns (pending + active)

Errors

ErrorCause
ProjectNameRequiredEmpty project name
ProjectNameTooLongProject name exceeds 100 characters
InvalidRewardTokenZero address passed as reward token
AmountMustBeGreaterThanZeroAmount is 0
InsufficientAllowanceERC20 approve not called or amount too low
TransferFailedToken transfer reverted (check balance)
Pausable: pausedContract is paused by admin

Contract ABI

Minimal ABI for createCampaign and view functions.

JSON ABI
[
  {
    "inputs": [
      { "name": "_projectName", "type": "string" },
      { "name": "_rewardToken", "type": "address" },
      { "name": "_amount", "type": "uint256" },
      { "name": "_startTime", "type": "uint256" },
      { "name": "_xAccount", "type": "string" },
      { "name": "_logoUrl", "type": "string" },
      { "name": "_websiteUrl", "type": "string" },
      { "name": "_referralCode", "type": "bytes32" }
    ],
    "name": "createCampaign",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [{ "name": "_campaignId", "type": "uint256" }],
    "name": "getCampaign",
    "outputs": [
      {
        "components": [
          { "name": "creator", "type": "address" },
          { "name": "projectName", "type": "string" },
          { "name": "rewardToken", "type": "address" },
          { "name": "amount", "type": "uint256" },
          { "name": "startTime", "type": "uint256" },
          { "name": "endTime", "type": "uint256" },
          { "name": "protocolFee", "type": "uint256" },
          { "name": "withdrawn", "type": "uint256" },
          { "name": "isActive", "type": "bool" },
          { "name": "refunded", "type": "bool" },
          { "name": "createdAtBlock", "type": "uint256" },
          { "name": "xAccount", "type": "string" },
          { "name": "logoUrl", "type": "string" },
          { "name": "websiteUrl", "type": "string" },
          { "name": "referralCode", "type": "bytes32" }
        ],
        "name": "",
        "type": "tuple"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [{ "name": "_campaignId", "type": "uint256" }],
    "name": "getRemainingFunds",
    "outputs": [{ "name": "", "type": "uint256" }],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "campaignCount",
    "outputs": [{ "name": "", "type": "uint256" }],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "getParameters",
    "outputs": [{ "name": "", "type": "uint256" }],
    "stateMutability": "view",
    "type": "function"
  }
]
    Launch a Campaign — Inject Protocol | borged.io