Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
720e1cfd74
|
||
|
|
d5fde35651
|
@@ -1,18 +0,0 @@
|
|||||||
use serde::{Deserialize, Serialize};
|
|
||||||
|
|
||||||
pub const MESSAGE_EVENT_RESPONSE_STATUS_INSTANT: &str = "INSTANT";
|
|
||||||
pub const MESSAGE_EVENT_RESPONSE_STATUS_SCHEDULED: &str = "SCHEDULED";
|
|
||||||
|
|
||||||
#[derive(Clone, Debug, Default, Deserialize, Serialize)]
|
|
||||||
pub struct MessageEventResponse {
|
|
||||||
pub id: uuid::Uuid,
|
|
||||||
pub scheduled_message_event_id: uuid::Uuid,
|
|
||||||
// Json field
|
|
||||||
pub response: String,
|
|
||||||
pub user_id: uuid::Uuid,
|
|
||||||
pub contact_id: uuid::Uuid,
|
|
||||||
pub message_id: uuid::Uuid,
|
|
||||||
pub status: String,
|
|
||||||
#[serde(with = "time::serde::rfc3339::option")]
|
|
||||||
pub sent: Option<time::OffsetDateTime>,
|
|
||||||
}
|
|
||||||
@@ -1,6 +1,3 @@
|
|||||||
pub mod event;
|
|
||||||
pub mod scheduling;
|
|
||||||
|
|
||||||
use serde::{Deserialize, Serialize};
|
use serde::{Deserialize, Serialize};
|
||||||
|
|
||||||
#[derive(Clone, Debug, Default, Deserialize, Serialize)]
|
#[derive(Clone, Debug, Default, Deserialize, Serialize)]
|
||||||
|
|||||||
@@ -1,27 +0,0 @@
|
|||||||
use serde::{Deserialize, Serialize};
|
|
||||||
|
|
||||||
#[derive(Clone, Debug, Default, Deserialize, Serialize)]
|
|
||||||
pub struct ScheduledMessageEvent {
|
|
||||||
id: uuid::Uuid,
|
|
||||||
contact_id: uuid::Uuid,
|
|
||||||
message_id: uuid::Uuid,
|
|
||||||
scheduled_message_id: uuid::Uuid,
|
|
||||||
#[serde(with = "time::serde::rfc3339::option")]
|
|
||||||
created: Option<time::OffsetDateTime>,
|
|
||||||
}
|
|
||||||
|
|
||||||
#[derive(Clone, Debug, Default, Deserialize, Serialize)]
|
|
||||||
pub struct ScheduledMessage {
|
|
||||||
id: uuid::Uuid,
|
|
||||||
#[serde(with = "time::serde::rfc3339::option")]
|
|
||||||
scheduled: Option<time::OffsetDateTime>,
|
|
||||||
#[serde(with = "time::serde::rfc3339::option")]
|
|
||||||
created: Option<time::OffsetDateTime>,
|
|
||||||
status: String,
|
|
||||||
user_id: uuid::Uuid,
|
|
||||||
}
|
|
||||||
|
|
||||||
pub const READY: &str = "READY";
|
|
||||||
pub const PENDING: &str = "PENDING";
|
|
||||||
pub const PROCESSING: &str = "PROCESSING";
|
|
||||||
pub const DONE: &str = "DONE";
|
|
||||||
Reference in New Issue
Block a user