Skip to content
Facteur
/ Comparison

Facteur and MailSlurp

MailSlurp offers test inboxes and, on its higher plans, phone numbers. Here is what it publishes, then what Facteur does.

Sources

What MailSlurp publishes

Each line is something MailSlurp publishes. It carries the address of the page where we read it and the date we read it. What we could not check is not here. These pages change: read the source again before you decide.

  1. 01

    Five plans are listed: Free at $0, Starter at $19.99 per month, Pro at $49.99, Growth at $129.99 and Enterprise on quote.

    https://app.mailslurp.com/pricing/ ·

  2. 02

    The Free plan shows 500 emails received per month, 100 inbox creations per month and 50 retained inboxes.

    https://app.mailslurp.com/pricing/ ·

  3. 03

    Beyond what is included, the Pro and Growth plans bill extra inbox creations by usage.

    https://app.mailslurp.com/pricing/ ·

  4. 04

    Phone numbers come with the Pro, Growth and Enterprise plans, up to 5 rentals on Pro and 35 on Growth.

    https://app.mailslurp.com/pricing/ ·

  5. 05

    The JavaScript client installs with npm install --save mailslurp-client. A test creates an inbox with createInbox(), then waits for the latest email with waitForLatestEmail(inbox.id, timeoutMs). The documentation recommends a 60,000 ms timeout, because SMTP is a slow protocol.

    https://www.mailslurp.com/docs/js/ ·

Translating your tests

The same test, with one then the other

Both APIs wait for the message instead of leaving it to your suite, and the shape of the test stays the same. What changes comes down to two points: there is no inbox to create, and the code no longer needs extracting.

Before, with MailSlurp JavaScript
const { MailSlurp } = require('mailslurp-client');
const mailslurp = new MailSlurp({ apiKey: process.env.MAILSLURP_API_KEY });

// An inbox created for the test, which the application writes to.
const inbox = await mailslurp.createInbox();

// Waits for the latest email; the documentation recommends 60,000 ms.
const email = await mailslurp.waitForLatestEmail(inbox.id, 60000);

// The code is still to be found in the body of email.
Every call of MailSlurp shown here comes from its documentation: the Sources section gives the page and the date it was read.
After, with Facteur TypeScript
// No Facteur package to install: one HTTP call that waits.
const search = new URLSearchParams({
  inbox: 'j3k9x2mq',
  sentTo: address,
  wait: '30000',
});

const response = await fetch('https://api.facteur.eu/v1/messages?' + search, {
  headers: { authorization: 'Bearer ' + process.env.FACTEUR_API_KEY },
});
const { messages } = await response.json();

// The code is already extracted, in a field of its own.
const code = messages[0].otp;
Facteur publishes no library yet: the test calls the API over HTTP. The developers' portal plays this call against the service.
The migration, step by step

Four steps, both services side by side

  1. Step 01

    Create an account and an inbox

    The address already exists: each inbox has its own domain and accepts any address ending with it. The createInbox() at the top of the test goes away.

  2. Step 02

    Write to one address per test

    Each test picks its address, for example signup+run-42 followed by the inbox's domain. Two tests in parallel never read the same message.

  3. Step 03

    Replace the wait and the extraction

    waitForLatestEmail(inbox.id, timeout) becomes a search with inbox, sentTo and wait. The code arrives in the otp field: the regular expression has no purpose any more.

  4. Step 04

    Run the suite, then cancel

    Nothing needs moving: test messages come back on the next run. Keep both accounts until everything is green.

The switch, in short

What changes, row by row

Each cell about MailSlurp links to the sentence of the sources it comes from. A row that no source lets us write is not in the table.

Topic Facteur MailSlurp
Before sending Nothing to create: any address of the inbox's domain arrives. An inbox created by createInbox() at the top of the test. source
Waiting for a message The search waits on the server side, five minutes at most. waitForLatestEmail(inbox.id, timeoutMs), with 60,000 ms recommended. source
Billing A volume included in the plan, then prepaid packs or capped overage. Beyond what is included, inbox creations are billed by usage on Pro and Growth. source
Phone numbers Numbers from the Solo plan up, but the connection to the carrier is not in service. Numbers on the Pro, Growth and Enterprise plans. source
Facteur

What Facteur does

These lines describe Facteur as its product pages and help centre give it.

01

One address per test

Everything before the at sign is free. Two tests writing to inscription+run-42 and inscription+run-43 each get their own message, in the same inbox.

02

Wait for the message in one request

The search accepts a wait of five minutes at most. If nothing arrives, it answers an empty list, not an error.

03

The code, already extracted

The otp field holds the most likely one-time code. When nothing announces it, Facteur leaves it empty rather than guess.

04

Reading costs nothing

Only a received, kept message counts against your plan. A test that receives 3 emails and reads them 40 times uses 3.

05

Deleted when its time is up

Each message is deleted when your plan's duration has passed, with its raw file and attachments.

06

Hosted at OVHcloud

The application and its database are hosted at OVHcloud, and billing is in euros. The data centre is in France.

07

SMS are not received yet

The connection to the carrier that delivers SMS is not in service. An assigned number receives no real SMS today.

Choosing

Frequently asked questions

When to look at MailSlurp?

MailSlurp publishes phone numbers on its Pro, Growth and Enterprise plans. At Facteur, receiving real SMS is not in service yet. If you need to receive SMS right now, look at MailSlurp.

How much work is the migration from MailSlurp?

One line per call: createInbox() goes away, waitForLatestEmail() becomes Facteur's search, and extracting the code becomes reading a field. The migration goes file by file, with both services in parallel.

What happens to the messages already received at MailSlurp?

They stay at MailSlurp. They are test messages: they come back on the next run of your suite.

Where are Facteur's prices?

On the Pricing page, which reads Facteur's grid. No Facteur price is written here.

Try Facteur without an account

The trial receives a test email, with no sign-up. Prices are on the Pricing page.