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

# Get Loyalty Points Log

> Get the loyalty-points activity log for a patient (newest first).

Combines the BalanceTransaction ledger (adjustments, redemptions, voids) with
a synthesized "points added" entry for each grant's creation — grant creation
is not itself a BalanceTransaction, so it would otherwise be absent from the log.



## OpenAPI

````yaml get /user/patient/{patient_id}/loyalty-points/log
openapi: 3.1.0
info:
  title: Decoda API
  description: External API documentation for the Decoda Health platform.
  version: '1.0'
servers: []
security: []
paths:
  /user/patient/{patient_id}/loyalty-points/log:
    get:
      tags:
        - Loyalty Points
      summary: Get Loyalty Points Log
      description: >-
        Get the loyalty-points activity log for a patient (newest first).


        Combines the BalanceTransaction ledger (adjustments, redemptions, voids)
        with

        a synthesized "points added" entry for each grant's creation — grant
        creation

        is not itself a BalanceTransaction, so it would otherwise be absent from
        the log.
      operationId: get_loyalty_points_log_user_patient__patient_id__loyalty_points_log_get
      parameters:
        - name: TENANT
          in: header
          required: true
          schema:
            type: string
            title: Tenant
          description: The tenant you are making this request on behalf of
        - name: API-KEY
          in: header
          required: true
          schema:
            type: string
            title: Api-Key
          description: Your api key
        - name: patient_id
          in: path
          required: true
          schema:
            type: string
            title: Patient Id
        - name: grant_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Limit the log to a single grant
            title: Grant Id
          description: Limit the log to a single grant
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/LoyaltyPointTransactionSummary'
                title: >-
                  Response Get Loyalty Points Log User Patient  Patient Id 
                  Loyalty Points Log Get
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    LoyaltyPointTransactionSummary:
      properties:
        id:
          type: string
          title: Id
        balanceId:
          type: string
          title: Balanceid
          description: ID of the loyalty grant this transaction belongs to
        type:
          $ref: '#/components/schemas/BalanceTransactionType'
        amount:
          type: integer
          title: Amount
        note:
          anyOf:
            - type: string
            - type: 'null'
          title: Note
        createdDate:
          type: string
          format: date-time
          title: Createddate
        actor:
          anyOf:
            - $ref: '#/components/schemas/UserTiny'
            - type: 'null'
      type: object
      required:
        - id
        - balanceId
        - type
        - amount
        - createdDate
      title: LoyaltyPointTransactionSummary
      description: One entry in a patient's loyalty-points activity log.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    BalanceTransactionType:
      type: string
      enum:
        - REDEMPTION
        - REDEMPTION_REVERSAL
        - REFUND
        - ADJUSTMENT_INCREASE
        - ADJUSTMENT_DECREASE
        - EXPIRY
        - PURCHASE_REFUND
        - VOID
        - TRANSFER_OUT
        - TRANSFER_IN
      title: BalanceTransactionType
    UserTiny:
      properties:
        id:
          type: string
          title: Id
          description: The unique identifier for the user.
        firstName:
          anyOf:
            - type: string
            - type: 'null'
          title: Firstname
          description: The user's first name.
        lastName:
          anyOf:
            - type: string
            - type: 'null'
          title: Lastname
          description: The user's last name.
        phoneNumber:
          anyOf:
            - type: string
            - type: 'null'
          title: Phonenumber
          description: The user's phone number.
        email:
          anyOf:
            - type: string
            - type: 'null'
          title: Email
          description: The user's email address.
        type:
          $ref: '#/components/schemas/UserType'
          description: The type of user.
        locationId:
          anyOf:
            - type: string
            - type: 'null'
          title: Locationid
          description: The location of the user.
      type: object
      required:
        - id
        - type
      title: UserTiny
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    UserType:
      type: string
      enum:
        - PROVIDER
        - PATIENT
        - ASSISTANT
      title: UserType

````