pub struct Record {
pub attributes: RecordAttributes,
}Fields§
§attributes: RecordAttributesImplementations§
Source§impl Record
impl Record
Sourcepub fn new() -> Self
pub fn new() -> Self
Examples found in repository?
examples/voice_call.rs (line 85)
84fn voicemail() {
85 let record = Record::new()
86 .action("https://example.com/handle-recording")
87 .method("POST")
88 .max_length(120)
89 .finish_on_key("#")
90 .transcribe(true)
91 .transcribe_callback("https://example.com/transcription");
92
93 let response = VoiceResponse::new()
94 .say("Please leave a message after the beep. Press the pound key when finished.")
95 .record(record)
96 .say("Thank you for your message. Goodbye!")
97 .hangup();
98
99 println!("{}", response.to_xml());
100}Sourcepub fn action(self, action: impl Into<String>) -> Self
pub fn action(self, action: impl Into<String>) -> Self
Examples found in repository?
examples/voice_call.rs (line 86)
84fn voicemail() {
85 let record = Record::new()
86 .action("https://example.com/handle-recording")
87 .method("POST")
88 .max_length(120)
89 .finish_on_key("#")
90 .transcribe(true)
91 .transcribe_callback("https://example.com/transcription");
92
93 let response = VoiceResponse::new()
94 .say("Please leave a message after the beep. Press the pound key when finished.")
95 .record(record)
96 .say("Thank you for your message. Goodbye!")
97 .hangup();
98
99 println!("{}", response.to_xml());
100}Sourcepub fn method(self, method: impl Into<String>) -> Self
pub fn method(self, method: impl Into<String>) -> Self
Examples found in repository?
examples/voice_call.rs (line 87)
84fn voicemail() {
85 let record = Record::new()
86 .action("https://example.com/handle-recording")
87 .method("POST")
88 .max_length(120)
89 .finish_on_key("#")
90 .transcribe(true)
91 .transcribe_callback("https://example.com/transcription");
92
93 let response = VoiceResponse::new()
94 .say("Please leave a message after the beep. Press the pound key when finished.")
95 .record(record)
96 .say("Thank you for your message. Goodbye!")
97 .hangup();
98
99 println!("{}", response.to_xml());
100}pub fn timeout(self, timeout: u32) -> Self
Sourcepub fn max_length(self, max_length: u32) -> Self
pub fn max_length(self, max_length: u32) -> Self
Examples found in repository?
examples/voice_call.rs (line 88)
84fn voicemail() {
85 let record = Record::new()
86 .action("https://example.com/handle-recording")
87 .method("POST")
88 .max_length(120)
89 .finish_on_key("#")
90 .transcribe(true)
91 .transcribe_callback("https://example.com/transcription");
92
93 let response = VoiceResponse::new()
94 .say("Please leave a message after the beep. Press the pound key when finished.")
95 .record(record)
96 .say("Thank you for your message. Goodbye!")
97 .hangup();
98
99 println!("{}", response.to_xml());
100}pub fn play_beep(self, play_beep: bool) -> Self
Sourcepub fn transcribe(self, transcribe: bool) -> Self
pub fn transcribe(self, transcribe: bool) -> Self
Examples found in repository?
examples/voice_call.rs (line 90)
84fn voicemail() {
85 let record = Record::new()
86 .action("https://example.com/handle-recording")
87 .method("POST")
88 .max_length(120)
89 .finish_on_key("#")
90 .transcribe(true)
91 .transcribe_callback("https://example.com/transcription");
92
93 let response = VoiceResponse::new()
94 .say("Please leave a message after the beep. Press the pound key when finished.")
95 .record(record)
96 .say("Thank you for your message. Goodbye!")
97 .hangup();
98
99 println!("{}", response.to_xml());
100}Sourcepub fn transcribe_callback(self, callback: impl Into<String>) -> Self
pub fn transcribe_callback(self, callback: impl Into<String>) -> Self
Examples found in repository?
examples/voice_call.rs (line 91)
84fn voicemail() {
85 let record = Record::new()
86 .action("https://example.com/handle-recording")
87 .method("POST")
88 .max_length(120)
89 .finish_on_key("#")
90 .transcribe(true)
91 .transcribe_callback("https://example.com/transcription");
92
93 let response = VoiceResponse::new()
94 .say("Please leave a message after the beep. Press the pound key when finished.")
95 .record(record)
96 .say("Thank you for your message. Goodbye!")
97 .hangup();
98
99 println!("{}", response.to_xml());
100}pub fn recording_channels(self, channels: impl Into<String>) -> Self
pub fn recording_track(self, track: impl Into<String>) -> Self
Sourcepub fn finish_on_key(self, key: impl Into<String>) -> Self
pub fn finish_on_key(self, key: impl Into<String>) -> Self
Examples found in repository?
examples/voice_call.rs (line 89)
84fn voicemail() {
85 let record = Record::new()
86 .action("https://example.com/handle-recording")
87 .method("POST")
88 .max_length(120)
89 .finish_on_key("#")
90 .transcribe(true)
91 .transcribe_callback("https://example.com/transcription");
92
93 let response = VoiceResponse::new()
94 .say("Please leave a message after the beep. Press the pound key when finished.")
95 .record(record)
96 .say("Thank you for your message. Goodbye!")
97 .hangup();
98
99 println!("{}", response.to_xml());
100}pub fn trim(self, trim: impl Into<String>) -> Self
pub fn recording_status_callback(self, callback: impl Into<String>) -> Self
pub fn recording_status_callback_method(self, method: impl Into<String>) -> Self
pub fn recording_status_callback_event(self, events: Vec<String>) -> Self
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Record
impl RefUnwindSafe for Record
impl Send for Record
impl Sync for Record
impl Unpin for Record
impl UnwindSafe for Record
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more