Skip to main content
Solved

Connecting to Mistral

  • August 6, 2026
  • 3 replies
  • 64 views

redgeographics
VIP
Forum|alt.badge.img+63

Wondering if anybody has successfully connected to Mistral using FME. I'm trying to work through a very basic sample, straight from their documentation, but no luck, I keep getting an error that seems to imply there's something wrong with my request body:

Request body:

{

Β  "model": "mistral-medium-latest",

Β  "messages": [

Β  Β  {

Β  Β  Β  "role": "user",

Β  Β  Β  "content": "What is the capital of France?"

Β  Β  }

Β  ],

Β  "temperature": 0.7,

Β  "max_tokens": 100

}

Β 

Response:

{

Β Β  Β "detail": [

Β Β  Β Β Β  Β {

Β Β  Β Β Β  Β Β Β  Β "input": "{\n Β \"model\": \"mistral-medium-latest\",\n Β \"messages\": [\nΒ Β  Β {\nΒ Β  Β  Β \"role\": \"user\",\nΒ Β  Β  Β \"content\": \"",

Β Β  Β Β Β  Β Β Β  Β "loc": [

Β Β  Β Β Β  Β Β Β  Β Β Β  Β "body"

Β Β  Β Β Β  Β Β Β  Β ],

Β Β  Β Β Β  Β Β Β  Β "msg": "Input should be a valid dictionary or object to extract fields from",

Β Β  Β Β Β  Β Β Β  Β "type": "model_attributes_type"

Β Β  Β Β Β  Β }

Β Β  Β ]

}

However… if I try the same request in Postman it does work.

Β 

My HTTPCaller settings:

I have a feeling I'm missing something really obvious, but I'm at a loss to what that would be...
Β 

Best answer by alexbiz

Hey Hans !

Have you tried our MistralAIConnector ?

https://hub.safe.com/publishers/veremes-officiel/transformers/mistralaiconnector

3 replies

alexbiz
Influencer
Forum|alt.badge.img+33
  • Influencer
  • Best Answer
  • August 6, 2026

redgeographics
VIP
Forum|alt.badge.img+63

I hadn’t tried that, but I have now and it works, so to be honest I’m not going to bother troubleshooting my own efforts much more. I suspect it has something to do with hidden characters (tabs and spaces) in the messages part of the request. Apparently Postman cleans that up for you.

Merci!


alexbiz
Influencer
Forum|alt.badge.img+33
  • Influencer
  • August 6, 2026

Nice ! IΒ made that some time ago. We have plans to rework intoΒ an FME Package.

"I suspect it has something to do with hidden characters (tabs and spaces) in the messages part of the request. Apparently Postman cleans that up for you."

Maybe a JSONFormatter set to Linearize could have done the trick there πŸ€”