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

# List magic links

> Returns a paginated list of magic links for the authenticated partner. Filter by visibility (active/expired), status, referenceId, and date range.



## OpenAPI

````yaml /raas-widgets/openapi.json get /partner/links
openapi: 3.0.0
info:
  title: RaaS Widgets Partner API
  description: >
    REST API for RaaS Widgets partner integrations. Create magic links for
    embeddable flows, manage end users, track transfer operations, handle CIP
    verification, and configure webhooks for real-time event notifications.


    This specification covers the **Partner-accessible API** only (`X-API-Key`
    against `/partner/*`). Widget and Superadmin APIs are out of scope.


    ## Authentication


    All endpoints require an API key passed in the `X-API-Key` header. Use
    `raas_sandbox_*` keys for the sandbox environment and `raas_live_*` keys for
    production.


    ## Environments


    | Environment | Base URL |

    |---|---|

    | Sandbox | `https://raas-widgets-backend-sandbox.up.railway.app` |
  version: 1.18.0
  contact: {}
servers:
  - url: https://raas-widgets-backend-sandbox.up.railway.app
    description: Sandbox
security: []
tags:
  - name: Partner - Magic Links
    description: Create, list, and manage magic links for flows
  - name: Partner - Flows
    description: List enabled flows and the full flow catalog
  - name: Partner - Users
    description: View and manage end users associated with your partner account
  - name: Partner - Operations
    description: Track money transfer operations and their statuses
  - name: Partner - Requests
    description: List and inspect money-request records
  - name: Partner - Deferred Payouts
    description: List, inspect, and cancel deferred payout remittances
  - name: Partner - CIP
    description: Customer Identification Program (CIP) verification management
  - name: Partner - Data Requests
    description: Fulfill data requests for additional user information
  - name: Partner - Settings
    description: Configure partner-level settings (redirect URLs, logo, etc.)
  - name: Partner - Webhooks
    description: Configure webhook endpoints and inspect delivery history
  - name: Partner - Pricing
    description: >-
      Indicative pre-quote summaries (best / worst / averages) for partner
      integrations
paths:
  /partner/links:
    get:
      tags:
        - Partner - Magic Links
      summary: List magic links
      description: >-
        Returns a paginated list of magic links for the authenticated partner.
        Filter by visibility (active/expired), status, referenceId, and date
        range.
      operationId: LinksController_listLinks
      parameters:
        - name: page
          required: false
          in: query
          description: Page number (1-indexed)
          schema:
            minimum: 1
            default: 1
            example: 1
            type: number
        - name: limit
          required: false
          in: query
          description: Number of items per page
          schema:
            minimum: 1
            maximum: 100
            default: 20
            example: 20
            type: number
        - name: from
          required: false
          in: query
          description: Filter records created on or after this date (ISO 8601)
          schema:
            example: '2026-01-01T00:00:00.000Z'
            type: string
        - name: to
          required: false
          in: query
          description: Filter records created on or before this date (ISO 8601)
          schema:
            example: '2026-02-28T23:59:59.999Z'
            type: string
        - name: visibility
          required: false
          in: query
          description: >-
            Filter by link visibility. "active" returns links that have not
            expired and are not revoked. "expired" returns links whose expiresAt
            has passed but are not revoked. Omit to return all links regardless
            of expiration.
          schema:
            example: active
            enum:
              - active
              - expired
            type: string
        - name: status
          required: false
          in: query
          description: >-
            Filter by specific link status. Can be combined with the visibility
            filter. "created" = link not yet opened. "opened" = user has
            accessed the link. "revoked" = partner revoked the link.
          schema:
            example: opened
            enum:
              - created
              - opened
              - revoked
            type: string
        - name: referenceId
          required: false
          in: query
          description: Filter links by the partner reference ID of the associated user
          schema:
            example: user-12345
            type: string
      responses:
        '200':
          description: Paginated list of magic links
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ListLinksResponseDto'
        '401':
          description: Unauthorized — invalid or missing API key / bearer token
      security:
        - api-key: []
components:
  schemas:
    ListLinksResponseDto:
      type: object
      properties:
        success:
          type: boolean
          example: true
        data:
          $ref: '#/components/schemas/ListLinksDataDto'
      required:
        - success
        - data
    ListLinksDataDto:
      type: object
      properties:
        items:
          description: Array of magic links
          type: array
          items:
            $ref: '#/components/schemas/LinkListItemDto'
        pagination:
          $ref: '#/components/schemas/PaginationMetaDto'
      required:
        - items
        - pagination
    LinkListItemDto:
      type: object
      properties:
        linkId:
          type: string
          description: Unique link identifier
          example: link_acme_m2m_a1b2c3d4e5f6
        referenceId:
          type: string
          description: Reference ID of the user in your system
          example: user-12345
        externalId:
          type: string
          description: Partner tracing ID for this link/intent
          example: ORD-2026-001
        status:
          type: string
          description: Current link status
          example: created
          enum:
            - created
            - opened
            - revoked
        url:
          type: string
          description: Full widget URL
          example: >-
            https://flows.sandbox.raas-widgets.leapfinancial.com/link_acme_m2m_a1b2c3d4e5f6
        flow:
          type: string
          description: Flow slug that determines the widget experience
          example: m2m
        expiresAt:
          type: string
          description: Link expiration timestamp (ISO 8601)
          example: '2026-02-11T12:00:00.000Z'
        createdAt:
          type: string
          description: Link creation timestamp (ISO 8601)
          example: '2026-02-10T12:00:00.000Z'
        openedAt:
          type: string
          description: When the link was first opened by the end user (ISO 8601)
          example: '2026-02-10T13:00:00.000Z'
        userId:
          type: string
          description: M2M user ID (assigned after link is opened)
          example: user_acme_x1y2z3
        operationId:
          type: string
          description: Operation ID if a transfer was initiated
          example: op_acme_abc123
        config:
          type: object
          description: >-
            Flow-specific configuration (masked). Shape depends on `flow` (e.g.
            m2m exposes masked userData, flavor, themeMode).
      required:
        - linkId
        - referenceId
        - status
        - url
        - flow
        - expiresAt
        - createdAt
    PaginationMetaDto:
      type: object
      properties:
        page:
          type: number
          description: Current page number
          example: 1
        limit:
          type: number
          description: Number of items per page
          example: 20
        total:
          type: number
          description: Total number of items matching the query
          example: 85
        totalPages:
          type: number
          description: Total number of pages
          example: 5
      required:
        - page
        - limit
        - total
        - totalPages
  securitySchemes:
    api-key:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        Your partner API key. Use `raas_sandbox_*` keys for the sandbox
        environment and `raas_live_*` keys for production.

````