# Salesforce (/integrations/salesforce)





{/* MANUAL-CONTENT-START:intro */}

Use [Salesforce](https://www.salesforce.com/) in Sim to manage accounts, contacts, leads, opportunities, cases, and tasks, run reports and SOQL queries, and create custom fields and objects through the Tooling API.

{/* MANUAL-CONTENT-END */}

Connection guides: [Integration users](/integrations/salesforce-service-account).

## OAuth scopes [#oauth-scopes]

Sim requests these scopes when someone connects a Salesforce account. For a self-hosted deployment, register your own app with the provider using the settings below. See [Integrations and OAuth](/platform/self-hosting/integrations-oauth) for setup.

| Setting | Value |
| - | - |
| Redirect URI | Production or Developer Edition: `<NEXT_PUBLIC_APP_URL>/api/auth/oauth2/callback/salesforce`<br />Sandbox: `<NEXT_PUBLIC_APP_URL>/api/auth/oauth2/callback/salesforce-sandbox` |
| Environment variables | `SALESFORCE_CLIENT_ID`, `SALESFORCE_CLIENT_SECRET` |

| Scope | Description |
| - | - |
| `api` | Access Salesforce API |
| `refresh_token` | Maintain long-term access to Salesforce account |
| `openid` | Standard authentication |

## Use the block [#usage-instructions]

Manage accounts, contacts, leads, opportunities, cases, and tasks, run reports and SOQL queries, and manage org schema by creating custom fields and objects via the Tooling API.

## Actions [#actions]

### Get Accounts from Salesforce [#get-accounts-from-salesforce]

Retrieve accounts from Salesforce CRM

<ReferenceDetails>
  #### Input [#input]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `limit` | string | No | Maximum number of results (default: 100, max: 2000) |
  | `fields` | string | No | Comma-separated field API names (e.g., "Id,Name,Industry,Phone") |
  | `orderBy` | string | No | Field and direction for sorting (e.g., "Name ASC" or "CreatedDate DESC") |

  #### Output [#output]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Accounts data |
  | ↳ `paging` | object | Pagination information from Salesforce API |
  | ↳ `nextRecordsUrl` | string | URL to fetch the next batch of records (present when done is false) |
  | ↳ `totalSize` | number | Total number of records matching the query (may exceed records returned) |
  | ↳ `done` | boolean | Whether all records have been returned (false if more batches exist) |
  | ↳ `metadata` | object | Response metadata |
  | ↳ `totalReturned` | number | Number of records returned in this response |
  | ↳ `hasMore` | boolean | Whether more records exist (inverse of done) |
  | ↳ `accounts` | array | Array of account objects |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### Create Account in Salesforce [#create-account-in-salesforce]

Create a new account in Salesforce CRM

<ReferenceDetails>
  #### Input [#input-1]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `name` | string | Yes | Account name (required) |
  | `type` | string | No | Account type (e.g., Customer, Partner, Prospect) |
  | `industry` | string | No | Industry (e.g., Technology, Healthcare, Finance) |
  | `phone` | string | No | Phone number |
  | `website` | string | No | Website URL |
  | `billingStreet` | string | No | Billing street address |
  | `billingCity` | string | No | Billing city |
  | `billingState` | string | No | Billing state/province |
  | `billingPostalCode` | string | No | Billing postal code |
  | `billingCountry` | string | No | Billing country |
  | `description` | string | No | Account description |
  | `annualRevenue` | string | No | Annual revenue as a number |
  | `numberOfEmployees` | string | No | Number of employees as an integer |

  #### Output [#output-1]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Created account data |
  | ↳ `id` | string | The Salesforce ID of the newly created record |
  | ↳ `success` | boolean | Whether the create operation was successful |
  | ↳ `created` | boolean | Whether the record was created (always true on success) |
</ReferenceDetails>

### Update Account in Salesforce [#update-account-in-salesforce]

Update an existing account in Salesforce CRM

<ReferenceDetails>
  #### Input [#input-2]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `accountId` | string | Yes | Salesforce Account ID to update (18-character string starting with 001) |
  | `name` | string | No | Account name |
  | `type` | string | No | Account type (e.g., Customer, Partner, Prospect) |
  | `industry` | string | No | Industry (e.g., Technology, Healthcare, Finance) |
  | `phone` | string | No | Phone number |
  | `website` | string | No | Website URL |
  | `billingStreet` | string | No | Billing street address |
  | `billingCity` | string | No | Billing city |
  | `billingState` | string | No | Billing state/province |
  | `billingPostalCode` | string | No | Billing postal code |
  | `billingCountry` | string | No | Billing country |
  | `description` | string | No | Account description |
  | `annualRevenue` | string | No | Annual revenue as a number |
  | `numberOfEmployees` | string | No | Number of employees as an integer |

  #### Output [#output-2]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Updated account data |
  | ↳ `id` | string | The Salesforce ID of the updated record |
  | ↳ `updated` | boolean | Whether the record was updated (always true on success) |
</ReferenceDetails>

### Delete Account from Salesforce [#delete-account-from-salesforce]

Delete an account from Salesforce CRM

<ReferenceDetails>
  #### Input [#input-3]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `accountId` | string | Yes | Salesforce Account ID to delete (18-character string starting with 001) |

  #### Output [#output-3]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Deleted account data |
  | ↳ `id` | string | The Salesforce ID of the deleted record |
  | ↳ `deleted` | boolean | Whether the record was deleted (always true on success) |
</ReferenceDetails>

### Get Contacts from Salesforce [#get-contacts-from-salesforce]

Get contact(s) from Salesforce - single contact if ID provided, or list if not

<ReferenceDetails>
  #### Input [#input-4]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `contactId` | string | No | Salesforce Contact ID (18-character string starting with 003) to get a single contact |
  | `limit` | string | No | Maximum number of results (default: 100, max: 2000). Only for list query. |
  | `fields` | string | No | Comma-separated field API names (e.g., "Id,FirstName,LastName,Email,Phone") |
  | `orderBy` | string | No | Field and direction for sorting (e.g., "LastName ASC"). Only for list query. |

  #### Output [#output-4]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Contact(s) data |
  | ↳ `paging` | object | Pagination information from Salesforce API |
  | ↳ `nextRecordsUrl` | string | URL to fetch the next batch of records (present when done is false) |
  | ↳ `totalSize` | number | Total number of records matching the query (may exceed records returned) |
  | ↳ `done` | boolean | Whether all records have been returned (false if more batches exist) |
  | ↳ `metadata` | object | Response metadata |
  | ↳ `totalReturned` | number | Number of records returned in this response |
  | ↳ `hasMore` | boolean | Whether more records exist (inverse of done) |
  | ↳ `contacts` | array | Array of contacts (list query) |
  | ↳ `contact` | object | Single contact (by ID) |
  | ↳ `singleContact` | boolean | Whether single contact was returned |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### Create Contact in Salesforce [#create-contact-in-salesforce]

Create a new contact in Salesforce CRM

<ReferenceDetails>
  #### Input [#input-5]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `lastName` | string | Yes | Last name (required) |
  | `firstName` | string | No | First name |
  | `email` | string | No | Email address |
  | `phone` | string | No | Phone number |
  | `accountId` | string | No | Salesforce Account ID (18-character string starting with 001) |
  | `title` | string | No | Job title |
  | `department` | string | No | Department |
  | `mailingStreet` | string | No | Mailing street |
  | `mailingCity` | string | No | Mailing city |
  | `mailingState` | string | No | Mailing state |
  | `mailingPostalCode` | string | No | Mailing postal code |
  | `mailingCountry` | string | No | Mailing country |
  | `description` | string | No | Contact description |

  #### Output [#output-5]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Created contact data |
  | ↳ `id` | string | The Salesforce ID of the newly created record |
  | ↳ `success` | boolean | Whether the create operation was successful |
  | ↳ `created` | boolean | Whether the record was created (always true on success) |
</ReferenceDetails>

### Update Contact in Salesforce [#update-contact-in-salesforce]

Update an existing contact in Salesforce CRM

<ReferenceDetails>
  #### Input [#input-6]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `contactId` | string | Yes | Salesforce Contact ID to update (18-character string starting with 003) |
  | `lastName` | string | No | Last name |
  | `firstName` | string | No | First name |
  | `email` | string | No | Email address |
  | `phone` | string | No | Phone number |
  | `accountId` | string | No | Salesforce Account ID (18-character string starting with 001) |
  | `title` | string | No | Job title |
  | `department` | string | No | Department |
  | `mailingStreet` | string | No | Mailing street |
  | `mailingCity` | string | No | Mailing city |
  | `mailingState` | string | No | Mailing state |
  | `mailingPostalCode` | string | No | Mailing postal code |
  | `mailingCountry` | string | No | Mailing country |
  | `description` | string | No | Contact description |

  #### Output [#output-6]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Updated contact data |
  | ↳ `id` | string | The Salesforce ID of the updated record |
  | ↳ `updated` | boolean | Whether the record was updated (always true on success) |
</ReferenceDetails>

### Delete Contact from Salesforce [#delete-contact-from-salesforce]

Delete a contact from Salesforce CRM

<ReferenceDetails>
  #### Input [#input-7]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `contactId` | string | Yes | Salesforce Contact ID to delete (18-character string starting with 003) |

  #### Output [#output-7]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Deleted contact data |
  | ↳ `id` | string | The Salesforce ID of the deleted record |
  | ↳ `deleted` | boolean | Whether the record was deleted (always true on success) |
</ReferenceDetails>

### Get Leads from Salesforce [#get-leads-from-salesforce]

Retrieve lead(s) from Salesforce CRM

<ReferenceDetails>
  #### Input [#input-8]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `leadId` | string | No | Salesforce Lead ID (18-character string starting with 00Q) to get a single lead |
  | `limit` | string | No | Maximum number of results to return (default: 100) |
  | `fields` | string | No | Comma-separated list of field API names to return |
  | `orderBy` | string | No | Field and direction for sorting (e.g., LastName ASC) |

  #### Output [#output-8]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Lead data |
  | ↳ `paging` | object | Pagination information from Salesforce API |
  | ↳ `nextRecordsUrl` | string | URL to fetch the next batch of records (present when done is false) |
  | ↳ `totalSize` | number | Total number of records matching the query (may exceed records returned) |
  | ↳ `done` | boolean | Whether all records have been returned (false if more batches exist) |
  | ↳ `metadata` | object | Response metadata |
  | ↳ `totalReturned` | number | Number of records returned in this response |
  | ↳ `hasMore` | boolean | Whether more records exist (inverse of done) |
  | ↳ `lead` | object | Single lead object (when leadId provided) |
  | ↳ `leads` | array | Array of lead objects (when listing) |
  | ↳ `singleLead` | boolean | Whether single lead was returned |
  | ↳ `success` | boolean | Operation success status |
</ReferenceDetails>

### Create Lead in Salesforce [#create-lead-in-salesforce]

Create a new lead

<ReferenceDetails>
  #### Input [#input-9]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `lastName` | string | Yes | Last name (required) |
  | `company` | string | Yes | Company name (required) |
  | `firstName` | string | No | First name |
  | `email` | string | No | Email address |
  | `phone` | string | No | Phone number |
  | `status` | string | No | Lead status (e.g., Open, Working, Closed) |
  | `leadSource` | string | No | Lead source (e.g., Web, Referral, Campaign) |
  | `title` | string | No | Job title |
  | `description` | string | No | Lead description |

  #### Output [#output-9]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Created lead data |
  | ↳ `id` | string | The Salesforce ID of the newly created record |
  | ↳ `success` | boolean | Whether the create operation was successful |
  | ↳ `created` | boolean | Whether the record was created (always true on success) |
</ReferenceDetails>

### Update Lead in Salesforce [#update-lead-in-salesforce]

Update an existing lead

<ReferenceDetails>
  #### Input [#input-10]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `leadId` | string | Yes | Salesforce Lead ID to update (18-character string starting with 00Q) |
  | `lastName` | string | No | Last name |
  | `company` | string | No | Company name |
  | `firstName` | string | No | First name |
  | `email` | string | No | Email address |
  | `phone` | string | No | Phone number |
  | `status` | string | No | Lead status (e.g., Open, Working, Closed) |
  | `leadSource` | string | No | Lead source (e.g., Web, Referral, Campaign) |
  | `title` | string | No | Job title |
  | `description` | string | No | Lead description |

  #### Output [#output-10]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Updated lead data |
  | ↳ `id` | string | The Salesforce ID of the updated record |
  | ↳ `updated` | boolean | Whether the record was updated (always true on success) |
</ReferenceDetails>

### Delete Lead from Salesforce [#delete-lead-from-salesforce]

Delete a lead

<ReferenceDetails>
  #### Input [#input-11]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `leadId` | string | Yes | Salesforce Lead ID to delete (18-character string starting with 00Q) |

  #### Output [#output-11]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Deleted lead data |
  | ↳ `id` | string | The Salesforce ID of the deleted record |
  | ↳ `deleted` | boolean | Whether the record was deleted (always true on success) |
</ReferenceDetails>

### Get Opportunities from Salesforce [#get-opportunities-from-salesforce]

Get opportunity(ies) from Salesforce

<ReferenceDetails>
  #### Input [#input-12]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `opportunityId` | string | No | Salesforce Opportunity ID (18-character string starting with 006) to get a single opportunity |
  | `limit` | string | No | Maximum number of results to return (default: 100) |
  | `fields` | string | No | Comma-separated list of field API names to return |
  | `orderBy` | string | No | Field and direction for sorting (e.g., CloseDate DESC) |

  #### Output [#output-12]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Opportunity data |
  | ↳ `paging` | object | Pagination information from Salesforce API |
  | ↳ `nextRecordsUrl` | string | URL to fetch the next batch of records (present when done is false) |
  | ↳ `totalSize` | number | Total number of records matching the query (may exceed records returned) |
  | ↳ `done` | boolean | Whether all records have been returned (false if more batches exist) |
  | ↳ `metadata` | object | Response metadata |
  | ↳ `totalReturned` | number | Number of records returned in this response |
  | ↳ `hasMore` | boolean | Whether more records exist (inverse of done) |
  | ↳ `opportunity` | object | Single opportunity object (when opportunityId provided) |
  | ↳ `opportunities` | array | Array of opportunity objects (when listing) |
  | ↳ `success` | boolean | Operation success status |
</ReferenceDetails>

### Create Opportunity in Salesforce [#create-opportunity-in-salesforce]

Create a new opportunity

<ReferenceDetails>
  #### Input [#input-13]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `name` | string | Yes | Opportunity name (required) |
  | `stageName` | string | Yes | Stage name (required, e.g., Prospecting, Qualification, Closed Won) |
  | `closeDate` | string | Yes | Close date in YYYY-MM-DD format (required) |
  | `accountId` | string | No | Salesforce Account ID (18-character string starting with 001) |
  | `amount` | string | No | Deal amount as a number |
  | `probability` | string | No | Win probability as integer (0-100) |
  | `description` | string | No | Opportunity description |

  #### Output [#output-13]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Created opportunity data |
  | ↳ `id` | string | The Salesforce ID of the newly created record |
  | ↳ `success` | boolean | Whether the create operation was successful |
  | ↳ `created` | boolean | Whether the record was created (always true on success) |
</ReferenceDetails>

### Update Opportunity in Salesforce [#update-opportunity-in-salesforce]

Update an existing opportunity

<ReferenceDetails>
  #### Input [#input-14]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `opportunityId` | string | Yes | Salesforce Opportunity ID to update (18-character string starting with 006) |
  | `name` | string | No | Opportunity name |
  | `stageName` | string | No | Stage name (e.g., Prospecting, Qualification, Closed Won) |
  | `closeDate` | string | No | Close date in YYYY-MM-DD format |
  | `accountId` | string | No | Salesforce Account ID (18-character string starting with 001) |
  | `amount` | string | No | Deal amount as a number |
  | `probability` | string | No | Win probability as integer (0-100) |
  | `description` | string | No | Opportunity description |

  #### Output [#output-14]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Updated opportunity data |
  | ↳ `id` | string | The Salesforce ID of the updated record |
  | ↳ `updated` | boolean | Whether the record was updated (always true on success) |
</ReferenceDetails>

### Delete Opportunity from Salesforce [#delete-opportunity-from-salesforce]

Delete an opportunity

<ReferenceDetails>
  #### Input [#input-15]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `opportunityId` | string | Yes | Salesforce Opportunity ID to delete (18-character string starting with 006) |

  #### Output [#output-15]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Deleted opportunity data |
  | ↳ `id` | string | The Salesforce ID of the deleted record |
  | ↳ `deleted` | boolean | Whether the record was deleted (always true on success) |
</ReferenceDetails>

### Get Cases from Salesforce [#get-cases-from-salesforce]

Get case(s) from Salesforce

<ReferenceDetails>
  #### Input [#input-16]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `caseId` | string | No | Salesforce Case ID (18-character string starting with 500) to get a single case |
  | `limit` | string | No | Maximum number of results to return (default: 100) |
  | `fields` | string | No | Comma-separated list of field API names to return |
  | `orderBy` | string | No | Field and direction for sorting (e.g., CreatedDate DESC) |

  #### Output [#output-16]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Case data |
  | ↳ `paging` | object | Pagination information from Salesforce API |
  | ↳ `nextRecordsUrl` | string | URL to fetch the next batch of records (present when done is false) |
  | ↳ `totalSize` | number | Total number of records matching the query (may exceed records returned) |
  | ↳ `done` | boolean | Whether all records have been returned (false if more batches exist) |
  | ↳ `metadata` | object | Response metadata |
  | ↳ `totalReturned` | number | Number of records returned in this response |
  | ↳ `hasMore` | boolean | Whether more records exist (inverse of done) |
  | ↳ `case` | object | Single case object (when caseId provided) |
  | ↳ `cases` | array | Array of case objects (when listing) |
  | ↳ `success` | boolean | Operation success status |
</ReferenceDetails>

### Create Case in Salesforce [#create-case-in-salesforce]

Create a new case

<ReferenceDetails>
  #### Input [#input-17]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `subject` | string | Yes | Case subject (required) |
  | `status` | string | No | Status (e.g., New, Working, Escalated) |
  | `priority` | string | No | Priority (e.g., Low, Medium, High) |
  | `origin` | string | No | Origin (e.g., Phone, Email, Web) |
  | `contactId` | string | No | Salesforce Contact ID (18-character string starting with 003) |
  | `accountId` | string | No | Salesforce Account ID (18-character string starting with 001) |
  | `description` | string | No | Case description |

  #### Output [#output-17]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Created case data |
  | ↳ `id` | string | The Salesforce ID of the newly created record |
  | ↳ `success` | boolean | Whether the create operation was successful |
  | ↳ `created` | boolean | Whether the record was created (always true on success) |
</ReferenceDetails>

### Update Case in Salesforce [#update-case-in-salesforce]

Update an existing case

<ReferenceDetails>
  #### Input [#input-18]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `caseId` | string | Yes | Salesforce Case ID to update (18-character string starting with 500) |
  | `subject` | string | No | Case subject |
  | `status` | string | No | Status (e.g., New, Working, Escalated, Closed) |
  | `priority` | string | No | Priority (e.g., Low, Medium, High) |
  | `origin` | string | No | Origin (e.g., Phone, Email, Web) |
  | `contactId` | string | No | Salesforce Contact ID (18-character string starting with 003) |
  | `accountId` | string | No | Salesforce Account ID (18-character string starting with 001) |
  | `description` | string | No | Case description |

  #### Output [#output-18]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Updated case data |
  | ↳ `id` | string | The Salesforce ID of the updated record |
  | ↳ `updated` | boolean | Whether the record was updated (always true on success) |
</ReferenceDetails>

### Delete Case from Salesforce [#delete-case-from-salesforce]

Delete a case

<ReferenceDetails>
  #### Input [#input-19]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `caseId` | string | Yes | Salesforce Case ID to delete (18-character string starting with 500) |

  #### Output [#output-19]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Deleted case data |
  | ↳ `id` | string | The Salesforce ID of the deleted record |
  | ↳ `deleted` | boolean | Whether the record was deleted (always true on success) |
</ReferenceDetails>

### Get Tasks from Salesforce [#get-tasks-from-salesforce]

Get task(s) from Salesforce

<ReferenceDetails>
  #### Input [#input-20]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `taskId` | string | No | Salesforce Task ID (18-character string starting with 00T) to get a single task |
  | `limit` | string | No | Maximum number of results to return (default: 100) |
  | `fields` | string | No | Comma-separated list of field API names to return |
  | `orderBy` | string | No | Field and direction for sorting (e.g., ActivityDate DESC) |

  #### Output [#output-20]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Task data |
  | ↳ `paging` | object | Pagination information from Salesforce API |
  | ↳ `nextRecordsUrl` | string | URL to fetch the next batch of records (present when done is false) |
  | ↳ `totalSize` | number | Total number of records matching the query (may exceed records returned) |
  | ↳ `done` | boolean | Whether all records have been returned (false if more batches exist) |
  | ↳ `metadata` | object | Response metadata |
  | ↳ `totalReturned` | number | Number of records returned in this response |
  | ↳ `hasMore` | boolean | Whether more records exist (inverse of done) |
  | ↳ `task` | object | Single task object (when taskId provided) |
  | ↳ `tasks` | array | Array of task objects (when listing) |
  | ↳ `success` | boolean | Operation success status |
</ReferenceDetails>

### Create Task in Salesforce [#create-task-in-salesforce]

Create a new task

<ReferenceDetails>
  #### Input [#input-21]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `subject` | string | Yes | Task subject (required) |
  | `status` | string | No | Status (e.g., Not Started, In Progress, Completed) |
  | `priority` | string | No | Priority (e.g., Low, Normal, High) |
  | `activityDate` | string | No | Due date in YYYY-MM-DD format |
  | `whoId` | string | No | Related Contact ID (003...) or Lead ID (00Q...) |
  | `whatId` | string | No | Related Account ID (001...) or Opportunity ID (006...) |
  | `description` | string | No | Task description |

  #### Output [#output-21]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Created task data |
  | ↳ `id` | string | The Salesforce ID of the newly created record |
  | ↳ `success` | boolean | Whether the create operation was successful |
  | ↳ `created` | boolean | Whether the record was created (always true on success) |
</ReferenceDetails>

### Update Task in Salesforce [#update-task-in-salesforce]

Update an existing task

<ReferenceDetails>
  #### Input [#input-22]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `taskId` | string | Yes | Salesforce Task ID to update (18-character string starting with 00T) |
  | `subject` | string | No | Task subject |
  | `status` | string | No | Status (e.g., Not Started, In Progress, Completed) |
  | `priority` | string | No | Priority (e.g., Low, Normal, High) |
  | `activityDate` | string | No | Due date in YYYY-MM-DD format |
  | `whoId` | string | No | Related Contact ID (003...) or Lead ID (00Q...) |
  | `whatId` | string | No | Related Account ID (001...) or Opportunity ID (006...) |
  | `description` | string | No | Task description |

  #### Output [#output-22]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Updated task data |
  | ↳ `id` | string | The Salesforce ID of the updated record |
  | ↳ `updated` | boolean | Whether the record was updated (always true on success) |
</ReferenceDetails>

### Delete Task from Salesforce [#delete-task-from-salesforce]

Delete a task

<ReferenceDetails>
  #### Input [#input-23]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `taskId` | string | Yes | Salesforce Task ID to delete (18-character string starting with 00T) |

  #### Output [#output-23]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Deleted task data |
  | ↳ `id` | string | The Salesforce ID of the deleted record |
  | ↳ `deleted` | boolean | Whether the record was deleted (always true on success) |
</ReferenceDetails>

### List Reports from Salesforce [#list-reports-from-salesforce]

Get a list of up to 200 recently viewed reports for the current user

<ReferenceDetails>
  #### Input [#input-24]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `searchTerm` | string | No | Filter reports by name (case-insensitive partial match) |

  #### Output [#output-24]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Reports data |
  | ↳ `reports` | array | Array of report objects |
  | ↳ `totalReturned` | number | Number of items returned |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### Get Report Metadata from Salesforce [#get-report-metadata-from-salesforce]

Get the describe (definition and metadata) for a specific report

<ReferenceDetails>
  #### Input [#input-25]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `reportId` | string | Yes | Salesforce Report ID (18-character string starting with 00O) |

  #### Output [#output-25]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Report metadata |
  | ↳ `report` | object | Report metadata object |
  | ↳ `reportId` | string | Report ID |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### Run Report in Salesforce [#run-report-in-salesforce]

Execute a report and retrieve the results

<ReferenceDetails>
  #### Input [#input-26]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `reportId` | string | Yes | Salesforce Report ID (18-character string starting with 00O) |
  | `includeDetails` | string | No | Include detail rows (true/false, default: true) |
  | `filters` | string | No | JSON array of report filter objects to apply |

  #### Output [#output-26]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Report results |
  | ↳ `reportId` | string | Report ID |
  | ↳ `reportMetadata` | object | Report metadata including name, format, and filter definitions |
  | ↳ `reportExtendedMetadata` | object | Extended metadata for aggregate columns and groupings |
  | ↳ `factMap` | object | Report data organized by groupings with aggregates and row data |
  | ↳ `groupingsDown` | object | Row grouping hierarchy and values |
  | ↳ `groupingsAcross` | object | Column grouping hierarchy and values |
  | ↳ `hasDetailRows` | boolean | Whether the report includes detail-level row data |
  | ↳ `allData` | boolean | Whether all data is returned (false if truncated due to size limits) |
  | ↳ `reportName` | string | Display name of the report |
  | ↳ `reportFormat` | string | Report format type (TABULAR, SUMMARY, MATRIX, JOINED) |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### List Report Types from Salesforce [#list-report-types-from-salesforce]

Get a list of available report types

<ReferenceDetails>
  #### Input [#input-27]

  | Parameter | Type | Required | Description |
  | - | - | - | - |

  #### Output [#output-27]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Report types data |
  | ↳ `reportTypes` | array | Array of report type objects |
  | ↳ `totalReturned` | number | Number of items returned |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### List Dashboards from Salesforce [#list-dashboards-from-salesforce]

Get a list of recently used dashboards for the current user

<ReferenceDetails>
  #### Input [#input-28]

  | Parameter | Type | Required | Description |
  | - | - | - | - |

  #### Output [#output-28]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Dashboards data |
  | ↳ `dashboards` | array | Array of dashboard objects |
  | ↳ `totalReturned` | number | Number of items returned |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### Get Dashboard from Salesforce [#get-dashboard-from-salesforce]

Get details and results for a specific dashboard

<ReferenceDetails>
  #### Input [#input-29]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `dashboardId` | string | Yes | Salesforce Dashboard ID (18-character string starting with 01Z) |

  #### Output [#output-29]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Dashboard data |
  | ↳ `dashboard` | object | Full dashboard details object |
  | ↳ `dashboardId` | string | Dashboard ID |
  | ↳ `components` | array | Array of dashboard component data with visualizations and filters |
  | ↳ `dashboardName` | string | Display name of the dashboard |
  | ↳ `dashboardMetadata` | object | Structured dashboard metadata (attributes, component definitions, layout) |
  | ↳ `runningUser` | object | User context under which the dashboard data was retrieved |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### Refresh Dashboard in Salesforce [#refresh-dashboard-in-salesforce]

Refresh a dashboard to get the latest data

<ReferenceDetails>
  #### Input [#input-30]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `dashboardId` | string | Yes | Salesforce Dashboard ID (18-character string starting with 01Z) |

  #### Output [#output-30]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Refreshed dashboard data |
  | ↳ `dashboard` | object | Full dashboard details object |
  | ↳ `dashboardId` | string | Dashboard ID |
  | ↳ `components` | array | Array of dashboard component data with fresh visualizations |
  | ↳ `status` | object | Dashboard refresh status (dashboardStatus), when returned by the refresh |
  | ↳ `statusUrl` | string | URL of the status resource to poll for refresh completion |
  | ↳ `dashboardName` | string | Display name of the dashboard |
  | ↳ `dashboardMetadata` | object | Structured dashboard metadata (attributes, component definitions, layout) |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### Run SOQL Query in Salesforce [#run-soql-query-in-salesforce]

Execute a custom SOQL query to retrieve data from Salesforce

<ReferenceDetails>
  #### Input [#input-31]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `query` | string | Yes | SOQL query to execute (e.g., SELECT Id, Name FROM Account LIMIT 10) |

  #### Output [#output-31]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Query results |
  | ↳ `records` | array | Array of sObject records matching the query |
  | ↳ `query` | string | The executed SOQL query |
  | ↳ `metadata` | object | Response metadata |
  | ↳ `totalReturned` | number | Number of records returned in this response |
  | ↳ `hasMore` | boolean | Whether more records exist (inverse of done) |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### Get More Query Results from Salesforce [#get-more-query-results-from-salesforce]

Retrieve additional query results using the nextRecordsUrl from a previous query

<ReferenceDetails>
  #### Input [#input-32]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `nextRecordsUrl` | string | Yes | The nextRecordsUrl value from a previous query response (e.g., /services/data/v59.0/query/01g...) |

  #### Output [#output-32]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Query results |
  | ↳ `records` | array | Array of sObject records matching the query |
  | ↳ `metadata` | object | Response metadata |
  | ↳ `totalReturned` | number | Number of records returned in this response |
  | ↳ `hasMore` | boolean | Whether more records exist (inverse of done) |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### Describe Salesforce Object [#describe-salesforce-object]

Get metadata and field information for a Salesforce object

<ReferenceDetails>
  #### Input [#input-33]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `objectName` | string | Yes | Salesforce object API name (e.g., Account, Contact, Lead, Custom\_Object\_\_c) |

  #### Output [#output-33]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Object metadata |
  | ↳ `objectName` | string | API name of the object (e.g., Account, Contact) |
  | ↳ `label` | string | Human-readable singular label for the object |
  | ↳ `labelPlural` | string | Human-readable plural label for the object |
  | ↳ `fields` | array | Array of field metadata objects |
  | ↳ `name` | string | API name of the field |
  | ↳ `label` | string | Display label of the field |
  | ↳ `type` | string | Field data type (string, boolean, int, double, date, etc.) |
  | ↳ `length` | number | Maximum length for text fields |
  | ↳ `precision` | number | Precision for numeric fields |
  | ↳ `scale` | number | Scale for numeric fields |
  | ↳ `nillable` | boolean | Whether the field can be null |
  | ↳ `unique` | boolean | Whether values must be unique |
  | ↳ `createable` | boolean | Whether field can be set on create |
  | ↳ `updateable` | boolean | Whether field can be updated |
  | ↳ `defaultedOnCreate` | boolean | Whether field has default value on create |
  | ↳ `calculated` | boolean | Whether field is a formula field |
  | ↳ `autoNumber` | boolean | Whether field is auto-number |
  | ↳ `externalId` | boolean | Whether field is an external ID |
  | ↳ `idLookup` | boolean | Whether field can be used in ID lookup |
  | ↳ `inlineHelpText` | string | Help text for the field |
  | ↳ `picklistValues` | array | Available picklist values for picklist fields |
  | ↳ `referenceTo` | array | Objects this field can reference (for lookup fields) |
  | ↳ `relationshipName` | string | Relationship name for lookup fields |
  | ↳ `custom` | boolean | Whether this is a custom field |
  | ↳ `filterable` | boolean | Whether field can be used in SOQL filter |
  | ↳ `groupable` | boolean | Whether field can be used in GROUP BY |
  | ↳ `sortable` | boolean | Whether field can be used in ORDER BY |
  | ↳ `keyPrefix` | string | Three-character prefix used in record IDs (e.g., "001" for Account) |
  | ↳ `queryable` | boolean | Whether the object can be queried via SOQL |
  | ↳ `createable` | boolean | Whether records can be created for this object |
  | ↳ `updateable` | boolean | Whether records can be updated for this object |
  | ↳ `deletable` | boolean | Whether records can be deleted for this object |
  | ↳ `childRelationships` | array | Array of child relationship metadata for related objects |
  | ↳ `recordTypeInfos` | array | Array of record type information for the object |
  | ↳ `fieldCount` | number | Total number of fields on the object |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### List Salesforce Objects [#list-salesforce-objects]

Get a list of all available Salesforce objects

<ReferenceDetails>
  #### Input [#input-34]

  | Parameter | Type | Required | Description |
  | - | - | - | - |

  #### Output [#output-34]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Objects list |
  | ↳ `objects` | array | Array of sObject metadata |
  | ↳ `name` | string | API name of the object |
  | ↳ `label` | string | Display label of the object |
  | ↳ `labelPlural` | string | Plural display label |
  | ↳ `keyPrefix` | string | Three-character ID prefix |
  | ↳ `custom` | boolean | Whether this is a custom object |
  | ↳ `queryable` | boolean | Whether object can be queried |
  | ↳ `createable` | boolean | Whether records can be created |
  | ↳ `updateable` | boolean | Whether records can be updated |
  | ↳ `deletable` | boolean | Whether records can be deleted |
  | ↳ `searchable` | boolean | Whether object is searchable |
  | ↳ `triggerable` | boolean | Whether triggers are supported |
  | ↳ `layoutable` | boolean | Whether page layouts are supported |
  | ↳ `replicateable` | boolean | Whether object can be replicated |
  | ↳ `retrieveable` | boolean | Whether records can be retrieved |
  | ↳ `undeletable` | boolean | Whether records can be undeleted |
  | ↳ `urls` | object | URLs for accessing object resources |
  | ↳ `encoding` | string | Character encoding for the organization (e.g., UTF-8) |
  | ↳ `maxBatchSize` | number | Maximum number of records that can be returned in a single query batch (typically 200) |
  | ↳ `totalReturned` | number | Number of objects returned |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

### Create Custom Field in Salesforce [#create-custom-field-in-salesforce]

Create a custom field on a Salesforce object (e.g., Account) using the Tooling API

<ReferenceDetails>
  #### Input [#input-35]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `objectName` | string | Yes | API name of the object to add the field to (e.g., Account, Contact, Lead, MyObject\_\_c) |
  | `fieldName` | string | Yes | API name of the new field; the \_\_c suffix is added automatically (e.g., Region) |
  | `label` | string | No | Display label shown in the UI (defaults to the field name when omitted) |
  | `fieldType` | string | Yes | Field data type: Text, TextArea, LongTextArea, Html, Number, Currency, Percent, Checkbox, Date, DateTime, Time, Phone, Email, Url, Picklist, or MultiselectPicklist |
  | `length` | number | No | Maximum length for Text (1-255), LongTextArea, Html, or MultiselectPicklist fields |
  | `precision` | number | No | Total number of digits for Number, Currency, or Percent fields (1-18) |
  | `scale` | number | No | Number of digits to the right of the decimal for numeric fields |
  | `visibleLines` | number | No | Number of visible lines for LongTextArea, Html, or MultiselectPicklist fields |
  | `required` | boolean | No | Whether the field is required on record create/edit |
  | `unique` | boolean | No | Whether the field enforces unique values |
  | `externalId` | boolean | No | Whether the field is an external ID (for Text, Number, or Email fields) |
  | `defaultValue` | string | No | Default value; for Checkbox fields use true or false |
  | `description` | string | No | Internal description of the field |
  | `inlineHelpText` | string | No | Help text shown next to the field in the UI |
  | `picklistValues` | string | No | Comma-separated values for Picklist or MultiselectPicklist fields |

  #### Output [#output-35]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Created custom field metadata |
  | ↳ `id` | string | Tooling API Id of the newly created custom field |
  | ↳ `fullName` | string | Full API name of the field, including object (e.g., Account.Region\_\_c) |
  | ↳ `success` | boolean | Whether the create operation was successful |
  | ↳ `created` | boolean | Whether the field was created (always true on success) |
</ReferenceDetails>

### Update Custom Field in Salesforce [#update-custom-field-in-salesforce]

Update an existing custom field on a Salesforce object using the Tooling API

<ReferenceDetails>
  #### Input [#input-36]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `fieldId` | string | Yes | Tooling API Id of the custom field to update (find it via the Tooling Query tool) |
  | `label` | string | No | Display label shown in the UI |
  | `length` | number | No | Maximum length for Text, LongTextArea, Html, or MultiselectPicklist fields |
  | `precision` | number | No | Total number of digits for Number, Currency, or Percent fields |
  | `scale` | number | No | Number of digits to the right of the decimal for numeric fields |
  | `visibleLines` | number | No | Number of visible lines for LongTextArea, Html, or MultiselectPicklist fields |
  | `required` | boolean | No | Whether the field is required on record create/edit |
  | `unique` | boolean | No | Whether the field enforces unique values |
  | `externalId` | boolean | No | Whether the field is an external ID |
  | `defaultValue` | string | No | Default value; for Checkbox fields use true or false |
  | `description` | string | No | Internal description of the field |
  | `inlineHelpText` | string | No | Help text shown next to the field in the UI |
  | `picklistValues` | string | No | Comma-separated values to add to a Picklist or MultiselectPicklist field (existing values are kept) |

  #### Output [#output-36]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Updated custom field metadata |
  | ↳ `id` | string | Tooling API Id of the updated custom field |
  | ↳ `updated` | boolean | Whether the field was updated (always true on success) |
</ReferenceDetails>

### Delete Custom Field in Salesforce [#delete-custom-field-in-salesforce]

Delete a custom field from a Salesforce object using the Tooling API

<ReferenceDetails>
  #### Input [#input-37]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `fieldId` | string | Yes | Tooling API Id of the custom field to delete (find it via the Tooling Query tool) |

  #### Output [#output-37]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Deleted custom field metadata |
  | ↳ `id` | string | Tooling API Id of the deleted custom field |
  | ↳ `deleted` | boolean | Whether the field was deleted (always true on success) |
</ReferenceDetails>

### Create Custom Object in Salesforce [#create-custom-object-in-salesforce]

Create a custom object in Salesforce using the Tooling API

<ReferenceDetails>
  #### Input [#input-38]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `objectName` | string | Yes | API name of the new object; the \_\_c suffix is added automatically (e.g., Project) |
  | `label` | string | Yes | Singular display label for the object (e.g., Project) |
  | `pluralLabel` | string | Yes | Plural display label for the object (e.g., Projects) |
  | `nameFieldLabel` | string | No | Label for the standard Name field (defaults to "\<label> Name") |
  | `description` | string | No | Internal description of the object |
  | `sharingModel` | string | No | Org-wide sharing model: ReadWrite, Read, Private, or ControlledByParent (default ReadWrite) |

  #### Output [#output-38]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Created custom object metadata |
  | ↳ `id` | string | Tooling API Id of the newly created custom object |
  | ↳ `fullName` | string | Full API name of the object (e.g., Project\_\_c) |
  | ↳ `success` | boolean | Whether the create operation was successful |
  | ↳ `created` | boolean | Whether the object was created (always true on success) |
</ReferenceDetails>

### Run Tooling SOQL Query in Salesforce [#run-tooling-soql-query-in-salesforce]

Execute a SOQL query against the Tooling API to inspect metadata objects

<ReferenceDetails>
  #### Input [#input-39]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `query` | string | Yes | Tooling SOQL query (e.g., SELECT Id, DeveloperName FROM CustomField WHERE TableEnumOrId = 'Account') |

  #### Output [#output-39]

  | Parameter | Type | Description |
  | - | - | - |
  | `success` | boolean | Operation success status |
  | `output` | object | Tooling query results |
  | ↳ `records` | array | Array of Tooling API records matching the query |
  | ↳ `query` | string | The executed Tooling SOQL query |
  | ↳ `metadata` | object | Response metadata |
  | ↳ `totalReturned` | number | Number of records returned in this response |
  | ↳ `hasMore` | boolean | Whether more records exist (inverse of done) |
  | ↳ `success` | boolean | Salesforce operation success |
</ReferenceDetails>

## Triggers [#triggers]

A trigger starts a workflow when a supported event occurs in this service.

### Salesforce Case Status Changed [#salesforce-case-status-changed]

Trigger workflow when a case status changes

#### Configuration [#configuration]

| Parameter | Type | Required | Description |
| - | - | - | - |
| `webhookSecret` | string | Yes | Required. Use the same value in your Salesforce HTTP Callout as Bearer token or X-Sim-Webhook-Secret. |

#### Output [#output-40]

| Parameter | Type | Description |
| - | - | - |
| `eventType` | string | The type of event |
| `simEventType` | string | Optional alias from the payload (`simEventType`). Empty when only `eventType` is sent. |
| `objectType` | string | Salesforce object type (Case) |
| `recordId` | string | Case ID |
| `timestamp` | string | When the event occurred (ISO 8601) |
| `record` | object | |
| ↳ `Id` | string | Case ID |
| ↳ `Subject` | string | Case subject |
| ↳ `Status` | string | Current case status |
| ↳ `Priority` | string | Case priority |
| ↳ `CaseNumber` | string | Case number |
| ↳ `AccountId` | string | Related Account ID |
| ↳ `ContactId` | string | Related Contact ID |
| ↳ `OwnerId` | string | Case owner ID |
| `previousStatus` | string | Previous case status |
| `newStatus` | string | New case status |
| `payload` | json | Full webhook payload |

***

### Salesforce Opportunity Stage Changed [#salesforce-opportunity-stage-changed]

Trigger workflow when an opportunity stage changes

#### Configuration [#configuration-1]

| Parameter | Type | Required | Description |
| - | - | - | - |
| `webhookSecret` | string | Yes | Required. Use the same value in your Salesforce HTTP Callout as Bearer token or X-Sim-Webhook-Secret. |

#### Output [#output-41]

| Parameter | Type | Description |
| - | - | - |
| `eventType` | string | The type of event |
| `simEventType` | string | Optional alias from the payload (`simEventType`). Empty when only `eventType` is sent. |
| `objectType` | string | Salesforce object type (Opportunity) |
| `recordId` | string | Opportunity ID |
| `timestamp` | string | When the event occurred (ISO 8601) |
| `record` | object | |
| ↳ `Id` | string | Opportunity ID |
| ↳ `Name` | string | Opportunity name |
| ↳ `StageName` | string | Current stage name |
| ↳ `Amount` | string | Deal amount |
| ↳ `CloseDate` | string | Expected close date |
| ↳ `Probability` | string | Win probability |
| ↳ `AccountId` | string | Related Account ID (standard Opportunity field) |
| ↳ `OwnerId` | string | Opportunity owner ID |
| `previousStage` | string | Previous stage name |
| `newStage` | string | New stage name |
| `payload` | json | Full webhook payload |

***

### Salesforce Record Created [#salesforce-record-created]

Trigger workflow when a Salesforce record is created

#### Configuration [#configuration-2]

| Parameter | Type | Required | Description |
| - | - | - | - |
| `webhookSecret` | string | Yes | Required. Use the same value in your Salesforce HTTP Callout as Bearer token or X-Sim-Webhook-Secret. |
| `objectType` | string | No | When set, the payload must include matching object type metadata (for example objectType, sobjectType, or attributes.type) or the event is rejected. |

#### Output [#output-42]

| Parameter | Type | Description |
| - | - | - |
| `eventType` | string | The type of event (e.g., created, updated, deleted) |
| `simEventType` | string | Optional alias from the payload (`simEventType`). Empty when only `eventType` is sent. |
| `objectType` | string | Salesforce object type (e.g., Account, Contact, Lead) |
| `recordId` | string | ID of the affected record |
| `timestamp` | string | When the event occurred (ISO 8601) |
| `record` | object | |
| ↳ `Id` | string | Record ID |
| ↳ `Name` | string | Record name |
| ↳ `CreatedDate` | string | Record creation date |
| ↳ `LastModifiedDate` | string | Last modification date |
| ↳ `OwnerId` | string | Record owner ID (standard field when sent in the Flow body) |
| ↳ `SystemModstamp` | string | System modstamp from the record (ISO 8601) when included in the payload |
| `changedFields` | json | Fields that were changed (for update events) |
| `payload` | json | Full webhook payload |

***

### Salesforce Record Deleted [#salesforce-record-deleted]

Trigger workflow when a Salesforce record is deleted

#### Configuration [#configuration-3]

| Parameter | Type | Required | Description |
| - | - | - | - |
| `webhookSecret` | string | Yes | Required. Use the same value in your Salesforce HTTP Callout as Bearer token or X-Sim-Webhook-Secret. |
| `objectType` | string | No | When set, the payload must include matching object type metadata (for example objectType, sobjectType, or attributes.type) or the event is rejected. |

#### Output [#output-43]

| Parameter | Type | Description |
| - | - | - |
| `eventType` | string | The type of event (e.g., created, updated, deleted) |
| `simEventType` | string | Optional alias from the payload (`simEventType`). Empty when only `eventType` is sent. |
| `objectType` | string | Salesforce object type (e.g., Account, Contact, Lead) |
| `recordId` | string | ID of the affected record |
| `timestamp` | string | When the event occurred (ISO 8601) |
| `record` | object | |
| ↳ `Id` | string | Record ID |
| ↳ `Name` | string | Record name |
| ↳ `CreatedDate` | string | Record creation date |
| ↳ `LastModifiedDate` | string | Last modification date |
| ↳ `OwnerId` | string | Record owner ID (standard field when sent in the Flow body) |
| ↳ `SystemModstamp` | string | System modstamp from the record (ISO 8601) when included in the payload |
| `changedFields` | json | Fields that were changed (for update events) |
| `payload` | json | Full webhook payload |

***

### Salesforce Record Updated [#salesforce-record-updated]

Trigger workflow when a Salesforce record is updated

#### Configuration [#configuration-4]

| Parameter | Type | Required | Description |
| - | - | - | - |
| `webhookSecret` | string | Yes | Required. Use the same value in your Salesforce HTTP Callout as Bearer token or X-Sim-Webhook-Secret. |
| `objectType` | string | No | When set, the payload must include matching object type metadata (for example objectType, sobjectType, or attributes.type) or the event is rejected. |

#### Output [#output-44]

| Parameter | Type | Description |
| - | - | - |
| `eventType` | string | The type of event (e.g., created, updated, deleted) |
| `simEventType` | string | Optional alias from the payload (`simEventType`). Empty when only `eventType` is sent. |
| `objectType` | string | Salesforce object type (e.g., Account, Contact, Lead) |
| `recordId` | string | ID of the affected record |
| `timestamp` | string | When the event occurred (ISO 8601) |
| `record` | object | |
| ↳ `Id` | string | Record ID |
| ↳ `Name` | string | Record name |
| ↳ `CreatedDate` | string | Record creation date |
| ↳ `LastModifiedDate` | string | Last modification date |
| ↳ `OwnerId` | string | Record owner ID (standard field when sent in the Flow body) |
| ↳ `SystemModstamp` | string | System modstamp from the record (ISO 8601) when included in the payload |
| `changedFields` | json | Fields that were changed (for update events) |
| `payload` | json | Full webhook payload |

***

### Salesforce Webhook (All Events) [#salesforce-webhook-all-events]

Trigger workflow on any Salesforce webhook event

#### Configuration [#configuration-5]

| Parameter | Type | Required | Description |
| - | - | - | - |
| `webhookSecret` | string | Yes | Required. Use the same value in your Salesforce HTTP Callout as Bearer token or X-Sim-Webhook-Secret. |
| `objectType` | string | No | When set, the payload must include matching object type metadata (for example objectType, sobjectType, or attributes.type) or the event is rejected. |

#### Output [#output-45]

| Parameter | Type | Description |
| - | - | - |
| `eventType` | string | The type of event |
| `simEventType` | string | Optional alias from the payload (`simEventType`). Empty when only `eventType` is sent. |
| `objectType` | string | Salesforce object type |
| `recordId` | string | ID of the affected record |
| `timestamp` | string | When the event occurred (ISO 8601) |
| `record` | json | Full record data |
| `payload` | json | Full webhook payload |
