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

# Get learning guide by ID

> Resolve a learning guide via its Wealthyhood identifier.

Retrieve a learning guide and its chapters using the Wealthyhood identifier.

### Authentication & headers

<ParamField header="Authorization" type="string" required>
  Bearer token issued by Auth0. Format: `Bearer YOUR_ACCESS_TOKEN` and must include the `wealthyhood:nbg` scope.
</ParamField>

### Path parameters

<ParamField path="id" type="string" required>
  Content entry identifier. Use the `id` field from the learning guide summary response.
</ParamField>

### Example request

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET 'https://api.wealthyhood.com/learn/learning-guides/64f0c51e7fb3fc001234abcd' \
    -H 'Accept: application/json' \
    -H 'Authorization: Bearer YOUR_ACCESS_TOKEN'
  ```
</RequestExample>

### Example response

<ResponseExample>
  ```json Success theme={null}
  {
    "data": {
      "key": "investing-basics",
      "contentType": "learningGuide",
      "id": "64f0c51e7fb3fc001234abcd",
      "title": "Investing basics",
      "description": "Start your investing journey with the essentials.",
      "backgroundColor": "#F0F4FF",
      "guideIconURL": "https://images.ctfassets.net/.../guide-icon.png",
      "mobileCoverImageURL": "https://images.ctfassets.net/.../mobile-cover.png",
      "webCoverImageURL": "https://images.ctfassets.net/.../web-cover.png",
      "slug": "investing-basics",
      "chapterCount": 6,
      "chapters": [
        {
          "title": "Introduction to Investing",
          "body": "<body>...</body>",
          "slug": "introduction"
        }
      ]
    }
  }
  ```
</ResponseExample>

### Response fields

<ResponseField name="data" type="LearningGuideDetail" required>
  Learning guide detail including all chapters. Extends `LearningGuideSummary` with `chapters[]` containing HTML bodies.

  <Expandable title="LearningGuideDetail">
    <ResponseField name="id" type="string" required>
      MongoDB document identifier (24-hex). This is the same ID used in the path parameter.
    </ResponseField>

    <ResponseField name="chapters" type="LearningGuideChapter[]" required>
      Ordered list of chapters with HTML content. Content is trimmed for non-paid users.
    </ResponseField>
  </Expandable>
</ResponseField>


## OpenAPI

````yaml GET /learn/learning-guides/{id}
openapi: 3.0.3
info:
  title: Wealthyhood Learn API
  version: 1.0.0
  description: >
    Machine-to-machine endpoints that power the Wealthyhood Learn screen.


    All routes require a bearer access token issued by Auth0 with the
    `wealthyhood:nbg` scope.
servers:
  - url: https://{host}
    variables:
      host:
        default: api.wealthyhood.com
        description: Wealthyhood API host.
security:
  - bearerAuth: []
tags:
  - name: Learn
    description: Investor education content surfaced in the Learn screen.
paths:
  /learn/learning-guides/{id}:
    get:
      tags:
        - Learn
      summary: Get a learning guide by ID
      description: >
        Retrieve a learning guide and its chapters using the Wealthyhood
        identifier. Content is localized based on the user's language
        preference.
      parameters:
        - $ref: '#/components/parameters/XUserId'
        - name: id
          in: path
          required: true
          schema:
            type: string
            description: Wealthyhood content entry identifier.
      responses:
        '200':
          description: Learning guide payload resolved by ID.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LearningGuideDetailResponse'
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '403':
          $ref: '#/components/responses/ForbiddenError'
        '404':
          $ref: '#/components/responses/NotFoundError'
components:
  parameters:
    XUserId:
      name: x-user-id
      in: header
      required: true
      description: >-
        MongoDB identifier of the Wealthyhood user. Used to determine the
        language preference for localized content.
      schema:
        type: string
        pattern: ^[a-f0-9]{24}$
  schemas:
    LearningGuideDetailResponse:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/LearningGuideDetail'
      required:
        - data
    LearningGuideDetail:
      allOf:
        - $ref: '#/components/schemas/LearningGuideSummary'
        - type: object
          properties:
            chapters:
              type: array
              description: Ordered list of chapters included in the guide.
              items:
                $ref: '#/components/schemas/LearningGuideChapter'
          required:
            - chapters
    ApiErrorResponse:
      type: object
      properties:
        status:
          type: integer
        error:
          type: object
          properties:
            message:
              type: string
            description:
              type: string
              nullable: true
        responseId:
          type: string
          format: uuid
    LearningGuideSummary:
      type: object
      properties:
        key:
          type: string
          example: investing-basics
        id:
          type: string
          description: >-
            MongoDB document identifier (24-hex). Use this ID to fetch the full
            guide via `GET /learning-guides/{id}`.
          example: 64f0c51e7fb3fc001234abcd
        title:
          type: string
        description:
          type: string
        slug:
          type: string
        chapterCount:
          type: integer
      required:
        - key
        - id
        - title
        - description
        - slug
        - chapterCount
    LearningGuideChapter:
      type: object
      properties:
        title:
          type: string
        body:
          type: string
          description: HTML chapter content.
        slug:
          type: string
      required:
        - title
        - body
        - slug
  responses:
    UnauthorizedError:
      description: Missing or invalid bearer token.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiErrorResponse'
    ForbiddenError:
      description: Token lacks the required scope.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiErrorResponse'
    NotFoundError:
      description: Resource not found.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiErrorResponse'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Auth0-issued access token that includes the `wealthyhood:nbg` scope.

````