Skip to content

Jay9596/goRant

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

goRant

An unofficial Go client for public devRant API

https://www.devrant.io/

Go Report Card

Table of Content

  1. Installation
  2. Documentation
  3. Getting Started
  4. Todo

Installation:

go get github.com/jay9596/goRant

Documentation

go doc github.com/jay9596/goRant
Or visit: GoDoc

Getting Started

  • goRant Functions

    Assign a New client

    devRant := goRant.New()
    

    Rants : Fetch rants

    rants,err := devRant.Rants()

    Rant : Fetch a single rant

    rant,comments,err := devRant.GetRant(rantID)

    Profile : Fetch a user profile

    user,err := devRant.Profile("byte")

    Search : Search on devrant

    rants,err := devRant.Search("vscode")

    Surprise : Fetch a random rant

    rant,comments,err := devRant.Surprise()

    WeeklyRant : Fetch weekly rants

    rants,err := devRant.WeeklyRant()

    Collabs : Fetch collabs

    rants,err := devRant.Collabs()

    Stories : Fetch stories

    rants,err := devRant.Stories()
  • goRant Types

    All rant specified above represent a Rant struct
    The rants represent an array of Rant [ ]Rant
    The user represent User struct
    The comments represent an array of Comment [ ]Comment

Todo

  • Add supporter ++ support
  • Add Tests