Enter position
Create an enter action withPOST /v1/actions/enter. The API returns ordered unsigned transactions. You sign them, then either submit the signed payload for Yield.xyz to broadcast or broadcast it yourself and submit the hash.
When to use
- Stake tokens (for example, “Stake 1 ETH with Lido”)
- Deposit into a lending market or vault
- Start earning on a token
Authentication and host
Send the project API key in thex-api-key header.
Step 1: Check the yield accepts deposits
status.enter is true. If the yield has mechanics.requirements.kycRequired, check KYC first with GET /v1/yields/{yieldId}/kyc/status?address=....
Step 2: Read the argument schema
Readmechanics.arguments.enter.fields[] from the yield. Common arguments:
The schema on the yield is authoritative. Send only fields it lists.
Step 3: Create the enter action
POST /v1/actions/enter. yieldId and address are required. arguments is optional in the schema, but most yields need fields.
201 with an ActionDto: id, intent: "enter", type, status, executionPattern, and transactions[]. Each transaction has id, type, status, stepIndex, unsignedTransaction, and network. Solana enters can also return entryReserveEstimate.
Optionally call POST /v1/actions/enter/simulate first to estimate gas. Simulation does not count against the action creation limit.
Step 4: Sign and submit each transaction
Processtransactions[] in stepIndex order.
- If
executionPatternissynchronous, wait for each transaction to confirm before the next. - If it is
batch, one transaction bundles several operations. asynchronousis also a declared value, but current actions returnsynchronousorbatch.
unsignedTransaction with the user’s wallet, then use one path per transaction, never both:
A. Yield.xyz broadcasts: POST /v1/transactions/{transactionId}/submit with body { "signedTransaction": "..." }. Returns 201 with the updated transaction, including hash.
B. You broadcast: PUT /v1/transactions/{transactionId}/submit-hash with body { "hash": "0x..." }. Returns 200.
Step 5: Track completion
GET /v1/actions/{actionId} until status is terminal: SUCCESS, FAILED, or CANCELED. Track a single transaction with GET /v1/transactions/{transactionId}; CONFIRMED, FAILED, and SKIPPED are terminal. If a broadcast fails, the action moves to FAILED; create a new action to retry.
Errors
Edge cases
- Approvals: EVM lending and vault yields often return an
APPROVALtransaction before the deposit. Run them in order. - Minimums: Entry limits are in
mechanics.entryLimits. Amounts below them fail with400. - Stale actions: An action with no progress for 30 minutes becomes
STALE. Create a new one. - Never reuse signed payloads: A terminal transaction rejects a different signed payload or hash with
412.

