Capacity investments API


POST /api/v1/initiatives/:initiative_id/capacity_investments

Create a capacity investment on an initiative

Parameters

Name Description
initiative_id * Numeric ID or key of the initiative to create a capacity_investment for
start_date The start date for the capacity investment
end_date The end date for the capacity investment
date_source The date source for the capacity investment, can be one of: manual_dates, capacity_plannable
estimate_source The estimate source for the capacity investment, can be one of: manual_estimate, features, epics

POST /api/v1/initiatives/PRJ1-S-6/capacity_investments

Example CURL command

curl "https://company.aha.io/api/v1/initiatives/PRJ1-S-6/capacity_investments" -d '{}' -X POST \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
Content-Type: application/json
Accept: application/json
{
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "capacity_investment": {
    "id": "6733663036416802888",
    "capacity_scenario_id": "997808419",
    "total": null,
    "estimate_source": "manual_estimate",
    "date_source": "capacity_plannable",
    "start_date": null,
    "end_date": null,
    "initiative": {
      "id": "1042392694",
      "name": "Initiative 3",
      "created_at": "2019-01-01T00:00:00.000Z",
      "url": "http://company.aha.io/initiatives/PRJ1-S-6",
      "resource": "http://company.aha.io/api/v1/initiatives/PRJ1-S-6"
    },
    "estimate_values": [

    ]
  }
}

POST /api/v1/features/:master_feature_id/capacity_investments

Create a capacity investment on a master feature

Parameters

Name Description
master_feature_id * Numeric ID or key of the master feature to create a capacity_investment for
start_date The start date for the capacity investment
end_date The end date for the capacity investment
date_source The date source for the capacity investment, can be one of: manual_dates, capacity_plannable
estimate_source The estimate source for the capacity investment, can be one of: manual_estimate, features, epics

POST /api/v1/features/PRJ1-1/capacity_investments

Example CURL command

curl "https://company.aha.io/api/v1/features/PRJ1-1/capacity_investments" -d '{}' -X POST \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
Content-Type: application/json
Accept: application/json
{
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "capacity_investment": {
    "id": "6733663037123711751",
    "capacity_scenario_id": "997808419",
    "total": null,
    "estimate_source": "manual_estimate",
    "date_source": "capacity_plannable",
    "start_date": null,
    "end_date": null,
    "feature": {
      "id": "1007868956",
      "reference_num": "PRJ1-1",
      "name": "Feature 1",
      "created_at": "2019-01-01T00:00:00.000Z",
      "url": "http://company.aha.io/features/PRJ1-1",
      "resource": "http://company.aha.io/api/v1/features/PRJ1-1",
      "product_id": 131414752
    },
    "estimate_values": [

    ]
  }
}

POST /api/v1/features/:feature_id/capacity_investments

Create a capacity investment on a feature

Parameters

Name Description
feature_id * Numeric ID or key of the feature to create a capacity_investment for
start_date The start date for the capacity investment
end_date The end date for the capacity investment
date_source The date source for the capacity investment, can be one of: manual_dates, capacity_plannable
estimate_source The estimate source for the capacity investment, can be one of: manual_estimate, features, epics

POST /api/v1/features/PRJ1-1/capacity_investments

Example CURL command

curl "https://company.aha.io/api/v1/features/PRJ1-1/capacity_investments" -d '{}' -X POST \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
Content-Type: application/json
Accept: application/json
{
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "capacity_investment": {
    "id": "6733663037742133109",
    "capacity_scenario_id": "997808419",
    "total": null,
    "estimate_source": "manual_estimate",
    "date_source": "capacity_plannable",
    "start_date": null,
    "end_date": null,
    "feature": {
      "id": "1007868956",
      "reference_num": "PRJ1-1",
      "name": "Feature 1",
      "created_at": "2019-01-01T00:00:00.000Z",
      "url": "http://company.aha.io/features/PRJ1-1",
      "resource": "http://company.aha.io/api/v1/features/PRJ1-1",
      "product_id": 131414752
    },
    "estimate_values": [

    ]
  }
}

GET /api/v1/products/:product_id/capacity_investments

Retrieve capacity investments for a product

Parameters

Name Description
product_id * Numeric ID or key of the product to retrieve capacity investments for

GET /api/v1/products/PRJ1/capacity_investments

Example CURL command

curl -g "https://company.aha.io/api/v1/products/PRJ1/capacity_investments" -X GET \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
Content-Type: application/json
Accept: application/json

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "capacity_investments": [
    {
      "id": "756888381",
      "capacity_scenario_id": "997808419",
      "total": null
    },
    {
      "id": "873751177",
      "capacity_scenario_id": "997808419",
      "total": "100.0"
    }
  ],
  "pagination": {
    "total_records": 2,
    "total_pages": 1,
    "current_page": 1
  }
}

GET /api/v1/initiatives/:initiative_id/capacity_investments

Retrieve capacity investments for an initiative

Parameters

Name Description
initiative_id * Numeric ID or key of the initiative to retrieve capacity investments for

GET /api/v1/initiatives/PRJ1-S-1/capacity_investments

Example CURL command

curl -g "https://company.aha.io/api/v1/initiatives/PRJ1-S-1/capacity_investments" -X GET \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
Content-Type: application/json
Accept: application/json

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "capacity_investments": [
    {
      "id": "756888381",
      "capacity_scenario_id": "997808419",
      "total": null
    }
  ],
  "pagination": {
    "total_records": 1,
    "total_pages": 1,
    "current_page": 1
  }
}

GET /api/v1/master_features/:master_feature_id/capacity_investments

Retrieve capacity investments for a master feature

Parameters

Name Description
master_feature_id * Numeric ID or key of the master feature to retrieve capacity investments for

GET /api/v1/master_features/PRJ1-E-1/capacity_investments

Example CURL command

curl -g "https://company.aha.io/api/v1/master_features/PRJ1-E-1/capacity_investments" -X GET \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
Content-Type: application/json
Accept: application/json

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "capacity_investments": [
    {
      "id": "6733663039023093084",
      "capacity_scenario_id": "997808419",
      "total": null
    }
  ],
  "pagination": {
    "total_records": 1,
    "total_pages": 1,
    "current_page": 1
  }
}

GET /api/v1/features/:feature_id/capacity_investments

Retrieve capacity investments for a feature

Parameters

Name Description
feature_id * Numeric ID or key of the feature to retrieve capacity investments for

GET /api/v1/features/PRJ1-1/capacity_investments

Example CURL command

curl -g "https://company.aha.io/api/v1/features/PRJ1-1/capacity_investments" -X GET \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
Content-Type: application/json
Accept: application/json

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "capacity_investments": [
    {
      "id": "6733663039526753777",
      "capacity_scenario_id": "997808419",
      "total": null
    }
  ],
  "pagination": {
    "total_records": 1,
    "total_pages": 1,
    "current_page": 1
  }
}

GET /api/v1/capacity_investments/:id

Retrieve capacity investment details

Parameters

Name Description
id * Numeric ID of the capacity investment to retrieve

GET /api/v1/capacity_investments/6733663040289126627

Example CURL command

curl -g "https://company.aha.io/api/v1/capacity_investments/6733663040289126627" -X GET \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
Content-Type: application/json
Accept: application/json

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "capacity_investment": {
    "id": "6733663040289126627",
    "capacity_scenario_id": "997808419",
    "total": "50.0",
    "estimate_source": "manual_estimate",
    "date_source": "capacity_plannable",
    "start_date": null,
    "end_date": null,
    "feature": {
      "id": "1007868956",
      "reference_num": "PRJ1-1",
      "name": "Feature 1",
      "created_at": "2019-01-01T00:00:00.000Z",
      "url": "http://company.aha.io/features/PRJ1-1",
      "resource": "http://company.aha.io/api/v1/features/PRJ1-1",
      "product_id": 131414752
    },
    "estimate_values": [
      {
        "id": "6733663042113166838",
        "team_id": 563889676,
        "period_start": "2019-01-01",
        "total": "15.0",
        "computed": false,
        "ignored": false
      },
      {
        "id": "6733663042941777377",
        "team_id": 563889676,
        "period_start": "2019-01-01",
        "total": "20.0",
        "computed": false,
        "ignored": false
      },
      {
        "id": "6733663042163988877",
        "team_id": 563889676,
        "period_start": null,
        "total": "35.0",
        "computed": true,
        "ignored": false
      },
      {
        "id": "6733663040663230649",
        "team_id": 949295028,
        "period_start": "2019-01-01",
        "total": "5.0",
        "computed": false,
        "ignored": false
      },
      {
        "id": "6733663041431369549",
        "team_id": 949295028,
        "period_start": "2019-01-01",
        "total": "10.0",
        "computed": false,
        "ignored": false
      },
      {
        "id": "6733663040739063088",
        "team_id": 949295028,
        "period_start": null,
        "total": "15.0",
        "computed": true,
        "ignored": false
      },
      {
        "id": "6733663041088433450",
        "team_id": null,
        "period_start": "2019-01-01",
        "total": "5.0",
        "computed": true,
        "ignored": false
      },
      {
        "id": "6733663041792720566",
        "team_id": null,
        "period_start": "2019-01-01",
        "total": "25.0",
        "computed": true,
        "ignored": false
      },
      {
        "id": "6733663043275096382",
        "team_id": null,
        "period_start": "2019-01-01",
        "total": "20.0",
        "computed": true,
        "ignored": false
      },
      {
        "id": "6733663040926976798",
        "team_id": null,
        "period_start": null,
        "total": "50.0",
        "computed": true,
        "ignored": false
      }
    ]
  }
}

PUT /api/v1/capacity_investments/:id

Update a capacity investment

Parameters

Name Description
id * Numeric ID of capacity investment to be edited
start_date The start date for the capacity investment
end_date The end date for the capacity investment
date_source The date source for the capacity investment, can be one of: manual_dates, capacity_plannable
estimate_source The estimate source for the capacity investment, can be one of: manual_estimate, features, epics

PUT /api/v1/capacity_investments/756888381

Example CURL command

curl "https://company.aha.io/api/v1/capacity_investments/756888381" -d '{"capacity_investment":{"date_source":"manual_dates","start_date":"2019-01-01","end_date":"2019-01-01"}}' -X PUT \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
Content-Type: application/json
Accept: application/json
{
  "capacity_investment": {
    "date_source": "manual_dates",
    "start_date": "2019-01-01",
    "end_date": "2019-01-01"
  }
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "capacity_investment": {
    "id": "756888381",
    "capacity_scenario_id": "997808419",
    "total": null,
    "estimate_source": "manual_estimate",
    "date_source": "manual_dates",
    "start_date": "2019-01-01",
    "end_date": "2019-01-01",
    "initiative": {
      "id": "423077122",
      "name": "Initiative 1",
      "created_at": "2019-01-01T00:00:00.000Z",
      "url": "http://company.aha.io/initiatives/PRJ1-S-1",
      "resource": "http://company.aha.io/api/v1/initiatives/PRJ1-S-1"
    },
    "estimate_values": [

    ]
  }
}

Overview

API Resources