Commitments
List EC2 Reserved Instances#
GET /api/organizations/{organization_id}/commitments/ec2
Your EC2 Reserved Instances. Without a state filter, it returns the active, retired, and returned ones.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
organization_id | path | string (uuid) | The organization's ID, from the organizations list. Required. |
account | query | string, repeatable | Only the records in these AWS accounts, by 12-digit account ID. |
region | query | string, repeatable | Only the records in these regions. One of 33 values, like us-east-1. |
state | query | string, repeatable | Only the records in these states. One of active, payment-failed, payment-pending, queued, queued-deleted, retired. |
Response
summary(object): Totals for the matching records.total(integer): How many commitments match.active(integer): How many of them are active.accounts(integer): How many accounts they span.
commitments(array of objects): The matching commitments.id(string): Unique identifier for the reserved instance.type(string): EC2 instance type.region(string): AWS region where the instances are reserved. One of 33 values, likeus-east-1.count(number): Number of reserved instances.platform(string): Operating system platform.start_time(string): Start date of the reservation (ISO 8601).end_time(string): Expiration date of the reservation (ISO 8601).duration(number): Length of the reservation period in months.state(string): Current state of the reservation. One ofactive,payment-failed,payment-pending,queued,queued-deleted,retired.payment_option(string): Payment structure.offering_class(string): Offering class type. One ofconvertible,standard.commitment_price(number): Monthly cost with the reservation, per reserved instance.on_demand_price(number): What one reserved instance would cost a month at the on-demand list price, not based on usage.savings(number): Expected monthly savings for the whole reservation: (on_demand_price - commitment_price) x count.managed_by(string): Who manages it: aws for a commitment you bought, milkstraw for one MilkStraw AI provides. One ofaws,milkstraw.utilization_percentage(number or null): How much of the commitment was used so far this month, from 0 to 100; null until AWS reports it, about 2 days late.account_id(string): The 12-digit ID of the AWS account it belongs to.
Errors: 401, 403, 404, 422, 429. See errors.
curl https://app.milkstraw.ai/api/organizations/$ORGANIZATION_ID/commitments/ec2 \
-H "Authorization: Bearer $MILKSTRAW_API_KEY"{
"summary": {
"total": 2,
"active": 2,
"accounts": 2
},
"commitments": [
{
"id": "ri-acc-1",
"type": "m5.large",
"region": "us-east-1",
"count": 1,
"platform": "Linux/UNIX",
"start_time": "2026-11-08T13:01:58.000Z",
"end_time": "2026-12-09T13:01:58.000Z",
"duration": 12,
"state": "active",
"payment_option": "No Upfront",
"offering_class": "standard",
"commitment_price": 50,
"on_demand_price": 100,
"savings": 50,
"managed_by": "aws",
"utilization_percentage": null,
"account_id": "123456789012"
},
{
"id": "ri-mb-1",
"type": "m5.large",
"region": "us-east-1",
"count": 1,
"platform": "Linux/UNIX",
"start_time": "2026-11-08T13:01:58.000Z",
"end_time": "2026-12-09T13:01:58.000Z",
"duration": 12,
"state": "active",
"payment_option": "No Upfront",
"offering_class": "standard",
"commitment_price": 50,
"on_demand_price": 100,
"savings": 50,
"managed_by": "aws",
"utilization_percentage": null,
"account_id": "345678901234"
}
]
}List RDS Reserved Instances#
GET /api/organizations/{organization_id}/commitments/rds
Your RDS Reserved Instances. Without a state filter, it returns the active, retired, and returned ones.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
organization_id | path | string (uuid) | The organization's ID, from the organizations list. Required. |
account | query | string, repeatable | Only the records in these AWS accounts, by 12-digit account ID. |
region | query | string, repeatable | Only the records in these regions. One of 33 values, like us-east-1. |
state | query | string, repeatable | Only the records in these states. One of active, payment-failed, payment-pending, queued, queued-deleted, retired. |
Response
summary(object): Totals for the matching records.total(integer): How many commitments match.active(integer): How many of them are active.accounts(integer): How many accounts they span.
commitments(array of objects): The matching commitments.id(string): Unique identifier for the reserved instance.type(string): RDS instance type.platform(string): Database engine type.region(string): AWS region where the instances are reserved. One of 33 values, likeus-east-1.count(number): Number of reserved instances.multi_az(boolean): Whether Multi-AZ deployment is enabled.start_time(string): Start date of the reservation (ISO 8601).end_time(string): Expiration date of the reservation (ISO 8601).duration(number): Length of the reservation period in months.state(string): Current state of the reservation. One ofactive,payment-failed,payment-pending,queued,queued-deleted,retired.payment_option(string): Payment structure.commitment_price(number): Monthly cost with the reservation, per reserved instance.on_demand_price(number): What one reserved instance would cost a month at the on-demand list price, not based on usage.savings(number): Expected monthly savings for the whole reservation: (on_demand_price - commitment_price) x count.managed_by(string): Who manages it: aws for a commitment you bought, milkstraw for one MilkStraw AI provides. One ofaws,milkstraw.utilization_percentage(number or null): How much of the commitment was used so far this month, from 0 to 100; null until AWS reports it, about 2 days late.account_id(string): The 12-digit ID of the AWS account it belongs to.
Errors: 401, 403, 404, 422, 429. See errors.
curl https://app.milkstraw.ai/api/organizations/$ORGANIZATION_ID/commitments/rds \
-H "Authorization: Bearer $MILKSTRAW_API_KEY"{
"summary": {
"total": 1,
"active": 1,
"accounts": 1
},
"commitments": [
{
"id": "ri-rds-acc-1",
"type": "db.m5.large",
"platform": "aurora-mysql",
"region": "us-east-1",
"count": 1,
"multi_az": false,
"start_time": "2026-11-08T13:01:58.000Z",
"end_time": "2026-12-09T13:01:58.000Z",
"duration": 12,
"state": "active",
"payment_option": "No Upfront",
"commitment_price": 80,
"on_demand_price": 160,
"savings": 80,
"managed_by": "aws",
"utilization_percentage": null,
"account_id": "123456789012"
}
]
}List ElastiCache Reserved Instances#
GET /api/organizations/{organization_id}/commitments/elasticache
Your ElastiCache Reserved Instances. Without a state filter, it returns the active, retired, and returned ones.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
organization_id | path | string (uuid) | The organization's ID, from the organizations list. Required. |
account | query | string, repeatable | Only the records in these AWS accounts, by 12-digit account ID. |
region | query | string, repeatable | Only the records in these regions. One of 33 values, like us-east-1. |
state | query | string, repeatable | Only the records in these states. One of active, payment-failed, payment-pending, queued, queued-deleted, retired. |
Response
summary(object): Totals for the matching records.total(integer): How many commitments match.active(integer): How many of them are active.accounts(integer): How many accounts they span.
commitments(array of objects): The matching commitments.id(string): Unique identifier for the reserved instance.type(string): Cache node instance type.platform(string): Cache engine type (e.g., redis, memcached, valkey).region(string): AWS region where the instances are reserved. One of 33 values, likeus-east-1.count(number): Number of reserved instances.start_time(string): Start date of the reservation (ISO 8601).end_time(string): Expiration date of the reservation (ISO 8601).duration(number): Length of the reservation period in months.state(string): Current state of the reservation. One ofactive,payment-failed,payment-pending,queued,queued-deleted,retired.payment_option(string): Payment structure.commitment_price(number): Monthly cost with the reservation, per reserved instance.on_demand_price(number): What one reserved instance would cost a month at the on-demand list price, not based on usage.savings(number): Expected monthly savings for the whole reservation: (on_demand_price - commitment_price) x count.managed_by(string): Who manages it: aws for a commitment you bought, milkstraw for one MilkStraw AI provides. One ofaws,milkstraw.utilization_percentage(number or null): How much of the commitment was used so far this month, from 0 to 100; null until AWS reports it, about 2 days late.account_id(string): The 12-digit ID of the AWS account it belongs to.
Errors: 401, 403, 404, 422, 429. See errors.
curl https://app.milkstraw.ai/api/organizations/$ORGANIZATION_ID/commitments/elasticache \
-H "Authorization: Bearer $MILKSTRAW_API_KEY"{
"summary": {
"total": 1,
"active": 1,
"accounts": 1
},
"commitments": [
{
"id": "ri-elc-acc-1",
"type": "cache.m5.large",
"platform": "redis",
"region": "us-east-1",
"count": 1,
"start_time": "2026-11-08T13:01:58.000Z",
"end_time": "2026-12-09T13:01:58.000Z",
"duration": 12,
"state": "active",
"payment_option": "No Upfront",
"commitment_price": 60,
"on_demand_price": 120,
"savings": 60,
"managed_by": "aws",
"utilization_percentage": null,
"account_id": "123456789012"
}
]
}List OpenSearch Reserved Instances#
GET /api/organizations/{organization_id}/commitments/opensearch
Your OpenSearch Reserved Instances. Without a state filter, it returns the active, retired, and returned ones.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
organization_id | path | string (uuid) | The organization's ID, from the organizations list. Required. |
account | query | string, repeatable | Only the records in these AWS accounts, by 12-digit account ID. |
region | query | string, repeatable | Only the records in these regions. One of 33 values, like us-east-1. |
state | query | string, repeatable | Only the records in these states. One of active, payment-failed, payment-pending, queued, queued-deleted, retired. |
Response
summary(object): Totals for the matching records.total(integer): How many commitments match.active(integer): How many of them are active.accounts(integer): How many accounts they span.
commitments(array of objects): The matching commitments.id(string): Unique identifier for the reserved instance.type(string): OpenSearch instance type.region(string): AWS region where the instances are reserved. One of 33 values, likeus-east-1.count(number): Number of reserved instances.start_time(string): Start date of the reservation (ISO 8601).end_time(string): Expiration date of the reservation (ISO 8601).duration(number): Length of the reservation period in months.state(string): Current state of the reservation. One ofactive,payment-failed,payment-pending,queued,queued-deleted,retired.payment_option(string): Payment structure.commitment_price(number): Monthly cost with the reservation, per reserved instance.on_demand_price(number): What one reserved instance would cost a month at the on-demand list price, not based on usage.savings(number): Expected monthly savings for the whole reservation: (on_demand_price - commitment_price) x count.managed_by(string): Who manages it: aws for a commitment you bought, milkstraw for one MilkStraw AI provides. One ofaws,milkstraw.utilization_percentage(number or null): How much of the commitment was used so far this month, from 0 to 100; null until AWS reports it, about 2 days late.account_id(string): The 12-digit ID of the AWS account it belongs to.
Errors: 401, 403, 404, 422, 429. See errors.
curl https://app.milkstraw.ai/api/organizations/$ORGANIZATION_ID/commitments/opensearch \
-H "Authorization: Bearer $MILKSTRAW_API_KEY"{
"summary": {
"total": 1,
"active": 1,
"accounts": 1
},
"commitments": [
{
"id": "ri-opn-acc-1",
"type": "r6g.large.search",
"region": "us-east-1",
"count": 1,
"start_time": "2026-11-08T13:01:58.000Z",
"end_time": "2026-12-09T13:01:58.000Z",
"duration": 12,
"state": "active",
"payment_option": "No Upfront",
"commitment_price": 70,
"on_demand_price": 140,
"savings": 70,
"managed_by": "aws",
"utilization_percentage": null,
"account_id": "123456789012"
}
]
}List Compute Savings Plans#
GET /api/organizations/{organization_id}/commitments/savings_plans/compute
Your Compute Savings Plans. Without a state filter, it returns the active, retired, and returned ones.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
organization_id | path | string (uuid) | The organization's ID, from the organizations list. Required. |
account | query | string, repeatable | Only the records in these AWS accounts, by 12-digit account ID. |
region | query | string, repeatable | Only the records in these regions. |
state | query | string, repeatable | Only the records in these states. One of active, payment-failed, payment-pending, pending-return, queued, queued-deleted, retired, returned. |
Response
summary(object): Totals for the matching records.total(integer): How many commitments match.active(integer): How many of them are active.accounts(integer): How many accounts they span.
commitments(array of objects): The matching commitments.id(string): Unique identifier assigned by AWS for this Savings Plan.service(string): Savings Plan type. One ofcompute,database,ec2_instance,sage_maker.region(string): AWS region, or "N/A" for region-agnostic Savings Plans.family(string): EC2 instance family for EC2 Instance Savings Plans, or "N/A" for family-agnostic Savings Plans.commitment(number): Hourly commitment amount in USD.cost(number): Monthly cost calculated from hourly commitment (commitment x ~730 hours/month).payment_option(string): Payment structure.up_front_amount(string): One-time upfront payment amount, or "N/A" if no upfront payment applies.recurring_amount(string): Recurring hourly charge amount, or "N/A" if fully paid upfront.term_seconds(number or null): Contract term reported by AWS, in seconds.start_time(string): Start date of the Savings Plan (ISO 8601).end_time(string): Expiration date of the Savings Plan (ISO 8601).state(string): Current state of the Savings Plan. One ofactive,payment-failed,payment-pending,pending-return,queued,queued-deleted,retired,returned.savings(number): Expected monthly savings assuming full utilization.managed_by(string): Who manages it: aws for a commitment you bought, milkstraw for one MilkStraw AI provides. One ofaws,milkstraw.utilization_percentage(number or null): How much of the commitment was used so far this month, from 0 to 100; null until AWS reports it, about 2 days late.account_id(string): The 12-digit ID of the AWS account it belongs to.
Errors: 401, 403, 404, 422, 429. See errors.
curl https://app.milkstraw.ai/api/organizations/$ORGANIZATION_ID/commitments/savings_plans/compute \
-H "Authorization: Bearer $MILKSTRAW_API_KEY"{
"summary": {
"total": 2,
"active": 2,
"accounts": 2
},
"commitments": [
{
"id": "sp-acc-1",
"service": "compute",
"region": "N/A",
"family": "N/A",
"commitment": 1,
"cost": 720,
"payment_option": "All Upfront",
"up_front_amount": "0",
"recurring_amount": "0",
"term_seconds": null,
"start_time": "2026-11-08T13:01:58.000Z",
"end_time": "2026-12-09T13:01:58.000Z",
"state": "active",
"savings": 100,
"managed_by": "aws",
"utilization_percentage": null,
"account_id": "123456789012"
},
{
"id": "sp-mb-1",
"service": "compute",
"region": "N/A",
"family": "N/A",
"commitment": 1,
"cost": 720,
"payment_option": "All Upfront",
"up_front_amount": "0",
"recurring_amount": "0",
"term_seconds": null,
"start_time": "2026-11-08T13:01:58.000Z",
"end_time": "2026-12-09T13:01:58.000Z",
"state": "active",
"savings": 100,
"managed_by": "aws",
"utilization_percentage": null,
"account_id": "345678901234"
}
]
}List EC2 Instance Savings Plans#
GET /api/organizations/{organization_id}/commitments/savings_plans/ec2_instance
Your EC2 Instance Savings Plans. Without a state filter, it returns the active, retired, and returned ones.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
organization_id | path | string (uuid) | The organization's ID, from the organizations list. Required. |
account | query | string, repeatable | Only the records in these AWS accounts, by 12-digit account ID. |
region | query | string, repeatable | Only the records in these regions. |
state | query | string, repeatable | Only the records in these states. One of active, payment-failed, payment-pending, pending-return, queued, queued-deleted, retired, returned. |
Response
summary(object): Totals for the matching records.total(integer): How many commitments match.active(integer): How many of them are active.accounts(integer): How many accounts they span.
commitments(array of objects): The matching commitments.id(string): Unique identifier assigned by AWS for this Savings Plan.service(string): Savings Plan type. One ofcompute,database,ec2_instance,sage_maker.region(string): AWS region, or "N/A" for region-agnostic Savings Plans.family(string): EC2 instance family for EC2 Instance Savings Plans, or "N/A" for family-agnostic Savings Plans.commitment(number): Hourly commitment amount in USD.cost(number): Monthly cost calculated from hourly commitment (commitment x ~730 hours/month).payment_option(string): Payment structure.up_front_amount(string): One-time upfront payment amount, or "N/A" if no upfront payment applies.recurring_amount(string): Recurring hourly charge amount, or "N/A" if fully paid upfront.term_seconds(number or null): Contract term reported by AWS, in seconds.start_time(string): Start date of the Savings Plan (ISO 8601).end_time(string): Expiration date of the Savings Plan (ISO 8601).state(string): Current state of the Savings Plan. One ofactive,payment-failed,payment-pending,pending-return,queued,queued-deleted,retired,returned.savings(number): Expected monthly savings assuming full utilization.managed_by(string): Who manages it: aws for a commitment you bought, milkstraw for one MilkStraw AI provides. One ofaws,milkstraw.utilization_percentage(number or null): How much of the commitment was used so far this month, from 0 to 100; null until AWS reports it, about 2 days late.account_id(string): The 12-digit ID of the AWS account it belongs to.
Errors: 401, 403, 404, 422, 429. See errors.
curl https://app.milkstraw.ai/api/organizations/$ORGANIZATION_ID/commitments/savings_plans/ec2_instance \
-H "Authorization: Bearer $MILKSTRAW_API_KEY"{
"summary": {
"total": 1,
"active": 1,
"accounts": 1
},
"commitments": [
{
"id": "sp-acc-3-ec2-instance",
"service": "ec2_instance",
"region": "us-east-1",
"family": "m5",
"commitment": 0.75,
"cost": 540,
"payment_option": "Partial Upfront",
"up_front_amount": "100",
"recurring_amount": "440",
"term_seconds": null,
"start_time": "2026-11-08T13:01:58.000Z",
"end_time": "2026-12-09T13:01:58.000Z",
"state": "active",
"savings": 75,
"managed_by": "aws",
"utilization_percentage": null,
"account_id": "123456789012"
}
]
}List SageMaker Savings Plans#
GET /api/organizations/{organization_id}/commitments/savings_plans/sage_maker
Your SageMaker Savings Plans. Without a state filter, it returns the active, retired, and returned ones.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
organization_id | path | string (uuid) | The organization's ID, from the organizations list. Required. |
account | query | string, repeatable | Only the records in these AWS accounts, by 12-digit account ID. |
region | query | string, repeatable | Only the records in these regions. |
state | query | string, repeatable | Only the records in these states. One of active, payment-failed, payment-pending, pending-return, queued, queued-deleted, retired, returned. |
Response
summary(object): Totals for the matching records.total(integer): How many commitments match.active(integer): How many of them are active.accounts(integer): How many accounts they span.
commitments(array of objects): The matching commitments.id(string): Unique identifier assigned by AWS for this Savings Plan.service(string): Savings Plan type. One ofcompute,database,ec2_instance,sage_maker.region(string): AWS region, or "N/A" for region-agnostic Savings Plans.family(string): EC2 instance family for EC2 Instance Savings Plans, or "N/A" for family-agnostic Savings Plans.commitment(number): Hourly commitment amount in USD.cost(number): Monthly cost calculated from hourly commitment (commitment x ~730 hours/month).payment_option(string): Payment structure.up_front_amount(string): One-time upfront payment amount, or "N/A" if no upfront payment applies.recurring_amount(string): Recurring hourly charge amount, or "N/A" if fully paid upfront.term_seconds(number or null): Contract term reported by AWS, in seconds.start_time(string): Start date of the Savings Plan (ISO 8601).end_time(string): Expiration date of the Savings Plan (ISO 8601).state(string): Current state of the Savings Plan. One ofactive,payment-failed,payment-pending,pending-return,queued,queued-deleted,retired,returned.savings(number): Expected monthly savings assuming full utilization.managed_by(string): Who manages it: aws for a commitment you bought, milkstraw for one MilkStraw AI provides. One ofaws,milkstraw.utilization_percentage(number or null): How much of the commitment was used so far this month, from 0 to 100; null until AWS reports it, about 2 days late.account_id(string): The 12-digit ID of the AWS account it belongs to.
Errors: 401, 403, 404, 422, 429. See errors.
curl https://app.milkstraw.ai/api/organizations/$ORGANIZATION_ID/commitments/savings_plans/sage_maker \
-H "Authorization: Bearer $MILKSTRAW_API_KEY"{
"summary": {
"total": 1,
"active": 1,
"accounts": 1
},
"commitments": [
{
"id": "sp-acc-4-sage-maker",
"service": "sage_maker",
"region": "us-east-1",
"family": "ml.m5",
"commitment": 0.4,
"cost": 288,
"payment_option": "No Upfront",
"up_front_amount": "0",
"recurring_amount": "0",
"term_seconds": null,
"start_time": "2026-11-08T13:01:58.000Z",
"end_time": "2026-12-09T13:01:58.000Z",
"state": "active",
"savings": 40,
"managed_by": "aws",
"utilization_percentage": null,
"account_id": "123456789012"
}
]
}List Database Savings Plans#
GET /api/organizations/{organization_id}/commitments/savings_plans/database
Your Database Savings Plans. Without a state filter, it returns the active, retired, and returned ones.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
organization_id | path | string (uuid) | The organization's ID, from the organizations list. Required. |
account | query | string, repeatable | Only the records in these AWS accounts, by 12-digit account ID. |
region | query | string, repeatable | Only the records in these regions. |
state | query | string, repeatable | Only the records in these states. One of active, payment-failed, payment-pending, pending-return, queued, queued-deleted, retired, returned. |
Response
summary(object): Totals for the matching records.total(integer): How many commitments match.active(integer): How many of them are active.accounts(integer): How many accounts they span.
commitments(array of objects): The matching commitments.id(string): Unique identifier assigned by AWS for this Savings Plan.service(string): Savings Plan type. One ofcompute,database,ec2_instance,sage_maker.region(string): AWS region, or "N/A" for region-agnostic Savings Plans.family(string): EC2 instance family for EC2 Instance Savings Plans, or "N/A" for family-agnostic Savings Plans.commitment(number): Hourly commitment amount in USD.cost(number): Monthly cost calculated from hourly commitment (commitment x ~730 hours/month).payment_option(string): Payment structure.up_front_amount(string): One-time upfront payment amount, or "N/A" if no upfront payment applies.recurring_amount(string): Recurring hourly charge amount, or "N/A" if fully paid upfront.term_seconds(number or null): Contract term reported by AWS, in seconds.start_time(string): Start date of the Savings Plan (ISO 8601).end_time(string): Expiration date of the Savings Plan (ISO 8601).state(string): Current state of the Savings Plan. One ofactive,payment-failed,payment-pending,pending-return,queued,queued-deleted,retired,returned.savings(number): Expected monthly savings assuming full utilization.managed_by(string): Who manages it: aws for a commitment you bought, milkstraw for one MilkStraw AI provides. One ofaws,milkstraw.utilization_percentage(number or null): How much of the commitment was used so far this month, from 0 to 100; null until AWS reports it, about 2 days late.account_id(string): The 12-digit ID of the AWS account it belongs to.
Errors: 401, 403, 404, 422, 429. See errors.
curl https://app.milkstraw.ai/api/organizations/$ORGANIZATION_ID/commitments/savings_plans/database \
-H "Authorization: Bearer $MILKSTRAW_API_KEY"{
"summary": {
"total": 1,
"active": 1,
"accounts": 1
},
"commitments": [
{
"id": "sp-acc-2-database",
"service": "database",
"region": "N/A",
"family": "N/A",
"commitment": 0.5,
"cost": 360,
"payment_option": "No Upfront",
"up_front_amount": "0",
"recurring_amount": "0",
"term_seconds": null,
"start_time": "2026-11-08T13:01:58.000Z",
"end_time": "2026-12-09T13:01:58.000Z",
"state": "active",
"savings": 50,
"managed_by": "aws",
"utilization_percentage": null,
"account_id": "123456789012"
}
]
}