Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add API endpoint for issuing programs certificates #11541

Merged
merged 1 commit into from
Feb 17, 2016

Conversation

rlucioni
Copy link
Contributor

Allows staff users to manually enqueue the task responsible for awarding programs certificates. ECOM-3692.

@jimabramson please review.

@rlucioni rlucioni force-pushed the renzo/manual-cert-trigger branch 4 times, most recently from 75be793 to 3633db6 Compare February 16, 2016 21:47
@rlucioni
Copy link
Contributor Author

@jimabramson I've moved the endpoint to the LMS support app.


from rest_framework import permissions, status, views
from rest_framework.response import Response
from rest_framework.authentication import SessionAuthentication

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: alphabetization

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You got me! Fixed.

@jimabramson
Copy link

@rlucioni LGTM. Is CSRF protection happening by default (under session auth)? I don't see it as a high risk endpoint, but if we need to explicitly enable protection then I believe we should do that.

@rlucioni
Copy link
Contributor Author

@jimabramson DRF's SessionAuthentication enforces CSRF validation by default (reference).

Allows staff users to manually enqueue the task responsible for awarding programs certificates. ECOM-3692.
@rlucioni rlucioni force-pushed the renzo/manual-cert-trigger branch from 3633db6 to 619420b Compare February 17, 2016 18:52
@jimabramson
Copy link

👍 once tests pass.

rlucioni pushed a commit that referenced this pull request Feb 17, 2016
Add API endpoint for issuing programs certificates
@rlucioni rlucioni merged commit 62d07c9 into master Feb 17, 2016
@rlucioni rlucioni deleted the renzo/manual-cert-trigger branch February 17, 2016 20:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants