Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

A python API for accessing RESTful resources on the force.com platform.

Project Description

Usage

Rest Force offers a python API for easily working with RESTful resources exposed by the force.com platform. Typical usage often looks like this:

#!/usr/bin/python

from restforce.login import SalesforceAuthenticationFailedException
from restforce.rest import Resources, RestInvocationException

try:
    r = Resources()
    print r.post('hello', '{ "postData" : "world"}')
    print r.get('hello/1')
    print r.delete('hello/1')
except SalesforceAuthenticationFailedException as e:
    print e
except RestInvocationException as e:
    print e

Salesforce REST Example

Creating a REST resource on the force.com platform is easy. Here’s an example::

@RestResource(urlMapping='/hello/*')
global class HelloResource {

    @HttpGet
    global static String doGet()
    {
        return 'Hello, world!';
    }

    @HttpDelete
    global static String doDelete()
    {
        return 'Good bye, cruel world!';
    }

}
Release History

Release History

This version
History Node

1.0.0

Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
RestForce-1.0.0.tar.gz (5.4 kB) Copy SHA256 Checksum SHA256 Source Apr 10, 2012

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting