post https://youraccountname.api-us1.com/api/3/customObjects/records/
record.id and record.externalId are optional if record is new
New records are "upserted":
Any value in
id
will be ignored if there is no record matching that id, and a new record will be created with an assigned, newid
. If an existing record has a matchingid
provided in the request body, the existing record with that same id will be overwritten to the new record.
externalId
can be used for updating and reference, and can be updated.
id
can be used for updating and reference, but are automatically assigned on record creation and can not be changed.
{
"record": {
"id": "this-id-is-created-on-a-new-record-and-can-not-be-updated",
"externalId": "external-id-that-can-be-updated",
"fields": [
{
"id": "my-number-field",
"value": 100
}
],
"relationships": {
"primary-contact": [
14
]
}
}
}
{
"record": {
"id": "test-obj-1",
"externalId": "test-obj-1",
"schemaId": "6449c3f3-b68d-46d1-850b-c8aea998ce1b",
"fields": [
{
"id": "my-number-field",
"value": 100
}
],
"relationships": {
"primary-contact": [
"14"
]
}
}
}