Code Monkey home page Code Monkey logo

habrahabr's Introduction

Habrahabr

Habrahabr API client.

Installation

For now, use bundler and install via git. I am currently feeling uncomfortable squatting rubygems entry for habrahabr.

gem 'habrahabr', git: 'https://github.com/markiz/habrahabr.git'

Usage

client = Habrahabr::Client.new(oauth_token: '1234567890abcdef1234567890abcdef12345678', client_id: '1234567890abcdef.12345678')
client.hubs.first
# => {"count_posts"=>3632,
# "count_subscribers"=>116524,
# "is_profiled"=>true,
# "rating"=>1594.3064,
# "alias"=>"infosecurity",
# "title"=>"Информационная безопасность",
# "tags_string"=>
#    "безопасность, фишинг, fishing, защита, взлом, XSS, CSRF, SQL-inj, sql-инъекция, PHP-inj, DoS, DDoS, социальная инженерия, capcha, капча, sql injection, php injection, хакер, хакеры, хакерская атака",
# "about"=>
#    "О том, как мы защищаем свою информацию - от взлома, повреждения, фишинга и т.д. Новости мира anti-virus, anti-spam, anti-spy  и т.д.\r\n\r\nЛичные впечатления, опыт, мнения.",
# "is_membership"=>true,
# "is_company"=>false}

client.hub_habred('infosecurity').first
# => {"id"=>221359,
#  "is_tutorial"=>false,
#  "time_published"=>"2014-04-29T15:52:35+04:00",
#  "time_interesting"=>nil,
#  "comments_count"=>0,
#  "score"=>nil,
#  "votes_count"=>1,
#  "favorites_count"=>5,
#  "tags_string"=>"iso/iec27000, стандарты ИБ, риск-менеджмент",
#  "title"=>"Переход к ISO/IEC 27001:2013. Тонкости перевода и не только",
#  "preview_html"=> ... }

Disclaimer

I have no relation to habrahabr other than having a need to develop an API wrapper.

License

The code for API client is public domain. It uses some MIT and Ruby-licensed stuff underneath.

habrahabr's People

Contributors

markiz avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.