Waziup / Socialbackend

1 stars 3 forks source link

Include the domain #9

Closed cdupont closed 6 years ago

cdupont commented 6 years ago

All waziup API contains the "domain" (see D3.1 for more details):

/api/v1/domain/waziup/sensors

The domain here is "waziup". Another example is "UGB-Farm1". A domain corresponds to a set of resources that we don't want to mix with others. For instance, we store the sensor measured values in a mongo DB, with collectionName = domain. So it makes sense to sort the social messages by domain, too...

cdupont commented 6 years ago

I suggest to change the API URL to:

/domain/:domain/socials

And to use the domain for the collection name in mongo. What do you think?

pandaconstantin commented 6 years ago

Ok, let me update then.

cdupont commented 6 years ago

Hi Constantin, did you succeed?

pandaconstantin commented 6 years ago

Yes I did :)

cdupont commented 6 years ago

Thanks, closing