misardev 1.0.0

Async Rust client for the Misar.Dev API: create projects, write files, build and deploy, start from templates, run OpenAI-compatible chat completions, search code and read usage. Retries, typed plan-limit errors, SSE streaming.
Documentation
// GENERATED by scripts/generate-sdk-resources.mjs from sdks/manifest.json.
// Do not edit by hand — change the route, run `pnpm sdk:sync`, and regenerate.

use crate::error::MisarDevError;
use crate::transport::Transport;
use crate::transport::body_or_empty;
use reqwest::Method;
use serde_json::Value;

/// The `reports` resource — 1 operation(s).
///
/// Report abusive content.
///
/// Reached through [`crate::MisarDev::reports`].
#[derive(Debug, Clone, Copy)]
pub struct ReportsResource<'a> {
    pub(crate) t: &'a Transport,
}

impl ReportsResource<'_> {
    /// `POST /reports`
    ///
    /// misardev:method reports.create
    pub async fn create(self, body: Option<Value>) -> Result<Value, MisarDevError> {
        self.t.request(Method::POST, "/reports", "", Some(body_or_empty(body))).await
    }
}