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

# List rewards



## OpenAPI

````yaml /openapi/v1.yaml get /api/v1/rewards
openapi: 3.1.0
info:
  title: Rigaly Business API
  version: '1.0'
  description: |
    Public API for businesses to manage their Rigaly loyalty programs: issue
    and redeem points, manage rewards, validate redemptions, and generate mass
    codes for physical products.

    All endpoints require an API key created in the Rigaly business dashboard
    (Tools → API Management), passed as `Authorization: Bearer rgly_sk_...`.
  contact:
    email: support@rigaly.com
servers:
  - url: https://api.rigaly.com
    description: Production
security:
  - apiKey: []
paths:
  /api/v1/rewards:
    get:
      tags:
        - Rewards
      summary: List rewards
      operationId: listRewards
      parameters:
        - name: include_inactive
          in: query
          schema:
            type: boolean
            default: false
      responses:
        '200':
          description: Rewards
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/SuccessEnvelope'
                  - type: object
                    properties:
                      data:
                        type: object
                        properties:
                          rewards:
                            type: array
                            items:
                              $ref: '#/components/schemas/Reward'
components:
  schemas:
    SuccessEnvelope:
      type: object
      properties:
        success:
          type: boolean
          example: true
        message:
          type: string
        data:
          type: object
    Reward:
      allOf:
        - $ref: '#/components/schemas/RewardInput'
        - type: object
          properties:
            id:
              type: string
              format: uuid
            business_id:
              type: string
              format: uuid
            type:
              type: string
              example: standard
            image_url:
              type: string
              nullable: true
            created_at:
              type: string
              format: date-time
    RewardInput:
      type: object
      properties:
        name:
          type: string
          example: Free Coffee
        description:
          type: string
          nullable: true
        points_cost:
          type: integer
          minimum: 0
          example: 500
        active:
          type: boolean
          default: true
        start_date:
          type: string
          format: date
          nullable: true
        end_date:
          type: string
          format: date
          nullable: true
        time_active:
          $ref: '#/components/schemas/TimeActive'
        conditions:
          type: string
          nullable: true
          maxLength: 1000
          description: >-
            Free-text conditions shown to customers and returned on validation —
            use it to encode product restrictions your system enforces.
        cooldown_mode:
          type: string
          enum:
            - none
            - limit
            - once
          default: none
        cooldown_count:
          type: integer
          nullable: true
        cooldown_amount:
          type: integer
          nullable: true
        cooldown_unit:
          type: string
          enum:
            - minute
            - hour
            - day
            - month
          nullable: true
        birthday:
          type: boolean
          default: false
    TimeActive:
      type: object
      description: >-
        Per-day time-of-day windows. Omit a day to leave it unrestricted; omit
        the whole field for always-active.
      additionalProperties:
        type: object
        properties:
          active:
            type: boolean
          start:
            type: string
            example: '09:00'
          end:
            type: string
            example: '17:00'
      example:
        monday:
          active: true
          start: '09:00'
          end: '17:00'
        tuesday:
          active: true
          start: '09:00'
          end: '17:00'
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      description: 'API key from the Rigaly dashboard: `Authorization: Bearer rgly_sk_...`'

````