cloudflare/endpoints/workers/
send_tail_heartbeat.rs1use surf::http::Method;
2
3use super::WorkersTail;
4
5use crate::framework::endpoint::Endpoint;
6
7#[derive(Debug)]
10pub struct SendTailHeartbeat<'a> {
11 pub account_identifier: &'a str,
13 pub script_name: &'a str,
15 pub tail_id: &'a str,
17}
18
19impl<'a> Endpoint<WorkersTail> for SendTailHeartbeat<'a> {
20 fn method(&self) -> Method {
21 Method::Post
22 }
23 fn path(&self) -> String {
24 format!(
25 "accounts/{}/workers/scripts/{}/tails/{}/heartbeat",
26 self.account_identifier, self.script_name, self.tail_id
27 )
28 }
29}