PATCH /v1/lab/paper-runs/{id}
Change when one of the caller’s ACTIVE paper runs ends: `ends_at` (ISO 8601) at least 1 hour and at most 90 days from now (400 `invalid_ends_at` otherwise), or `null` for no end (it runs until stopped). A new end gets its own notice about 24 hours before it. 409 `paper_run_not_active` when the run already stopped; 404 when it is not the caller’s. Answers the run as GET /v1/lab/paper-runs/:id does (its newest 100 copies). Needs no plan. 404 `lab_paper_disabled` while LAB_PAPER_ENABLED is off.
Change when one of the caller’s ACTIVE paper runs ends: ends_at (ISO 8601) at least 1 hour and at most 90 days from now (400 invalid_ends_at otherwise), or null for no end (it runs until stopped). A new end gets its own notice about 24 hours before it. 409 paper_run_not_active when the run already stopped; 404 when it is not the caller’s. Answers the run as GET /v1/lab/paper-runs/:id does (its newest 100 copies). Needs no plan. 404 lab_paper_disabled while LAB_PAPER_ENABLED is off.
API key: Authorization: Bearer pk_live_… (mint at polyrank.app/api-keys)
In: header
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X PATCH "https://example.com/v1/lab/paper-runs/497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -H "Content-Type: application/json" \ -d '{ "ends_at": "string" }'{ "id": "string", "strategy_id": "string", "status": "active", "wallets": [ "string" ], "wallets_refreshed_at": "string", "started_at": "string", "stopped_at": "string", "ends_at": "string", "stop_reason": "user", "graded_at": "string", "resolved_copies": 0, "promotable": true, "stats": { "property1": null, "property2": null }, "notes": [ "string" ], "known_issues": [ "string" ], "kind": "copy", "entry_order": "market", "wallet_rules": [ { "wallet": "string", "label": "string", "chips": [ { "key": "string", "words": "string" } ] } ], "seat": { "at": "string", "source": "history_ranking", "score": "string", "window_days": 0, "min_positions": 0, "recomputed": true, "wallets": [ { "wallet": "string", "rank": 0, "score": 0, "n": 0 } ] }, "copies": [ { "wallet": "string", "token_id": "string", "condition_id": "string", "title": "string", "category": "string", "signal_at": "string", "leader_price": 0, "leader_usd": 0, "outcome": "string", "reason": "string", "entry_at": "string", "entry_price": 0, "entry_delay_s": 0, "clip_usd": 0, "tradable_usd": 0, "exit_at": "string", "exit_price": 0, "won": 0, "pnl_usd": 0, "settled_at": "string", "signal": { "kind": "string", "side": "buy", "token": "string", "price": 0, "ref": 0 }, "signal_kind": "wallet", "rule": { "moment": "string", "ask": 0, "bid": 0, "phase": "string", "outcome": "yes", "days_to_end": 0, "conditions": [ { "feature": "string", "op": "string", "value": 0, "window_h": 0, "actual": 0, "holds": true, "words": "string", "unit": "string" } ], "basis": "top" }, "shares": 0, "fills": [ { "at": 0, "usd": 0, "shares": 0, "px": 0, "try": -9007199254740991 } ], "top_up": { "tries": -9007199254740991, "times": -9007199254740991, "every_s": 0, "ended": "string", "summary": "string" }, "exit_legs": [ { "seq": -9007199254740991, "rule": "string", "sold_at": "string", "shares": 0, "proceeds_usd": 0, "avg_price": 0, "try": -9007199254740991, "floor": 0 } ], "exit_held": { "rule": "string", "shares": 0, "tries": -9007199254740991 }, "adds": { "added": -9007199254740991, "refused": -9007199254740991, "added_usd": 0, "refused_by": { "property1": -9007199254740991, "property2": -9007199254740991 } } } ]}{ "error": "string", "message": "string", "feature": "string", "field": "string", "plan": "string", "retry_after_sec": 0, "retry_after_seconds": 0, "reason": "string", "running": 0, "limit": 0, "issues": [ null ], "trace_id": "string"}{ "error": "string", "message": "string", "feature": "string", "field": "string", "plan": "string", "retry_after_sec": 0, "retry_after_seconds": 0, "reason": "string", "running": 0, "limit": 0, "issues": [ null ], "trace_id": "string"}{ "error": "string", "message": "string", "feature": "string", "field": "string", "plan": "string", "retry_after_sec": 0, "retry_after_seconds": 0, "reason": "string", "running": 0, "limit": 0, "issues": [ null ], "trace_id": "string"}{ "error": "string", "message": "string", "feature": "string", "field": "string", "plan": "string", "retry_after_sec": 0, "retry_after_seconds": 0, "reason": "string", "running": 0, "limit": 0, "issues": [ null ], "trace_id": "string"}{ "error": "string", "message": "string", "feature": "string", "field": "string", "plan": "string", "retry_after_sec": 0, "retry_after_seconds": 0, "reason": "string", "running": 0, "limit": 0, "issues": [ null ], "trace_id": "string"}{ "error": "string", "message": "string", "feature": "string", "field": "string", "plan": "string", "retry_after_sec": 0, "retry_after_seconds": 0, "reason": "string", "running": 0, "limit": 0, "issues": [ null ], "trace_id": "string"}{ "error": "string", "message": "string", "feature": "string", "field": "string", "plan": "string", "retry_after_sec": 0, "retry_after_seconds": 0, "reason": "string", "running": 0, "limit": 0, "issues": [ null ], "trace_id": "string"}PATCH /v1/lab/credits/settings PATCH
Set (or clear with null) the caller’s own ceiling on a UTC day’s assistant spend, in credits (`daily_ceiling`; there is no other daily cap), and/or the mode the caller’s new chats start in (`mode`: `standard` or `deep`; remembered per account, returned as `last_mode` / `start_mode`; `deep` is 403 `plan_required` feature `agent_deep_mode` on a plan without Deep mode). Signed-in session only.
PATCH /v1/lab/strategies/{id} PATCH
Rename, edit the spec of, archive or unarchive one of the caller’s strategies. An edited spec returns the strategy to draft: its past backtests keep the spec they ran with. 403 `plan_required` (strategy_lab; own rules: Lab Pro and up). 404 `lab_disabled` while LAB_ENABLED is off.