Integration Fields API


POST /api/v1/features/:feature_id/integrations/:integration_id/fields

Create an integration field for a feature by integration id

Parameters

Name Description
feature_id * Numeric ID or key of the feature the integration field should be created for
integration_id * ID of integration the field is for

POST /api/v1/features/PRJ1-1/integrations/204584239/fields

Example CURL command

curl "https://secure.aha.io/api/v1/features/PRJ1-1/integrations/204584239/fields" -d '{"integration_field":{"name":"key","value":"JRA-34"}}' -X POST \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json
{
  "integration_field": {
    "name": "key",
    "value": "JRA-34"
  }
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "integration_field": {
    "id": "728894778",
    "name": "key",
    "value": "JRA-34",
    "integration_id": 204584239,
    "service_name": "jira",
    "created_at": "2017-03-16T17:02:52.000Z",
    "integratable": {
      "url": "http://account1.example.org/features/PRJ1-1",
      "resource": "http://account1.example.org/api/v1/features/PRJ1-1"
    }
  }
}

POST /api/v1/features/:feature_id/integrations/:integration_id/fields

Create multiple integration fields for a feature by integration id

Parameters

Name Description
feature_id * Numeric ID or key of the feature the integration field should be created for
integration_id * ID of integration the field is for

POST /api/v1/features/PRJ1-1/integrations/204584239/fields

Example CURL command

curl "https://secure.aha.io/api/v1/features/PRJ1-1/integrations/204584239/fields" -d '{"integration_fields":[{"name":"key","value":"JRA-34"},{"name":"id","value":"34"}]}' -X POST \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json
{
  "integration_fields": [
    {
      "name": "key",
      "value": "JRA-34"
    },
    {
      "name": "id",
      "value": "34"
    }
  ]
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
[
  728894778,
  846945422
]

POST /api/v1/features/:feature_id/integrations/:service_name/fields

Create an integration field for a feature by service name

DEPRECATED: pass :integration_id rather than :service_name to identify the integration.

Parameters

Name Description
feature_id * Numeric ID or key of the feature the integration field should be created for
service_name * Name of the integration service the field is for

POST /api/v1/features/PRJ1-1/integrations/jira/fields

Example CURL command

curl "https://secure.aha.io/api/v1/features/PRJ1-1/integrations/jira/fields" -d '{"integration_field":{"name":"key","value":"JRA-34"}}' -X POST \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json
{
  "integration_field": {
    "name": "key",
    "value": "JRA-34"
  }
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "integration_field": {
    "id": "6398143261556827151",
    "name": "key",
    "value": "JRA-34",
    "integration_id": 322044925,
    "service_name": "jira",
    "created_at": "2017-03-16T17:03:33.778Z",
    "integratable": {
      "url": "http://account1.example.org/features/PRJ1-1",
      "resource": "http://account1.example.org/api/v1/features/PRJ1-1"
    }
  }
}

POST /api/v1/features/:feature_id/integrations/:service_name/fields

Create multiple integration fields for a feature by service name

DEPRECATED: pass :integration_id rather than :service_name to identify the integration.

Parameters

Name Description
feature_id * Numeric ID or key of the feature the integration field should be created for
service_name * Name of the integration service the field is for

POST /api/v1/features/PRJ1-1/integrations/jira/fields

Example CURL command

curl "https://secure.aha.io/api/v1/features/PRJ1-1/integrations/jira/fields" -d '{"integration_fields":[{"name":"key","value":"JRA-34"},{"name":"id","value":"34"}]}' -X POST \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json
{
  "integration_fields": [
    {
      "name": "key",
      "value": "JRA-34"
    },
    {
      "name": "id",
      "value": "34"
    }
  ]
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
[
  "6398143262725647670",
  "6398143263073200299"
]

POST /api/v1/idea_endorsements/:idea_endorsement_id/integrations/:integration_id/fields

Create an integration field for an idea endorsement

Parameters

Name Description
idea_endorsement_id * Numeric ID of the idea endorsement the integration field should be created for
integration_id * ID of integration the field is for

POST /api/v1/idea_endorsements/53377392/integrations/204584239/fields

Example CURL command

curl "https://secure.aha.io/api/v1/idea_endorsements/53377392/integrations/204584239/fields" -d '{"integration_field":{"name":"key","value":"JRA-34"}}' -X POST \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json
{
  "integration_field": {
    "name": "key",
    "value": "JRA-34"
  }
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "integration_field": {
    "id": "975466318",
    "name": "key",
    "value": "JRA-34",
    "integration_id": 204584239,
    "service_name": "jira",
    "created_at": "2017-03-16T17:02:52.000Z",
    "integratable": {
      "url": "http://account1.example.org/ideas/idea_endorsements/53377392",
      "resource": "http://account1.example.org/api/v1/ideas/idea_endorsements/53377392"
    }
  }
}

GET /api/v1/features/:feature_id/integrations/:integration_id/fields/:field_name

Get an integration field value

Parameters

Name Description
feature_id * Numeric ID or key of the feature the integration field belongs to
integration_id * ID of integration the field is for
field_name * Name of the field to retrieve

GET /api/v1/features/PRJ1-1/integrations/204584239/fields/key

Example CURL command

curl "https://secure.aha.io/api/v1/features/PRJ1-1/integrations/204584239/fields/key" -X GET \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "integration_field": {
    "id": "728894778",
    "name": "key",
    "value": "JRA-123",
    "integration_id": 204584239,
    "service_name": "jira",
    "created_at": "2017-03-16T17:02:52.000Z",
    "integratable": {
      "url": "http://account1.example.org/features/PRJ1-1",
      "resource": "http://account1.example.org/api/v1/features/PRJ1-1"
    }
  }
}

GET /api/v1/integrations/:integration_id/fields/:field_name/value/:field_value

Find objects (releases, initiatives, features, requirements or idea endorsements) based on an integration field value

Parameters

Name Description
integration_id * ID of integration the field belongs to
field_name * Integration fields to search for the value
field_value * Value that matching objects must have in the integration field

GET /api/v1/integrations/204584239/fields/key/value/JRA-123

Example CURL command

curl "https://secure.aha.io/api/v1/integrations/204584239/fields/key/value/JRA-123" -X GET \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "records": [
    {
      "idea_endorsement": {
        "id": "53377392",
        "idea_id": "58056975",
        "created_at": "2017-03-16T17:02:52.000Z",
        "value": null,
        "endorsed_by_portal_user": {
          "id": "646391926",
          "name": "John Long",
          "email": "john@long.com",
          "created_at": "2017-03-16T17:02:52.000Z"
        },
        "integration_fields": [
          {
            "id": "975466318",
            "name": "key",
            "value": "JRA-123",
            "integration_id": 204584239,
            "service_name": "jira",
            "created_at": "2017-03-16T17:02:52.000Z"
          }
        ],
        "idea": {
          "id": "58056975",
          "reference_num": "PRJ1-I-1",
          "name": "Idea 1",
          "created_at": "2017-03-16T17:02:52.000Z",
          "workflow_status": {
            "id": "3259216",
            "name": "New",
            "complete": false
          },
          "description": {
            "id": "103757394",
            "body": "Description of idea 1",
            "created_at": "2017-03-16T17:02:52.000Z",
            "attachments": [

            ]
          },
          "url": "http://account1.example.org/ideas/ideas/PRJ1-I-1",
          "resource": "http://account1.example.org/api/v1/ideas/PRJ1-I-1"
        }
      }
    },
    {
      "feature": {
        "id": "1007868956",
        "name": "Feature 1",
        "reference_num": "PRJ1-1",
        "position": 1,
        "score": 0,
        "created_at": "2017-03-16T17:02:52.000Z",
        "updated_at": "2017-03-16T17:02:52.000Z",
        "start_date": null,
        "due_date": null,
        "workflow_kind": {
          "id": "98484309",
          "name": "New"
        },
        "workflow_status": {
          "id": "934242751",
          "name": "New",
          "complete": false
        },
        "description": {
          "id": "793547626",
          "body": "Body of note 1",
          "created_at": "2017-03-16T17:02:52.000Z",
          "attachments": [
            {
              "id": "724655692",
              "download_url": "http://account1.lvh.me/attachments/token/db1e08f19cd5cb2556ad7c870573fcb20faaca59b8c5c6eb3b87f3aaf1350aa0.download",
              "created_at": "2017-03-16T17:02:52.000Z",
              "file_size": 123,
              "content_type": "text/plain",
              "file_name": "uploaded_file_name.txt"
            }
          ]
        },
        "attachments": [

        ],
        "integration_fields": [
          {
            "id": "846945422",
            "name": "id",
            "value": "435",
            "integration_id": 204584239,
            "service_name": "jira",
            "created_at": "2017-03-16T17:02:52.000Z"
          },
          {
            "id": "728894778",
            "name": "key",
            "value": "JRA-123",
            "integration_id": 204584239,
            "service_name": "jira",
            "created_at": "2017-03-16T17:02:52.000Z"
          }
        ],
        "url": "http://account1.example.org/features/PRJ1-1",
        "resource": "http://account1.example.org/api/v1/features/PRJ1-1",
        "release": {
          "id": "278327321",
          "reference_num": "PRJ1-R-1",
          "name": "Release 1",
          "start_date": "2017-03-23",
          "release_date": "2017-03-23",
          "parking_lot": false,
          "created_at": "2017-03-16T17:02:53.000Z",
          "integration_fields": [
            {
              "id": "68217473",
              "name": "id",
              "value": "777",
              "integration_id": 204584239,
              "service_name": "jira",
              "created_at": "2017-03-16T17:02:52.000Z"
            }
          ],
          "url": "http://account1.example.org/releases/PRJ1-R-1",
          "resource": "http://account1.example.org/api/v1/releases/PRJ1-R-1",
          "owner": {
            "id": "16338845",
            "name": "John Smith",
            "email": "john.smith@account1.com",
            "created_at": "2017-03-16T17:02:53.000Z",
            "updated_at": "2017-03-16T17:02:53.000Z"
          },
          "project": {
            "id": "131414752",
            "reference_prefix": "PRJ1",
            "name": "Project 1",
            "product_line": false,
            "created_at": "2017-03-16T17:02:52.000Z"
          }
        },
        "created_by_user": {
          "id": "16338845",
          "name": "John Smith",
          "email": "john.smith@account1.com",
          "created_at": "2017-03-16T17:02:53.000Z",
          "updated_at": "2017-03-16T17:02:53.000Z"
        },
        "assigned_to_user": {
          "id": "16338845",
          "name": "John Smith",
          "email": "john.smith@account1.com",
          "created_at": "2017-03-16T17:02:53.000Z",
          "updated_at": "2017-03-16T17:02:53.000Z",
          "default_assignee": false
        },
        "requirements": [
          {
            "id": "483368544",
            "name": "Body of requirement 1",
            "reference_num": "PRJ1-1-1",
            "position": 1,
            "created_at": "2017-03-16T17:02:53.000Z",
            "updated_at": "2017-03-16T17:02:53.000Z",
            "workflow_status": {
              "id": "934242751",
              "name": "New",
              "complete": false
            },
            "url": "http://account1.example.org/requirements/PRJ1-1-1",
            "resource": "http://account1.example.org/api/v1/requirements/PRJ1-1-1",
            "description": {
              "id": "910541534",
              "body": "Body of requirement 1",
              "created_at": "2017-03-16T17:02:52.000Z",
              "attachments": [

              ]
            },
            "assigned_to_user": null,
            "created_by_user": {
              "id": "1020675218",
              "name": "Mary Humpty",
              "email": "mary.humpty@account1.com",
              "created_at": "2017-03-16T17:02:53.000Z",
              "updated_at": "2017-03-16T17:02:53.000Z"
            },
            "attachments": [

            ],
            "custom_fields": [
              {
                "key": "expected_completion_date",
                "name": "Expected completion date",
                "value": null,
                "type": "date"
              }
            ],
            "integration_fields": [

            ],
            "comments_count": 0
          }
        ],
        "initiative": {
          "id": "423077122",
          "name": "Initiative 1",
          "url": "http://account1.example.org/initiatives/423077122",
          "resource": "http://account1.example.org/api/v1/initiatives/423077122",
          "created_at": "2017-03-16T17:02:52.000Z",
          "description": {
            "id": "673273729",
            "body": "Description of initiative 1",
            "created_at": "2017-03-16T17:02:52.000Z",
            "attachments": [

            ]
          },
          "integration_fields": [

          ]
        },
        "goals": [
          {
            "id": "602095703",
            "name": "Goal 1",
            "url": "http://account1.example.org/strategic_imperatives/602095703",
            "resource": "http://account1.example.org/api/v1/goals/602095703",
            "created_at": "2017-03-16T17:02:53.000Z",
            "description": {
              "id": "166463080",
              "body": "Description of goal 1",
              "created_at": "2017-03-16T17:02:52.000Z",
              "attachments": [

              ]
            }
          }
        ],
        "comments_count": 1,
        "score_facts": [

        ],
        "tags": [
          "Infrastructure"
        ],
        "custom_fields": [
          {
            "key": "expected_completion_date",
            "name": "Expected completion date",
            "value": null,
            "type": "date"
          }
        ],
        "feature_links": [
          {
            "link_type": "Depends on",
            "link_type_id": 20,
            "created_at": "2017-03-16T17:02:52.000Z",
            "parent_record": {
              "id": "1007868956",
              "reference_num": "PRJ1-1",
              "name": "Feature 1",
              "created_at": "2017-03-16T17:02:52.000Z",
              "url": "http://account1.example.org/features/PRJ1-1",
              "resource": "http://account1.example.org/api/v1/features/PRJ1-1"
            },
            "child_record": {
              "id": "622562724",
              "reference_num": "PRJ1-2",
              "name": "Another Feature",
              "created_at": "2017-03-16T17:02:52.000Z",
              "url": "http://account1.example.org/features/PRJ1-2",
              "resource": "http://account1.example.org/api/v1/features/PRJ1-2"
            }
          }
        ]
      }
    }
  ],
  "pagination": {
    "total_records": 2,
    "total_pages": 1,
    "current_page": 1
  }
}

DELETE /api/v1/integration_fields/:id

Delete an integration field

Parameters

Name Description
id * Numeric ID of the integration field to be deleted

DELETE /api/v1/integration_fields/728894778

Example CURL command

curl "https://secure.aha.io/api/v1/integration_fields/728894778" -d '' -X DELETE \
	-H "Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 15b60d42d4bc417284a246ced6877b0bf13fb4aca415f7b55f7006bc3694a8ab
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json

Response

Status: 204 No Content
  

Overview

API Resources