All Projects → youpin-city → youpin-api

youpin-city / youpin-api

Licence: MIT License
YouPin's API

Programming Languages

javascript
184084 projects - #8 most used programming language
HTML
75241 projects

Projects that are alternatives of or similar to youpin-api

youpin-web
YouPin on the web
Stars: ✭ 13 (-35%)
Mutual labels:  smartcity

YouPin API

Build Status

API (dev environment): https://dev.api.youpin.city All data is sent and recieved as JSON.

API Documents

API Documents is auto-generated by apidoc and can be accessed at https://youpin-city.github.io/youpin-api-docs. Moreover, we also have POSTMAN examples that you can try by importing it to your own POSTMAN.

Run

Docker is needed to run your local YouPin API. After you have Docker, please follow the following instructions:

  1. Clone repo git clone [email protected]:youpin-city/youpin-api.git.

  2. Get credential GCS private key. Currently, YouPin API depends on Google Cloud Storage (GCS) to store photos and videos.

    1. Follow instruction 1 to 9 to get GCS private key.
    2. Rename the key to youpin_gcs_credentials_xxx.json where xxx is development for DEV environment or production for PROD environment.
    3. Place it under config/gcs/ (Ex. config/gcs/youpin_gcs_credentials_development.json)
  3. Setup your YouPin config. Always having config/default.json as a basic settings for DEV environment. If you want to run using PROD config, add additional config/production.json for PROD to replace some fields in default.json. Please find some useful templates under config/ folder itself.

  4. Start service with docker-compose up -d. The service will run on port 9100. To stop, run docker-compose stop. If you need to build a new docker image with modified code, run docker-compose up --build -d. To run on PROD, just add .env with the content NODE_ENV=production to YouPin root directory.

Changelog

0.1.0

  • Initial release

License

Copyright (c) 2016

Licensed under the MIT license.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].