37 lines
1.5 KiB
Rust
37 lines
1.5 KiB
Rust
pub mod contact;
|
|
pub mod message;
|
|
|
|
pub mod endpoints {
|
|
pub const ROOT: &str = "/";
|
|
|
|
/// Constant for adding Contact endpoint
|
|
pub const ADD_CONTACT: &str = "/api/v1/contact/new";
|
|
/// Constant for getting Contact endpoint
|
|
pub const GET_CONTACT: &str = "/api/v1/contact";
|
|
/// Constant for updating names of a Contact endpoint
|
|
pub const UPDATE_CONTACT_NAME: &str = "/api/v1/contact/update";
|
|
/// Constant for adding message endpoint
|
|
pub const ADD_MESSAGE: &str = "/api/v1/message/new";
|
|
/// Constant for getting messages endpoint
|
|
pub const GET_MESSAGE: &str = "/api/v1/message";
|
|
/// Constant for scheduling message endpoint
|
|
pub const SCHEDULE_MESSAGE: &str = "/api/v1/schedule/message";
|
|
/// Constant for getting scheduled message endpoint
|
|
pub const GET_SCHEDULE_MESSAGE: &str = "/api/v1/schedule/message";
|
|
/// Constant for creating Scheduled Message Event endpoint
|
|
pub const CREATE_SCHEDULED_MESSAGE_EVENT: &str = "/api/v1/schedule/message/event";
|
|
/// Constant for getting Scheduled Message Event endpoint
|
|
pub const GET_SCHEDULED_MESSAGE_EVENT: &str = "/api/v1/schedule/message/event";
|
|
/// Constant for deleting Scheduled Message Event endpoint
|
|
pub const DELETE_SCHEDULED_MESSAGE_EVENT: &str = "/api/v1/schedule/message/event/{id}";
|
|
}
|
|
|
|
pub mod response {
|
|
pub const SUCCESSFUL: &str = "SUCCESSFUL";
|
|
}
|
|
|
|
/// Basic handler that responds with a static string
|
|
pub async fn root() -> &'static str {
|
|
"Hello, World!"
|
|
}
|