class Devto::Client
- Devto::Client
- Reference
- Object
Included Modules
Defined in:
devto/client.crConstructors
Instance Method Summary
- #close
-
#convert_to_api_url(url : String) : String
Converts public article url to api format url.
-
#post_by_url(url : String) : Devto::Post
Retrive article from provider and convert build Post object.
- #post_urls_by_author(author : String)
Instance methods inherited from module Devto::Connection
download(endpoint : String)
download,
get(endpoint, params : Hash(String, String) | Nil = nil, headers : HTTP::Headers | Nil = nil, body : String | Nil = nil)
get,
get_pagination(endpoint, params : Hash(String, String) | Nil = nil, headers : HTTP::Headers | Nil = nil, body : String | Nil = nil, &)
get_pagination,
http(host : String | Nil = HOST) : HTTP::Client
http,
request(method, endpoint, params : Hash(String, String) | Nil = nil, headers : HTTP::Headers | Nil = nil, body : String | Nil = nil)
request
Constructor Detail
Instance Method Detail
def convert_to_api_url(url : String) : String
#
Converts public article url to api format url. in: https://dev.to/jetthoughts/how-to-use-linear-gradient-in-css-bi1 out: https://dev.to/api/articles/jetthoughts/how-to-use-linear-gradient-in-css-bi1
def post_by_url(url : String) : Devto::Post
#
Retrive article from provider and convert build Post object.