REDA One Help Center
EN
Language
English EN Español ES Português PT Italiano coming soon Français FR Deutsch coming soon العربية coming soon
reda.one ↗
Home / REDA AI / Tool Management / Document Processing

Document Processing

AI funding and usage

AI included uses REDA credits. Bring your own AI uses your organisation’s provider account, billed directly by that provider. The licence selects one funding model for the organisation. In either model, REDA AI governs configured tools and actions in Salesforce. Set up your licence and AI accounts.

In customer-account mode, the selected model determines which Deep Reasoning levels and capabilities are available. Review the AI Account selector’s supported levels and warnings; do not assume every provider supports the same combination. Admin AI tools and document processing use the organisation default connection. Configure the default and test the workflow.

Documents to Records REDA AI reads PDFs, CSVs and images natively inside Salesforce, extracts the information your agent needs, and updates records using your normal field-level security. No external OCR service, no document pipeline to maintain, no data egress.

What is Document Processing?

Document Processing is the platform capability that lets a REDA AI agent treat a file as a first-class input. The agent can read the document, reason over its contents, and use the results to query or update Salesforce records — all in a single conversation turn or async job.

Unlike a traditional “upload then parse” pipeline, REDA AI sends the raw document directly to the model as multimodal content. There is no separate OCR step, no schema-locked template, and no external storage hop. The same processor handles documents that arrive through any channel:

  • Files attached by a user inside a chat conversation
  • Email attachments received through an inbound Email Service address
  • Files passed in by a Salesforce Flow as part of a declarative agent action
  • Files pushed in through the REST API by an external system

Supported Formats

Format Extensions How the agent reads it
PDF .pdf Sent as a multimodal document block — text, layout and embedded images are read together.
Image .png, .jpg, .jpeg Sent as a vision input — the agent reads visible text and describes visual content.
CSV .csv Parsed as tabular data; rows can be mapped to Salesforce records via a File Mapping tool.
Text .txt Inlined as plain text content for the agent to summarise or extract from.
JSON .json Inlined as structured data for the agent to query or transform.

The active allowlist is controlled by the Allowed File Extensions Platform Setting and can be tightened per agent on the Agent Definition record.

How the Processor Works

  1. File arrives

    However the file enters the org — chat upload, email attachment, Flow input, or API call — it is stored as a ContentVersion record so that standard sharing and audit rules apply.

  2. Validation

    The file extension is checked against the allowlist, the size is checked against Max File Size (MB), and CSV character counts are checked against Max CSV Characters. Files that fail validation are rejected with a clear error and never sent to the model.

  3. Block assembly

    The processor converts the file into the right multimodal block for the model: a document block for PDFs, an image block for vision inputs, or an inline text block for plain-text formats.

  4. Large files

    Small files are inlined directly. Files above the File Distribution Threshold are exposed through a short-lived ContentDistribution URL so the model can fetch them without the file being loaded into memory. The distribution link expires automatically and is cleaned up by a scheduled job.

  5. Reasoning

    The agent reads the document inside its current turn, then calls whatever tools it has available — querying records, creating records, or invoking a custom Apex tool that receives the extracted data as structured JSON.

  6. Outcome

    The agent reports what was found, asks for confirmation before any write action (unless auto-execute is enabled for that agent), and any new or updated records are subject to the running user’s field-level security and sharing.

Three Ways to Wire Documents to Records

Reading a document is only half of the job. The other half is deciding what the agent should do with what it read. REDA AI gives you three patterns, all built on the same processor.

Pattern Best for Configuration effort
Conversational extraction
(built-in tools only)
Ad-hoc questions about a file, summarisation, copy-pasting a few values into an existing record. Works with the standard get_record, create_record, update_record tools. None — works out of the box on any agent that has Allow File Upload enabled.
File Mapping tool
(File_Mapping tool type)
Predictable bulk imports — typically CSV. You declare which columns map to which fields on which object; the agent fills in the values from the file. Low — declarative configuration in the Tool Builder. No Apex required.
Apex tool with file processing
(Apex_Class tool type with Is File Processing enabled)
Domain-specific extraction where you want full control — multi-object writes, conditional logic, calling external systems, reconciling against existing records. Higher — requires an Apex class implementing the executor interface. The class receives the extracted data as a Map<String, Object> input.
Where these are configured

Both the File Mapping and Apex tool types are created in the Tool Builder. See Configuring Tools for the type-card builder UI, the live impact panel, and the per-type guidance the AI Generator provides while you build.

Channels That Trigger Document Processing

In a chat conversation

On any agent with Allow File Upload enabled, users attach a file in the same way they would type a message. The agent reads the file as part of the next turn. See File Upload for the user-facing experience, supported channels and per-agent settings.

From an inbound email

REDA AI ships an Email Service handler that accepts inbound email at a Salesforce-managed address. Attachments above a small minimum size are filtered against the same allowlist, stored as ContentVersion, and queued for asynchronous processing by the routed agent. Tiny attachments such as logos and email signatures are skipped automatically.

The mapping from inbound address to agent is held in the Email Routing custom metadata. See Email Channel — Inbound for the full setup.

From a Salesforce Flow

A record-triggered Flow can pass a ContentDocumentId (or the related ContentVersion) to the REDA AI invocable action, along with a target agent and an instruction. The agent processes the file in the background and writes its results back to Salesforce. See Invoking REDA AI from Flows.

From an external system

The External Widget and Community APIs both accept file inputs alongside a chat message, so a third-party application can push a document into a REDA AI conversation programmatically.

Action Confirmation

Document Processing follows the same safety model as the rest of the platform. When the agent decides to write to Salesforce based on what it read, it presents an action card and waits for the user to confirm — unless the agent is configured with Auto Execute File Actions, in which case writes happen immediately. See Action Confirmation for the full flow and the recommended posture for each channel.

Configuration

Document Processing reuses the file-handling settings on the Platform Settings page. The most relevant values:

Setting Default Purpose
Max File Size (MB) 5 Hard ceiling on any file the processor will accept.
Allowed File Extensions pdf,csv,png,jpg,jpeg,txt,json Global allowlist enforced before any file reaches the model.
Max CSV Characters 50,000 Caps the size of a single CSV file the agent will process inline.
File Distribution Threshold (KB) 1300 Files above this size are delivered to the model via a short-lived URL instead of being inlined.
Distribution Expiry (Minutes) 30 Lifetime of the temporary URL used for large-file delivery.
File Processing Credit Multiplier Configurable Expands the output token budget for file-aware turns so the agent can produce richer extraction results.
Email File Processing Enabled — Security control for whether attachments on inbound Email Service messages are processed. Off ignores attachments; the email still routes to its agent.

See Platform Settings for the full Setup metadata reference.

Credit Impact

Document Processing increases the input token count of a conversation because the file content is sent to the model. The credit impact depends on the format:

  • Text and CSV — token count scales with character count.
  • PDF and images — sent as multimodal blocks, which use more tokens per unit of content than plain text.
  • Output — the File Processing Credit Multiplier increases the maximum response budget for file-aware turns. Higher means richer extraction results, at higher credit cost.

See Credit Usage Optimisation for tuning guidance.

Security & Governance

  • Stays in your org. Files are stored as ContentVersion in your Salesforce org. The platform does not copy files to any external store.
  • Standard sharing applies. Whoever runs the agent must have sharing access to the file and to any record the agent reads or writes.
  • Field-level security is enforced. Writes that result from document extraction respect the running user’s FLS — fields the user cannot edit are not changed.
  • Short-lived large-file URLs. When the model fetches a large file via a distribution link, the URL expires after the configured window and is cleaned up by a scheduled job.
  • Audit trail. Every file-driven conversation is captured in the standard Conversation and Message records, including the tool calls the agent made and the records it touched.

See Data Security in REDA AI for the full security posture.

Best Practices

Match the pattern to the job. Use built-in tools for one-off extraction; use a File Mapping tool when the same shape of file is processed repeatedly; reach for an Apex tool only when the logic genuinely needs code.

Tighten the allowlist per agent. An agent that only ever processes invoices does not need to accept image uploads. Constrain Supported File Types on the Agent Definition to reduce surprise inputs.

Keep CSVs lean. Strip unused columns before processing, and split large files into batches that fit comfortably under Max CSV Characters. The agent is more accurate on focused inputs.

Be deliberate about Auto Execute File Actions. Auto-execute removes the confirmation step. Reserve it for trusted internal agents and well-understood file shapes.

Test the unhappy paths. Hand the agent malformed PDFs, blank CSVs, and irrelevant images during build-out — the response style on bad inputs is part of the user experience.

Automation and reliability

Bulk Flow invocations can return deferred request IDs instead of immediate answers. Review downstream Flow elements that expect response, credits or action-result output in the same transaction. Automated action handling carries the configured channel and execution mode, and retains actual outcomes in conversation context; this does not guarantee an extra narrated turn. Explicit datetime offsets are preserved in supported event, scheduled-action, field-write and CSV paths. Offset-free values retain the running user's interpretation. Routine System-mode processing no longer raises warning incidents merely because it uses that mode; ERROR-level notifications and incident logs remain. File extraction respects the configured output limit, semantic status colours work across the supported Salesforce themes, and packaged tests avoid static Account record-type references that blocked installation in orgs without those record types.

Frequently Asked Questions

No. Files stay in your Salesforce org as ContentVersion records. The model reads the document directly as a multimodal input — there is no intermediate OCR or document-extraction service.

Files above the File Distribution Threshold are delivered to the model through a short-lived ContentDistribution URL instead of being held in memory. The link expires after the configured window and is cleaned up by a scheduled job.

Yes. With Email File Processing enabled, attachments on the inbound Email Service address are filtered, stored as files in Salesforce, and routed to the agent mapped to that address through the Email Routing metadata. See Email Channel — Inbound.

Use a File Mapping tool when the file is tabular, the column-to-field mapping is stable, and the operation is a straight create or update. Use an Apex tool when you need conditional logic, multi-object writes, deduplication against existing records, or callouts to external systems.

Yes. Writes triggered by Document Processing run under the user’s permissions and respect field-level security and sharing. Fields the user cannot edit are not changed even if the document contains a value for them.

Scanned PDFs and images are read by the model as visual content, so legible text is extracted as part of the same call. Quality depends on the source image — clear scans extract reliably, low-resolution photos are best paired with explicit user guidance in the conversation.

Yes. File content is part of the input the model sees, so larger files use more credits. The File Processing Credit Multiplier also expands the output budget for file-aware turns. See Credit Usage Optimisation for tuning advice.

Next Steps

Set up bulk imports with the File Mapping tool type, build a custom extractor with the Apex tool type, or learn how to wire inbound documents on the Email Channel — Inbound page.