Reinvest
info
- Need authentication. Up to 5 requests per second per UID. Requires Earn permission on the API key.
- Reinvests the claimable yield of the specified position back into the pool.
- Orders are processed asynchronously. A successful response means the order was accepted. Use Get Order Info to track order status.
orderLinkIdprovides idempotency — submitting the sameorderLinkIdwithin 30 minutes returns the sameorderIdwithout creating a duplicate order.- Only one pending order is allowed per position at a time.
HTTP Request
POST/v5/earn/liquidity-mining/reinvestRequest Parameters
| Parameter | Required | Type | Comments |
|---|---|---|---|
| productId | true | string | Product ID |
| orderLinkId | true | string | User-customised order ID (max 36 characters). Used for idempotency |
| positionId | true | string | Position ID to reinvest. Obtain from Get Position Info |
Response Parameters
| Parameter | Type | Comments |
|---|---|---|
| orderId | string | System-generated order ID |
| orderLinkId | string | User-customised order ID |
Request Example
POST /v5/earn/liquidity-mining/reinvest HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-SIGN: XXXXX
X-BAPI-API-KEY: xxxxxxxxxxxxxxxxxx
X-BAPI-TIMESTAMP: 1741651200000
X-BAPI-RECV-WINDOW: 5000
Content-Type: application/json
{
"productId": "5",
"orderLinkId": "lm-reinvest-01",
"positionId": "1498"
}
Response Example
{
"retCode": 0,
"retMsg": "",
"result": {
"orderId": "c3d4e5f6-a7b8-9012-cdef-123456789012",
"orderLinkId": "lm-reinvest-01"
},
"retExtInfo": {},
"time": 1741651200000
}