lmsa icon indicating copy to clipboard operation
lmsa copied to clipboard

tlaw: generic HTTP API wrapper

Open zverok opened this issue 6 years ago • 2 comments

Project

tlaw is a somewhat experimental library/DSL for creating fast, thin and reliable wrappers for HTTP APIs. Currently, it supports only GET APIs and lacks some deeper HTTP features (like headers passing or authorization), yet already proven to be a promising way to the "right" thickness balance.

The idea is to develop several generally useful TLAW-based wrappers for common APIs, adding new TLAW features on the way, when necessary.

Plan

  1. Go through lists of public APIs (like this one) and select those of general importance or interesting to you personally.
  2. Create TLAW-based wrappers for them and commit those to tlaws repo.
  3. Good wrapper should include:
    • Wrapper itself, with inline docs and proper hierarchical structure
    • Sanity tests for the wrapper (that it works and does what it is expected to do)
    • README/offline docs for it.

It is expected, that alongside the wrappers themselves, participants of the project also will/should:

  1. Develop some generic good ways of testing and describing small API wrappers;
  2. Enhance TLAW library with (no particular order):
    • Headers support
    • Authorization support
    • Non-GET requests support

Importance

Good abstractions layer for "thin" API wrappers, which can be developed by one person in a few hours and still be robust and useful, seems of general importance for the entire Ruby ecosystem. Also, some regular, small, well-documented wrappers for common APIs, working in the same manner on small yet solid foundation could become a project of huge popularity.

Skills and domains

This task will require a lot of experimenting with API and architecture, and serious intent to write less code, and rewrite a lot, and document a lot.

zverok avatar Feb 23 '18 18:02 zverok