Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1060985
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T18:24:36+00:00 2026-05-16T18:24:36+00:00

Is there an online resource that shows how to write a simple (but robust)

  • 0

Is there an online resource that shows how to write a simple (but robust) RESTFUL server/client (preferably with authentication), written in Python?

The objective is to be able to write my own lightweight RESTFUL services without being encumbered by an entire web framework. Having said that, if there is a way to do this (i.e. write RESFUL services) in a lightweight manner using Django, I’d be equally interested.

Actually, coming to thing of it, I may even PREFER a Django based solution (provided its lightweight enough – i.e. does not bring the whole framework into play), since I will be able to take advantage of only the components I need, in order to implement better security/access to the services.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T18:24:36+00:00Added an answer on May 16, 2026 at 6:24 pm

    Well, first of all you can use django-piston, as @Tudorizer already mentioned.

    But then again, as I see it (and I might be wrong!), REST is more of a set of design guidelines, rather than a concrete API. What it essentially says is that the interaction with your service should not be based on ‘things you can do’ (typical RPC-style methods), but rather ‘things, you can act on in predictable ways, organized in a certain way’ (the ‘resource’ entity and http verbs).

    That being said, you don’t need anything extra to write REST-style services using django.

    Consider the following:

    # urlconf
    from django.conf.urls.defaults import patterns, url
    urlpatterns = patterns('',
        url(r'^tickets$', 'myapp.views.tickets', name='tickets'),
        url(r'^ticket/(?P<id>\d+)$', 'myapp.views.tickets', name='ticket'),
        url(r'^ticket$', 'myapp.views.tickets', name='ticket'),
    )
    
    # views
    def tickets(request):
        tickets = Ticket.objects.all()
        return render_to_response('tickets.html', {'tickets':tickets})
    
    def ticket(request, id=None):
        if id is not None:
            ticket = get_object_or_404(Ticket, id=id)
        if request.method == 'POST':
            # create or update ticket here
        else:
            # just render the ticket (GET)
        ...
    

    … and so on.

    What matters is how your service is exposed to its user, not the library/toolkit/framework it uses.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We are signing up to an online resource that uses http-referer as authentication (bad
I've researched online and found several interesting Perl modules/frameworks, such as HTML:Mason, HTML::Embperl, or
I am thinking of writing a DSL to be run in the .Net environment.
i'm trying to create an application which connects to internet and consume web services
I was tweaking my .htaccess file for the first time, and ran into the
Does anyone know of a decent reference for synchronization issues in C++? I'm thinking
I am reviewing / redesigning / refactoring a database and want to create a
I have been working on forms only recently and I am still puzzeld by
Background I am developing a social web app for poets and writers, allowing them

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.