Skip to content

Instantly share code, notes, and snippets.

@mattapayne
Created April 19, 2009 20:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mattapayne/98213 to your computer and use it in GitHub Desktop.
Save mattapayne/98213 to your computer and use it in GitHub Desktop.
#To announce an article:
RDefensio::API.announce_article({
"article-author" => "Me",
"article-author-email" => "my@email.com",
"article-title" => @post.title,
"article-content" => @post.body,
"permalink" => @post.slug
}
#To audit a comment:
RDefensio::API.audit_comment({
"user-ip" => user_ip,
"article-date" => @comment.post.created_at,
"comment-author" => @comment.username,
"comment-type" => "comment",
"comment-content" => @comment.comment,
"comment-author-email" => @comment.email,
"permalink" => @comment.post.slug,
"referrer" => user_referrer,
"user-logged-in" => logged_in?.to_s,
"trusted-user" => logged_in?.to_s
})
#To report a false positive or negative:
RDefensio::API.report_false_positives(@comment.signature)
RDefensio::API.report_false_negatives(@comment.signature)
#To validate your API key or get stats:
RDefensio::API.get_stats
RDefensio::API.validate_key
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment