Files
backend/libs/common/src/constants/controller-route.ts
2025-07-03 00:10:00 -06:00

955 lines
45 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

export class ControllerRoute {
static CLIENT = class {
public static readonly ROUTE = 'client';
static ACTIONS = class {
public static readonly REGISTER_NEW_CLIENT_SUMMARY =
'Register a new client';
public static readonly REGISTER_NEW_CLIENT_DESCRIPTION =
'This endpoint registers a new client in the system.';
public static readonly LOGIN_CLIENT_SUMMARY = 'Login a client';
public static readonly LOGIN_CLIENT_DESCRIPTION =
'This endpoint allows a client to log in to the system.';
};
};
static PROJECT = class {
public static readonly ROUTE = 'projects';
static ACTIONS = class {
public static readonly CREATE_PROJECT_SUMMARY = 'Create a new project';
public static readonly CREATE_PROJECT_DESCRIPTION =
'This endpoint allows you to create a new project by providing the required project details.';
public static readonly GET_PROJECT_SUMMARY = 'Retrieve project details';
public static readonly GET_PROJECT_DESCRIPTION =
'This endpoint retrieves the details of a project by its unique identifier (UUID).';
public static readonly UPDATE_PROJECT_SUMMARY = 'Update project details';
public static readonly UPDATE_PROJECT_DESCRIPTION =
'This endpoint updates the details of an existing project using its unique identifier (UUID).';
public static readonly LIST_PROJECTS_SUMMARY = 'List all projects';
public static readonly LIST_PROJECTS_DESCRIPTION =
'This endpoint retrieves a list of all existing projects, including their details.';
public static readonly DELETE_PROJECT_SUMMARY = 'Delete a project';
public static readonly DELETE_PROJECT_DESCRIPTION =
'This endpoint deletes an existing project by its unique identifier (UUID).';
public static readonly GET_USERS_BY_PROJECT_SUMMARY =
'Get users by project';
public static readonly GET_USERS_BY_PROJECT_DESCRIPTION =
'This endpoint retrieves all users associated with a specific project.';
public static readonly GET_USER_BY_UUID_IN_PROJECT_SUMMARY =
'Get user by uuid in project';
public static readonly GET_USER_BY_UUID_IN_PROJECT_DESCRIPTION =
'This endpoint retrieves a user by their unique identifier (UUID) associated with a specific project.';
public static readonly EXPORT_STRUCTURE_CSV_SUMMARY =
'Export project with their full structure to a CSV file';
public static readonly EXPORT_STRUCTURE_CSV_DESCRIPTION =
'This endpoint exports project along with their associated communities, spaces, and nested space hierarchy into a downloadable CSV file. Useful for backups, reports, or audits';
};
};
static PROJECT_USER = class {
public static readonly ROUTE = '/projects/:projectUuid/user';
static ACTIONS = class {
public static readonly GET_USERS_BY_PROJECT_SUMMARY =
'Get users by project';
public static readonly GET_USERS_BY_PROJECT_DESCRIPTION =
'This endpoint retrieves all users associated with a specific project.';
};
};
static REGION = class {
public static readonly ROUTE = 'region';
static ACTIONS = class {
public static readonly GET_REGIONS_SUMMARY = 'Get list of all regions';
public static readonly GET_REGIONS_DESCRIPTION =
'Retrieve the list of all regions registered in Syncrow.';
};
};
static BOOKABLE_SPACES = class {
public static readonly ROUTE = 'bookable-spaces';
static ACTIONS = class {
public static readonly ADD_BOOKABLE_SPACES_SUMMARY =
'Add new bookable spaces';
public static readonly ADD_BOOKABLE_SPACES_DESCRIPTION =
'This endpoint allows you to add new bookable spaces by providing the required details.';
};
};
static COMMUNITY = class {
public static readonly ROUTE = '/projects/:projectUuid/communities';
static ACTIONS = class {
public static readonly GET_COMMUNITY_BY_ID_SUMMARY =
'Get community by community community uuid';
public static readonly GET_COMMUNITY_BY_ID_DESCRIPTION =
'Get community by community community uuid - ( [a-zA-Z0-9]{10} )';
public static readonly LIST_COMMUNITY_SUMMARY = 'Get list of community';
public static readonly LIST_COMMUNITY_DESCRIPTION =
'Return a list of community';
public static readonly UPDATE_COMMUNITY_SUMMARY = 'Update community';
public static readonly UPDATE_COMMUNITY_DESCRIPTION =
'Update community in the database and return updated community';
public static readonly DELETE_COMMUNITY_SUMMARY = 'Delete community';
public static readonly DELETE_COMMUNITY_DESCRIPTION =
'Delete community matching by community id';
public static readonly CREATE_COMMUNITY_SUMMARY = 'Create community';
public static readonly CREATE_COMMUNITY_DESCRIPTION =
'Create community in the database and return in model';
};
};
static COMMUNITY_SPACE = class {
public static readonly ROUTE = 'communities/:communityUuid/space';
static ACTIONS = class {
public static readonly GET_COMMUNITY_SPACES_HIERARCHY_SUMMARY =
'Fetch hierarchical structure of spaces within a community.';
public static readonly GET_COMMUNITY_SPACES_HIERARCHY_DESCRIPTION =
'retrieves all the spaces associated with a given community, organized into a hierarchical structure.';
};
};
static USER_COMMUNITY = class {
public static readonly ROUTE = '/user/:userUuid/communities';
static ACTIONS = class {
public static readonly GET_USER_COMMUNITIES_SUMMARY =
'Get communities associated with a user by user UUID';
public static readonly GET_USER_COMMUNITIES_DESCRIPTION =
'This endpoint returns the list of communities a specific user is associated with';
public static readonly ASSOCIATE_USER_COMMUNITY_SUMMARY =
'Associate a user with a community';
public static readonly ASSOCIATE_USER_COMMUNITY_DESCRIPTION =
'This endpoint associates a user with a community.';
public static readonly DISASSOCIATE_USER_COMMUNITY_SUMMARY =
'Disassociate a user from a community';
public static readonly DISASSOCIATE_USER_COMMUNITY_DESCRIPTION =
'This endpoint disassociates a user from a community. It removes the relationship between the specified user and the community. If the user is not associated with the community, an error will be returned.';
};
};
static USER_SPACE = class {
public static readonly ROUTE = '/user/:userUuid/spaces';
static ACTIONS = class {
public static readonly GET_USER_SPACES_SUMMARY =
'Retrieve list of spaces a user belongs to';
public static readonly GET_USER_SPACES_DESCRIPTION =
'This endpoint retrieves all the spaces that a user is associated with, based on the user ID. It fetches the user spaces by querying the UserSpaceEntity to find the spaces where the user has an association.';
public static readonly VERIFY_CODE_AND_ADD_USER_SPACE_SUMMARY =
'Verify code and add user space';
public static readonly VERIFY_CODE_AND_ADD_USER_SPACE_DESCRIPTION =
'This endpoint verifies a provided code and associates the user with a space. It checks the validity of the code and, if valid, links the user to the corresponding space in the system.';
};
};
static SCENE = class {
public static readonly ROUTE = 'scene';
static ACTIONS = class {
public static readonly CREATE_TAP_TO_RUN_SCENE_SUMMARY =
'Create a Tap-to-Run Scene';
public static readonly CREATE_TAP_TO_RUN_SCENE_DESCRIPTION =
'Creates a new Tap-to-Run scene in Tuya and stores the scene in the local database.';
public static readonly DELETE_TAP_TO_RUN_SCENE_SUMMARY =
'Delete a Tap-to-Run Scene';
public static readonly DELETE_TAP_TO_RUN_SCENE_DESCRIPTION =
'Deletes a Tap-to-Run scene from Tuya and removes it from the local database.';
public static readonly TRIGGER_TAP_TO_RUN_SCENE_SUMMARY =
'Trigger a Tap-to-Run Scene';
public static readonly TRIGGER_TAP_TO_RUN_SCENE_DESCRIPTION =
'Triggers an existing Tap-to-Run scene in Tuya by scene UUID, executing its actions immediately.';
public static readonly GET_TAP_TO_RUN_SCENE_SUMMARY =
'Get Tap-to-Run Scene Details';
public static readonly GET_TAP_TO_RUN_SCENE_DESCRIPTION =
'Retrieves detailed information of a specific Tap-to-Run scene identified by the scene UUID.';
public static readonly UPDATE_TAP_TO_RUN_SCENE_SUMMARY =
'Update a Tap-to-Run Scene';
public static readonly UPDATE_TAP_TO_RUN_SCENE_DESCRIPTION =
'Updates an existing Tap-to-Run scene in Tuya and updates the scene in the local database, reflecting any new configurations or actions.';
};
};
static SPACE = class {
public static readonly ROUTE =
'/projects/:projectUuid/communities/:communityUuid/spaces';
static ACTIONS = class {
public static readonly CREATE_SPACE_SUMMARY = 'Create a new space';
public static readonly CREATE_SPACE_DESCRIPTION =
'This endpoint allows you to create a space in a specified community. Optionally, you can specify a parent space to nest the new space under it.';
public static readonly LIST_SPACE_SUMMARY = 'List spaces in community';
public static readonly LIST_SPACE_DESCRIPTION =
'List spaces in specified community by community id';
public static readonly GET_SPACE_SUMMARY = 'Get a space in community';
public static readonly GET_SPACE_DESCRIPTION =
'Get Space in specified community by community id';
public static readonly DELETE_SPACE_SUMMARY = 'Delete a space';
public static readonly DELETE_SPACE_DESCRIPTION =
'Deletes a space by its UUID and community ID. If the space has children, they will also be deleted due to cascade delete.';
public static readonly UPDATE_SPACE_SUMMARY = 'Update a space';
public static readonly UPDATE_SPACE_DESCRIPTION =
'Updates a space by its UUID and community ID. You can update the name, parent space, and other properties. If a parent space is provided and not already a parent, its `isParent` flag will be set to true.';
public static readonly GET_HEIRARCHY_SUMMARY = 'Get space hierarchy';
public static readonly GET_HEIRARCHY_DESCRIPTION =
'This endpoint retrieves the hierarchical structure of spaces under a given space ID. It returns all the child spaces nested within the specified space, organized by their parent-child relationships. ';
public static readonly CREATE_INVITATION_CODE_SPACE_SUMMARY =
'Generate a new invitation code for a specific space';
public static readonly CREATE_INVITATION_CODE_SPACE_DESCRIPTION =
'This endpoint generates a new 6-character invitation code for a space identified by its UUID and stores it in the space entity';
public static readonly GET_COMMUNITY_SPACES_HIERARCHY_SUMMARY =
'Fetch hierarchical structure of spaces within a community.';
public static readonly GET_COMMUNITY_SPACES_HIERARCHY_DESCRIPTION =
'retrieves all the spaces associated with a given community, organized into a hierarchical structure.';
};
};
static SPACE_VALIDATION = class {
public static readonly ROUTE = '/projects/:projectUuid/spaces';
static ACTIONS = class {
public static readonly VALIDATE_SPACE_WITH_DEVICES_OR_SUBSPACES_SUMMARY =
'Check if a space has devices or sub-spaces';
public static readonly VALIDATE_SPACE_WITH_DEVICES_OR_SUBSPACES_DESCRIPTION =
'Checks if a space has any devices or sub-spaces associated with it.';
};
};
static SPACE_SCENE = class {
public static readonly ROUTE =
'/projects/:projectUuid/communities/:communityUuid/spaces/:spaceUuid/scenes';
static ACTIONS = class {
public static readonly GET_TAP_TO_RUN_SCENE_BY_SPACE_SUMMARY =
'Retrieve Tap-to-Run Scenes by Space';
public static readonly GET_TAP_TO_RUN_SCENE_BY_SPACE_DESCRIPTION =
'Fetches all Tap-to-Run scenes associated with a specified space UUID. An optional query parameter can filter the results to show only scenes marked for the homepage display.';
};
};
static SPACE_USER = class {
public static readonly ROUTE =
'/projects/:projectUuid/communities/:communityUuid/spaces/:spaceUuid/user';
static ACTIONS = class {
public static readonly ASSOCIATE_SPACE_USER_SUMMARY =
'Associate a user to a space';
public static readonly ASSOCIATE_SPACE_USER_DESCRIPTION =
'Associates a user with a given space by their respective UUIDs';
public static readonly DISSOCIATE_SPACE_USER_SUMMARY =
'Disassociate a user from a space';
public static readonly DISSOCIATE_SPACE_USER_DESCRIPTION =
'Disassociates a user from a space by removing the existing association.';
};
};
static SPACE_DEVICES = class {
public static readonly ROUTE =
'/projects/:projectUuid/communities/:communityUuid/spaces/:spaceUuid/devices';
static ACTIONS = class {
public static readonly LIST_SPACE_DEVICE_SUMMARY =
'List devices in a space';
public static readonly LIST_SPACE_DEVICE_DESCRIPTION =
'Retrieves a list of all devices associated with a specified space.';
};
};
static SUBSPACE = class {
public static readonly ROUTE =
'/projects/:projectUuid/communities/:communityUuid/spaces/:spaceUuid/subspaces';
static ACTIONS = class {
public static readonly CREATE_SUBSPACE_SUMMARY = 'Create Subspace';
public static readonly CREATE_SUBSPACE_DESCRIPTION =
'Creates a new subspace within a specific space and community.';
public static readonly LIST_SUBSPACES_SUMMARY = 'List Subspaces';
public static readonly LIST_SUBSPACES_DESCRIPTION =
'Retrieves a list of subspaces within a specified space and community.';
public static readonly GET_SUBSPACE_SUMMARY = 'Get Subspace';
public static readonly GET_SUBSPACE_DESCRIPTION =
'Fetches a specific subspace by UUID within a given space and community';
public static readonly UPDATE_SUBSPACE_SUMMARY = 'Update Subspace';
public static readonly UPDATE_SUBSPACE_DESCRIPTION =
'Updates a specific subspace within a given space and community.';
public static readonly DELETE_SUBSPACE_SUMMARY = 'Delete Subspace';
public static readonly DELETE_SUBSPACE_DESCRIPTION =
'Deletes a specific subspace within a given space and community.';
};
};
static SUBSPACE_DEVICE = class {
public static readonly ROUTE =
'/projects/:projectUuid/communities/:communityUuid/spaces/:spaceUuid/subspaces/:subSpaceUuid/devices';
static ACTIONS = class {
public static readonly LIST_SUBSPACE_DEVICE_SUMMARY =
'List devices in a subspace';
public static readonly LIST_SUBSPACE_DEVICE_DESCRIPTION =
'Retrieves a list of all devices associated with a specified subspace.';
public static readonly ASSOCIATE_SUBSPACE_DEVICE_SUMMARY =
'Associate a device to a subspace';
public static readonly ASSOCIATE_SUBSPACE_DEVICE_DESCRIPTION =
'Associates a device with a specific subspace, enabling it to be managed within that subspace context.';
public static readonly DISASSOCIATE_SUBSPACE_DEVICE_SUMMARY =
'Disassociate a device from a subspace';
public static readonly DISASSOCIATE_SUBSPACE_DEVICE_DESCRIPTION =
'Removes the association of a device from a specific subspace, making it no longer managed within that subspace.';
};
};
static SPACE_MODEL = class {
public static readonly ROUTE = '/projects/:projectUuid/space-models';
static ACTIONS = class {
public static readonly CREATE_SPACE_MODEL_SUMMARY =
'Create a New Space Model';
public static readonly CREATE_SPACE_MODEL_DESCRIPTION =
'This endpoint allows you to create a new space model within a specified project. A space model defines the structure of spaces, including subspaces, products, and product items, and is uniquely identifiable within the project.';
public static readonly GET_SPACE_MODEL_SUMMARY = 'Get a Space Model';
public static readonly GET_SPACE_MODEL_DESCRIPTION =
'Fetch a space model details';
public static readonly LIST_SPACE_MODEL_SUMMARY = 'List Space Models';
public static readonly LIST_SPACE_MODEL_DESCRIPTION =
'This endpoint allows you to retrieve a list of space models within a specified project. Each space model includes its structure, associated subspaces, products, and product items.';
public static readonly UPDATE_SPACE_MODEL_SUMMARY = 'Update Space Model';
public static readonly UPDATE_SPACE_MODEL_DESCRIPTION =
'This endpoint allows you to update a Space Model attributesas well as manage its associated Subspaces and Device';
public static readonly DELETE_SPACE_MODEL_SUMMARY = 'Delete Space Model';
public static readonly DELETE_SPACE_MODEL_DESCRIPTION =
'This endpoint allows you to delete a specified Space Model within a project. Deleting a Space Model disables the model and all its associated subspaces and tags, ensuring they are no longer active but remain in the system for auditing.';
public static readonly LINK_SPACE_MODEL_SUMMARY =
'Link a Space Model to spaces';
public static readonly LINK_SPACE_MODEL_DESCRIPTION =
'This endpoint allows you to link a specified Space Model within a project to multiple spaces. Linking a Space Model applies the model and all its associated subspaces and tags, to the spaces.';
};
};
static PRODUCT = class {
public static readonly ROUTE = 'products';
static ACTIONS = class {
public static readonly CREATE_PRODUCT_SUMMARY = 'Create a new product';
public static readonly CREATE_PRODUCT_DESCRIPTION =
'This endpoint allows you to create a new product in the system.';
public static readonly LIST_PRODUCT_SUMMARY = 'Retrieve all products';
public static readonly LIST_PRODUCT_DESCRIPTION =
'Fetches a list of all products along with their associated device details';
};
};
static TAG = class {
public static readonly ROUTE = '/projects/:projectUuid/tags';
static ACTIONS = class {
public static readonly CREATE_TAG_SUMMARY = 'Create a new tag';
public static readonly CREATE_TAG_DESCRIPTION =
'Creates a new tag and assigns it to a specific project and product.';
public static readonly GET_TAGS_BY_PROJECT_SUMMARY =
'Get tags by project';
public static readonly GET_TAGS_BY_PROJECT_DESCRIPTION =
'Retrieves a list of tags associated with a specific project.';
};
};
static USER = class {
public static readonly ROUTE = '/user';
static ACTIONS = class {
public static readonly GET_USER_DETAILS_SUMMARY =
'Retrieve user details by user UUID';
public static readonly GET_USER_DETAILS_DESCRIPTION =
'This endpoint retrieves detailed information for a specific user based on their UUID.';
public static readonly UPDATE_PROFILE_PICTURE_SUMMARY =
'Update profile picture by user UUID';
public static readonly UPDATE_PROFILE_PICTURE_DESCRIPTION =
'This endpoint updates the profile picture for a user identified by their UUID.';
public static readonly UPDATE_REGION_SUMMARY =
'Update region by user UUID';
public static readonly UPDATE_REGION_DESCRIPTION =
'This endpoint updates the region information for a user identified by their UUID.';
public static readonly UPDATE_TIMEZONE_SUMMARY =
'Update timezone by user UUID';
public static readonly UPDATE_TIMEZONE_DESCRIPTION =
'This endpoint updates the timezone information for a user identified by their UUID.';
public static readonly UPDATE_NAME_SUMMARY = 'Update name by user UUID';
public static readonly UPDATE_NAME_DESCRIPTION =
'This endpoint updates the name for a user identified by their UUID.';
public static readonly DELETE_USER_SUMMARY = 'Delete user by UUID';
public static readonly DELETE_USER_DESCRIPTION =
'This endpoint deletes a user identified by their UUID. Accessible only by users with the Super Admin role.';
public static readonly DELETE_USER_PROFILE_SUMMARY =
'Delete user profile by UUID';
public static readonly DELETE_USER_PROFILE_DESCRIPTION =
'This endpoint deletes a user profile identified by their UUID. Accessible only by users with the Super Admin role.';
public static readonly UPDATE_USER_WEB_AGREEMENT_SUMMARY =
'Update user web agreement by user UUID';
public static readonly UPDATE_USER_WEB_AGREEMENT_DESCRIPTION =
'This endpoint updates the web agreement for a user identified by their UUID.';
};
};
static AUTHENTICATION = class {
public static readonly ROUTE = 'authentication';
static ACTIONS = class {
public static readonly SIGN_UP_SUMMARY =
'Sign up a new user and return a JWT token';
public static readonly SIGN_UP_DESCRIPTION =
'This endpoint is used to register a new user by providing the user details. A JWT token will be generated and returned upon successful registration.';
public static readonly LOGIN_SUMMARY =
'Login a user and return an access token';
public static readonly LOGIN_DESCRIPTION =
'This endpoint allows an existing user to log in using their credentials. Upon successful login, an access token will be returned.';
public static readonly SEND_OTP_SUMMARY =
'Generate and send OTP to the user';
public static readonly SEND_OTP_DESCRIPTION =
'This endpoint generates and sends an OTP to the user for verification, such as for password reset or account verification.';
public static readonly VERIFY_OTP_SUMMARY =
'Verify the OTP entered by the user';
public static readonly VERIFY_OTP_DESCRIPTION =
'This endpoint verifies the OTP entered by the user. If the OTP is valid, the process continues (e.g., password reset).';
public static readonly FORGET_PASSWORD_SUMMARY =
'Reset the user password after OTP verification';
public static readonly FORGET_PASSWORD_DESCRIPTION =
'This endpoint allows users who have forgotten their password to reset it. After verifying the OTP, the user can set a new password.';
public static readonly USER_LIST_SUMMARY = 'Fetch the list of all users';
public static readonly USER_LIST_DESCRIPTION =
'This endpoint retrieves a list of all users in the system. Access is restricted to super admins only.';
public static readonly REFRESH_TOKEN_SUMMARY =
'Refresh the user session token';
public static readonly REFRESH_TOKEN_DESCRIPTION =
'This endpoint allows a user to refresh their session token. The user must provide a valid refresh token to get a new session token.';
};
};
static ROLE = class {
public static readonly ROUTE = 'role';
static ACTIONS = class {
public static readonly FETCH_ROLE_TYPES_SUMMARY =
'Fetch available role types';
public static readonly FETCH_ROLE_TYPES_DESCRIPTION =
'This endpoint retrieves all available role types in the system.';
public static readonly ADD_USER_ROLE_SUMMARY = 'Add a new user role';
public static readonly ADD_USER_ROLE_DESCRIPTION =
'This endpoint adds a new user role to the system based on the provided role data.';
};
};
static TERMS_AND_CONDITIONS = class {
public static readonly ROUTE = 'terms';
static ACTIONS = class {
public static readonly FETCH_TERMS_SUMMARY = 'Fetch Terms and Conditions';
public static readonly FETCH_TERMS_DESCRIPTION =
'This endpoint retrieves the terms and conditions for the application.';
};
};
static WEATHER = class {
public static readonly ROUTE = 'weather';
static ACTIONS = class {
public static readonly FETCH_WEATHER_DETAILS_SUMMARY =
'Fetch Weather Details';
public static readonly FETCH_WEATHER_DETAILS_DESCRIPTION =
'This endpoint retrieves the current weather details for a specified location like temperature, humidity, etc.';
};
};
static PRIVACY_POLICY = class {
public static readonly ROUTE = 'policy';
static ACTIONS = class {
public static readonly FETCH_POLICY_SUMMARY = 'Fetch Privacy Policy';
public static readonly FETCH_POLICY_DESCRIPTION =
'This endpoint retrieves the privacy policy for the application.';
};
};
static GROUP = class {
public static readonly ROUTE = 'group';
static ACTIONS = class {
public static readonly GET_GROUPS_BY_SPACE_UUID_SUMMARY =
'Get groups by space UUID';
public static readonly GET_GROUPS_BY_SPACE_UUID_DESCRIPTION =
'This endpoint retrieves all groups for a specific space, identified by the space UUID.';
public static readonly GET_UNIT_DEVICES_BY_GROUP_NAME_SUMMARY =
'Get devices by group name in a space';
public static readonly GET_UNIT_DEVICES_BY_GROUP_NAME_DESCRIPTION =
'This endpoint retrieves all devices in a specified group within a space, based on the group name and space UUID.';
};
};
static PowerClamp = class {
public static readonly ROUTE = 'power-clamp';
static ACTIONS = class {
public static readonly GET_ENERGY_SUMMARY =
'Get power clamp historical data';
public static readonly GET_ENERGY_DESCRIPTION =
'This endpoint retrieves the historical data of a power clamp device based on the provided parameters.';
public static readonly GET_ENERGY_BY_COMMUNITY_OR_SPACE_SUMMARY =
'Get power clamp historical data by community or space';
public static readonly GET_ENERGY_BY_COMMUNITY_OR_SPACE_DESCRIPTION =
'This endpoint retrieves the historical data of power clamp devices based on the provided community or space UUID.';
};
};
static Occupancy = class {
public static readonly ROUTE = 'occupancy';
static ACTIONS = class {
public static readonly GET_OCCUPANCY_HEAT_MAP_SUMMARY =
'Get occupancy heat map data';
public static readonly GET_OCCUPANCY_HEAT_MAP_DESCRIPTION =
'This endpoint retrieves the occupancy heat map data based on the provided parameters.';
};
};
static AQI = class {
public static readonly ROUTE = 'aqi';
static ACTIONS = class {
public static readonly GET_AQI_RANGE_DATA_SUMMARY = 'Get AQI range data';
public static readonly GET_AQI_RANGE_DATA_DESCRIPTION =
'This endpoint retrieves the AQI (Air Quality Index) range data based on the provided parameters.';
public static readonly GET_AQI_DISTRIBUTION_DATA_SUMMARY =
'Get AQI distribution data';
public static readonly GET_AQI_DISTRIBUTION_DATA_DESCRIPTION =
'This endpoint retrieves the AQI (Air Quality Index) distribution data based on the provided parameters.';
};
};
static DEVICE = class {
public static readonly ROUTE = 'devices';
static ACTIONS = class {
public static readonly ADD_DEVICE_SUMMARY = 'Add new device';
public static readonly ADD_DEVICE_DESCRIPTION =
'This endpoint adds a new device in the system.';
public static readonly GET_DEVICES_BY_SPACE_UUID_SUMMARY =
'Get devices by space UUID';
public static readonly GET_DEVICES_BY_SPACE_UUID_DESCRIPTION =
'This endpoint retrieves all devices associated with a specific space UUID.';
public static readonly UPDATE_DEVICE_IN_ROOM_SUMMARY =
'Update device in Space';
public static readonly UPDATE_DEVICE_IN_ROOM_DESCRIPTION =
'This endpoint updates the device in a specific space with new details.';
public static readonly GET_DEVICE_DETAILS_SUMMARY = 'Get device details';
public static readonly GET_DEVICE_DETAILS_DESCRIPTION =
'This endpoint retrieves details of a specific device by its UUID.';
public static readonly UPDATE_DEVICE_SUMMARY = 'Update device';
public static readonly UPDATE_DEVICE_DESCRIPTION =
'This endpoint updates the details of a device by its UUID.';
public static readonly GET_DEVICE_INSTRUCTION_SUMMARY =
'Get device instruction';
public static readonly GET_DEVICE_INSTRUCTION_DESCRIPTION =
'This endpoint retrieves the instruction details for a specific device.';
public static readonly GET_DEVICE_STATUS_SUMMARY = 'Get device status';
public static readonly GET_DEVICE_STATUS_DESCRIPTION =
'This endpoint retrieves the current status of a specific device.';
public static readonly CONTROL_DEVICE_SUMMARY = 'Control device';
public static readonly CONTROL_DEVICE_DESCRIPTION =
'This endpoint allows control operations (like power on/off) on a specific device.';
public static readonly UPDATE_DEVICE_FIRMWARE_SUMMARY =
'Update device firmware';
public static readonly UPDATE_DEVICE_FIRMWARE_DESCRIPTION =
'This endpoint updates the firmware of a specific device to the provided version.';
public static readonly GET_DEVICES_IN_GATEWAY_SUMMARY =
'Get devices in gateway';
public static readonly GET_DEVICES_IN_GATEWAY_DESCRIPTION =
'This endpoint retrieves all devices associated with a specific gateway.';
public static readonly GET_ALL_DEVICES_SUMMARY = 'Get all devices';
public static readonly GET_ALL_DEVICES_DESCRIPTION =
'This endpoint retrieves all devices in the system.';
public static readonly GET_DEVICE_LOGS_SUMMARY = 'Get device logs';
public static readonly GET_DEVICE_LOGS_DESCRIPTION =
'This endpoint retrieves the logs for a specific device based on device UUID.';
public static readonly BATCH_CONTROL_DEVICES_SUMMARY =
'Batch control devices';
public static readonly BATCH_CONTROL_DEVICES_DESCRIPTION =
'This endpoint controls a batch of devices with the specified actions.';
public static readonly BATCH_STATUS_DEVICES_SUMMARY =
'Batch status devices';
public static readonly BATCH_STATUS_DEVICES_DESCRIPTION =
'This endpoint retrieves the status of a batch of devices.';
public static readonly BATCH_FACTORY_RESET_DEVICES_SUMMARY =
'Batch factory reset devices';
public static readonly BATCH_FACTORY_RESET_DEVICES_DESCRIPTION =
'This endpoint performs a factory reset on a batch of devices.';
public static readonly GET_POWER_CLAMP_STATUS_SUMMARY =
'Get power clamp status';
public static readonly GET_POWER_CLAMP_STATUS_DESCRIPTION =
'This endpoint retrieves the status of a specific power clamp device.';
public static readonly ADD_SCENE_TO_DEVICE_SUMMARY =
'Add scene to device';
public static readonly ADD_SCENE_TO_DEVICE_DESCRIPTION =
'This endpoint adds a scene to a specific switch device.';
public static readonly GET_SCENES_BY_DEVICE_SUMMARY =
'Get scenes by device';
public static readonly GET_SCENES_BY_DEVICE_DESCRIPTION =
'This endpoint retrieves all scenes associated with a specific switch device.';
public static readonly DELETE_SCENES_BY_SWITCH_NAME_SUMMARY =
'Delete scenes by device uuid and switch name';
public static readonly DELETE_SCENES_BY_SWITCH_NAME_DESCRIPTION =
'This endpoint deletes all scenes associated with a specific switch device.';
};
};
static DEVICE_COMMISSION = class {
public static readonly ROUTE = '/projects/:projectUuid/devices/commission';
static ACTIONS = class {
public static readonly ADD_ALL_DEVICES_SUMMARY = 'Add all devices';
public static readonly ADD_ALL_DEVICES_DESCRIPTION =
'This endpoint add all devices in the system from tuya.';
};
};
static DEVICE_PROJECT = class {
public static readonly ROUTE = '/projects/:projectUuid/devices';
static ACTIONS = class {
public static readonly GET_ALL_DEVICES_SUMMARY = 'Get all devices';
public static readonly GET_ALL_DEVICES_DESCRIPTION =
'This endpoint retrieves all devices in the system.';
};
};
static DEVICE_SPACE_COMMUNITY = class {
public static readonly ROUTE = 'devices-space-community';
static ACTIONS = class {
public static readonly GET_ALL_DEVICES_BY_SPACE_OR_COMMUNITY_WITH_RECURSIVE_CHILD_SUMMARY =
'Get all devices by space or community with recursive child';
public static readonly GET_ALL_DEVICES_BY_SPACE_OR_COMMUNITY_WITH_RECURSIVE_CHILD_DESCRIPTION =
'This endpoint retrieves all devices in the system by space or community with recursive child.';
};
};
static DEVICE_PERMISSION = class {
public static readonly ROUTE = 'device-permission';
static ACTIONS = class {
public static readonly ADD_PERMISSION_SUMMARY =
'Add user permission for device';
public static readonly ADD_PERMISSION_DESCRIPTION =
'This endpoint adds a user permission for a specific device. Accessible only by users with the Super Admin role.';
public static readonly EDIT_PERMISSION_SUMMARY =
'Edit user permission for device';
public static readonly EDIT_PERMISSION_DESCRIPTION =
'This endpoint updates a user permission for a specific device. Accessible only by users with the Super Admin role.';
public static readonly FETCH_PERMISSION_SUMMARY =
'Fetch user permission for device';
public static readonly FETCH_PERMISSION_DESCRIPTION =
'This endpoint retrieves the user permission for a specific device. Accessible only by users with the Super Admin role.';
public static readonly DELETE_PERMISSION_SUMMARY =
'Delete user permission for device';
public static readonly DELETE_PERMISSION_DESCRIPTION =
'This endpoint deletes the user permission for a specific device. Accessible only by users with the Super Admin role.';
};
};
static USER_NOTIFICATION = class {
public static readonly ROUTE = 'user-notification/subscription';
static ACTIONS = class {
public static readonly ADD_SUBSCRIPTION_SUMMARY =
'Add user notification subscription';
public static readonly ADD_SUBSCRIPTION_DESCRIPTION =
'This endpoint adds a subscription for user notifications.';
public static readonly FETCH_SUBSCRIPTIONS_SUMMARY =
'Fetch user notification subscriptions';
public static readonly FETCH_SUBSCRIPTIONS_DESCRIPTION =
'This endpoint retrieves the subscriptions of a specific user based on their UUID.';
public static readonly UPDATE_SUBSCRIPTION_SUMMARY =
'Update user notification subscription';
public static readonly UPDATE_SUBSCRIPTION_DESCRIPTION =
'This endpoint updates the notification subscription details for a user.';
};
};
static AUTOMATION = class {
public static readonly ROUTE = '/projects/:projectUuid/automations';
static ACTIONS = class {
public static readonly ADD_AUTOMATION_SUMMARY = 'Add automation';
public static readonly ADD_AUTOMATION_DESCRIPTION =
'This endpoint creates a new automation based on the provided details.';
public static readonly GET_AUTOMATION_DETAILS_SUMMARY =
'Get automation details';
public static readonly GET_AUTOMATION_DETAILS_DESCRIPTION =
'This endpoint retrieves detailed information about a specific automation.';
public static readonly DELETE_AUTOMATION_SUMMARY = 'Delete automation';
public static readonly DELETE_AUTOMATION_DESCRIPTION =
'This endpoint deletes an automation identified by its UUID.';
public static readonly UPDATE_AUTOMATION_SUMMARY = 'Update automation';
public static readonly UPDATE_AUTOMATION_DESCRIPTION =
'This endpoint updates the details of an existing automation.';
public static readonly UPDATE_AUTOMATION_STATUS_SUMMARY =
'Update automation status';
public static readonly UPDATE_AUTOMATION_STATUS_DESCRIPTION =
'This endpoint updates the status of an automation identified by its UUID (enabled/disabled).';
};
};
static AUTOMATION_SPACE = class {
public static readonly ROUTE =
'/projects/:projectUuid/communities/:communityUuid/spaces/:spaceUuid/automations';
static ACTIONS = class {
public static readonly GET_AUTOMATION_BY_SPACE_SUMMARY =
'Get automation by space';
public static readonly GET_AUTOMATION_BY_SPACE_DESCRIPTION =
'This endpoint retrieves the automations associated with a particular space.';
};
};
static DOOR_LOCK = class {
public static readonly ROUTE = 'door-lock';
static ACTIONS = class {
public static readonly ADD_ONLINE_TEMPORARY_PASSWORD_SUMMARY =
'Add online temporary password';
public static readonly ADD_ONLINE_TEMPORARY_PASSWORD_DESCRIPTION =
'This endpoint allows you to add an online temporary password to a door lock.';
public static readonly ADD_OFFLINE_ONE_TIME_TEMPORARY_PASSWORD_SUMMARY =
'Add offline one-time temporary password';
public static readonly ADD_OFFLINE_ONE_TIME_TEMPORARY_PASSWORD_DESCRIPTION =
'This endpoint allows you to add an offline one-time temporary password to a door lock.';
public static readonly ADD_OFFLINE_MULTIPLE_TIME_TEMPORARY_PASSWORD_SUMMARY =
'Add offline multiple-time temporary password';
public static readonly ADD_OFFLINE_MULTIPLE_TIME_TEMPORARY_PASSWORD_DESCRIPTION =
'This endpoint allows you to add an offline multiple-time temporary password to a door lock.';
public static readonly GET_ONLINE_TEMPORARY_PASSWORDS_SUMMARY =
'Get online temporary passwords';
public static readonly GET_ONLINE_TEMPORARY_PASSWORDS_DESCRIPTION =
'This endpoint retrieves the list of online temporary passwords for a door lock.';
public static readonly DELETE_ONLINE_TEMPORARY_PASSWORD_SUMMARY =
'Delete online temporary password';
public static readonly DELETE_ONLINE_TEMPORARY_PASSWORD_DESCRIPTION =
'This endpoint deletes an online temporary password for a door lock.';
public static readonly GET_OFFLINE_ONE_TIME_TEMPORARY_PASSWORDS_SUMMARY =
'Get offline one-time temporary passwords';
public static readonly GET_OFFLINE_ONE_TIME_TEMPORARY_PASSWORDS_DESCRIPTION =
'This endpoint retrieves the list of offline one-time temporary passwords for a door lock.';
public static readonly GET_OFFLINE_MULTIPLE_TIME_TEMPORARY_PASSWORDS_SUMMARY =
'Get offline multiple-time temporary passwords';
public static readonly GET_OFFLINE_MULTIPLE_TIME_TEMPORARY_PASSWORDS_DESCRIPTION =
'This endpoint retrieves the list of offline multiple-time temporary passwords for a door lock.';
public static readonly UPDATE_OFFLINE_TEMPORARY_PASSWORD_SUMMARY =
'Update offline temporary password';
public static readonly UPDATE_OFFLINE_TEMPORARY_PASSWORD_DESCRIPTION =
'This endpoint updates an offline temporary password for a door lock.';
public static readonly OPEN_DOOR_LOCK_SUMMARY = 'Open door lock';
public static readonly OPEN_DOOR_LOCK_DESCRIPTION =
'This endpoint allows you to open a door lock.';
};
};
static TIMEZONE = class {
public static readonly ROUTE = 'timezone';
static ACTIONS = class {
public static readonly GET_ALL_TIME_ZONES_SUMMARY = 'Get all time zones';
public static readonly GET_ALL_TIME_ZONES_DESCRIPTION =
'This endpoint retrieves all available time zones.';
};
};
static VISITOR_PASSWORD = class {
public static readonly ROUTE = 'visitor-passwords';
public static readonly PROJECT_ROUTE =
'/projects/:projectUuid/visitor-password';
static ACTIONS = class {
public static readonly ADD_VISITOR_PASSWORD_SUMMARY =
'Add visitor password';
public static readonly ADD_VISITOR_PASSWORD_DESCRIPTION =
'This endpoint allows you to add a visitor password based on the operation type.';
public static readonly GET_VISITOR_PASSWORD_SUMMARY =
'Get visitor passwords';
public static readonly GET_VISITOR_PASSWORD_DESCRIPTION =
'This endpoint retrieves all visitor passwords.';
public static readonly GET_VISITOR_DEVICES_SUMMARY =
'Get visitor devices';
public static readonly GET_VISITOR_DEVICES_DESCRIPTION =
'This endpoint retrieves all devices associated with visitor passwords.';
};
};
static SCHEDULE = class {
public static readonly ROUTE = 'schedule';
static ACTIONS = class {
public static readonly ADD_DEVICE_SCHEDULE_SUMMARY =
'Add device schedule';
public static readonly ADD_DEVICE_SCHEDULE_DESCRIPTION =
'This endpoint allows you to add a schedule for a specific device.';
public static readonly GET_DEVICE_SCHEDULE_BY_CATEGORY_SUMMARY =
'Get device schedule by category';
public static readonly GET_DEVICE_SCHEDULE_BY_CATEGORY_DESCRIPTION =
'This endpoint retrieves the schedule for a specific device based on the given category.';
public static readonly DELETE_DEVICE_SCHEDULE_SUMMARY =
'Delete device schedule';
public static readonly DELETE_DEVICE_SCHEDULE_DESCRIPTION =
'This endpoint deletes a specific schedule for a device.';
public static readonly ENABLE_DEVICE_SCHEDULE_SUMMARY =
'Enable device schedule';
public static readonly ENABLE_DEVICE_SCHEDULE_DESCRIPTION =
'This endpoint enables a device schedule for a specific device.';
public static readonly UPDATE_DEVICE_SCHEDULE_SUMMARY =
'Update device schedule';
public static readonly UPDATE_DEVICE_SCHEDULE_DESCRIPTION =
'This endpoint updates the schedule for a specific device.';
};
};
static DEVICE_STATUS_FIREBASE = class {
public static readonly ROUTE = 'device-status-firebase';
static ACTIONS = class {
public static readonly ADD_DEVICE_STATUS_SUMMARY =
'Add device status to Firebase';
public static readonly ADD_DEVICE_STATUS_DESCRIPTION =
'This endpoint adds a device status in Firebase based on the provided device UUID.';
public static readonly GET_DEVICE_STATUS_SUMMARY =
'Get device status from Firebase';
public static readonly GET_DEVICE_STATUS_DESCRIPTION =
'This endpoint retrieves a device status from Firebase using the device UUID.';
};
};
static DEVICE_MESSAGES_SUBSCRIPTION = class {
public static readonly ROUTE = 'device-messages/subscription';
static ACTIONS = class {
public static readonly ADD_DEVICE_MESSAGES_SUBSCRIPTION_SUMMARY =
'Add device messages subscription';
public static readonly ADD_DEVICE_MESSAGES_SUBSCRIPTION_DESCRIPTION =
'This endpoint adds a subscription for device messages.';
public static readonly GET_DEVICE_MESSAGES_SUBSCRIPTION_SUMMARY =
'Get device messages subscription';
public static readonly GET_DEVICE_MESSAGES_SUBSCRIPTION_DESCRIPTION =
'This endpoint fetches a users subscription for a specific device.';
public static readonly DELETE_DEVICE_MESSAGES_SUBSCRIPTION_SUMMARY =
'Delete device messages subscription';
public static readonly DELETE_DEVICE_MESSAGES_SUBSCRIPTION_DESCRIPTION =
'This endpoint deletes a users subscription for device messages.';
};
};
static INVITE_USER = class {
public static readonly ROUTE = 'invite-user';
static ACTIONS = class {
public static readonly CREATE_USER_INVITATION_SUMMARY =
'Create user invitation';
public static readonly CREATE_USER_INVITATION_DESCRIPTION =
'This endpoint creates an invitation for a user to assign to role and spaces.';
public static readonly UPDATE_USER_INVITATION_SUMMARY =
'Update user invitation';
public static readonly UPDATE_USER_INVITATION_DESCRIPTION =
'This endpoint updates an invitation for a user to assign to role and spaces.';
public static readonly DISABLE_USER_INVITATION_SUMMARY =
'Disable user invitation';
public static readonly DISABLE_USER_INVITATION_DESCRIPTION =
'This endpoint disables an invitation for a user to assign to role and spaces.';
public static readonly DELETE_USER_INVITATION_SUMMARY =
'Delete user invitation';
public static readonly DELETE_USER_INVITATION_DESCRIPTION =
'This endpoint deletes an invitation for a user to assign to role and spaces.';
public static readonly ACTIVATION_CODE_SUMMARY =
'Activate Invitation Code';
public static readonly ACTIVATION_CODE_DESCRIPTION =
'This endpoint activate invitation code';
public static readonly CHECK_EMAIL_SUMMARY = 'Check email';
public static readonly CHECK_EMAIL_DESCRIPTION =
'This endpoint checks if an email already exists and have a project in the system.';
};
};
static PERMISSION = class {
public static readonly ROUTE = 'permission';
static ACTIONS = class {
public static readonly GET_PERMISSION_BY_ROLE_SUMMARY =
'Get permissions by role';
public static readonly GET_PERMISSION_BY_ROLE_DESCRIPTION =
'This endpoint retrieves the permissions associated with a specific role.';
};
};
}