### GET /business/{businessId}/product Source: https://api.tricolors.app/api-docs.json Get all products for a specific business. Can be filtered by category. ```markdown ### Parameters - **businessId** (string, path, required) - **categoryId** (string, query, optional) ### Responses #### 200 - Products retrieved successfully - Array of object - **id** (integer) (required) - **categoryId** (integer) (required) - **productName** (string) (required) - **sku** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) (required) ("on"|"off"|"temporal_off"|"custom") - **fileId** (string,null) (required) - **discountPercentage** (number,null) (required) - **discountStartAt** (string,null) (required) - **discountEndAt** (string,null) (required) - **discountActive** (boolean,null) (required) - **visibilityStartAt** (string,null) (required) - **visibilityEndAt** (string,null) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/product?categoryId=string" ``` ``` -------------------------------- ### GET /ping Source: https://api.tricolors.app/api-docs.json This endpoint checks if the server is running and responsive. ```markdown ### Responses #### 200 - Ping response ### Example Usage ```bash curl -X GET "https://api.tricolors.app/ping" ``` ``` -------------------------------- ### GET /business/{businessId}/course Source: https://api.tricolors.app/api-docs.json Get all courses for a specific business. Can be filtered by category. ```markdown ### Parameters - **businessId** (string, path, required) - **categoryId** (string, query, optional) ### Responses #### 200 - Courses retrieved successfully - Array of object - **id** (integer) (required) - **categoryId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) (required) ("on"|"off"|"temporal_off"|"custom") - **eventId** (integer,null) (required) - **fileId** (string,null) (required) - **maxUsers** (integer,null) (required) - **language** (string,null) (required) - **discountPercentage** (number,null) (required) - **discountStartAt** (string,null) (required) - **discountEndAt** (string,null) (required) - **discountActive** (boolean,null) (required) - **visibilityStartAt** (string,null) (required) - **visibilityEndAt** (string,null) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/course?categoryId=string" ``` ``` -------------------------------- ### GET /business/{businessId}/schedule/available Source: https://api.tricolors.app/api-docs.json Get all available schedules for a business. ```markdown ### Parameters - **businessId** (string, path, required) ### Responses #### 200 - Available schedules retrieved successfully - Array of object - **id** (integer) (required) - **businessId** (integer) (required) - **name** (string) (required) - **timezone** (string) (required) - **isDefault** (boolean) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/schedule/available" ``` ``` -------------------------------- ### GET /business/{businessId}/activities Source: https://api.tricolors.app/api-docs.json Get all activities for a business. ```markdown ### Parameters - **businessId** (string, path, required) ### Responses #### 200 - Activities retrieved successfully - Array of object - **id** (integer) (required) - **availableId** (integer) (required) - **name** (string) (required) - **description** (string,null) (required) - **duration** (integer) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/activities" ``` ``` -------------------------------- ### GET /public/business/{businessId}/products Source: https://api.tricolors.app/api-docs.json Retrieve public products for a business, optionally filtered by category. Requires product module to be active. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) - **categoryId** (string, query, optional): Optional category ID to filter products (example: 1) ### Responses #### 200 - Public products retrieved successfully #### 400 - Invalid request parameters #### 403 - Module not active #### 404 - Business or category not found ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}/products?categoryId=1" ``` ``` -------------------------------- ### GET /business/{businessId}/service Source: https://api.tricolors.app/api-docs.json Get all services for a specific business. Can be filtered by category. ```markdown ### Parameters - **businessId** (string, path, required) - **categoryId** (string, query, optional) ### Responses #### 200 - Services retrieved successfully - Array of object - **id** (integer) (required) - **categoryId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) (required) ("on"|"off"|"temporal_off"|"custom") - **eventId** (integer,null) (required) - **fileId** (string,null) (required) - **discountPercentage** (number,null) (required) - **discountStartAt** (string,null) (required) - **discountEndAt** (string,null) (required) - **discountActive** (boolean,null) (required) - **visibilityStartAt** (string,null) (required) - **visibilityEndAt** (string,null) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/service?categoryId=string" ``` ``` -------------------------------- ### GET /public/business/{businessId}/courses/{courseId}/available-blocks Source: https://api.tricolors.app/api-docs.json Returns available time slots for a course on a given date, considering schedule blocks, existing appointments, and course capacity. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) - **courseId** (string, path, required): The unique identifier of the course (example: 1) - **date** (string, query, required): Date to check availability (YYYY-MM-DD) (example: "2024-09-18") ### Responses #### 200 - Available time slots for the course #### 404 - Course, business, or event not found ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}/courses/{courseId}/available-blocks?date=2024-09-18" ``` ``` -------------------------------- ### GET /business/{businessId}/schedule/available/{availableId}/blocks Source: https://api.tricolors.app/api-docs.json Get all schedule blocks for an available schedule. ```markdown ### Parameters - **businessId** (string, path, required) - **availableId** (string, path, required) ### Responses #### 200 - Schedule blocks retrieved successfully - **schedule** (object) (required) - **id** (integer) (required) - **businessId** (integer) (required) - **name** (string) (required) - **timezone** (string) (required) - **isDefault** (boolean) (required) - **createdAt** (string (date)) (required) - **blocks** (array (object)) (required) Array items: - **id** (integer) (required) - **availableId** (integer) (required) - **dayOfWeek** (integer) (required) - **startTime** (string) (required) - **endTime** (string) (required) - **createdAt** (string (date)) (required) - **dayName** (string) (required) - **displayStartTime** (string) (required) - **displayEndTime** (string) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/schedule/available/{availableId}/blocks" ``` ``` -------------------------------- ### GET /business/list Source: https://api.tricolors.app/api-docs.json Retrieve a list of businesses associated with the authenticated user. ```markdown ### Responses #### 200 - List of businesses retrieved successfully - Array of object - **id** (integer) (required) - **userId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **phone** (string) (required) - **createdAt** (string (date)) (required) - **information** (object,null) (required) - **location** (object,null) (required) - **modules** (array (object)) (required) Array items: - **id** (integer) (required) - **businessId** (integer) (required) - **name** (string (product|service|course|eventos)) (required) ("product"|"service"|"course"|"eventos") - **status** (boolean) (required) - **createdAt** (string (date)) (required) - **socialNetworks** (array (object)) (required) Array items: - **id** (integer) (required) - **businessId** (integer) (required) - **name** (string) (required) - **url** (string) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/list" ``` ``` -------------------------------- ### GET /business/{businessId}/appointments Source: https://api.tricolors.app/api-docs.json Get all appointments for services and courses belonging to the business. Only accessible by business owners. ```markdown ### Parameters - **businessId** (string, path, required) - **status** (string (pending|confirmed|cancelled|completed), query, optional): Filter appointments by status (example: "confirmed") - **date** (string, query, optional): Filter appointments by specific date (example: "2024-01-15") ### Responses #### 200 - Appointments retrieved successfully - Array of object - **id** (number) (required): Appointment ID (example: 1) - **customerName** (string) (required): Customer name (example: "Juan Pérez") - **customerEmail** (string) (required): Customer email (example: "juan.perez@example.com") - **customerPhone** (string,null) (required): Customer phone number (example: "+1234567890") - **customerNotes** (string,null) (required): Customer notes (example: "First time customer") - **appointmentDate** (string) (required): Appointment date in YYYY-MM-DD format (example: "2024-01-15") - **appointmentTime** (string) (required): Appointment time in HH:MM format (example: "10:30") - **duration** (number) (required): Duration in minutes (example: 60) - **status** (string (pending|confirmed|cancelled|completed)) (required): Appointment status (example: "confirmed") ("pending"|"confirmed"|"cancelled"|"completed") - **totalPrice** (number) (required): Total price for the appointment (example: 50) - **createdAt** (string) (required): When the appointment was created (example: "2024-01-01T12:00:00.000Z") - **service** (object,null) (required): Service information (if appointment is for a service) - **course** (object,null) (required): Course information (if appointment is for a course) - **event** (object) (required): Event information for the appointment - **id** (number) (required) - **name** (string) (required) - **description** (string,null) (required) - **duration** (number) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/appointments?status=confirmed&date=2024-01-15" ``` ``` -------------------------------- ### GET /file/{id} Source: https://api.tricolors.app/api-docs.json This endpoint retrieves a file stored in Tricolor R2 by its database ID. ```markdown ### Parameters - **id** (string, path, required): The database ID of the file to retrieve (example: "123") ### Responses #### 200 - File retrieved successfully #### 404 - File not found - **error** (string) (required): Error message when file is not found (example: "File not found") ### Example Usage ```bash curl -X GET "https://api.tricolors.app/file/{id}" ``` ``` -------------------------------- ### GET /business/{businessId}/team/invitations Source: https://api.tricolors.app/api-docs.json List all pending invitations for the business (not yet accepted). ```markdown ### Parameters - **businessId** (string, path, required) ### Responses #### 200 - Pending invitations list retrieved successfully - Array of object - **id** (number) (required) - **invitedEmail** (string) (required) - **invitationToken** (string) (required) - **expiresAt** (string,null) (required) - **maxUses** (number,null) (required) - **currentUses** (number) (required) - **isActive** (boolean) (required) - **createdAt** (string) (required) - **isExpired** (boolean) (required) - **isMaxedOut** (boolean) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/team/invitations" ``` ``` -------------------------------- ### GET /public/business/{businessId}/courses/{courseId}/available-days Source: https://api.tricolors.app/api-docs.json Returns available days for a course in a specific month, considering schedule blocks, existing appointments, and course capacity. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) - **courseId** (string, path, required): The unique identifier of the course (example: 1) - **year** (string, query, required): Year to check availability (example: 2024) - **month** (string, query, required): Month to check availability (1-12) (example: 9) ### Responses #### 200 - Available days for the course in the specified month #### 400 - Invalid request parameters #### 404 - Course, business, or event not found ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}/courses/{courseId}/available-days?year=2024&month=9" ``` ``` -------------------------------- ### GET /business/{businessId}/appointments/count Source: https://api.tricolors.app/api-docs.json Get the count of appointments grouped by status for services and courses belonging to the business. Only accessible by business owners. ```markdown ### Parameters - **businessId** (string, path, required) ### Responses #### 200 - Appointment counts retrieved successfully - **pending** (number) (required): Count of pending appointments (example: 3) - **confirmed** (number) (required): Count of confirmed appointments (example: 4) - **cancelled** (number) (required): Count of cancelled appointments (example: 7) - **completed** (number) (required): Count of completed appointments (example: 9) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/appointments/count" ``` ``` -------------------------------- ### GET /business/{businessId}/team/members Source: https://api.tricolors.app/api-docs.json List all team members who have accepted invitations to the business. ```markdown ### Parameters - **businessId** (string, path, required) ### Responses #### 200 - Team members list retrieved successfully - Array of object - **userId** (number) (required) - **email** (string) (required) - **isActive** (boolean) (required) - **joinedAt** (string) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/team/members" ``` ``` -------------------------------- ### GET /public/business/{businessId}/courses Source: https://api.tricolors.app/api-docs.json Retrieve public courses for a business, optionally filtered by category. Requires course module to be active. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) - **categoryId** (string, query, optional): Optional category ID to filter courses (example: 1) ### Responses #### 200 - Public courses retrieved successfully #### 400 - Invalid request parameters #### 403 - Module not active #### 404 - Business or category not found ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}/courses?categoryId=1" ``` ``` -------------------------------- ### GET /public/business/{businessId}/services/{serviceId}/available-blocks Source: https://api.tricolors.app/api-docs.json Returns available time slots for a service on a given date, considering schedule blocks and existing appointments. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) - **serviceId** (string, path, required): The unique identifier of the service (example: 1) - **date** (string, query, required): Date to check availability (YYYY-MM-DD) (example: "2024-09-18") ### Responses #### 200 - Available time slots for the service #### 404 - Service, business, or event not found ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}/services/{serviceId}/available-blocks?date=2024-09-18" ``` ``` -------------------------------- ### GET /public/business/{businessId}/courses/{courseId}/appointments/{appointmentId} Source: https://api.tricolors.app/api-docs.json Retrieve a specific course appointment by its ID. Includes course and event information. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) - **courseId** (string, path, required): The unique identifier of the course (example: 1) - **appointmentId** (string, path, required): The unique identifier of the appointment (example: 123) ### Responses #### 200 - Course appointment retrieved successfully #### 404 - Appointment, course, or business not found ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}/courses/{courseId}/appointments/{appointmentId}" ``` ``` -------------------------------- ### GET /public/business/{businessId}/services Source: https://api.tricolors.app/api-docs.json Retrieve public services for a business, optionally filtered by category. Requires service module to be active. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) - **categoryId** (string, query, optional): Optional category ID to filter services (example: 1) ### Responses #### 200 - Public services retrieved successfully #### 400 - Invalid request parameters #### 403 - Module not active #### 404 - Business or category not found ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}/services?categoryId=1" ``` ``` -------------------------------- ### GET /public/business/{businessId}/services/{serviceId}/available-days Source: https://api.tricolors.app/api-docs.json Returns available days for a service in a specific month, considering schedule blocks and existing appointments. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) - **serviceId** (string, path, required): The unique identifier of the service (example: 1) - **year** (string, query, required): Year to check availability (example: 2024) - **month** (string, query, required): Month to check availability (1-12) (example: 9) ### Responses #### 200 - Available days for the service in the specified month #### 400 - Invalid request parameters #### 404 - Service, business, or event not found ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}/services/{serviceId}/available-days?year=2024&month=9" ``` ``` -------------------------------- ### POST /business/create Source: https://api.tricolors.app/api-docs.json Create a new business app with the specified type and information. ```markdown ### Request Body **Content-Type:** application/json - **name** (string) (required) - **description** (string) (required) - **phone** (string) (required) ### Responses #### 200 - App created successfully **Business** - **id** (integer) (required) - **userId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **phone** (string) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X POST "https://api.tricolors.app/business/create" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "description": "string", "phone": "string" }' ``` ``` -------------------------------- ### POST /business/{businessId}/course Source: https://api.tricolors.app/api-docs.json Create a course for a specific category. ```markdown ### Parameters - **businessId** (string, path, required) ### Request Body **Content-Type:** application/json - **categoryId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) ("on"|"off"|"temporal_off"|"custom") - **eventId** (integer,null) - **fileId** (string,null) - **maxUsers** (integer,null) - **language** (string,null) - **discountPercentage** (number,null) - **discountActive** (boolean,null) - **discountStartAt** (string (date-time)) - **discountEndAt** (string (date-time)) - **visibilityStartAt** (string (date-time)) - **visibilityEndAt** (string (date-time)) ### Responses #### 200 - Course created successfully **Course** - **id** (integer) (required) - **categoryId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) (required) ("on"|"off"|"temporal_off"|"custom") - **eventId** (integer,null) (required) - **fileId** (string,null) (required) - **maxUsers** (integer,null) (required) - **language** (string,null) (required) - **discountPercentage** (number,null) (required) - **discountStartAt** (string,null) (required) - **discountEndAt** (string,null) (required) - **discountActive** (boolean,null) (required) - **visibilityStartAt** (string,null) (required) - **visibilityEndAt** (string,null) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X POST "https://api.tricolors.app/business/{businessId}/course" \ -H "Content-Type: application/json" \ -d '{ "categoryId": "0", "name": "string", "description": "string", "price": "0", "visibility": "on", "eventId": "value", "fileId": "value", "maxUsers": "value", "language": "value", "discountPercentage": "value", "discountActive": "value", "discountStartAt": "2023-01-01T00:00:00Z", "discountEndAt": "2023-01-01T00:00:00Z", "visibilityStartAt": "2023-01-01T00:00:00Z", "visibilityEndAt": "2023-01-01T00:00:00Z" }' ``` ``` -------------------------------- ### POST /business/{businessId}/product Source: https://api.tricolors.app/api-docs.json Create a product for a specific category. ```markdown ### Parameters - **businessId** (string, path, required) ### Request Body **Content-Type:** application/json - **categoryId** (integer) (required) - **productName** (string) (required) - **sku** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) ("on"|"off"|"temporal_off"|"custom") - **fileId** (string,null) - **discountPercentage** (number,null) - **discountActive** (boolean,null) - **discountStartAt** (string (date-time)) - **discountEndAt** (string (date-time)) - **visibilityStartAt** (string,null) - **visibilityEndAt** (string,null) ### Responses #### 200 - Product created successfully **Product** - **id** (integer) (required) - **categoryId** (integer) (required) - **productName** (string) (required) - **sku** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) (required) ("on"|"off"|"temporal_off"|"custom") - **fileId** (string,null) (required) - **discountPercentage** (number,null) (required) - **discountStartAt** (string,null) (required) - **discountEndAt** (string,null) (required) - **discountActive** (boolean,null) (required) - **visibilityStartAt** (string,null) (required) - **visibilityEndAt** (string,null) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X POST "https://api.tricolors.app/business/{businessId}/product" \ -H "Content-Type: application/json" \ -d '{ "categoryId": "0", "productName": "string", "sku": "string", "description": "string", "price": "0", "visibility": "on", "fileId": "value", "discountPercentage": "value", "discountActive": "value", "discountStartAt": "2023-01-01T00:00:00Z", "discountEndAt": "2023-01-01T00:00:00Z", "visibilityStartAt": "value", "visibilityEndAt": "value" }' ``` ``` -------------------------------- ### API Overview: Tricolors Dashboard API Source: https://api.tricolors.app/api-docs.json API for the Tricolors Dashboard ```yaml # Tricolors Dashboard API # Version: 1.0.0 API for the Tricolors Dashboard # Base URL: https://api.tricolors.app ``` -------------------------------- ### GET /business/{businessId}/eventos Source: https://api.tricolors.app/api-docs.json Get all eventos for a specific business. Can be filtered by category. ```markdown ### Parameters - **businessId** (string, path, required) - **categoryId** (string, query, optional) ### Responses #### 200 - Eventos retrieved successfully - Array of object - **id** (integer) (required) - **categoryId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **price** (number,null) (required) - **visibility** (string (on|off|temporal_off|custom)) (required) ("on"|"off"|"temporal_off"|"custom") - **fileId** (string,null) (required) - **maxUsers** (integer,null) (required) - **language** (string,null) (required) - **discountPercentage** (number,null) (required) - **discountStartAt** (string,null) (required) - **discountEndAt** (string,null) (required) - **discountActive** (boolean,null) (required) - **dateStartAt** (string,null) (required) - **dateEndAt** (string,null) (required) - **time** (string,null) (required) - **location** (string,null) (required) - **visibilityStartAt** (string,null) (required) - **visibilityEndAt** (string,null) (required) - **url** (string,null) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/eventos?categoryId=string" ``` ``` -------------------------------- ### Schema: Product Source: https://api.tricolors.app/api-docs.json Schema definition for Product ```markdown ## Schema: Product Schema definition for Product **Type:** object - **id** (integer) (required) - **categoryId** (integer) (required) - **productName** (string) (required) - **sku** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) (required) ("on"|"off"|"temporal_off"|"custom") - **fileId** (string,null) (required) - **discountPercentage** (number,null) (required) - **discountStartAt** (string,null) (required) - **discountEndAt** (string,null) (required) - **discountActive** (boolean,null) (required) - **visibilityStartAt** (string,null) (required) - **visibilityEndAt** (string,null) (required) - **createdAt** (string (date)) (required) ``` -------------------------------- ### Schema: Course Source: https://api.tricolors.app/api-docs.json Schema definition for Course ```markdown ## Schema: Course Schema definition for Course **Type:** object - **id** (integer) (required) - **categoryId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) (required) ("on"|"off"|"temporal_off"|"custom") - **eventId** (integer,null) (required) - **fileId** (string,null) (required) - **maxUsers** (integer,null) (required) - **language** (string,null) (required) - **discountPercentage** (number,null) (required) - **discountStartAt** (string,null) (required) - **discountEndAt** (string,null) (required) - **discountActive** (boolean,null) (required) - **visibilityStartAt** (string,null) (required) - **visibilityEndAt** (string,null) (required) - **createdAt** (string (date)) (required) ``` -------------------------------- ### POST /business/{businessId}/schedule/available Source: https://api.tricolors.app/api-docs.json Create a new available schedule for a business. ```markdown ### Parameters - **businessId** (string, path, required) ### Request Body **Content-Type:** application/json - **name** (string) (required) - **timezone** (string) (required) - **isDefault** (boolean) ### Responses #### 201 - Available schedule created successfully **Available** - **id** (integer) (required) - **businessId** (integer) (required) - **name** (string) (required) - **timezone** (string) (required) - **isDefault** (boolean) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X POST "https://api.tricolors.app/business/{businessId}/schedule/available" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "timezone": "string", "isDefault": "false" }' ``` ``` -------------------------------- ### GET /business/{businessId}/category Source: https://api.tricolors.app/api-docs.json Get all categories for a specific business ordered by order field. ```markdown ### Parameters - **businessId** (string, path, required) ### Responses #### 200 - categories retrieved successfully - Array of object - **id** (integer) (required) - **businessId** (integer) (required) - **moduleId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **pause** (boolean) (required) - **pauseStartAt** (string,null) (required) - **pauseEndAt** (string,null) (required) - **order** (integer) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/business/{businessId}/category" ``` ``` -------------------------------- ### POST /dev/cron/activate-discounts Source: https://api.tricolors.app/api-docs.json Trigger the activate discounts cron job manually for testing ```markdown ### Responses #### 200 - Job executed successfully - **message** (string) (required) - **timestamp** (string) (required) #### 500 - Job execution failed - **error** (string) (required) ### Example Usage ```bash curl -X POST "https://api.tricolors.app/dev/cron/activate-discounts" ``` ``` -------------------------------- ### POST /public/business/{businessId}/courses/{courseId}/appointments Source: https://api.tricolors.app/api-docs.json Create a new appointment for a course linked to an event. Validates time availability, schedule constraints, and maximum user limits. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) - **courseId** (string, path, required): The unique identifier of the course (example: 1) ### Request Body **Content-Type:** application/json - **customerName** (string) (required): Full name of the customer (example: "Jane Smith") - **customerEmail** (string (email)) (required): Customer email address (example: "jane.smith@example.com") - **customerPhone** (string): Customer phone number (example: "+1234567890") - **customerNotes** (string): Additional notes from customer (example: "Interested in advanced topics, has prior experience") - **appointmentDate** (string) (required): Course appointment date in YYYY-MM-DD format (example: "2024-01-20") - **appointmentTime** (string) (required): Course appointment time in HH:MM format (example: "14:00") ### Responses #### 201 - Course appointment created successfully #### 400 - Invalid request parameters, appointment conflicts, or course capacity exceeded #### 404 - Course, business, or event not found ### Example Usage ```bash curl -X POST "https://api.tricolors.app/public/business/{businessId}/courses/{courseId}/appointments" \ -H "Content-Type: application/json" \ -d '{ "customerName": "Jane Smith", "customerEmail": "jane.smith@example.com", "customerPhone": "+1234567890", "customerNotes": "Interested in advanced topics, has prior experience", "appointmentDate": "2024-01-20", "appointmentTime": "14:00" }' ``` ``` -------------------------------- ### POST /business/{businessId}/schedule/available/{availableId}/activities Source: https://api.tricolors.app/api-docs.json Create a new activity for an available schedule. ```markdown ### Parameters - **businessId** (string, path, required) - **availableId** (string, path, required) ### Request Body **Content-Type:** application/json - **name** (string) (required) - **description** (string) - **duration** (integer) (required) ### Responses #### 201 - Activity created successfully **Activity** - **id** (integer) (required) - **availableId** (integer) (required) - **name** (string) (required) - **description** (string,null) (required) - **duration** (integer) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X POST "https://api.tricolors.app/business/{businessId}/schedule/available/{availableId}/activities" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "description": "string", "duration": "0" }' ``` ``` -------------------------------- ### GET /user/verify Source: https://api.tricolors.app/api-docs.json Retrieve user token after Firebase authentication ```markdown ### Responses #### 200 - User token retrieved successfully - **uid** (string) (required): Unique identifier for the user (example: "1234567890") - **login** (boolean) (required): Indicates if the user is logged in (example: true) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/user/verify" ``` ``` -------------------------------- ### POST /business/{businessId}/service Source: https://api.tricolors.app/api-docs.json Create a service for a specific category. ```markdown ### Parameters - **businessId** (string, path, required) ### Request Body **Content-Type:** application/json - **categoryId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) ("on"|"off"|"temporal_off"|"custom") - **eventId** (integer,null) - **fileId** (string,null) - **discountPercentage** (number,null) - **discountActive** (boolean,null) - **discountStartAt** (string (date-time)) - **discountEndAt** (string (date-time)) - **visibilityStartAt** (string (date-time)) - **visibilityEndAt** (string (date-time)) ### Responses #### 200 - Service created successfully **Service** - **id** (integer) (required) - **categoryId** (integer) (required) - **name** (string) (required) - **description** (string) (required) - **price** (number) (required) - **visibility** (string (on|off|temporal_off|custom)) (required) ("on"|"off"|"temporal_off"|"custom") - **eventId** (integer,null) (required) - **fileId** (string,null) (required) - **discountPercentage** (number,null) (required) - **discountStartAt** (string,null) (required) - **discountEndAt** (string,null) (required) - **discountActive** (boolean,null) (required) - **visibilityStartAt** (string,null) (required) - **visibilityEndAt** (string,null) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X POST "https://api.tricolors.app/business/{businessId}/service" \ -H "Content-Type: application/json" \ -d '{ "categoryId": "0", "name": "string", "description": "string", "price": "0", "visibility": "on", "eventId": "value", "fileId": "value", "discountPercentage": "value", "discountActive": "value", "discountStartAt": "2023-01-01T00:00:00Z", "discountEndAt": "2023-01-01T00:00:00Z", "visibilityStartAt": "2023-01-01T00:00:00Z", "visibilityEndAt": "2023-01-01T00:00:00Z" }' ``` ``` -------------------------------- ### POST /dev/cron/activate Source: https://api.tricolors.app/api-docs.json Trigger the activate visibility cron job manually for testing ```markdown ### Responses #### 200 - Job executed successfully - **message** (string) (required) - **timestamp** (string) (required) #### 500 - Job execution failed - **error** (string) (required) ### Example Usage ```bash curl -X POST "https://api.tricolors.app/dev/cron/activate" ``` ``` -------------------------------- ### Schema: BusinessModule Source: https://api.tricolors.app/api-docs.json Schema definition for BusinessModule ```markdown ## Schema: BusinessModule Schema definition for BusinessModule **Type:** object - **id** (integer) (required) - **businessId** (integer) (required) - **name** (string (product|service|course|eventos)) (required) ("product"|"service"|"course"|"eventos") - **status** (boolean) (required) - **createdAt** (string (date)) (required) ``` -------------------------------- ### GET /public/business/{businessId}/categories Source: https://api.tricolors.app/api-docs.json Retrieve all public categories for a business. Only returns categories that are not paused. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) ### Responses #### 200 - Public categories retrieved successfully - Array of object - **id** (number) (required) - **businessId** (number) (required) - **moduleId** (number) (required) - **name** (string) (required) - **description** (string) (required) - **pause** (boolean) (required) - **pauseStartAt** (string,null) (required) - **pauseEndAt** (string,null) (required) - **order** (number) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}/categories" ``` ``` -------------------------------- ### POST /business/{businessId}/social-network Source: https://api.tricolors.app/api-docs.json Create a social network for a specific business. ```markdown ### Parameters - **businessId** (string, path, required) ### Request Body **Content-Type:** application/json - **name** (string) (required) - **url** (string) (required) ### Responses #### 200 - Business social network created successfully **BusinessSocialNetwork** - **id** (integer) (required) - **businessId** (integer) (required) - **name** (string) (required) - **url** (string) (required) - **createdAt** (string (date)) (required) ### Example Usage ```bash curl -X POST "https://api.tricolors.app/business/{businessId}/social-network" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "url": "string" }' ``` ``` -------------------------------- ### GET /public/business/{businessId} Source: https://api.tricolors.app/api-docs.json Retrieve public business information including active modules, location, and social networks. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) ### Responses #### 200 - Public business information retrieved successfully #### 400 - Invalid request parameters #### 404 - Business not found ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}" ``` ``` -------------------------------- ### Schema: File Source: https://api.tricolors.app/api-docs.json Schema definition for File ```markdown ## Schema: File Schema definition for File **Type:** object - **id** (string) (required) - **filename** (string) (required) - **r2Key** (string) (required) - **contentType** (string,null) (required) - **size** (integer,null) (required) - **uploadedBy** (integer) (required) - **createdAt** (string (date)) (required) ``` -------------------------------- ### GET /public/business/{businessId}/scheduling Source: https://api.tricolors.app/api-docs.json Retrieve public scheduling information for a business including available schedules and time blocks. ```markdown ### Parameters - **businessId** (string, path, required): The unique identifier of the business (example: 1) ### Responses #### 200 - Public scheduling information retrieved successfully #### 400 - Invalid request parameters #### 404 - Business not found ### Example Usage ```bash curl -X GET "https://api.tricolors.app/public/business/{businessId}/scheduling" ``` ```