How to connect config.json file to sync gateway

I have one more doubt , now i am able to connect sync gateway to couchbase server…I have a consideration like couchbase lite is used as a local database or standalone database for windows application…so how the couchbase lite (local database from application) is connected with sync gateway??? is it done by API provided by Couchbase lite??