Automate your work with AI, from the first rule to the complete workflow
Your progress
0 lesson completed out of 50

A lesson is completed when you tick it, when you watch its video to the end or when you score 80% on its quiz. The certificate is issued online after the final assessment, from a score of 32 out of 40.

Your progress is saved in this browser. Log in to your client area to pick it up on your other devices.

Video transcript

Lesson 19, module 5: Plugging an AI into a flow Plugging OpenAI, Claude, Gemini or Mistral into a flow: the key, the model and the cost Is your ChatGPT subscription enough to plug an AI into a flow?

No. The API is paid for separately, per token, with its own key. A developer account, not the subscription One named key per flow Stored in the credentials A call is set up in six layers, once and for all. [Diagram: What a call to an AI contains] The credential The model The system prompt The flow data The output format The token limit Each layer is set once in the module or the node, then used on every run. Sorting a thousand short e-mails costs a few tens of pence. Price per million tokens Output costs more than input The platform often weighs more The smallest model first, the biggest only if the test requires it. [Diagram: Which model for which task] Vertically, task difficulty; horizontally, call volume. Mid-range model Mid-range, but measured The cheapest Preferred: The cheapest, in batches Always start with the highlighted box, then move up a notch if the test on your data requires it. Test the key on a real case before building the rest. Prompt: Classify this message into a single category from quote, after-sales, other. Reply with the word only. Message: “ Hello, could you price three oak windows?” Response: A single word: quote. If the key is pasted wrongly, the node shows an authentication error instead of a response. Cap spending in the console before the first real call. A low monthly cap to start with An alert before the cap One revocable key per flow In the exercise, you choose the AI for the joinery firm in Pessac and work out its cost. Your turn: Choose the AI for the joinery firm's quote request flow The written lesson, the corrected exercise and the quiz are below the video.

Lesson 19 of 50 · module 5, connect ai to a workflow

Connecting OpenAI, Claude, Gemini or Mistral to a workflow: the key, the model and the cost

Connecting an AI to a workflow takes three settings: a paid API key stored in the tool’s credentials, a model chosen for the task, and a spending cap. Classifying a thousand short emails costs a few tens of cents in tokens; the platform, with its tasks and credits, often costs more.

  • 28 min of reading
  • 1 min 49 of video
  • 6 diagrams
  • 1 demande to copy
  • 3 exemples pratiques
  • 4 exercices answerss
  • 5 questions
  • 1 ressource

By the end of this lesson, you will know how to

  • Create an API key and store it in the n8n, Make or Zapier credentials
  • Choose a provider and a model based on the task, the data and the volume
  • Estimate a workflow’s monthly cost in tokens and cap spending before the first call

What’s covered

  1. Three ways to bring AI into a flow
  2. Create the key and store it in the right place
  3. Choose the provider based on your data
  4. Choose the model, smallest first
  5. Cap spending before the first real call
  6. 3 worked examples, followed from start to finish
  7. Exercise with answers · Choose the AI for the joinery’s quote request workflow
  8. 3 practice exercises, from guided to demanding cases
  9. The quiz

Key points

  • An AI’s API is a separate account from the subscription, billed per token, opened with a key.
  • One key per flow, stored in the tool's credentials, never in a text field or a spreadsheet.
  • Choose the provider on data first: paid plan, training excluded, contract accepted, Europe if possible.
  • The cheapest model first; the biggest only if a test on your data requires it.
  • A spending cap is set in the console on the day the key is created.