Skip to content

Commit 3eb546f

Browse files
committed
Add extra info to docs for social connect
#347
1 parent fed6b98 commit 3eb546f

File tree

1 file changed

+27
-2
lines changed

1 file changed

+27
-2
lines changed

docs/installation.rst

Lines changed: 27 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -161,10 +161,35 @@ If you are using Twitter for your social authentication, it is a bit different s
161161
urlpatterns += [
162162
...,
163163
url(r'^rest-auth/twitter/$', TwitterLogin.as_view(), name='twitter_login')
164-
url(r'^rest-auth/twitter/connect/$', TwitterConnect.as_view(), name='twitter_login')
164+
url(r'^rest-auth/twitter/connect/$', TwitterConnect.as_view(), name='twitter_connect')
165165
]
166166
.. note:: Starting from v0.21.0, django-allauth has dropped support for context processors. Check out http://django-allauth.readthedocs.org/en/latest/changelog.html#from-0-21-0 for more details.
167167

168+
Additional Social Connect Views
169+
###############################
170+
171+
If you are using social connect views, you can also use additional views to check all social accounts attached to the current authenticated user and disconnect selected social accounts.
172+
173+
.. code-block:: python
174+
175+
from rest_auth.registration.views import (
176+
SocialAccountListView, SocialAccountDisconnectView
177+
)
178+
179+
urlpatterns += [
180+
...,
181+
url(
182+
r'^socialaccounts/$',
183+
SocialAccountListView.as_view(),
184+
name='social_account_list'
185+
),
186+
url(
187+
r'^socialaccounts/(?P<pk>\d+)/disconnect/$',
188+
SocialAccountDisconnectView.as_view(),
189+
name='social_account_disconnect'
190+
)
191+
]
192+
168193
169194
JWT Support (optional)
170195
----------------------
@@ -180,4 +205,4 @@ By default ``django-rest-auth`` uses Django's Token-based authentication. If you
180205

181206
.. code-block:: python
182207
183-
REST_USE_JWT = True
208+
REST_USE_JWT = True

0 commit comments

Comments
 (0)