Skip to content
Get started
Esc
Test mode

Building

Updated 4 December 2026

How it works

  • A test key sends on the simulator: messages are recorded and pass the same checks, but go nowhere.
  • In test mode channel is simulator in responses and webhooks, and that alone marks a test: there is no separate mode field. A test key sees only test messages, and the consent it records counts only on the simulator.

Writing as a customer

  • ⁠POST /v1/test/inbound writes as a customer. The message.received webhook arrives, and until its free_text_until you can answer this number with text.
  • ⁠POST /v1/test/inbound with type voice, audio, image or video sends a sample file: message.received carries its media_id, and ⁠GET /v1/media/{id} downloads it with the test key. A file uploaded with a test key is checked and goes nowhere.
Code language
import { Airbox } from "@airboxhq/api";

const client = new Airbox(process.env.AIRBOX_API_KEY);

const { data, error } = await client.test.inbound({
  from: "+77011234567",
  text: { body: "Hello! When will my order be ready?" },
  name: "Asel",
});

if (error) {
  throw new Error(`${error.code}: ${error.message} (${error.requestId})`);
}

console.log(data);

What differs from live

  • The simulator reports no delivery or reading, so test messages stay sent.
  • In test mode too, templates come from the ones Meta approved for the number.
  • A test key sends on the simulator with whatsapp and auto alike, and auto chooses from what the customer wrote through ⁠POST /v1/test/inbound.