Event Connect API

Comprehensive API Documentation for Event Management System

Laravel 12.33.0 MySQL Sanctum Auth

Base URL

http://localhost:8000/api

Authentication

This API uses Laravel Sanctum for authentication. Include the Bearer token in the Authorization header for protected endpoints.

Authorization: Bearer {your-token-here}

Authentication Endpoints

POST /auth/register

Register a new user account

Request Body:

{
    "full_name": "John Doe",
    "email": "john@example.com",
    "password": "password123",
    "password_confirmation": "password123"
}

Response:

{
    "success": true,
    "message": "User registered successfully",
    "data": {
        "user": {
            "id": 1,
            "name": "John Doe",
            "full_name": "John Doe",
            "email": "john@example.com",
            "created_at": "2025-10-14T09:22:29.000000Z",
            "updated_at": "2025-10-14T09:22:29.000000Z"
        },
        "token": "1|hy0riaMP1xTEodrVb4a75xzutTKKMg2RitwI3eA97940a713",
        "token_type": "Bearer"
    }
}
POST /auth/login

Login with email and password

Request Body:

{
    "email": "john@example.com",
    "password": "password123"
}

Response:

{
    "success": true,
    "message": "Login successful",
    "data": {
        "user": {
            "id": 1,
            "name": "John Doe",
            "full_name": "John Doe",
            "email": "john@example.com",
            "phone": null,
            "bio": null,
            "avatar": null,
            "is_organizer": false,
            "email_verified_at": null,
            "created_at": "2025-10-14T09:22:29.000000Z",
            "updated_at": "2025-10-14T09:22:29.000000Z"
        },
        "token": "2|Yf53sZr53IWX4LL95axxguF8SuuhgnUNqaaYM8212f174190",
        "token_type": "Bearer"
    }
}
POST /auth/logout Auth Required

Logout and invalidate current token

GET /auth/me Auth Required

Get current authenticated user information

Profile Management

GET /profile Auth Required

Get user profile information

PUT /profile Auth Required

Update user profile information

Request Body:

{
    "full_name": "John Updated",
    "phone": "+1234567890",
    "bio": "Event enthusiast and organizer",
    "avatar": "path/to/avatar.jpg"
}
POST /profile/change-password Auth Required

Change user password

Request Body:

{
    "current_password": "oldpassword123",
    "password": "newpassword123",
    "password_confirmation": "newpassword123"
}

Event Management

GET /events

Get all published events (homepage)

Query Parameters:

?search=tech&category=1&is_paid=false&date=2025-10-15&page=1
GET /events/{id}

Get specific event details

POST /events Auth Required Organizer Only

Create a new event

Request Body:

{
    "title": "Tech Conference 2025",
    "description": "Annual technology conference",
    "location": "Convention Center, Jakarta",
    "start_date": "2025-12-15 09:00:00",
    "end_date": "2025-12-15 17:00:00",
    "category_id": 1,
    "is_paid": true,
    "price": 150000,
    "quota": 100,
    "image": "path/to/image.jpg"
}
PUT /events/{id} Auth Required Organizer Only

Update event information

DELETE /events/{id} Auth Required Organizer Only

Delete an event

GET /events/my-events Auth Required

Get events created by current user

GET /events/participating Auth Required

Get events user is participating in

Event Participation

POST /participants/join/{event_id} Auth Required

Join an event

POST /participants/cancel/{event_id} Auth Required

Cancel event participation

POST /participants/attendance Auth Required

Mark attendance via QR code scan

Request Body:

{
    "event_id": 1,
    "qr_data": "event_qr_code_data"
}
GET /participants/my-participations Auth Required

Get user's event participations

Feedback Summary (AI-Generated)

AI-powered feedback analysis and summary generation for event organizers

POST /events/{event_id}/feedback/generate-summary Auth Required Organizer Only

Generate AI summary for feedback event. Event must be ended, minimum 1 feedback required, and summary hasn't been generated before.

Response (201):

{
    "success": true,
    "message": "Feedback summary generated successfully",
    "data": {
        "summary": "Overall, participants enjoyed the event. The venue was praised for its accessibility and comfort...",
        "generated_at": "2024-12-06T10:30:00.000000Z",
        "feedback_count": 15,
        "average_rating": 4.5
    }
}

Error Responses:

// 400 - Event not ended yet
{
    "success": false,
    "message": "Cannot generate summary. Event has not ended yet."
}

// 400 - Summary already exists
{
    "success": false,
    "message": "Summary already generated for this event. Each event can only have one summary."
}

// 400 - Not enough feedback
{
    "success": false,
    "message": "Need at least 1 feedbacks to generate summary. Current: 0"
}
GET /events/{event_id}/feedback/summary Auth Required Organizer Only

Get AI-generated summary with statistics

Response (200):

{
    "success": true,
    "data": {
        "summary": "Overall, participants enjoyed the event...",
        "generated_at": "2024-12-06T10:30:00.000000Z",
        "feedback_count": 15,
        "current_feedback_count": 20,
        "average_rating": 4.5,
        "rating_distribution": {
            "5_star": 10,
            "4_star": 5,
            "3_star": 3,
            "2_star": 1,
            "1_star": 1
        }
    }
}
GET /events/{event_id}/feedback/summary/detailed Auth Required Organizer Only

Get detailed summary with all feedbacks and complete statistics

Response (200):

{
    "success": true,
    "data": {
        "summary": "Overall, participants enjoyed the event...",
        "generated_at": "2024-12-06T10:30:00.000000Z",
        "statistics": {
            "total_feedbacks": 20,
            "feedback_count_at_summary": 15,
            "average_rating": 4.5,
            "rating_distribution": {
                "5_star": 10,
                "4_star": 5,
                "3_star": 3,
                "2_star": 1,
                "1_star": 1
            }
        },
        "feedbacks": [
            {
                "id": 1,
                "rating": 5,
                "comment": "Great event! Very informative and well organized.",
                "created_at": "2024-12-06T10:30:00.000000Z",
                "user": {
                    "name": "John Doe",
                    "email": "john@example.com"
                }
            }
        ]
    }
}
PUT /events/{event_id}/feedback/summary Auth Required Organizer Only

Regenerate AI summary with latest feedbacks. Previous summary will be replaced.

Response (200):

{
    "success": true,
    "message": "Feedback summary updated successfully",
    "data": {
        "summary": "Updated summary based on all feedbacks...",
        "generated_at": "2024-12-06T11:00:00.000000Z",
        "feedback_count": 20,
        "average_rating": 4.6,
        "previous_feedback_count": 15
    }
}
DELETE /events/{event_id}/feedback/summary Auth Required Organizer Only

Delete AI-generated summary. Can be regenerated after deletion.

Response (200):

{
    "success": true,
    "message": "Feedback summary deleted successfully"
}

Notifications

GET /notifications Auth Required

Get user notifications with pagination

Query Parameters:

?unread_only=true&page=1

Response (200):

{
    "success": true,
    "data": {
        "current_page": 1,
        "data": [
            {
                "id": 1,
                "type": "event_reminder",
                "title": "Event Reminder",
                "message": "Reminder: Tech Conference 2024 on 15 Dec 2024",
                "is_read": false,
                "created_at": "2024-12-06T10:30:00.000000Z",
                "event": {
                    "id": 1,
                    "title": "Tech Conference 2024"
                }
            }
        ],
        "per_page": 20,
        "total": 100
    }
}
POST /notifications/{id}/read Auth Required

Mark notification as read

Response (200):

{
    "success": true,
    "message": "Notification marked as read"
}
POST /notifications/mark-all-read Auth Required

Mark all notifications as read

Response (200):

{
    "success": true,
    "message": "All notifications marked as read"
}
GET /notifications/unread-count Auth Required

Get unread notifications count

Response (200):

{
    "success": true,
    "data": {
        "unread_count": 5
    }
}
DELETE /notifications/{id} Auth Required

Delete a notification

Response (200):

{
    "success": true,
    "message": "Notification deleted successfully"
}
POST /notifications/send-reminder Auth Required

Send email reminder to event participants manually (for testing or admin trigger)

Request Body:

{
    "event_id": 1,
    "user_id": 24  // Optional: send to specific user only
}

Response (200) - All participants:

{
    "success": true,
    "message": "Event reminders sent successfully to 10 participant(s)"
}

Response (200) - Specific user:

{
    "success": true,
    "message": "Event reminder sent successfully to john@example.com"
}

Error Responses:

// 404 - No participants found
{
    "success": false,
    "message": "No participants found for this event"
}

// 500 - Failed to send
{
    "success": false,
    "message": "Failed to send event reminder: {error_message}"
}
GET /notifications/upcoming-reminders Auth Required

Get upcoming events in next 7 days that need reminder

Response (200):

{
    "success": true,
    "data": [
        {
            "event_id": 1,
            "event_title": "Tech Conference 2024",
            "start_date": "2024-12-15T09:00:00.000000Z",
            "end_date": "2024-12-15T17:00:00.000000Z",
            "days_until_event": 3,
            "location": "Jakarta Convention Center",
            "event_type": "online",
            "contact_info": "info@techconf.com"
        }
    ]
}

Categories

GET /categories

Get all active categories

Response:

{
    "success": true,
    "data": [
        {
            "id": 1,
            "name": "Technology",
            "description": "Tech conferences, workshops, and meetups",
            "color": "#3B82F6",
            "is_active": true,
            "created_at": "2025-10-14T09:13:18.000000Z",
            "updated_at": "2025-10-14T09:13:18.000000Z"
        }
    ]
}
POST /categories Auth Required Admin Only

Create a new category

PUT /categories/{id} Auth Required Admin Only

Update category information

DELETE /categories/{id} Auth Required Admin Only

Delete a category

Error Responses

Validation Error (422):

{
    "success": false,
    "message": "Validation errors",
    "errors": {
        "email": ["The email has already been taken."],
        "password": ["The password confirmation does not match."]
    }
}

Unauthorized (401):

{
    "message": "Unauthenticated."
}

Forbidden (403):

{
    "message": "This action is unauthorized."
}

Not Found (404):

{
    "message": "The route api/events/999 could not be found."
}

HTTP Status Codes

200 Success
401 Unauthorized
403 Forbidden
404 Not Found
422 Validation Error
500 Internal Server Error

Payment History API

GET /payments/history

Get payment history for authenticated user

Query Parameters:

{
    "status": "paid|pending|failed|cancelled",     // Optional
    "payment_method": "invoice|virtual_account|ewallet", // Optional
    "date_from": "2025-01-01",                    // Optional
    "date_to": "2025-12-31",                      // Optional
    "per_page": 10                                // Optional, default: 10
}

Response:

{
    "success": true,
    "data": {
        "payments": [
            {
                "id": 93,
                "event": {
                    "id": 9,
                    "title": "Digital Art Exhibition",
                    "start_date": "2025-11-24T16:25:39.000000Z",
                    "location": "Jakarta Art Gallery",
                    "price": "50000.00",
                    "organizer": {
                        "id": 3,
                        "name": "Sarah Johnson",
                        "email": "sarah@workshop.com"
                    },
                    "category": {
                        "id": 5,
                        "name": "Arts & Culture",
                        "color": "#8B5CF6"
                    }
                },
                "payment": {
                    "reference": "69024d448a9cf659daae6855",
                    "method": "invoice",
                    "status": "paid",
                    "amount": 50000,
                    "is_paid": true,
                    "paid_at": "2025-10-29T17:25:00.000000Z"
                },
                "participation": {
                    "status": "registered",
                    "attended_at": null,
                    "qr_code": "qr_codes/participants/user_24_event_9_1761757593_69024999af04a.svg",
                    "qr_code_url": "http://localhost:8000/storage/qr_codes/participants/user_24_event_9_1761757593_69024999af04a.svg"
                }
            }
        ],
        "pagination": {
            "current_page": 1,
            "last_page": 1,
            "per_page": 10,
            "total": 2,
            "from": 1,
            "to": 2,
            "has_more_pages": false
        },
        "summary": {
            "total_payments": 2,
            "total_paid": 100000,
            "total_pending": 0,
            "total_failed": 0
        }
    }
}
GET /payments/statistics

Get payment statistics for authenticated user

Query Parameters:

{
    "date_from": "2024-01-01",    // Optional, default: 12 months ago
    "date_to": "2025-12-31"       // Optional, default: now
}

Response:

{
    "success": true,
    "data": {
        "period": {
            "from": "2024-01-01T00:00:00.000000Z",
            "to": "2025-12-31T23:59:59.000000Z"
        },
        "status_breakdown": {
            "paid": {"count": 5, "total_amount": 250000},
            "pending": {"count": 2, "total_amount": 100000},
            "failed": {"count": 1, "total_amount": 50000}
        },
        "method_breakdown": {
            "invoice": {"count": 6, "total_amount": 300000},
            "virtual_account": {"count": 2, "total_amount": 100000}
        },
        "monthly_trends": [
            {"month": "2025-01", "count": 2, "total_amount": 100000},
            {"month": "2025-02", "count": 3, "total_amount": 150000}
        ],
        "category_breakdown": [
            {"category_name": "Technology", "count": 4, "total_amount": 200000},
            {"category_name": "Arts & Culture", "count": 2, "total_amount": 100000}
        ],
        "summary": {
            "total_payments": 8,
            "total_amount": 400000,
            "average_amount": 50000,
            "success_rate": 87.5
        }
    }
}

Xendit Payment Gateway API

POST /payments/create

Create payment for event using Xendit

Request Body:

{
    "event_id": 9,
    "payment_method": "invoice",
    "bank_code": "BCA",           // Optional: untuk virtual_account
    "ewallet_type": "OVO"         // Optional: untuk ewallet
}

Payment Methods:

  • invoice - Credit Card (Snap Xendit)
  • virtual_account - Virtual Account (BCA, BNI, BRI, MANDIRI)
  • ewallet - E-Wallet (OVO, DANA, LINKAJA, SHOPEEPAY)

Response:

{
    "success": true,
    "message": "Payment created successfully",
    "data": {
        "participant": {
            "id": 93,
            "user_id": 24,
            "event_id": 9,
            "status": "registered",
            "is_paid": false,
            "amount_paid": null,
            "payment_reference": "690251be8a9cf659daae6bcb",
            "qr_code": "qr_codes/participants/user_24_event_9_1761757593_69024999af04a.svg",
            "qr_code_string": "user_24_event_9_1761757593_69024999af04a",
            "payment_url": null,
            "payment_status": "pending",
            "payment_method": null,
            "attended_at": null,
            "created_at": "2025-10-29T17:05:28.000000Z",
            "updated_at": "2025-10-29T17:22:13.000000Z"
        },
        "payment_url": "https://checkout-staging.xendit.co/web/690251be8a9cf659daae6bcb",
        "payment_reference": "690251be8a9cf659daae6bcb",
        "payment_method": "invoice",
        "event": {
            "id": 9,
            "title": "Digital Art Exhibition",
            "start_date": "2025-11-24T16:25:39.000000Z",
            "location": "Jakarta Art Gallery"
        },
        "attendance_qr": {
            "qr_code": "qr_codes/participants/user_24_event_9_1761757593_69024999af04a.svg",
            "qr_code_url": "http://localhost:8000/storage/qr_codes/participants/user_24_event_9_1761757593_69024999af04a.svg",
            "qr_code_string": "user_24_event_9_1761757593_69024999af04a",
            "message": "Use this QR code for attendance check-in at the event"
        }
    }
}
GET /payments/methods

Get available payment methods

Response:

{
    "success": true,
    "data": {
        "invoice": {
            "name": "Credit Card",
            "description": "Pay with credit card via Xendit",
            "icon": "credit-card"
        },
        "virtual_account": {
            "name": "Virtual Account",
            "description": "Pay via bank transfer",
            "banks": ["BCA", "BNI", "BRI", "MANDIRI"]
        },
        "ewallet": {
            "name": "E-Wallet",
            "description": "Pay with digital wallet",
            "providers": ["OVO", "DANA", "LINKAJA", "SHOPEEPAY"]
        }
    }
}
POST /payments/webhook

Xendit webhook endpoint (called by Xendit)

Headers:

{
    "X-Xendit-Signature": "{webhook_signature}",
    "Content-Type": "application/json"
}

Webhook Payload (from Xendit):

{
    "id": "690251be8a9cf659daae6bcb",
    "external_id": "event_9_participant_93_1761757593_69024999af04a",
    "user_id": "5e8b4c4b4b4b4b4b4b4b4b4b",
    "status": "PAID",
    "merchant_name": "Event Connect",
    "amount": 50000,
    "description": "Payment for event: Digital Art Exhibition",
    "invoice_url": "https://checkout-staging.xendit.co/web/690251be8a9cf659daae6bcb",
    "expiry_date": "2025-10-30T17:22:13.000Z",
    "created": "2025-10-29T17:22:13.000Z",
    "updated": "2025-10-29T17:25:00.000Z",
    "currency": "IDR",
    "paid_at": "2025-10-29T17:25:00.000Z",
    "payment_method": "CREDIT_CARD",
    "payment_channel": "CREDIT_CARD",
    "payment_destination": "CREDIT_CARD"
}

Super Admin API

APIs for Super Admin to manage all event organizers and events

GET /super-admin/organizers

Get all event organizers with their events

Query Parameters:

{
    "search": "john",                    // Optional: search by name/email
    "status": "active|inactive",         // Optional: filter by status
    "per_page": 10                       // Optional, default: 10
}

Response:

{
    "success": true,
    "data": {
        "organizers": [
            {
                "id": 3,
                "name": "Sarah Johnson",
                "email": "sarah@workshop.com",
                "phone": "+6281234567890",
                "bio": "Event management expert",
                "avatar": null,
                "role": "admin",
                "is_organizer": true,
                "created_at": "2025-10-14T09:22:29.000000Z",
                "updated_at": "2025-10-14T09:22:29.000000Z",
                "events": {
                    "total": 5,
                    "published": 3,
                    "draft": 1,
                    "completed": 1,
                    "cancelled": 0,
                    "total_participants": 150,
                    "total_revenue": 750000,
                    "recent_events": [
                        {
                            "id": 9,
                            "title": "Digital Art Exhibition",
                            "status": "published",
                            "start_date": "2025-11-24T16:25:39.000000Z",
                            "location": "Jakarta Art Gallery",
                            "price": 50000,
                            "is_paid": true,
                            "registered_count": 25,
                            "quota": 100,
                            "category": {
                                "id": 5,
                                "name": "Arts & Culture",
                                "color": "#8B5CF6"
                            },
                            "created_at": "2025-10-29T16:25:39.000000Z"
                        }
                    ]
                }
            }
        ],
        "pagination": {
            "current_page": 1,
            "last_page": 1,
            "per_page": 10,
            "total": 5,
            "from": 1,
            "to": 5,
            "has_more_pages": false
        }
    }
}
GET /super-admin/events

Get all events from all organizers

Query Parameters:

{
    "search": "conference",              // Optional: search by title/description
    "status": "published|draft|completed|cancelled", // Optional
    "category_id": 1,                    // Optional: filter by category
    "organizer_id": 3,                   // Optional: filter by organizer
    "date_from": "2025-01-01",           // Optional
    "date_to": "2025-12-31",             // Optional
    "per_page": 10                       // Optional, default: 10
}

Response:

{
    "success": true,
    "data": {
        "events": [
            {
                "id": 9,
                "title": "Digital Art Exhibition",
                "description": "Contemporary digital art exhibition...",
                "location": "Jakarta Art Gallery",
                "start_date": "2025-11-24T16:25:39.000000Z",
                "end_date": "2025-11-24T18:25:39.000000Z",
                "price": "50000.00",
                "is_paid": true,
                "quota": 100,
                "registered_count": 25,
                "status": "published",
                "is_active": true,
                "image": "events/digital-art-exhibition.jpg",
                "qr_code": "qr_codes/event_1234567890_abc123.svg",
                "created_at": "2025-10-29T16:25:39.000000Z",
                "updated_at": "2025-10-29T16:25:39.000000Z",
                "organizer": {
                    "id": 3,
                    "name": "Sarah Johnson",
                    "email": "sarah@workshop.com",
                    "phone": "+6281234567890",
                    "role": "admin"
                },
                "category": {
                    "id": 5,
                    "name": "Arts & Culture",
                    "color": "#8B5CF6"
                },
                "participants": {
                    "total": 25,
                    "attended": 15,
                    "registered": 10,
                    "cancelled": 0
                }
            }
        ],
        "pagination": {
            "current_page": 1,
            "last_page": 3,
            "per_page": 10,
            "total": 25,
            "from": 1,
            "to": 10,
            "has_more_pages": true
        }
    }
}
GET /super-admin/statistics

Get overall statistics for all organizers and events

Query Parameters:

{
    "date_from": "2024-01-01",    // Optional, default: 12 months ago
    "date_to": "2025-12-31"       // Optional, default: now
}

Response:

{
    "success": true,
    "data": {
        "statistics": {
            "total_organizers": 15,
            "total_events": 150,
            "total_participants": 5000,
            "total_revenue": 25000000
        },
        "period_statistics": {
            "organizers": 10,
            "events": 75,
            "participants": 2500,
            "revenue": 12500000
        },
        "event_status_breakdown": {
            "published": 100,
            "draft": 25,
            "completed": 20,
            "cancelled": 5
        },
        "monthly_trends": [
            {"month": "2025-01", "count": 10, "total_amount": 5000000},
            {"month": "2025-02", "count": 15, "total_amount": 7500000}
        ],
        "top_organizers": [
            {
                "id": 3,
                "name": "Sarah Johnson",
                "email": "sarah@workshop.com",
                "events_count": 25
            }
        ],
        "category_breakdown": [
            {"name": "Technology", "count": 50, "total_amount": 10000000},
            {"name": "Arts & Culture", "count": 30, "total_amount": 6000000}
        ]
    }
}
POST /super-admin/organizers/{id}/toggle-status

Toggle organizer status (activate/deactivate)

Response:

{
    "success": true,
    "message": "Organizer status updated successfully",
    "data": {
        "user": {
            "id": 3,
            "name": "Sarah Johnson",
            "email": "sarah@workshop.com",
            "is_organizer": true
        }
    }
}
GET /super-admin/organizers/{id}

Get detailed information about a specific organizer

Response:

{
    "success": true,
    "data": {
        "id": 3,
        "name": "Sarah Johnson",
        "email": "sarah@workshop.com",
        "phone": "+6281234567890",
        "bio": "Event management expert",
        "avatar": null,
        "role": "admin",
        "is_organizer": true,
        "created_at": "2025-10-14T09:22:29.000000Z",
        "events": [
            {
                "id": 9,
                "title": "Digital Art Exhibition",
                "description": "Contemporary digital art exhibition...",
                "location": "Jakarta Art Gallery",
                "start_date": "2025-11-24T16:25:39.000000Z",
                "end_date": "2025-11-24T18:25:39.000000Z",
                "price": "50000.00",
                "is_paid": true,
                "quota": 100,
                "registered_count": 25,
                "status": "published",
                "is_active": true,
                "category": {
                    "id": 5,
                    "name": "Arts & Culture",
                    "color": "#8B5CF6"
                },
                "participants": {
                    "total": 25,
                    "attended": 15,
                    "registered": 10,
                    "cancelled": 0
                },
                "created_at": "2025-10-29T16:25:39.000000Z"
            }
        ]
    }
}

Admin Dashboard API

API untuk organizer (role admin) untuk melihat ringkasan aktivitas dan kinerja event mereka

GET /admin/dashboard Auth Required Organizer Only

Get organizer dashboard overview: stats, recent activities, monthly events, top events, and category breakdown

Response (200):

{
    "success": true,
    "data": {
        "stats": {
            "total_users": 120,
            "total_events": 8,
            "total_categories": 5,
            "total_participants": 340,
            "active_events": 3,
            "completed_events": 5,
            "this_month_events": 2,
            "this_month_participants": 45
        },
        "recent_activities": [
            {
                "type": "user_joined",
                "message": "User John Doe joined 'Tech Conference 2025'",
                "time": "2025-10-29T17:05:28.000000Z",
                "icon": "user-plus",
                "color": "green"
            }
        ],
        "monthly_events": {
            "months": ["Jan 2025", "Feb 2025", ..., "Oct 2025"],
            "events": [1, 0, 2, 1, 0, 1, 2, 0, 1, 0, 0, 2]
        },
        "category_stats": [
            {
                "id": 1,
                "name": "Technology",
                "count": 5,
                "color": "#3B82F6"
            }
        ],
        "top_events": [
            {
                "id": 9,
                "title": "Digital Art Exhibition",
                "participants_count": 25,
                "organizer": {
                    "id": 3,
                    "full_name": "Sarah Johnson"
                },
                "category": {
                    "id": 5,
                    "name": "Arts & Culture",
                    "color": "#8B5CF6"
                }
            }
        ]
    }
}

Analytics API

API untuk organizer (role admin) untuk melihat analitik kinerja event mereka dalam rentang waktu tertentu

GET /analytics Auth Required Organizer Only

Get detailed analytics: key metrics, monthly/event/user/revenue trends, category & top events

Query Parameters:

?date_range=30  // Days (default: 30)

Response (200):

{
    "success": true,
    "data": {
        "stats": {
            "total_revenue": 500000,
            "avg_rating": 4.5,
            "conversion_rate": 87.5,
            "active_users": 120,
            "new_users": 30,
            "total_participants": 340,
            "total_feedbacks": 20
        },
        "monthlyTrends": [
            {
                "month": "Jan 2025",
                "events": 2
            }
        ],
        "categoryAnalytics": [
            {
                "name": "Technology",
                "events_count": 4,
                "color": "#3B82F6"
            }
        ],
        "userAnalytics": {
            "user_trends": [
                {"date": "2025-10-29", "count": 15}
            ]
        },
        "eventAnalytics": {
            "event_trends": [
                {"date": "2025-10-28", "count": 1}
            ]
        },
        "revenueAnalytics": {
            "revenue_trends": [
                {"date": "2025-10-29", "revenue": 50000}
            ]
        },
        "topEvents": [
            {
                "title": "Digital Art Exhibition",
                "participants_count": 25,
                "price": 50000,
                "category": {
                    "name": "Arts & Culture",
                    "color": "#8B5CF6"
                }
            }
        ],
        "date_range": {
            "days": 30,
            "start_date": "2025-10-07",
            "end_date": "2025-11-06"
        }
    }
}
POST /analytics/export Auth Required Organizer Only

Export analytics data as PDF (only PDF supported)

Request Body (optional):

{
    "date_range": 30
}

Response (200):

{
    "success": true,
    "message": "PDF exported successfully",
    "data": {
        "url": "http://localhost:8000/storage/exports/analytics_export_2025-12-06_143022.pdf",
        "filename": "analytics_export_2025-12-06_143022.pdf"
    }
}

Event Connect API Documentation - Generated on 2026-02-02 15:37:11

Built with Laravel 12.33.0 & Tailwind CSS