
Show HN: OPEN SOURCE scalable BACKEND services generator + util \m/ - travolque
https://github.com/vangav/vos_backend
======
heshamg
Setting it up, looks great. I have a question though.. what's the difference
between server api and client(s) api(s) JSON config?

~~~
travolque
I'll answer using an example. Let's say you are building the hacker news
backend. You decided to divide it into two services:

\+ [main] service: handles posting, comments, votes, ...

\+ [auth] service: handles authentication users' requests (e.g.: using oauth
2)

Every time [main] receives a requests, it forwards the auth creds to the
[auth] service for authentication.

When you generate the [main]:

\+ server api config: will contain the api for the requests [main] receives
(e.g.: post, upvote, ...)

\+ client api config: will contain the api for the [auth] service since the
[main] will be a client for the [auth] server

Another example would be a backend service that needs to pull data from third-
party services (e.g.: instagram api, twitter api, ...). In that case the
client api config will contain the api for those third-party services.

This tutorial explains in depth the config file's structure:
[https://github.com/vangav/vos_backend/blob/master/README/04_...](https://github.com/vangav/vos_backend/blob/master/README/04_rest_service_config_structure.md#controllersjson-
structure)

Instagram test example
[[https://github.com/vangav/vos_instagram_test](https://github.com/vangav/vos_instagram_test)]
utilizes client api by including the client apis for the main and dash board
services to test them. Check the service's generator config @
[https://github.com/vangav/vos_instagram_test/tree/master/gen...](https://github.com/vangav/vos_instagram_test/tree/master/generator_config)

Please let me know if you have any more questions or need help using it :))

