src/Api/Story.php
public function comment(string $message) : ?Comment
    {
        $comment = $this->postJson(sprintf(self::ACTIVITY_ENDPOINT . 'v1/users/me/comment/%s', $this->storyId()), [
            'commentString' => $message
        ]);

        // Since I couldn't find an endpoint that gave me a comment's info using just it's comment id, let's just grab the newest comment.
        $newest = $this->comments(0, 1, 'ASC');

        if (count($newest) === 0) return null;
        
        return $newest[0];
    }
public function comment(string $message) : ?Comment
    {
        $comment = $this->postJson(sprintf(self::ACTIVITY_ENDPOINT . 'v1/users/me/comment/%s', $this->storyId()), [
            'commentString' => $message
        ]);

        // Since I couldn't find an endpoint that gave me a comment's info using just it's comment id, let's just grab the newest comment.
        $newest = $this->comments(0, 1, 'ASC');

        if (count($newest) === 0) return null;
        
        return $newest[0];
    }
public function comment ( string $ message ) : ? Comment { $ comment = $ this -> postJson ( sprintf ( self :: ACTIVITY_ENDPOINT . 'v1/users/me/comment/%s' , $ this -> storyId ( ) ) , [ 'commentString' => $ message ] ) ; // Since I couldn't find an endpoint that gave me a comment's info using just it's comment id, let's just grab the newest comment. $ newest = $ this -> comments ( 0 , 1 , 'ASC' ) ; if ( count ( $ newest ) === 0 ) return null ; return $ newest [ 0 ] ; }
Leave a comment on the Story.

@param string $message The comment.
@return Comment|null
Leave a comment on the Story .