Menu

Mattering Automations Mistral AI integration

Connect Mistral AI to Mattering Automations: chat completions, Codestral code completion, Mistral OCR, embeddings, moderation, classifiers, and batch inference as workflow steps, authenticated with a Mistral API key.

The Mattering Automations Mistral AI integration puts Mistral AI Studio on your automation canvas: run chat completions with reasoning, vision, JSON mode, and function calling inside a workflow step, complete code with Codestral, read documents with Mistral OCR, create embeddings, moderate or classify content, run agents built in Mistral's console, and push bulk work through asynchronous batch jobs.

Setup is one API key from the Mistral AI Studio console. This guide covers creating the key, connecting it, a verify path that costs nothing to run, and the full node reference, and it ends with the failure modes worth recognizing on sight.

Before you start

  • A Mistral account at console.mistral.ai with an active plan on the workspace. The free plan (Free mode) works for testing: no credit card is required. Mistral states that free-plan API data, input and output, may be used to train its models unless you opt out in the Admin Console, so keep free-tier calls to test data and use the pay per use Scale plan, which is opted out of training by default, for real workloads.
  • A Mattering workspace with access to the Automations app.
  • For the OCR node, documents reachable by URL or supplied as base64 data URLs. There is no local file upload.
  • For the two classification nodes, a classifier you have fine-tuned on Mistral's platform. They have no general-purpose default model; the moderation nodes cover the built-in categories.

Create a Mistral API key

Mattering authenticates to Mistral with an API key sent as an Authorization bearer header. It is a single field: no organization id, no version header, no OAuth flow to complete. Keys belong to a workspace, and the plan and rate limits attach at the workspace level, shared by every key in it.

Sign in at console.mistral.ai and open API Keys.
Create a new key and name it after where it will be used, such as Mattering Automations.
The key is shown once, at creation. Copy it before you close the dialog; if you lose it you have to create a new one.
API calls need an active plan on the workspace. The free plan activates with no credit card, but Mistral states free-plan API data may be used to train its models unless you opt out, so reserve it for test data. The Scale plan is pay per use and is opted out of training by default.
Copy the key and keep it somewhere safe until you have pasted it into Mattering.

Connect Mistral AI to Mattering

In Mattering Automations, open Connectors and click Add Connector.
Choose Mistral AI from the list.
Click Create new credential, paste the API key, and save.
The credential is stored encrypted in Google Secret Manager and never appears in workflow logs.
Click Test Connection. The connector calls Mistral's models endpoint, which verifies the key without spending a token.
Click Connect. All 24 Mistral nodes appear in your canvas palette.

Verify it works

Open any automation canvas and check the palette: a Mistral section should list eight query nodes and sixteen action nodes. Drop Mistral: List Models onto the canvas and run a test step. It takes no parameters and is free to call, so a successful response returns every model your key can use, each with its capabilities, context length, aliases, and deprecation date. That makes it the cheapest credential check available.

To confirm inference itself works, add Mistral: Chat Completion, keep the default mistral-small-latest model, put one short message in the messages array, and set max_tokens low. A successful run returns the reply at data.choices[0].message.content along with token usage.

Node reference

24 nodes, generated from the connector itself so this reference always matches what ships.

Read and query nodes 8

Mistral: Download File Content

mistral_download_file

Download a stored file's raw content: the primary way to collect batch job results. The full text comes back at data.content, and because batch outputs are JSONL, each line is also parsed into data.lines so a For Each node can loop over the individual responses.

Mistral: Get Batch Job

mistral_get_batch_job

Poll one batch job by ID: status (QUEUED, RUNNING, SUCCESS, FAILED...), progress counters, and on completion the output_file and error_file IDs. With inline=true, jobs created from inline requests return their outputs directly in the response.

Mistral: Get File

mistral_get_file

Retrieve one file's metadata by ID: filename, size, purpose, line count, and source. Useful for checking a batch job's output_file before downloading it.

Mistral: Get File Signed URL

mistral_get_file_signed_url

Get a temporary signed download URL for a stored file, valid for a configurable number of hours. Hand the URL to any downstream node or external system that needs the raw file without a Mistral credential.

Mistral: Get Model

mistral_get_model

Retrieve one model by ID: its capabilities (chat, FIM, function calling, vision, fine-tuning support), maximum context length, aliases, and deprecation date. Works for base models and your fine-tuned models alike.

Mistral: List Batch Jobs

mistral_list_batch_jobs

List your batch inference jobs with paging and filters by model, status, and creation date. Each job carries progress counters and, once finished, the output_file and error_file IDs to download.

Mistral: List Files

mistral_list_files

List files stored in your Mistral workspace: fine-tuning datasets, batch inputs, batch outputs, and OCR documents, with paging and filters by purpose, type, source, and filename search.

Mistral: List Models

mistral_list_models

List every model your Mistral API key can use: base models with their capabilities (chat, function calling, vision, fine-tuning), context lengths, aliases, and deprecation dates, plus your fine-tuned models. Free to call, which makes it the credential health check for this connector.

Action nodes 16

Mistral: Agent Completion

mistral_agent_completion

Run a completion against a Mistral agent built in the Mistral Studio console: the agent carries its own model, instructions, and tool set, so this node only needs the agent ID and the messages. Output lands at data.choices[0].message.content. Streaming is forced off.

Mistral: Archive Fine-Tuned Model

mistral_archive_fine_tuned_model

Archive a fine-tuned model, taking it out of active use without deleting it. Fully reversible with the Unarchive node.

Mistral: Cancel Batch Job

mistral_cancel_batch_job

Request cancellation of a running batch job. Requests already completed stay completed and billed; the job moves through CANCELLATION_REQUESTED to CANCELLED.

Mistral: Chat Completion

mistral_chat_completion

Generate a chat completion with a Mistral model: frontier reasoning with Magistral, multimodal input on vision models, JSON mode and structured outputs, and function calling. The generated text lands at data.choices[0].message.content. Streaming is not supported on the canvas and is forced off.

Mistral: Classify Chat

mistral_classify_chat

Run whole conversations through one of your custom classifier models: classify a chat transcript by intent, topic, resolution status, or any taxonomy the classifier was trained on, using the full multi-turn context.

Mistral: Classify Text

mistral_classify_text

Run raw text through one of YOUR custom classifier models (trained with Mistral's classifier factory fine-tuning): intent detection, sentiment, routing labels, or any custom taxonomy. Returns per-label score maps per input at data.results[i].

Mistral: Create Batch Job

mistral_create_batch_job

Start an asynchronous batch inference job at roughly half the price of live calls. Feed it either uploaded .jsonl input_files or - canvas-friendly - inline requests (a JSON array of {custom_id, body} objects), pick the target endpoint and model, then poll with Get Batch Job and download results with Download File Content.

Mistral: Create Embeddings

mistral_create_embeddings

Turn text into embedding vectors with mistral-embed or codestral-embed (for code). Send one string or a JSON array of strings, get one vector per input at data.data[i].embedding plus token usage. Keep batches modest: every vector is a large float array in the execution record.

Mistral: Delete File

mistral_delete_file

Permanently delete a stored file from your Mistral workspace. This cannot be undone; download anything you still need first.

Mistral: Delete Model

mistral_delete_model

Permanently delete a fine-tuned model. This cannot be undone: prefer the Archive node when the model might be needed again.

Mistral: FIM Code Completion

mistral_fim_completion

Fill-in-the-middle code completion with Codestral: give the code before the cursor as prompt and optionally the code after it as suffix, and the model generates what goes between. With no suffix it completes the prompt forward. Output lands at data.choices[0].message.content. Streaming is forced off.

Mistral: Moderate Chat

mistral_moderate_chat

Moderate a whole conversation instead of raw text: the model classifies the LAST message in each conversation against the nine moderation categories using the earlier turns as context, which catches conversational harms plain text moderation misses.

Mistral: Moderate Text

mistral_moderate_text

Classify raw text against Mistral's nine moderation categories (sexual, hate and discrimination, violence and threats, dangerous and criminal content, self-harm, health, financial, law, PII). Returns per-category booleans and scores per input at data.results[i], ready for a Filter node to gate on.

Mistral: OCR a Document

mistral_ocr_document

Run Mistral OCR on a PDF or image by URL: each page comes back as clean markdown at data.pages[i].markdown with optional extracted images, tables, headers/footers, and structured annotations via JSON schema. The document-understanding workhorse: point it at an invoice, contract, or scan and pipe the markdown into a chat node.

Mistral: Unarchive Fine-Tuned Model

mistral_unarchive_fine_tuned_model

Restore an archived fine-tuned model to active use. The reverse of the Archive node (the API models unarchive as a DELETE of the archive marker).

Mistral: Update Fine-Tuned Model

mistral_update_fine_tuned_model

Rename a fine-tuned model or update its description. Only applies to your ft:... models, not base models.

Using the integration

On the automation canvas

Mistral nodes chain with everything else: pull a record, generate or extract with Mistral: Chat Completion, then write the result into a task, a message, or a database row. Template references resolve inside nested JSON, so an upstream node's output can drop straight into one entry of the messages array rather than templating the whole array as a single blob.

Documents in, markdown out

Mistral: OCR a Document takes a PDF or image by URL, or a base64 data URL, and returns each page as markdown with optional tables, extracted images, headers and footers, and schema-driven annotations. The usual pattern is OCR first, then a chat completion in JSON mode to turn the markdown into structured fields.

Batch inference without file uploads

Mistral: Create Batch Job accepts inline requests, a JSON array of custom_id and body objects, alongside the target endpoint and model, so bulk work starts without uploading a JSONL file. Poll with Mistral: Get Batch Job, which can return outputs inline for inline jobs, or read the finished output file with Mistral: Download File Content, which parses each JSONL line into a lines array a For Each node can loop. Mistral's docs price batch inference at roughly half the cost of live calls.

Moderation and your own classifiers

Mistral: Moderate Text and Mistral: Moderate Chat score content against Mistral's nine moderation categories and return booleans plus scores a Filter node can gate on; the chat variant judges the last message in context. Mistral: Classify Text and Mistral: Classify Chat do the same through a classifier you trained yourself and require your own ft:classifier model id.

Agents built in Mistral's console

Mistral: Agent Completion runs an agent you configured in Mistral's agent builder in the Studio console by its id. The agent carries its own model, instructions, and tool set, so the node only needs the agent id and the messages, and the reply lands in the same choices shape as a chat completion.

From AI assistants over MCP

Every node speaks MCP, the open protocol for connecting AI assistants to tools. Claude, ChatGPT, and Matter can drive them, so an assistant can plan a workflow and hand the generation, document parsing, or classification to Mistral.

Troubleshooting

Every node returns a 401
The key is wrong, revoked, or truncated on paste, or the workspace has no active plan. Keys are shown once at creation, so a half-copied key is a common cause. Check the workspace has a plan activated in the console (the free plan needs no credit card, and Mistral states free-plan API data may be used to train its models unless you opt out), create a fresh key if needed, update the credential, and run Test Connection or Mistral: List Models to confirm the fix.
Calls start failing with a 429
Mistral enforces rate limits per workspace on requests per second and tokens per minute and per month, shared by every key in the workspace, so another integration's traffic counts against the same ceiling. The exact numbers depend on your plan and are shown in Mistral's admin console rather than published. The node surfaces the 429 body with success set to false, so a workflow can branch on it, slow its loop, or retry on a later scheduled run; upgrading the workspace's plan raises the ceilings.
A classification node rejects the model
Mistral: Classify Text and Mistral: Classify Chat only work with a classifier you have fine-tuned on Mistral's platform, with an id like ft:classifier:ministral-3b-latest:myorg:20250801:abc123. There is no general-purpose default, and pointing them at a base model fails. For Mistral's built-in safety categories use Mistral: Moderate Text or Mistral: Moderate Chat instead.
A node returns a model not found error
The model id is not available to your workspace, or Mistral has retired it on its deprecation schedule. Run Mistral: List Models to see what the key can call right now, including each model's deprecation date, and set the model field to one of those ids. The field is free text on purpose, so it does not rot the way a fixed dropdown would.
Create Batch Job returns a job instead of results
Batches are asynchronous by design. Mistral: Create Batch Job returns a job id and a QUEUED status, not completions. Poll with Mistral: Get Batch Job on a later scheduled run until the status reads SUCCESS; for jobs created from inline requests, set inline to true to get the outputs directly in the response, otherwise read the output file id and fetch it with Mistral: Download File Content. The timeout_hours you set on the job is the outer bound for how long that can take.
There is no file upload node
Mistral's upload endpoint needs a real binary multipart payload, and the canvas config panel has no file input, so uploads happen out of band. In practice the gap rarely bites: batch jobs run end to end from inline requests, OCR takes URLs or data URLs, and files Mistral itself creates, such as batch outputs, are fully covered by Mistral: List Files, Mistral: Get File, Mistral: Get File Signed URL, and Mistral: Download File Content.
A node you expected from Mistral's docs is missing
Some gaps are deliberate. Mistral lists its old fine-tuning jobs API as deprecated, so no nodes were built on it; managing existing fine-tuned models with Mistral: Update Fine-Tuned Model, Mistral: Archive Fine-Tuned Model, and Mistral: Unarchive Fine-Tuned Model is covered. The Agents and Conversations APIs are marked beta in Mistral's spec and are skipped for that reason, though the stable Mistral: Agent Completion node runs console-built agents today. Audio endpoints are out of scope for now, and streaming is stripped from every request so each node returns one complete response.
A delete ran and the model or file is gone
Mistral: Delete Model and Mistral: Delete File are permanent; neither can be undone. For models that might be needed again, Mistral: Archive Fine-Tuned Model takes them out of active use reversibly, and Mistral: Unarchive Fine-Tuned Model brings them back. Download any file content you still need with Mistral: Download File Content before deleting it.

Mistral AI is a trademark of its respective owner. Mattering uses platform names to identify the services these integrations connect to; no endorsement or affiliation is implied.

Start Free Explore our Products