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

# Export transactions to CSV for a bucket

> Export transactions to a CSV file for a specific bucket with optional date range filtering, An email will be sent to you, including the CSV file.



## OpenAPI

````yaml get /api/buckets/export_csv
openapi: 3.0.3
info:
  title: Athena API
  version: v3
  x-logo:
    url: https://cynopsis.co/wp-content/uploads/2021/03/logo-2.png
    altText: Cynopsis Solutions
  description: >-
    ATHENA is an advanced real-time transaction monitoring solution designed to
    detect and prevent money laundering, fraud, and terrorism financing. Powered
    by proprietary AML rules, ATHENA analyzes transactions in real time,
    providing clear, intuitive visual insights to streamline compliance
    processes.
        
        ✅ Real-Time Monitoring – Instantly analyzes transaction data to detect anomalies and potential compliance risks.
        ✅ Visualized Insights – Converts complex data into easy-to-understand charts, aiding faster decision-making.
        ✅ Seamless Integration – Easily integrates with existing financial and compliance systems.
        
        Ideal for financial institutions, fintech companies, and regulated businesses, ATHENA enhances risk management and ensures regulatory compliance with ease.
  contact:
    email: tech@cynopsis.co
servers:
  - url: http://localhost/api
    description: Local development server
security: []
paths:
  /api/buckets/export_csv:
    get:
      tags:
        - Buckets
      summary: Export transactions to CSV for a bucket
      description: >-
        Export transactions to a CSV file for a specific bucket with optional
        date range filtering, An email will be sent to you, including the CSV
        file.
      operationId: bucket_export_csv
      parameters:
        - in: query
          name: bucketId
          schema:
            type: integer
          description: Bucket ID.
          required: true
        - in: query
          name: max_date
          schema:
            type: string
          description: Maximum date in format YYYY-MM-DD.
          required: true
        - in: query
          name: min_date
          schema:
            type: string
          description: Minimum date in format YYYY-MM-DD.
          required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                    description: >-
                      Success message containing how many transactions were
                      exported.
          description: CSV export initiated successfully.
      security:
        - CustomAuthentication: []
        - cookieAuth: []
        - BearerAuth: []
components:
  securitySchemes:
    CustomAuthentication:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: JWT token obtained from AWS Cognito or custom authentication service
    cookieAuth:
      type: apiKey
      in: cookie
      name: sessionid

````