Files
edx-platform/lms/djangoapps/discussion_api/urls.py
Greg Price 90f28dce31 Add thread list endpoint to the new discussion API
This is an initial implementation that only allows retrieval of all
threads for a course and only returns an easily computed subset of the
fields that are needed, in order to keep this change from getting too
large.

JIRA: MA-641
2015-05-05 11:45:09 -04:00

24 lines
553 B
Python

"""
Discussion API URLs
"""
from django.conf import settings
from django.conf.urls import include, patterns, url
from rest_framework.routers import SimpleRouter
from discussion_api.views import CourseTopicsView, ThreadViewSet
ROUTER = SimpleRouter()
ROUTER.register("threads", ThreadViewSet, base_name="thread")
urlpatterns = patterns(
"discussion_api",
url(
r"^v1/course_topics/{}".format(settings.COURSE_ID_PATTERN),
CourseTopicsView.as_view(),
name="course_topics"
),
url("^v1/", include(ROUTER.urls)),
)