loklak / loklak_go_api

Go library client for using the Loklak API
1.06k stars 6 forks source link

Simplify API #12

Open yukiisbored opened 7 years ago

yukiisbored commented 7 years ago

The API is overly complicated and does not support the spirit of the Go programming language. Which results in high code complexity, confusing functions, etc.

yukiisbored commented 7 years ago

Also, using POST requests will be better than constructing complicated GET requests to decrease exploitation of the API

aviaryan commented 7 years ago

Agreed. For starters, we can create custom interfaces for each of the different return types (Apps, User, Tweets). Let's create individual issues and work on this step by step.

yukiisbored commented 7 years ago

@aviaryan I think it's better to make it into a simple API caller instead. Basically a communicator to keep it simple and flexible.

aviaryan commented 7 years ago

@yukiisbored Cool. Actually I was inspired from https://github.com/loklak/loklak_python_api which provides a much more coherent experience (like Twitter SDK). So if I want to do something like that, we will have to start a new project, right? The idea seems interesting to me and I will try it in my free time.

yukiisbored commented 7 years ago

@aviaryan Well, that's Python not Go. Go has a different taste, I suggest reading Effective Go to see what I'm talking about.