Ir al contenido

Los artículos de ayuda existen en alemán e inglés. Aquí los lees en inglés.

Instalación

How do I report a funnel step?

In the browser with metrunio.identify(userId) once after sign-in and then metrunio.goal('key') per step; from the backend with POST /v1/server/events and an event of type goal carrying goal_key and user_id. Both routes are equivalent; a step without a customer identifier is rejected.

How do I send the steps of my funnel from the browser or the backend?

A funnel step is an event of type goal with the key of the step and a customer identifier. Where it comes from does not matter: the SDK in the browser and the Server Events API produce the same event, with the same “once per customer” rule. Use the route where the step actually happens: sign-up where your backend creates the account; a completed setup dialog where it ends in the browser.

In the browser

// once after sign-in: makes the customer the same across devices
metrunio.identify('customer-4711');

// once per step; a second call for the same customer does not count again
metrunio.goal('shop_created');

// with an amount if the event knows it: counts as revenue.
// Without one, the acquisition value from the portal applies.
metrunio.goal('first_payment', { value: 49, currency: 'EUR' });

identify() comes before goal(), in the same page load or earlier: the SDK attaches the customer identifier to everything sent afterwards. Without identify() the step leaves with the pseudonymous browser ID. It is accepted, but counts per browser instead of per customer. The key is sent in lower case without spaces; an empty key yields GOAL_KEY_MISSING in the console.

From the backend

curl -X POST "$METRUNIO_COLLECTOR/v1/server/events" \
  -H "authorization: Bearer $METRUNIO_SERVER_KEY" \
  -H "content-type: application/json" \
  -d '{
    "site_id": "site_demo_app",
    "events": [{
      "event_id": "customer-4711-shop_created",
      "event_type": "goal",
      "goal_key": "shop_created",
      "user_id": "customer-4711",
      "occurred_at": "2026-09-14T10:15:00Z",
      "consent_state": "granted",
      "consent_purposes": ["analytics"]
    }]
  }'

$METRUNIO_COLLECTOR is the address from the ready-made call on the “Server Events API” tab in Setup (see “How do I report conversions server-side?”).

The user_id is the same customer number you pass to identify() in the browser; it is pseudonymised on receipt and never stored in clear text. If you already pseudonymise, send user_id_hash; it is also combined with your account’s key on receipt. A goal without goal_key or without a customer identifier is rejected, and the response names the field. Value and currency are optional. If you send them, the amount counts as revenue; if they are missing, the step’s acquisition value applies, separate from revenue. That is the default; the value logic of a step is set in the portal (see “What is a funnel step worth?”).

The event ID

Build the event ID from customer and step, for example customer-4711-shop_created. A repeated call (a job that runs again, a second click) is then harmless on two levels: the same event ID counts only once against the quota, and the same step counts only once per customer in the report. The SDK creates its own event IDs.

Testing

  • In the portal under “Orders & goals”, every step has a “Send test step” button. The event lands in the test data and counts there immediately as a conversion of that step, not in the reports.
  • In the setup assistant, the step “Define a conversion” with the choice “Steps in an application (SaaS)” creates three funnel steps: registriert, eingerichtet, erste_zahlung. You can rename, add or retire them.
  • From your own system: send the step with environment: "test", or in the SDK with testMode: true, and check it under “Orders & goals” with the “Test data” switch.

Caution

goal is an analytics event. Without analytics consent it does not leave the device in the browser, and server-side it is not stored without matching consent_purposes. Every step sent counts against the event quota.

Revisado por última vez el 14 oct 2026

En el portal del cliente

Go to orders & goals

También se pregunta

  • metrunio.goal
  • How do I send a goal event?
  • How do I report a funnel step from the backend?
  • Why do I need identify() before goal()?
  • Which event ID do I use for a funnel step?
  • How do I test a funnel step?
  • How do I set up a SaaS funnel in the assistant?

Artículos relacionados

  • What is a funnel step?

    How do I measure a funnel when there is no purchase?

    A funnel step is a conversion a customer reaches rather than buys: signed up, set up, first payment. Each step has a key and a position and counts exactly once per customer, however often it is reported. Several steps in order make up the funnel in the “Orders & goals” report.

  • How do I read the funnel report?

    What do “Reached”, “Transition” and “Skipped” mean in the funnel?

    “Reached” is the measured number of customers who reached the step in the period, once per customer. “Transition” follows the cohort: of the customers who reached the previous step in the period, the share that reached this step by the end of the period (never above 100%). “Skipped” are customers who reached the step but never the one before it.

  • What does the tracking SDK offer?

    Which JavaScript calls are available?

    The SDK provides init, setConsent, page, track, identify, conversion, goal and reset, plus paymentReference for Stripe and PayPal, fillForm for forms, and renderSurvey and survey for the post-purchase question. It loads asynchronously, queues calls made before it loads, and sends events in batches.

  • How do I report conversions server-side?

    How do I send events from my shop, CRM or backend?

    Through POST /v1/server/events to the collector, with the server key in the authorization header. The portal shows the address and the ready-made call for your website under “Setup” on the “Server Events API” tab. The call is independent of the browser and therefore robust against ad blockers and short-lived cookies.

  • How do I measure a single-page app?

    What do I do if route changes without a reload are not counted?

    With automatic page views (autoPageviews, on by default) the SDK also counts route changes without a reload: it notices every address change through pushState, replaceState and the back button. Call metrunio.page() yourself only if your router switches views without changing the address, or if you have turned autoPageviews off.

  • How do I test my first conversion?

    How do I check that a conversion arrives correctly?

    The setup assistant has a step called “Run a test conversion”. It creates a test purchase with a test visit before it, both stored as test data: they appear immediately in the live checklist, the journey shows an attributed touchpoint, and they stay excluded from standard reports.

  • Does consent apply to server events too?

    Do I need consent when I send server-side?

    Yes, because server-side processing does not mean exemption from consent: pass consent_state and consent_purposes in the event; without matching consent an event is rejected. The exception is purchases and refunds with consent_state unknown: they are stored for revenue reconciliation, with their order number and without browser, customer or advertising identifiers, count towards measured revenue and appear as not attributed with the reason “No consent”. With denied this only applies if the additional instruction for revenue reconciliation is activated for your account. You can switch revenue reconciliation off in the portal under Privacy; such an order can only be attributed via the checkout, if you switch that on.

Mira lo que cuentan tus datos.

Echa un vistazo primero a la demo. Por ahora, solo hay cuenta propia con invitación.

Abrir la demoSolicitar acceso