Skip to content

Instantly share code, notes, and snippets.

@mlynch
Created July 24, 2013 23:43
Show Gist options
  • Save mlynch/6075648 to your computer and use it in GitHub Desktop.
Save mlynch/6075648 to your computer and use it in GitHub Desktop.
// Use client to interact with Force.com platform
client.create("Account", { "Name" : "blerg3" },
function(response) {
console.log(response);
alert("Object successfully created.");
},
function(errorXhr) {
if (errorXhr.status == 401) {
// Invalid access token
login();
} else {
alert("Error creating object.");
}
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment