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

# تصدير تحليلات التحويلات

> صدّر تحليلات تتبع التحويلات المجمّعة بصيغ CSV أو XLS أو XLSX، مع إمكانية التصفية حسب رمز QR أو الفئة أو المستخدم أو المدة الزمنية.

## معاملات الاستعلام

| المعامل             | النوع                 | مطلوب | الوصف                                                                                                                                           |
| :------------------ | :-------------------- | :---- | :---------------------------------------------------------------------------------------------------------------------------------------------- |
| `type`              | `string`              | لا    | الأقسام مفصولة بفواصل. والمعتاد: `count,trend,event_breakdown,site_breakdown,funnel,scan_overview,hybrid_funnel`.                               |
| `from`              | `string (YYYY-MM-DD)` | نعم   | تاريخ البداية، شاملًا.                                                                                                                          |
| `to`                | `string (YYYY-MM-DD)` | نعم   | تاريخ النهاية، شاملًا.                                                                                                                          |
| `file_format`       | `string`              | نعم   | إحدى القيم: `csv` أو `xls` أو `xlsx`.                                                                                                           |
| `sheet`             | `string`              | لا    | لصيغة CSV فقط: مفتاح الورقة المختارة. أمثلة: `count` و`trend` و`event_breakdown` و`site_breakdown` و`funnel` و`hybrid_funnel` و`scan_overview`. |
| `all`               | `boolean`             | لا    | تضمين كل رموز QR ضمن النطاق.                                                                                                                    |
| `search`            | `string`              | لا    | قيمة البحث المستخدمة مع `all=true`.                                                                                                             |
| `category`          | `string`              | لا    | معرّفات الفئات مفصولة بفواصل.                                                                                                                   |
| `users`             | `string`              | لا    | معرّفات المستخدمين مفصولة بفواصل.                                                                                                               |
| `conversion_events` | `string`              | لا    | مفاتيح أحداث التحويل مفصولة بفواصل.                                                                                                             |
| `funnel_steps`      | `string`              | لا    | مفاتيح الأحداث مرتبة ومفصولة بفواصل لحساب مسار التحويل.                                                                                         |

## محتوى الطلب

| الحقل       | النوع           | مطلوب | الوصف                                 |
| :---------- | :-------------- | :---- | :------------------------------------ |
| `filter_by` | `string`        | نعم   | إحدى القيم: `qrid` أو `id` أو `tags`. |
| `q`         | `array[string]` | نعم   | القيم المقابلة لـ `filter_by`.        |

## مثال

```bash theme={null}
curl -X POST "https://api.scanova.io/analytics/ct/export/?type=count,trend,event_breakdown,site_breakdown,funnel,scan_overview,hybrid_funnel&from=2026-03-03&to=2026-03-10&file_format=xlsx" \
  -H "Authorization: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "filter_by": "qrid",
    "q": ["Q20a18d4af3e947a1"]
  }'
```


## OpenAPI

````yaml POST /analytics/ct/export/
openapi: 3.0.0
info:
  title: Scanova API - Analytics
  description: >-
    Analytics endpoints for retrieving QR code scan data, statistics, and
    exporting analytics reports. These endpoints provide comprehensive insights
    into QR code performance, user behavior, and geographic distribution.
  version: 1.0.0
servers:
  - url: https://api.scanova.io
    description: Scanova Management API Server
security:
  - apiKeyAuth: []
paths:
  /analytics/ct/export/:
    post:
      tags:
        - Analytics
      summary: Export Conversion Analytics
      description: Export aggregated conversion analytics in CSV/XLS/XLSX.
      parameters:
        - name: type
          in: query
          required: false
          schema:
            type: string
          description: Comma-separated analytics sections.
        - name: from
          in: query
          required: true
          schema:
            type: string
            format: date
        - name: to
          in: query
          required: true
          schema:
            type: string
            format: date
        - name: file_format
          in: query
          required: true
          schema:
            type: string
            enum:
              - csv
              - xls
              - xlsx
        - name: sheet
          in: query
          required: false
          schema:
            type: string
          description: CSV sheet key.
        - name: all
          in: query
          required: false
          schema:
            type: boolean
        - name: search
          in: query
          required: false
          schema:
            type: string
        - name: category
          in: query
          required: false
          schema:
            type: string
        - name: users
          in: query
          required: false
          schema:
            type: string
        - name: conversion_events
          in: query
          required: false
          schema:
            type: string
        - name: funnel_steps
          in: query
          required: false
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - filter_by
                - q
              properties:
                filter_by:
                  type: string
                  enum:
                    - qrid
                    - id
                    - tags
                q:
                  type: array
                  items:
                    type: string
      responses:
        '200':
          description: File generated successfully
          content:
            text/csv:
              schema:
                type: string
                format: binary
            application/vnd.ms-excel:
              schema:
                type: string
                format: binary
            application/vnd.openxmlformats-officedocument.spreadsheetml.sheet:
              schema:
                type: string
                format: binary
      security:
        - apiKeyAuth: []
components:
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
      description: >-
        API key authentication. Enter your API key directly in the Authorization
        header.

````