Skip to content

Create a classic Biron Zap

For the majority of use cases with Biron, you can set up a Zapier Zap following a classic 5-step architecture:

  1. Trigger
  2. Code Block: Dynamic date creation
  3. Biron Plugin: Data retrieval
  4. Code Block: Data formatting (Code Formatting)
  5. Output (Final action)

To illustrate this guide, we will follow a concrete example throughout the steps:

Example

A weekly automation that launches every Monday morning to retrieve the previous week’s store results and send them by email to the managers.

The first step is to define what will trigger your Zap. You generally have two options:

  • A scheduled time (via Schedule by Zapier): every day, every week, every month, etc.
  • An interaction with a third-party tool: a message posted in Slack, receiving an email, adding a row in a Google Sheets file, etc.

Zapier Schedule

Example

We choose the Schedule by Zapier app to configure a trigger every week (Every Week), on Monday at 8:00 AM.

By default, a Biron query uses fixed dates. To keep your automation relevant over time (e.g., “the last 7 days”), you need to provide it with dynamic dates.

The simplest method is to use a Code by Zapier block (Python). No need to be a developer: you can generate this code very easily using an AI (ChatGPT, Gemini, Claude…).

Here is the standard prompt to copy-paste into your AI to get the perfect code:

📋 PROMPT: Date generation
Role: Python Expert for Zapier.
Objective: Create a relative date calculation script.
Instructions:
Calculate the following dates while handling calendar specificities (leap years, end of month):
[INSERT DESIRED DATES HERE - e.g.: Yesterday, Last month, D+30]
Output: Return an "output" dictionary with all dates in YYYY-MM-DD format.

Zapier Code Date

Example

We ask the AI to generate two dates: the start of the previous week and the end of the previous week. We paste the Python code provided by the AI into the Zapier step.

In this step, we will configure the Biron module to execute our NexusQL query.

  1. The query: You can write it by hand or, more simply, copy it from an existing chart in Biron via the Copy NexusQL button. Zapier Biron Setup
  2. The Workspace: Enter the name of your workspace (it is often included as a comment when you copy the NexusQL from a chart).
  3. Date injection: This is the essential step! In your query (WHERE clause), replace the fixed dates with the dynamic date variables we just generated in step 2.
    Zapier Switch Date
  4. Multiple results configuration: ⚠️ Very important: If your result contains multiple rows, make sure to set the If multiple search results are found option to Return all results as line items. Zapier Setup Multiline

Example

I paste my NexusQL query. I replace the dates in the WHERE clause with the “Start of week” and “End of week” variables from the previous step. My query is configured to return the following data per store: Revenue incl. VAT, Number of orders, Margin incl. VAT.

4. Code Block: Data Formatting (Code Formatting)

Section titled “4. Code Block: Data Formatting (Code Formatting)”

The raw data returned by Biron often needs to be reworked to adapt to the final tool (creating a nice HTML table, formatting text for Slack, etc.). We use a Code by Zapier block (Python) again.

How to proceed:

  1. Configure the inputs (in Zapier): Map the elements returned by Biron (right column) to simple variable names (left column).
    Zapier Code Formatting
  2. Generate the code: Use the prompt below with your favorite LLM to create the formatting script. (Feel free to go back and forth with the AI if the format doesn’t suit you on the first try).
    📋 PROMPT: Formatting generation
    Role: Python Expert for Zapier.
    Objective: Format my data for [INSERT YOUR FINAL GOAL - e.g.: a Slack message, an HTML table].
    Inputs:
    - [Input name 1]: [Description of the data contained]
    - [Input name 2]: [Description of the data contained]
    Request:
    Using the exact input names provided, [INSERT DESCRIPTION OF WHAT THE CODE SHOULD DO].
    Output: [SPECIFY THE EXPECTED FORMAT - e.g.: an output dictionary with an 'html_table' key].

Example

I configure my inputs in Zapier: shops (Stores), billing (Revenue incl. VAT), orders (Number of orders), margin (Margin incl. VAT), week (Week start date). I then send this prompt to the AI:

📋 PROMPT: Formatting generation
Role: Python Expert for Zapier.
Objective: Format my data for an email.
Inputs:
- shops: The Stores
- shop_target_billing: Revenue incl. VAT
- shop_orders: Number of orders
- shop_margin: Margin incl. VAT
- week: Start of week date
Request:
Using the exact input names provided, I want to format an elegant and modern email that returns the stores' performance table.
Output: HTML code

Your data is now up to date, extracted, and perfectly formatted. All that remains is to send it to the tool of your choice (Gmail, Slack, Notion, Google Sheets…).

Configure the final action using the result generated by step 4 (the Code Formatting).

Example

We add a Gmail - Send Email step.

Zapier Gmail

We select the recipients (the store managers), we write the email subject, and in the message body (Body), we simply insert the HTML variable generated in step 4.

Zapier Email Result