mirror of
https://github.com/chatmail/core.git
synced 2026-05-14 12:26:31 +03:00
add json api to cffi and expose it in dc node
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "deltachat-jsonrpc"
|
||||
version = "0.1.0"
|
||||
version = "1.86.0"
|
||||
authors = ["Delta Chat Developers (ML) <delta@codespeak.net>"]
|
||||
edition = "2021"
|
||||
default-run = "webserver"
|
||||
|
||||
@@ -39,6 +39,10 @@ impl CommandApi {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn new_from_cffi(accounts: Arc<RwLock<Accounts>>) -> Self {
|
||||
CommandApi { accounts }
|
||||
}
|
||||
|
||||
async fn get_context(&self, id: u32) -> Result<deltachat::context::Context> {
|
||||
let sc = self
|
||||
.accounts
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
pub mod api;
|
||||
pub use api::events;
|
||||
|
||||
pub use yerpc;
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::api::{Accounts, CommandApi};
|
||||
|
||||
Reference in New Issue
Block a user