Reference
Savings Plans and Reserved Instances to buy, sized on the daily bill
The uncovered base, as /uncovered returns it, beside one proposal per payer and plan type at 12 months No Upfront. Each proposal offers three profiles sized on the daily CUR floor, net of the commitment already bought or agreed, capped by AWS's own recommendation, and replayed over the last 60 complete days. Free to every organization; reads cached rates and offerings and never calls AWS. raised is null until a proposal can be raised as a purchase. schedule lists every tranche of each purchase schedule with a month still to come: its day, its size, where it stands and why it last shrank or was skipped. reservations lists the new Reserved Instances LevelFour would buy for on-demand usage no Savings Plan covers, each sized on the 10th percentile day, quoted on the cached offering at the guardrails' term, and flagged quota_blocked when the RDS reserved instance quota cannot hold it.
Authorization
BearerAuth In: header
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/api/v1/commitments/purchase-plan"{
"success": true,
"timestamp": "2019-08-24T14:15:22Z",
"data": {
"provider": "aws",
"uncovered": [
{
"service": "string",
"organization_id": "string",
"payer_account_id": "string",
"plan_type": "compute",
"platform": "string",
"on_demand_hourly_avg": 0,
"on_demand_hourly_min": 0,
"volatility_ratio": 0,
"recommended_kind": "string",
"suggested_commitment_hourly": 0,
"grain": "daily",
"source": "cur",
"window_days": 0,
"fetched_on": "2019-08-24"
}
],
"proposals": [
{
"grain": "daily",
"source": "cur",
"basis": "public_on_demand",
"currency": "USD",
"payer_account_id": "string",
"plan_type": "compute",
"term_months": 0,
"payment_option": "all_upfront",
"unavailable_reason": "schema_pending",
"window": {
"first_day": "2019-08-24",
"last_day": "2019-08-24",
"days": 0,
"missing_days": 0,
"last_loaded": "2019-08-24"
},
"caveats": [
"string"
],
"profiles": {
"conservative": {
"commitment_hourly": 0,
"uncapped_hourly": 0,
"percentile": 0,
"capped_by": [
"string"
],
"utilization_pct": 0,
"coverage_pct": 0,
"net_savings_monthly": 0,
"net_savings_monthly_at_your_rates": 0
},
"balanced": {
"commitment_hourly": 0,
"uncapped_hourly": 0,
"percentile": 0,
"capped_by": [
"string"
],
"utilization_pct": 0,
"coverage_pct": 0,
"net_savings_monthly": 0,
"net_savings_monthly_at_your_rates": 0
},
"max_savings": {
"commitment_hourly": 0,
"uncapped_hourly": 0,
"percentile": 0,
"capped_by": [
"string"
],
"utilization_pct": 0,
"coverage_pct": 0,
"net_savings_monthly": 0,
"net_savings_monthly_at_your_rates": 0
}
},
"profiles_inverted": false,
"guards": [
{
"name": "string",
"limit": 0,
"applied": true,
"basis": "string"
}
],
"aws": {
"hourly_commitment_to_purchase": 0,
"cap": 0,
"cap_basis": "direct",
"cap_applied": true,
"lookback_days": 0,
"fetched_on": "2019-08-24",
"generated_at": "2019-08-24T14:15:22Z",
"min_hourly_on_demand": 0,
"avg_hourly_on_demand": 0,
"estimated_utilization_pct": 0,
"estimated_monthly_savings": 0,
"basis_check_pct": 0,
"basis_check_flagged": true,
"gap": [
{
"code": "ledger_claims",
"commitment_hourly": 0
}
]
},
"ledger": [
{
"source": "queued_plan",
"reference": "string",
"commitment_hourly": 0,
"on_demand_hourly": 0,
"scope": {
"family": "string",
"region": "string"
},
"effective_from": "2019-08-24"
}
],
"ledger_hourly": 0,
"stale_claims": [
{
"reference": "string",
"commitment_hourly": 0,
"on_demand_hourly": 0,
"accepted_days_ago": 0
}
],
"unmapped_holders": [
"string"
],
"window_changes": [
{
"reference": "string",
"kind": "string",
"change": "started",
"day": "2019-08-24"
}
],
"excluded": [
{
"reason": "string",
"on_demand_daily": 0
}
],
"recommended_profile": "balanced",
"raised": {
"recommendation_id": "string",
"commitment_hourly": 0,
"profile": "conservative",
"created_at": "2019-08-24T14:15:22Z",
"quantity": 0
}
}
],
"schedule": [
{
"id": "string",
"schedule_id": "string",
"payer_account_id": "string",
"plan_type": "compute",
"profile": "conservative",
"tranche_number": 0,
"tranches_total": 0,
"tranche_month": "2019-08-24",
"scheduled_for": "2019-08-24",
"commitment_hourly": 0,
"status": "planned",
"reason": "string",
"reason_detail": {},
"recommendation_id": "string",
"resized_at": "2019-08-24T14:15:22Z"
}
],
"reservations": [
{
"id": "string",
"payer_account_id": "string",
"buying_account_id": "string",
"target": {
"kind": "reserved_instance",
"service": "ec2",
"region": "string",
"engine": "string",
"deployment": "single_az",
"offering_class": "standard",
"tenancy": "default"
},
"resource": "string",
"quantity": 0,
"term_months": 0,
"payment_option": "string",
"offering_id": "string",
"quote": {
"basis": "usage",
"offering_id": "string",
"currency": "string",
"term_months": 0,
"payment_option": "string",
"upfront": 0,
"recurring_monthly": 0,
"commitment_monthly": 0,
"term_total": 0,
"covered_on_demand_monthly": 0,
"left_on_demand_monthly": 0,
"unused_monthly": 0,
"unused_units": 0,
"left_on_demand_units": 0,
"net_savings_monthly": 0,
"savings_pct": 0,
"coverage_before_pct": 0,
"coverage_after_pct": 0,
"utilization_pct": 0,
"break_even_months": 0,
"capacity": 0,
"over_automation_cap": true,
"pool": {
"window": {
"first_day": "2019-08-24",
"last_day": "2019-08-24",
"days": 0,
"missing_days": 0,
"last_loaded": "2019-08-24"
},
"recommended": 0,
"recommended_capacity": 0,
"already_covered_monthly": 0,
"agreed_hourly": 0
},
"series": [
{
"day": "2019-08-24",
"used": 0
}
]
},
"window": {
"first_day": "2019-08-24",
"last_day": "2019-08-24",
"days": 0,
"missing_days": 0,
"last_loaded": "2019-08-24"
},
"note": "licensed_engine",
"unavailable_reason": "no_cur",
"raised": {
"recommendation_id": "string",
"commitment_hourly": 0,
"profile": "conservative",
"created_at": "2019-08-24T14:15:22Z",
"quantity": 0
},
"quota_blocked": false
}
]
}
}{
"success": false,
"error": {
"code": "string",
"message": "string",
"details": null
},
"timestamp": "2019-08-24T14:15:22Z"
}{
"success": false,
"error": {
"code": "string",
"message": "string",
"details": null
},
"timestamp": "2019-08-24T14:15:22Z"
}{
"success": false,
"error": {
"code": "string",
"message": "string",
"details": null
},
"timestamp": "2019-08-24T14:15:22Z"
}{
"success": false,
"error": {
"code": "string",
"message": "string",
"details": null
},
"timestamp": "2019-08-24T14:15:22Z"
}{
"success": false,
"error": {
"code": "string",
"message": "string",
"details": null
},
"timestamp": "2019-08-24T14:15:22Z"
}{
"success": false,
"error": {
"code": "string",
"message": "string",
"details": null
},
"timestamp": "2019-08-24T14:15:22Z"
}{
"success": false,
"error": {
"code": "string",
"message": "string",
"details": null
},
"timestamp": "2019-08-24T14:15:22Z"
}{
"success": false,
"error": {
"code": "string",
"message": "string",
"details": null
},
"timestamp": "2019-08-24T14:15:22Z"
}Where a Savings Plan purchase stands GET
One BUY- purchase: what it buys, the tranche it belongs to, and its latest purchase run with the steps, logs and trigger of its row. execution.status reads as it does for a renewal, plus returned when AWS refunded the plan after it was bought, and cancelled when a plan queued inside AWS was deleted while queued. execution.starts_at is when AWS starts such a plan: only runs sent before LevelFour stopped queueing inside AWS carry either. bought_outside names the plan of the same type and term bought outside LevelFour that stopped the latest run. execution.status reads scheduled while a released purchase waits on LevelFour's side until execution.send_at, and cancelled_before_purchase once it was cancelled before it was sent. execution.can_buy_now and execution.can_cancel say whether the caller may buy it now or cancel it at this moment, by the rules those two routes apply. Reads stored state only and never calls AWS. 404 for an id that is no purchase of this organization.
What one Savings Plan commitment would have done GET
Replays a commitment in dollars an hour over the payer's recent daily bill: the eligible on-demand spend it would have covered, the commitment it would have left unused, its utilization, coverage and monthly savings, day by day, beside the sized profiles and AWS's own figure. A day averages its hours, so every figure is an upper bound on the hourly truth. Free to every organization; never calls AWS. A Database plan is sold for 12 months No Upfront only. payer_account_id may be omitted when the organization has one payer. Missing data answers 200 with unavailable_reason.