pub async fn create_comment(
        &self,
        number: u64,
        body: impl AsRef<str>,
    ) -> Result<models::issues::Comment> {
        let route = format!(
            "repos/{owner}/{repo}/issues/{issue}/comments",
            owner = self.owner,
            repo = self.repo,
            issue = number
        );

        self.crab
            .post(route, Some(&serde_json::json!({ "body": body.as_ref() })))
            .await
    }
/// Creates a comment in the issue.
/// ```no_run
/// # async fn run() -> octocrab::Result<()> {
/// let comment = octocrab::instance()
///     .issues("owner", "repo")
///     .create_comment(101, "Beep Boop")
///     .await?;
/// # Ok(())
/// # }
/// ```
Creates a comment in the issue.
Creates a comment in the issue .
pub async fn create_comment(
        &self,
        number: u64,
        body: impl AsRef<str>,
    ) -> Result<models::issues::Comment> {
        let route = format!(
            "repos/{owner}/{repo}/issues/{issue}/comments",
            owner = self.owner,
            repo = self.repo,
            issue = number
        );
        self.crab
            .post(route, Some(&serde_json::json!({ "body": body.as_ref() })))
            .await
    }
pub async fn create_comment ( & self , number : u64 , body : impl AsRef < str > , ) -> Result < models :: issues :: Comment > { let route = format ! ( " " owner self owner repo self repo issue number ) ; self . crab . post ( route , Some ( & serde_json :: json ! ( { " " body as_ref ( ) } ) ) ) . await }
Creates a comment in the issue.
Creates a comment in the issue .
&self
number
u64
body
impl AsRef<str>
&self
number
u64
body
impl AsRef<str>
async fn run() -> octocrab::result<()> {
let comment = octocrab::instance()
.issues("owner", "repo")
.create_comment(101, "Beep Boop")
.await?.
let comment = octocrab :: instance () . issues ( " owner " " repo " ) . create_comment ( 101 " Beep Boop " ) . await? .
ok(())
None
}
None