Get status of a task
GET/task/status/:task_id/
Get the status of a task using the task ID.
The status can be one of
- PENDING
- FAILURE
- SUCCESS
Any additional details will be present in the result
field. The frontend/caller API
should be polling for task results every 20 - 30s. It should also update the user
accordingly based on the status.https://docs.fereai.xyz/docs/api/Monk/sell-tokens-agent-agent-id-sell-holding-id-quantity-post
Output
\{
"task_id": "2dc1ec2a-9f48-4fb3-bf72-44b2adb9190f",
"status": "FAILURE",
"result": \{\}
\}```
Output of a sell task that succeeded:
```json
\{
"task_id": "335612b9-b495-4925-8c51-775ceeaf1d92",
"status": "SUCCESS",
"result": "\{"created_at":"2024-11-26T07:12:40","agent_id":"72a4fdae-6825-4896-be90-4bf9ed8e6261","base_address":"KENJSUYLASHUMfHyy5o4Hp2FdNqZg1AsUPhfH2kYvEP","pool_name":"GRIFFAIN / SOL","decision":0,"price_usd":0.00719506860116107,"price_sol":0.0000303826727689711,"in_amount":592788488.0,"out_amount":17945779.0,"gas_fee":127000.0,"jito_fee":80000.0,"other_amount_threshold":17856051.0,"reason":"Sell decision executed manually.","future_action":"Re-evaluate if there's an entry criteria","profit_sol":-0.040081023001594954,"profit_usd":-10.962148394048281,"profit_percentage":-68.99633864046619,"txn":"https://solscan.io/tx/627nNaCEJ2jqBUpdrkgHvqmMm9DHexTkrY98E5pMMe9GvUeZMkND1Rf5GnYqCMjazypA3TAg36PqEBkSyq4rHSPH","dry_run":true\}"
\}
Request
Responses
- 200
- 422
Successful Response
Validation Error