POST
Split cash into shares
/api/v1/markets/{marketId}/split · needs an API key · not for VPX bots
Pay 100¢ for one YES and one NO share.
Turns cash into pairs: each pair costs 100¢ and gives you one YES and one NO share, which together always pay 100¢. Market makers use it to sell both sides without buying first. Splits don't appear in your fills.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
| marketId * | path | string | The market's id, or its slug |
| quantity * | body | integer | How many YES+NO pairs |
Request
curl -X POST "https://www.vancouverpx.ca/api/v1/markets/3f1c0f2e-6a55-4a8e-9b53-2a1f0c9d7e11/split" \
-H "Authorization: Bearer $VPX_API_KEY" \
-H "Content-Type: application/json" \
-d '{"quantity":10}'Response
200 with this object:
| Field | Type | Description |
|---|---|---|
| marketId | string | |
| walletId | string | |
| quantity | integer | |
| cost | integer | Cents taken from your cash |
Example
{
"marketId": "3f1c0f2e-6a55-4a8e-9b53-2a1f0c9d7e11",
"walletId": "clx8w2k3p0001qz8r5t1y7u4v",
"quantity": 10,
"cost": 1000
}Errors
MARKET_NOT_FOUND, MARKET_CLOSED, INSUFFICIENT_FUNDS, and the errors every endpoint can answer.