> ## Documentation Index
> Fetch the complete documentation index at: https://docs.opigno.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get learning path results

<Note>
  For the moment Opigno Enterprise API provides possibility to retrieve attempt results only for the current API user.
</Note>

## `Attempt` API object

Any user attempt for activity, module or training is represented by the `Attempt` object:

| Property             | Type             | Description                                                                           |
| :------------------- | :--------------- | :------------------------------------------------------------------------------------ |
| `id`                 | `ID`             | Required; contains the unique identified of the attempt.                              |
| `lpRevisionId`       | `String`         | Required; represents the associated revision ID of the learning path.                 |
| `lpAttemptContextId` | `String`         | Required; contains a context ID associated with the attempt.                          |
| `cta`                | `[Cta]`          | A list of call-to-actions (CTAs) available for the attempt.                           |
| `metrics`            | `AttemptMetrics` | Performance and progress metrics for the attempt, such as score, progress and status. |

**`AttemptMetrics` object:**

| Property      | Type            | Description                                                                                                     |
| :------------ | :-------------- | :-------------------------------------------------------------------------------------------------------------- |
| `status`      | `AttemptStatus` | The current status of the attempt. Possible options: `IN_PROGRESS`, `COMPLETED`, `PASSED`, `FAILED`, `EXPIRED`. |
| `globalScore` | `Int`           | The overall score achieved in the attempt, returned as a percentage (0-100).                                    |
| `progress`    | `Int`           | The overall score achieved in the attempt, returned as a percentage (0-100).                                    |

## Get the training attempt data

The latest training attempt data for the current API user can be retrieved by using `getLearningPath` query:

<CodeGroup>
  ```GraphQL GraphQL [expandable] theme={null}
  query getLearningPath {
    getLearningPath(lpId: 23) {
      training {
        attempt {
          metrics {
            status
            progress
            globalScore
          }
        }
      }
    }
  }
  ```

  ```Query Query result [expandable] theme={null}
  {
    "data": {
      "getLearningPath": {
        "training": {
          "attempt": {
            "metrics": {
              "status": "PASSED",
              "globalScore": 85,
              "progress": 100,
            }
          }
        }
      }
    }
  }
  ```
</CodeGroup>
