How to make a custom Django api [closed] - python

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I made a simple Django website which supports user authentication(login/Logoff) and Registration I want to make a custom API which does this using REST how would i do this

What you want is to learn how to create REST API in Django, Here we cannot write the whole code for your requirement but can give you suggestion as per your question.
as #Siegmeyer said in comment that you should use the Django Rest Framework which is best and have tutorials and examples too:
Strongly Re-commanded to use:
http://www.django-rest-framework.org/
Read blog with link below for step by step tutorial:
http://agiliq.com/blog/2014/12/building-a-restful-api-with-django-rest-framework
For video check link below:
https://godjango.com/41-start-your-api-django-rest-framework-part-1/
or try youtube:
https://www.youtube.com/results?q=rest+api+in+django+rest+framework
These may help you crate your API in Django.

Related

How to use membership ( user account) in Django? [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 3 years ago.
Improve this question
I am a beginner in Django and need to learn it for a local bot web application.
Usually, modern MVC and MVM web frameworks such as ASP.net core and meteor have simple possibilities and tricks for membership and the user account (especially meteor). But I didn't find anything about this in Django. Does Django has these possibilities or I should download third-party packages?
Django has of course several methods related to user authentication or ACL and so on.
See this
https://docs.djangoproject.com/en/2.1/topics/auth/default/
One exemple you can retrive user of request:
request.user

How can I get Youtube videos after searching through the Youtube api [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
I want to make a python program that uses Youtube's api. The thing that I want to do is searching Youtube videos and showing the results in my program. Program gonna run like this: There is gonna be a textbox you write something and hit enter then you'll see the Youtube results below . What should I do for doing this in python or is this impossible?
Youtube has a Data API with very helpful example snippets. I would suggest reading through the official documentation before proceeding.
Relevant section: https://developers.google.com/youtube/v3/docs/search/list
Snippet tool instructions: https://google-developers.appspot.com/youtube/v3/code_samples/code_snippet_instructions

Discussion comments from Coursera [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 7 years ago.
Improve this question
I would like to do a simple machine learning project where I want to analyse comments from discussion forums on Coursera courses.
However, I am not sure if it is possible to do so programatically. So, providing a course page address, user name, password and getting all the discussion forums comments.
Being able to use Python for this would be awesome but I am language agnostic.
You can access web pages with python using urllib:
https://docs.python.org/2/library/urllib.html
or the higher lever interface requests:
http://requests.readthedocs.org/en/latest/
Then you still have to parse the content of the page and extract the comments.

Django website that use webcrawling [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I made in python a webcrawler, and I want to make Django website to display the results of the crawling, can I do it? for example: the crawler enter to "https://stackoverflow.com/questions" and take the questins of the first page and display it on the website(maybe on the tamplate of Django).
EDIT: I just re-read your question and it looks like you're already doing the scraping? You should implement that functionality into a Django site and then yes of course you can display it.
Yes you can do it. A great combination for web scraping with django is using the python requests library (which I'm guessing you're using) andBeautiful Soup. I've used this combination in a few different projects and I've been happy with it.
Another popular option uses the python Scrapy library and combines it into a django app called django-dynamic-scraper.
Hopefully this points you in the right direction.

Is it possible to use Boto with Django? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I'm really unfamiliar in this area. Is it possible to access the AWS API from Django? E.g. by using Boto? Can that be run on Django?
Yes.
There is even a django app for using boto. It is called django-boto.
It is the first result when you search for "django boto".
Sure. boto is just python library and you can use it from Django.
I used boto from other web frameworks (CherryPy, Flask), and it simply works. There is no reason it would not work with Django.

Categories