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

# Get a customer's referral history

> Lists the referrals a customer has sent, with each referral's status (PENDING, CLAIMED, RECURRING) and whether each side has been rewarded. Friends' emails are masked, since this list is meant to be shown to the referring customer. Paginated with `page`, `size` and `sort`; the total count is in the `X-Total-Count` response header.



## OpenAPI

````yaml /loyalty/admin-api-swagger.json get /api/external/customer-referrals
openapi: 3.0.1
info:
  description: ''
  title: Admin APIs
  version: 0.0.1
servers:
  - url: https://loyalty-admin.appstle.com
security: []
tags:
  - description: >-
      Admin APIs for enrolling customers into the loyalty program, retrieving
      customer loyalty details, and updating profile information such as birth
      date.
    name: Customer Enrollment & Profile
  - description: >-
      Admin APIs for managing customer point balances, transaction history,
      point earning rules, top customers leaderboard, and approving pending
      transactions.
    name: Points & Earn Rules
  - description: >-
      Admin APIs for redeeming customer points, managing redemption rules, and
      validating or updating discount codes generated through loyalty
      redemptions.
    name: Redemptions & Discount Codes
  - description: >-
      Admin APIs for retrieving storefront widget label translations consumed by
      the loyalty widget on the merchant's storefront.
    name: Storefront Widgets & Labels
paths:
  /api/external/customer-referrals:
    get:
      tags:
        - Referrals
      summary: Get a customer's referral history
      description: >-
        Lists the referrals a customer has sent, with each referral's status
        (PENDING, CLAIMED, RECURRING) and whether each side has been rewarded.
        Friends' emails are masked, since this list is meant to be shown to the
        referring customer. Paginated with `page`, `size` and `sort`; the total
        count is in the `X-Total-Count` response header.
      operationId: externalGetCustomerReferrals
      parameters:
        - description: API key for authentication
          in: header
          name: X-API-Key
          required: true
          schema:
            type: string
        - description: Shopify customer ID of the referring customer
          in: query
          name: customerId
          required: true
          schema:
            format: int64
            type: integer
        - description: Pagination parameters (page number, size, sort)
          in: query
          name: pageable
          required: true
          schema:
            $ref: '#/components/schemas/Pageable'
      responses:
        '200':
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/CustomerReferralDTO'
                type: array
          description: Successfully retrieved the customer's referrals
        '400':
          description: Invalid request - customerId is missing
        '401':
          description: Unauthorized - Invalid or missing X-API-Key
      security:
        - X-API-Key: []
components:
  schemas:
    Pageable:
      properties:
        page:
          format: int32
          minimum: 0
          type: integer
        size:
          format: int32
          minimum: 1
          type: integer
        sort:
          items:
            type: string
          type: array
      type: object
    CustomerReferralDTO:
      properties:
        claimAt:
          format: date-time
          type: string
        createAt:
          format: date-time
          type: string
        customerId:
          format: int64
          type: integer
        description:
          type: string
        id:
          format: int64
          type: integer
        orderCount:
          format: int32
          type: integer
        pixelData:
          type: string
        referralNote:
          type: string
        referralRewarded:
          type: boolean
        referralRuleId:
          format: int64
          type: integer
        referredEmailId:
          type: string
        referredNote:
          type: string
        referredRewarded:
          type: boolean
        shop:
          type: string
        status:
          enum:
            - PENDING
            - CLAIMED
            - RECURRING
          type: string
      required:
        - createAt
        - customerId
        - referredEmailId
        - shop
        - status
      type: object

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.