botserver/src/basic/keywords/messaging/mod.rs
Rodrigo Rodriguez (Pragmatismo) 16cf467bca Add documentation and core BASIC language functions
- Add SET_SCHEDULE.md and TEMPLATE_VARIABLES.md documentation
- Implement array functions (CONTAINS, PUSH/POP, SLICE, SORT, UNIQUE)
- Implement math functions module structure
- Implement datetime functions module structure
- Implement validation functions (ISNULL, ISEMPTY, VAL, STR, TYPEOF)
- Implement error handling functions (THROW, ERROR, ASSERT)
- Add CRM lead scoring keywords (SCORE_LEAD, AI_SCORE_LEAD)
- Add messaging keywords (SEND_TEMPLATE, CREATE_TEMPLATE)
2025-11-30 11:09:16 -03:00

16 lines
610 B
Rust

pub mod send_template;
use crate::shared::models::UserSession;
use crate::shared::state::AppState;
use log::debug;
use rhai::Engine;
use std::sync::Arc;
pub fn register_messaging_keywords(state: Arc<AppState>, user: UserSession, engine: &mut Engine) {
send_template::send_template_keyword(state.clone(), user.clone(), engine);
send_template::send_template_to_keyword(state.clone(), user.clone(), engine);
send_template::create_template_keyword(state.clone(), user.clone(), engine);
send_template::get_template_keyword(state, user, engine);
debug!("Registered all messaging keywords");
}