Simple scripts to interact with the Force.com REST API from the command line.
- getting started
- reference
- more information
You must update the login script with your OAuth credentials and the appropriate URLs. Then after running it you will be able to make requests.
-
login.sh
./login.sh USERNAME PASSWORD
Perform username-password OAuth authentication and set an environment variable with the Force.com session id.
You must log in before making any other requests.
-
get.sh
./get.sh path/to/resource
Makes an HTTP get request for the given API resource.
Returns the JSON returned by the request.
-
post.sh
./post.sh path/to/resource data_to_post.json HTTP_METHOD
Make an HTTP post, patch or delete to the given API resource. Pass the specified data as the body of the request.
Returns the JSON returned by the request.
http://www.salesforce.com/us/developer/docs/api_rest/index.htm