---
title: "Get Goal Aggregate"
method: GET
path: "/api/v1/performance/employees/{employeeId}/goals/{goalId}/aggregate"
tags: ["Goals", "Public API"]
---

# Get Goal Aggregate

`GET /api/v1/performance/employees/{employeeId}/goals/{goalId}/aggregate`

## Request

- Base URL: `https://companySubDomain.bamboohr.com`
- URL: `https://companySubDomain.bamboohr.com/api/v1/performance/employees/{employeeId}/goals/{goalId}/aggregate`
- Auth: one of:
  - HTTP basic
  - OAuth 2
    - Authorization code: `/authorize.php`
    - Token URL: `/token.php` scopes: `goal`
- TypeScript: <https://skmtc.dev/bamboohr/apis/bamboohr-api/docs/api/v1/performance/employees/:employeeId/goals/:goalId/aggregate/get.ts> (a function with typed inputs; its response is checked against the schema)

Returns a single goal with its comments, alignment options, and a list of all persons who are either shared on the goal or have commented on it. Useful for rendering a full goal detail view in a single request.

OAuth Scopes: goal

## Path parameters

- `employeeId` string, required
- `goalId` string, required

## Response `200`

The response content will be a JSON object with the requested information.

- object
  - `goal` TransformedApiGoal
    - `id` string: The id of the goal.
    - `title` string: Title of the goal.
    - `description` string: A description of the goal.
    - `percentComplete` integer: A percentage (0-100) that denotes how complete the goal is.
    - `alignsWithOptionId` string, nullable: The ID of the goal this goal is aligned with. Returns null when not aligned, or an empty string when the goal has no parent set.
    - `sharedWithEmployeeIds` integer[]: Ids of the employees that have access to this goal.
    - `dueDate` string: The due date of the goal.
    - `completionDate` string, nullable: ISO 8601 UTC timestamp of when the goal was completed.
    - `lastChangedDateTime` string, nullable: ISO 8601 UTC timestamp of when the goal was last modified.
    - `status` 'in_progress' | 'completed' | 'closed': The status of the goal.
    - `milestones` object[], nullable: All milestones for the individual goal. This array will not exist if milestones are not selected for this goal.
      - `id` integer: The id of the milestone.
      - `employeeGoalId` integer: The id of the goal which encompasses this milestone.
      - `title` string: The title of the milestone.
      - `currentValue` number, nullable: The current value for a numeric milestone. This number will be rounded to the nearest hundredth. On the creation of a numeric milestone this value will automatically be set to the start value of the milestone. If the milestone is a simple checkbox milestone, this value will always be null.
      - `startValue` number, nullable: The starting value for a numeric milestone. This number will be rounded to the nearest hundredth. If the milestone is a simple checkbox milestone, this value will always be null.
      - `endValue` number, nullable: The end goal for a numeric milestone. This number will be rounded to the nearest hundredth. If the milestone is a simple checkbox milestone, this value will always be null.
      - `completedDateTime` string: The date and time in which the goal has been completed. If the goal is not completed the value will be null.
      - `lastUpdateDateTime` string: The date and time in which the goal was last updated.
      - `lastUpdateUserId` integer: The ID of the user who last updated this milestone.
    - `actions` object, nullable: Actions that are available to a goal with milestones enabled. This object will not appear on a goal without milestones.
      - `canEditGoalProgressBar` boolean: Can the user edit the progress bar of this goal.
      - `canEditGoalMilestoneProgressBar` boolean: can the user edit the progress of a milestone in this goal.
  - `canAlign` boolean: The selected user can align goals with other users.
  - `canCreateGoals` boolean: The selected user can create a goal.
  - `alignsWithOptions` object[]: All possible goals that this goal could be aligned with.
    - `id` integer: Id of the goal that the selected goal could be aligned with.
    - `title` string: Title of the goal that the selected goal could be aligned with.
  - `comments` object[]: Comments linked to selected goal.
    - `id` string: Id of the comment.
    - `authorUserId` integer: Id of the author of the comment.
    - `createdAt` string: ISO 8601 UTC timestamp when the comment was created.
    - `text` string: The actual text of the comment.
    - `canEdit` boolean: Can the comment be edited.
    - `canDelete` boolean: Can the comment be deleted.
  - `persons` object[]: A list of people with access to the goal.
    - `employeeId` integer: The internal employee ID of this employee.
    - `userId` integer: The user id of the person if applicable.
    - `displayFirstName` string: First name of the person.
    - `lastName` string: Last name of the person.
    - `photoUrl` string: url of the user profile image.

## Other responses

- `403`: The authenticated caller does not have permission to view this goal.
- `404`: The specified goalId was not found.

---

[API](https://skmtc.dev/bamboohr/apis/bamboohr-api.md) - [All operations](https://skmtc.dev/bamboohr/apis/bamboohr-api/llms.txt) - [OpenAPI document](https://skmtc.dev/bamboohr/apis/bamboohr-api/revisions/922fc15f43a7?raw)
