Request Compute Grant Approval
Consolidated approval request endpoint. Orchestrates approval-session heartbeat, grants listing, credits / campaign-budget preflight and optional compute-status probe so the CLI can drop its multi-endpoint wrapper.
POST
HTTPBearerheader
AuthorizationBearer <token>application/json- body
Body shape for the consolidated POST /compute-grants/request-approval.
FLY-382 P4. Mirrors the orchestration previously fanned out by the CLI: heartbeat → grants listing → credits/campaign preflight → optional status probe. The CLI now POSTs once and returns the server's payload verbatim.
acquire_node_id?string|nullapproval_session_id?string|nullbudget_source*Budget Sourcecompute_budget_id?string|nullgrant_action?Grant ActionDefault
"create"lease_control_token?string|nullprovider?string|nullpurpose*Purposeregion?string|nullrequested_sku*Requested Skusuggested_hard_cap_cents?Suggested Hard Cap CentsDefault
0target_compute_grant_id?string|nullSuccessful Response
application/json- response
acquire_node_id?string|nullapproval_session*approval_session_id*Approval Session Idbudget_source*Budget SourceValue in
"user""root"compute_budget_id?string|nullcompute_grant_id*Compute Grant Idcompute_status?|nullgrant_action*Grant ActionValue in
"create""top_up"grants*array<>message*Messagepurpose*Purposeregion*string|nullrequested_sku*Requested Skustatus*Status[key: string]?anyExample Request
curl -X POST 'https://flywheel.paradigma.inc/api/v1/compute-grants/request-approval' \ -H 'Content-Type: application/json' \ -d '{ "budget_source": "string", "purpose": "string", "requested_sku": "string"}'Example Response
{ "acquire_node_id": "string", "approval_session": {}, "approval_session_id": "string", "budget_source": "user", "compute_budget_id": "string", "compute_grant_id": "string", "compute_status": { "active_lease_id": "string", "budget_remaining_cents": 0, "budget_source": "string", "compute_grant_id": "string", "cumulative_spend_cents": 0, "grant_cents": 0, "hard_cap_cents": 0, "leases": [ { "activated_at": "string", "auto_shutdown_at": "string", "budget_grace_deadline_at": "string", "connection_allowed_for_current_user": true, "created_at": "string", "error": "string", "has_ssh_private_key": true, "instance_status": "string", "last_heartbeat_at": "string", "lease_id": "string", "offer_id": "string", "owned_by_current_user": true, "price_cents_per_hour": 0, "provider": "string", "region": "string", "release_reason": "string", "released_at": "string", "ssh_host": "string", "ssh_port": 0, "ssh_user": "string", "status": "string", "total_charged_cents": 0, "usage_role_for_current_user": "owner" } ], "next_retry_after_seconds": 0, "recommended_next_action": "string", "remaining_cents": 0, "resume_offer_id": "string", "resume_region": "string", "root_compute_budget_id": "string", "spent_cents": 0 }, "grant_action": "create", "grants": [ {} ], "message": "string", "purpose": "string", "region": "string", "requested_sku": "string", "status": "already_approved"}