mirror of
https://github.com/v0l/route96.git
synced 2025-06-19 23:08:59 +00:00
refactor: yaml configs
This commit is contained in:
@ -1,4 +1,5 @@
|
||||
use anyhow::Error;
|
||||
use nostr::serde_json;
|
||||
use reqwest::{Client, ClientBuilder};
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
@ -31,11 +32,13 @@ impl Webhook {
|
||||
subject: Some(hex::encode(pubkey)),
|
||||
payload: fs,
|
||||
};
|
||||
let body = serde_json::to_string(&body)?;
|
||||
let req = self
|
||||
.client
|
||||
.post(&self.url)
|
||||
.header("accept", "application/json")
|
||||
.json(&body)
|
||||
.header("content-type", "application/json")
|
||||
.body(body)
|
||||
.send()
|
||||
.await?;
|
||||
|
||||
|
Reference in New Issue
Block a user