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

# Search user coupons

> Search user coupons by search parameters for the specified POS system.



## OpenAPI

````yaml /openapi.yaml post /pos/{posSystemId}/coupon/couponCode/search
openapi: 3.0.1
info:
  title: ClearLine POS API
  description: >-
    Point of Sale integration API for ClearLine Marketing Platform. This API
    enables POS systems to send transaction data, manage customer interactions,
    and integrate with marketing campaigns.
  version: v1
servers:
  - url: https://public-api-demo.clearline.me
    description: ClearLine API Server
security: []
paths:
  /pos/{posSystemId}/coupon/couponCode/search:
    post:
      tags:
        - Coupons
      summary: Search user coupons
      description: Search user coupons by search parameters for the specified POS system.
      operationId: PosCoupon_SearchCoupons
      parameters:
        - name: posSystemId
          in: path
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json-patch+json:
            schema:
              $ref: '#/components/schemas/SearchUserCouponsDto'
            example:
              code: 10OFFmq8kl8
              email: null
              phone: null
              posLocationId: 6orMqUyq2Hg3tP
          application/json:
            schema:
              $ref: '#/components/schemas/SearchUserCouponsDto'
            example:
              code: 10OFFmq8kl8
              email: null
              phone: null
              posLocationId: 6orMqUyq2Hg3tP
          text/json:
            schema:
              $ref: '#/components/schemas/SearchUserCouponsDto'
            example:
              code: 10OFFmq8kl8
              email: null
              phone: null
              posLocationId: 6orMqUyq2Hg3tP
          application/*+json:
            schema:
              $ref: '#/components/schemas/SearchUserCouponsDto'
            example:
              code: 10OFFmq8kl8
              email: null
              phone: null
              posLocationId: 6orMqUyq2Hg3tP
          application/xml:
            schema:
              $ref: '#/components/schemas/SearchUserCouponsDto'
            example:
              code: 10OFFmq8kl8
              email: null
              phone: null
              posLocationId: 6orMqUyq2Hg3tP
          text/xml:
            schema:
              $ref: '#/components/schemas/SearchUserCouponsDto'
            example:
              code: 10OFFmq8kl8
              email: null
              phone: null
              posLocationId: 6orMqUyq2Hg3tP
          application/*+xml:
            schema:
              $ref: '#/components/schemas/SearchUserCouponsDto'
            example:
              code: 10OFFmq8kl8
              email: null
              phone: null
              posLocationId: 6orMqUyq2Hg3tP
      responses:
        '200':
          description: Success
          content:
            text/plain:
              schema:
                $ref: '#/components/schemas/CouponCodeDisplayDtoPosApiListResponse'
            application/json:
              schema:
                $ref: '#/components/schemas/CouponCodeDisplayDtoPosApiListResponse'
            text/json:
              schema:
                $ref: '#/components/schemas/CouponCodeDisplayDtoPosApiListResponse'
      security:
        - BearerAuth: []
        - ImplicitAuth: []
components:
  schemas:
    SearchUserCouponsDto:
      type: object
      properties:
        code:
          type: string
          description: Search by code
          nullable: true
        email:
          type: string
          description: Search by email
          nullable: true
        phone:
          type: string
          description: Search by phone
          nullable: true
        posLocationId:
          type: string
          description: Location POS identifier
          nullable: true
      additionalProperties: false
      description: Represent coupon search dto
    CouponCodeDisplayDtoPosApiListResponse:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/CouponCodeDisplayDto'
          nullable: true
        page:
          $ref: '#/components/schemas/PageModel'
        posStatus:
          $ref: '#/components/schemas/PosResponseStatus'
      additionalProperties: false
    CouponCodeDisplayDto:
      type: object
      properties:
        rewardProvider:
          $ref: '#/components/schemas/RewardProvider'
        code:
          type: string
          description: Code
          nullable: true
        name:
          type: string
          description: Name
          nullable: true
        title:
          type: string
          description: Title
          nullable: true
        pictureUrl:
          type: string
          description: Picture URL
          nullable: true
        availableUntil:
          type: string
          description: Available until date
          format: date-time
          nullable: true
        status:
          $ref: '#/components/schemas/CouponCodeItemStatus'
        info:
          type: array
          items:
            $ref: '#/components/schemas/CouponCodeDisplayInfoDto'
          description: Additional info
          nullable: true
      additionalProperties: false
      description: CouponCode display data
    PageModel:
      type: object
      properties:
        page:
          type: integer
          format: int32
        pageSize:
          type: integer
          format: int32
        total:
          type: integer
          format: int32
      additionalProperties: false
    PosResponseStatus:
      enum:
        - Accepted
        - Disabled
        - NotAvailable
      type: string
    RewardProvider:
      enum:
        - TwoReward
        - PJM
        - Dummy
      type: string
    CouponCodeItemStatus:
      enum:
        - Issued
        - Redeemed
        - Cancelled
        - Expired
      type: string
    CouponCodeDisplayInfoDto:
      type: object
      properties:
        title:
          type: string
          description: Info section title
          nullable: true
        items:
          type: object
          additionalProperties:
            type: string
            nullable: true
          description: Info section data
          nullable: true
      additionalProperties: false
      description: Coupon info section
  securitySchemes:
    BearerAuth:
      type: http
      description: |-

        JWT Authorization header using the Bearer scheme.

        Enter **_JWT Bearer token only_** in the text input below.
      scheme: bearer
      bearerFormat: JWT
    ImplicitAuth:
      type: oauth2
      description: Implicit scheme
      flows:
        implicit:
          authorizationUrl: https://logindemo.clearline.me/connect/authorize
          scopes:
            clearline_api: Grants access to Clearline API endpoints.

````