CMS and API for InternetSemLimites colaborative project.
- All providers
GET /api/
- Hall of Fame
GET /api/fame/
- Hall of Shame
GET /api/shame/
- By state
GET /api/<state abbreviation>/
- Hall of Fame by state
GET /api/<state abbreviation>/fame/
- Hall of Shame by state
GET /api/<state abbreviation>/shame/
All API requests returns a JSON with list(s) of providers (providers
, hall-of-fame
or hall-of-shame
). Each provider is an obejct with the following properties:
category
: Hall of Fame or for Hall of Shamecoverage
: List os states covered by this providercreated_at
: Dated the provider was submitted to our servername
: Name of the providerother
: General information (e.g.: cities covered, residential and/or corporative only etc.)source
: URL for the source of the info (usually an archive.is link)url
: URL of the providerstatus
: (only for provider detail endpoint) moderation statusmoderation_reason
: (only for provider detail endpoint) moderation justification for the status above
Anyone can suggest new providers using our form.
Auto generated markdown files (main repository)
README.md
:GET /markdown/README.md
HALL_OF_SHAME.md
:GET /markdown/HALL_OF_SHAME.md
The CMS is based in Python 3.6 and Django. Once you have pipenv
available, install the dependencies:
pipenv install --dev
Copy contrib/.env.sample
as .env
in the project's root folder and adjust your settings. These are the main environment settings:
DEBUG
(boolean) enable or disable Django debug modeSECRET_KEY
(string) Django's secret keyALLOWED_HOSTS
(string) Django's allowed hosts
DATABASE_URL
(string) Database URL
DEFAULT_FROM_EMAIL
(string) default e-maill address to be used as the sender (e.g.[email protected]
)EMAIL_BACKEND
(string) Django e-mail backend (e.g.django.core.mail.backends.console.EmailBackend
)- SMTP e-mail settings:
EMAIL_HOST
(string),EMAIL_PORT
(integer),EMAIL_USE_TLS
(boolean),EMAIL_HOST_USER
(string), andEMAIL_HOST_PASSWORD
(string)
Once you're done with requirements, dependencies and settings, create the basic structure at the database and create a super-user for you:
pipenv run python manage.py migrate
pipenv run python manage.py createsuperuser
We serve static files through WhiteNoise, so depending on your configuration you might have to run:
pipenv run python manage.py collectstatic
Not sure? Run pipenv run python manage.py check
and pipenv run python manage.py test --parallel
just in case.
Run the server with pipenv run python manage.py runserver
and load localhost:8000 in your favorite browser.
If you created a super-user account, you can also use Django Admin at /admin/
.