| GET | /api/v1/salesforce/records | Query Salesforce Records Lists one page of records of one object, newest first, with totalSize as the count of all matches. With an API key or MCP token only object=Contact is allowed (403 otherwise, including when object is left at its Account default); a signed-in web session can read every supported object. 4 parametersobject (string) Account, Contact, Lead, Opportunity, Case or ContentVersion. Default Account; anything else returns 400.search (string) Contains-match on Name (Subject for Case, Title for ContentVersion). Trimmed and cut to 100 characters.limit (integer) Records per page, 1 to 200. Default 50.offset (integer) Records to skip, 0 to 1,900. Default 0.
Try Query Salesforce Records in the Playground |
| GET | /api/v1/salesforce/record | Get Salesforce Record Reads one record with Id plus the fields it can be edited with, to pre-fill an edit form. ContentVersion has no editable fields (400), the same Contact-only rule applies to API keys and MCP tokens as on Query Salesforce Records, and 404 means the record does not exist. 2 parametersobject (string, required) Account, Contact, Lead, Opportunity or Case.id (string, required) The record Id, 15 to 18 letters and digits.
Try Get Salesforce Record in the Playground |
| PATCH | /api/v1/salesforce/update | Update Salesforce Record Updates fields on one record. Only the object's editable fields are applied; other names, empty strings and nulls are dropped, so this cannot clear a field. 400 when no field is left to update or the Id is not a valid Salesforce Id. 3 parametersobject (string, required) Account, Contact, Lead, Opportunity or Case.id (string, required) The record Id, 15 to 18 letters and digits.fields (object, required) Field name to new value. Editable fields: Account: Name, Industry, Phone, Website, BillingCity, BillingState. Contact: LastName, FirstName, Email, Phone, MailingStreet, MailingCity, MailingState, MailingPostalCode, Description, Title, Department. Lead: LastName, FirstName, Company, Email, Phone, Street, City, State, PostalCode, Website, Description, Status, LeadSource. Opportunity: Name, StageName, CloseDate, Amount. Case: Subject, Status, Priority, Origin.
|
| POST | /api/v1/salesforce/records/delete-all | Delete All Salesforce Records Permanently deletes every record of one object that matches search, through a Salesforce bulk delete job; with no search it deletes every record of that object in the org. object is required here (there is no default), and the request waits for the job, up to 15 minutes, before reporting the counts. 2 parametersobject (string, required) Account, Contact, Lead, Opportunity, Case or ContentVersion.search (string) Delete only records whose Name (Subject for Case, Title for ContentVersion) contains this text. Max 100 characters.
|
| GET | /api/v1/salesforce/records/export | Export Salesforce Records (CSV) Downloads every matching record of one object (all pages) as a CSV file with the same columns as Query Salesforce Records; pass ids to export only chosen records. Cells starting with =, +, - or @ get a leading apostrophe, and Id, phone and ZIP cells are quoted with a leading tab so spreadsheets keep them as text. The file starts with a UTF-8 byte-order mark. 3 parametersobject (string) Account, Contact, Lead, Opportunity, Case or ContentVersion. Default Account.search (string) Contains-match on Name (Subject for Case, Title for ContentVersion). Trimmed and cut to 100 characters.ids (string) Comma-separated record Ids to export. Invalid Ids are dropped; at most 500 are used.
|
| POST | /api/v1/salesforce/upload | Create Salesforce Records Creates one record per row, for up to 200 rows (extra rows are ignored). Each row is reported on its own, so the call returns 200 even when rows fail; disconnected: true means the connection dropped part-way and the remaining rows were not tried. Contact and Lead rows also accept common column names (first_name, last_name, email, phone, city, state, zip), and a Contact row's company and website are added to its Description. 2 parametersobject (string, required) Account, Contact, Lead, Opportunity or Case.rows (array, required) Objects of field name to value; the first 200 are used, and unknown fields and empty values are dropped. Required: Account Name; Contact LastName; Lead LastName and Company; Opportunity Name, StageName and CloseDate; Case Subject. Field names as in Update Salesforce Record.
|
| POST | /api/v1/salesforce/upload/file | Upload File to Salesforce Uploads one file, up to 10 MB, as a Salesforce File (ContentVersion). Send multipart/form-data with the file in a field named file, plus targetRecordId to attach it to a record. 400 if no file is sent. 2 parametersfile (file, required) The file, as a multipart/form-data part. Max 10 MB.targetRecordId (string) Id of the record to attach the file to, such as an Account or Contact. Omit to upload it unattached.
|
| POST | /api/v1/salesforce/enrich-sync | Sync Salesforce Contacts for Enrichment Copies Salesforce Contacts into a new Connect Data upload, ready to map and enrich, named "Salesforce Contacts" (then "Salesforce Contacts (2)" and so on). Mode all takes the 5,000 newest contacts, optionally filtered by search; mode selected takes the given Ids. The upload has the columns First Name, Last Name, Company Name, Email, Phone, Title, Address, City, State and ZIP (a blank mailing address is filled from the contact's other address or its account); 400 when no contacts are found, and GTM Scoop accounts can run 20 CRM syncs per hour. 4 parametersmode (string) "all" (default; any other value counts as all) or "selected".ids (array) Required for selected mode: Contact Ids (15 to 18 letters and digits; invalid Ids are dropped), at most 5,000. Selected mode with no valid Id fails.search (string) All mode only: only Contacts whose Name contains this text. Max 100 characters.businessContext (object) Context stored with the upload for later AI analysis: { companyName, website, businessContext, updatedAt }, all strings. At most 4,000 characters in total; a larger value is refused.
|
| POST | /api/v1/salesforce/writeback-leads | Write Matched Rows to Salesforce as Leads Creates a Salesforce Lead for each matched row of an analysis run, up to 10,000 rows; above 1,000 rows a Salesforce bulk job is used and the call waits up to 2 minutes for it (processing: true and a jobId mean it was still running). Rows come from savedListId, else runId, else uploadId; when the run has no matched rows it falls back to its other results and then to the upload's own rows. Each Lead gets the org's default Lead Status (else its first active, non-converted one) and Lead Source "Other" when that value is active; 400 if there is nothing to write. 4 parametersrunId (string) The analysis run whose rows to write. Send runId, uploadId or savedListId.mode (string) "ai" (default; any other value counts as ai) or "data": which of the run's results to try first. Used with runId.uploadId (string) An upload: its run is written when runId is not sent, and its own rows are the last fallback.savedListId (string) A saved results list to write instead of a run (404 if it is not this account's).
|