Skip to main content
POST
/
prepare-transactions
Prepare Transactions
curl --request POST \
  --url https://api.sandbox.brickken.com/prepare-transactions \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '{
  "method": "newTokenization",
  "signerAddress": "0xSignerAddress",
  "chainId": "aa36a7",
  "tokenSymbol": "BKN",
  "tokenType": "EQUITY",
  "tokenizerEmail": "tokenizer.email@example.com",
  "acceptedCoin": "USDT",
  "amount": "100",
  "endDate": "2025-10-02T00:00:00.000Z",
  "from": "0x123...",
  "gasLimit": "2000000 but can be omitted",
  "initialHolders": [
    {
      "email": "<string>",
      "percentage": 123
    }
  ],
  "investmentAmount": "10",
  "investorAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "investorEmail": "investor@example.com",
  "maxInvestment": "100",
  "maxRaiseUSD": "100",
  "minInvestment": "10",
  "minRaiseUSD": "10",
  "name": "Brickken",
  "newInvestor": {
    "name": "John",
    "surname": "Doe"
  },
  "offeringName": "FE Test STO 5",
  "paymentTokenSymbol": "USDT",
  "preMints": [
    {
      "email": "<string>",
      "investorAddress": "<string>",
      "amount": "<string>",
      "needWhitelist": true
    }
  ],
  "rpcUrl": "{URL_TO_RPC} but can be omitted",
  "spenderAddress": "0x456...",
  "startDate": "2025-08-26T17:30:00.000Z",
  "supplyCap": "10",
  "to": "0x456...",
  "tokenAmount": "1000",
  "tokenizerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "url": "https://example.com/token-docs",
  "userToMint": [
    {
      "email": "<string>",
      "investorAddress": "<string>",
      "amount": "<string>",
      "needWhitelist": true
    }
  ],
  "userToWhitelist": [
    {
      "whitelistStatus": true,
      "investorAddress": "<string>"
    }
  ]
}'
{
  "transactions": [
    {
      "from": "0x1234567890abcdef1234567890abcdef12345678",
      "to": "0xabcdef1234567890abcdef1234567890abcdef12",
      "value": "0x00",
      "nonce": 3792,
      "chainId": 11155111,
      "data": "0xd362e8a70000000000000000000000000000000000000000000000000000000000000040...",
      "type": 2,
      "maxPriorityFeePerGas": "1150000",
      "maxFeePerGas": "1156037",
      "gasLimit": "0xccef"
    }
  ],
  "info": {
    "tokenizerEmail": "tokenizer@example.com",
    "tokenSymbol": "EXMPL",
    "investorEmail": "investor@example.com"
  },
  "txId": "0x46adea7bdf49c576a760102e0d6bc9ecd650b3998588cd3d7f576a7973426aad"
}
Prepares unsigned transactions for various blockchain operations. This endpoint supports multiple transaction methods for tokenization, STO management, token operations, and more.

Common Parameters

ParameterTypeRequiredDescription
chainIdstringYesBlockchain network identifier (hex format)
methodstringYesTransaction method type
signerAddressstringYesAddress that will sign the transaction

Supported Methods

newTokenization

Creates a new tokenized asset.
{
  "method": "newTokenization",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "aa36a7",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "initialHolders": [],
  "name": "Example Token",
  "tokenType": "EQUITY",
  "preMints": [],
  "rpcUrl": null,
  "supplyCap": "1000000",
  "tokenizerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "url": "https://example.com/token-docs"
}

newSto

Creates a new Security Token Offering.
{
  "method": "newSto",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "aa36a7",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "acceptedCoin": "USDT",
  "endDate": "2025-12-31T23:59:59.000Z",
  "gasLimit": null,
  "maxInvestment": "100",
  "maxRaiseUSD": "100",
  "minInvestment": "10",
  "minRaiseUSD": "10",
  "offeringName": "Example STO Offering",
  "rpcUrl": null,
  "startDate": "2025-01-01T00:00:00.000Z",
  "tokenAmount": "1000"
}

newInvest

Makes an investment in an STO.
{
  "method": "newInvest",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "aa36a7",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "investmentAmount": "10",
  "investorAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "investorEmail": "investor@example.com",
  "paymentTokenSymbol": "USDT"
}

claimTokens

Claims tokens from a completed STO.
{
  "method": "claimTokens",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "aa36a7",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "investorAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "investorEmail": "investor@example.com",
  "paymentTokenSymbol": "USDT"
}

mintToken

Mints additional tokens to specified addresses.
{
  "method": "mintToken",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "aa36a7",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "investorAddress": "0x456def789abc123ghi456jkl789mno012pqr345",
  "newInvestor": {
    "name": "John",
    "surname": "Doe"
  },
  "userToMint": [
    {
      "email": "user@example.com",
      "investorAddress": "0x456def789abc123ghi456jkl789mno012pqr345",
      "amount": "500",
      "needWhitelist": true
    }
  ]
}

whitelist

Manages whitelist status for addresses.
{
  "method": "whitelist",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "aa36a7",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "gasLimit": null,
  "investorEmail": "investor@example.com",
  "newInvestor": {
    "name": "John",
    "surname": "Doe"
  },
  "rpcUrl": null,
  "userToWhitelist": [
    {
      "whitelistStatus": true,
      "investorAddress": "0x456def789abc123ghi456jkl789mno012pqr345"
    }
  ]
}

approve

Approves another address to spend tokens on behalf of the signer.
{
  "method": "approve",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "0x89",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "amount": "100",
  "spenderAddress": "0x456..."
}

burnToken

Burns tokens from the signer’s address.
{
  "method": "burnToken",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "0x89",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "amount": "100"
}

transferFrom

Transfers tokens from one address to another (requires approval).
{
  "method": "transferFrom",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "0x89",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "amount": "50",
  "from": "0x123...",
  "to": "0x456..."
}

transferTo

Transfers tokens from signer’s address to another address.
{
  "method": "transferTo",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "0x89",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "amount": "50",
  "to": "0x456..."
}

dividendDistribution

Distributes dividends to token holders.
{
  "method": "dividendDistribution",
  "signerAddress": "0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b",
  "chainId": "0x89",
  "tokenSymbol": "EXMPL",
  "tokenizerEmail": "tokenizer@example.com",
  "amount": "1000"
}

Response Format

The response includes the transaction details, metadata, and a unique transaction ID that must be saved for use with the /send-transactions endpoint. Important: The txId is NOT a blockchain transaction hash - it’s an internal identifier used to link the prepared transactions with the send operation.
{
  "transactions": [
    {
      "from": "0x1234567890abcdef1234567890abcdef12345678",
      "to": "0xabcdef1234567890abcdef1234567890abcdef12",
      "value": "0x00",
      "nonce": 3792,
      "chainId": 11155111,
      "data": "0xd362e8a70000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000010000000000000000000000001234567890abcdef1234567890abcdef1234567800000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000001",
      "type": 2,
      "maxPriorityFeePerGas": "1150000",
      "maxFeePerGas": "1156037",
      "gasLimit": "0xccef"
    }
  ],
  "info": {
    "tokenizerEmail": "tokenizer@example.com",
    "tokenSymbol": "EXMPL",
    "investorEmail": "investor@example.com"
  },
  "txId": "0x46adea7bdf49c576a760102e0d6bc9ecd650b3998588cd3d7f576a7973426aad"
}

Response Fields

FieldTypeDescription
transactionsarrayArray of unsigned transaction objects ready for signing
infoobjectMetadata about the operation including emails and token symbol
txIdstringUnique identifier for this transaction batch (required for /send-transactions)
Next Steps:
  1. Sign each transaction in the transactions array
  2. Submit the signed transactions along with the txId to /send-transactions

Authorizations

x-api-key
string
header
required

Body

application/json
method
enum<string>

The operation to be performed. Supported methods: newTokenization (create tokenized asset), newSto (create STO), newInvest (invest in STO), claimTokens (claim from completed STO), mintToken (mint additional tokens), whitelist (manage whitelist), approve (approve spending), burnToken (burn tokens), transferFrom (transfer with approval), transferTo (transfer from signer), dividendDistribution (distribute dividends), closeOffer (close active STO).

Available options:
newTokenization,
newSto,
newInvest,
claimTokens,
mintToken,
whitelist,
approve,
burnToken,
transferFrom,
transferTo,
dividendDistribution,
closeOffer
Example:

"newTokenization"

signerAddress
string

The address of the user initiating the transaction.

Example:

"0xSignerAddress"

chainId
string

The blockchain network's chain ID in hexadecimal format (e.g., "aa36a7" for Sepolia testnet).

Example:

"aa36a7"

tokenSymbol
string

The token symbol (max 5 characters).

Example:

"BKN"

tokenType
enum<string>

Type of token. Allowed values: EQUITY, DEBT, BILL_FACTORING, ICO, STABLECOIN, REVENUE_SHARE, RWA_TOKEN, PROFIT_SHARING.

Available options:
EQUITY,
DEBT,
BILL_FACTORING,
ICO,
STABLECOIN,
REVENUE_SHARE,
RWA_TOKEN,
PROFIT_SHARING
Example:

"EQUITY"

tokenizerEmail
string

The email of the user.

Example:

"tokenizer.email@example.com"

acceptedCoin
string

Accepted payment token symbol (used in newSto).

Example:

"USDT"

amount
string

Amount for various operations (approve, burnToken, transferFrom, transferTo, dividendDistribution).

Example:

"100"

endDate
string<date-time>

End date of the STO (used in newSto).

Example:

"2025-10-02T00:00:00.000Z"

from
string

Source address for transfer (used in transferFrom).

Example:

"0x123..."

gasLimit
string

An amount of gas units as limits. If not specified, it will be automatically estimated.

Example:

"2000000 but can be omitted"

initialHolders
object[]

Array of initial token holders (used in newTokenization).

investmentAmount
string

Amount to invest (used in newInvest).

Example:

"10"

investorAddress
string

Address of the investor (used in newInvest, claimTokens, mintToken).

Example:

"0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b"

investorEmail
string

Email of the investor (used in newInvest, claimTokens, whitelist).

Example:

"investor@example.com"

maxInvestment
string

Maximum investment amount (used in newSto).

Example:

"100"

maxRaiseUSD
string

Maximum raise amount in USD (used in newSto).

Example:

"100"

minInvestment
string

Minimum investment amount (used in newSto).

Example:

"10"

minRaiseUSD
string

Minimum raise amount in USD (used in newSto).

Example:

"10"

name
string

Name of the token.

Example:

"Brickken"

newInvestor
object

New investor information (used in whitelist and mintToken).

offeringName
string

Name of the STO offering (used in newSto).

Example:

"FE Test STO 5"

paymentTokenSymbol
string

Symbol of the payment token (used in newInvest, claimTokens).

Example:

"USDT"

preMints
object[]

Array of pre-mint configurations (used in newTokenization).

rpcUrl
string

The RPC URL of the blockchain network. If not provided, a default RPC URL for the specified chain ID will be used.

Example:

"{URL_TO_RPC} but can be omitted"

spenderAddress
string

Address of the spender being approved (used in approve).

Example:

"0x456..."

startDate
string<date-time>

Start date of the STO (used in newSto).

Example:

"2025-08-26T17:30:00.000Z"

supplyCap
string

Max token supply.

Example:

"10"

to
string

Destination address for transfer (used in transferFrom, transferTo).

Example:

"0x456..."

tokenAmount
string

Amount of tokens for STO (used in newSto).

Example:

"1000"

tokenizerAddress
string

The address of the tokenizer (used in newTokenization).

Example:

"0x742d35Cc6634C0532925a3b8D4C9db96c4b4d8b"

url
string

URL associated with tokenization documents (required for newTokenization).

Example:

"https://example.com/token-docs"

userToMint
object[]

Array of users to mint tokens to (used in mintToken).

userToWhitelist
object[]

Array of users to whitelist/blacklist (used in whitelist).

Response

200 - application/json

Successful response

transactions
object[]
required

Array of unsigned transaction objects ready for signing

txId
string
required

Unique identifier for this transaction batch (required for /send-transactions). This is NOT a blockchain transaction hash.

Example:

"0x46adea7bdf49c576a760102e0d6bc9ecd650b3998588cd3d7f576a7973426aad"

info
object

Metadata about the operation