tooling_api_dml
Create, update, delete, or upsert Salesforce Tooling API records, such as Apex classes, triggers, custom metadata, and TraceFlag. For TraceFlag, prefer LogType USER_DEBUG; DEVELOPER_LOG is warned and PROFILING is rejected.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| record | No | The record to process, with all relevant fields. For an 'update' operation the record object must include an `Id` property`. For 'create' or 'upsert' the record may **not** have an `Id`. Do not use this property for the 'delete' operation | |
| sObject | Yes | API name of the Tooling API object | |
| sf_user | No | (optional) Salesforce username to identify the connection to use. Omit this to use the current default connection. | |
| recordId | No | Only used for the 'delete' operation: the ID of the record to delete | |
| operation | Yes | Type of DML operation to perform. Always ask for explicit user approval before executing any of these operations, and do not proceed without it | |
| cirra_ai_team | No | (optional) Cirra team ID or name that owns the Salesforce connection to use for this call. Must be provided together with 'sf_user'. Use it to run against a specific team's connection without changing your default team — e.g. to keep separate chats on Salesforce orgs in different teams. Omit it when this call carries the context_handle from cirra_ai_init, which names the team for the conversation. A user with more than one place to work (several teams, or a team and a personal account) must pass either the context_handle or 'cirra_ai_team' + 'sf_user'. | |
| context_handle | No | (recommended) The conversation context handle returned by cirra_ai_init in this conversation. Pass the exact context_handle value from the most recent cirra_ai_init result so this call runs against the team and Salesforce connection selected for this conversation. A user with more than one place to work (several Cirra AI teams, or a team and a personal account) must pass either this handle or 'cirra_ai_team' + 'sf_user'; a call with neither is refused. | |
| externalIdField | No | External ID field name. Required for upsert operations, ignored in other cases |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| message | Yes | ||
| results | No | ||
| success | Yes | ||
| warning | No | ||
| errorCode | No | ||
| errorCount | No | ||
| resultCount | No | ||
| artifactType | No | ||
| requestCount | No | ||
| skippedCount | No | ||
| successCount | No | ||
| artifactCategory | No |