How it works?

Treblle is an SDK that you add on top of your API. Select a platform below to see how to get started

Step 1

Install Treblle via NPM

Run command

npm install treblle

You can ⭐ our Github repo to stay up to date with new updates

View on Github

Go to Step 2
Step 2

Enable Treblle on your API

Add a few lines of code

// DON'T FORGET TO LOAD THE REQUIRED JS MODULES
const express = require("express");
const { useTreblle } = require("treblle");
 
const app = express();
app.use(express.json());
 
useTreblle(app, {
apiKey: "_YOUR_API_KEY_",
projectId: "_YOUR_PROJECT_ID_"
});

HEADS UP: You need to create an account to get your API KEY and PROJECT ID

Go to Step 3
Done

🎉 You're all set! 🎉

You and your team just got these amazing features:

  • Real-time API monitoring
  • Auto-generated API documenation
  • API analytics
  • Powerfull request search and filtering
  • 1-click API testing
  • Real-time problem detection
  • OpenAPI Specification support
  • Location based request tracking
  • Smart URL parameters detection
  • and many more..
Optional

Configuration params

Debug mode

// DON'T FORGET TO LOAD THE REQUIRED JS MODULES
const express = require("express");
const { useTreblle } = require("treblle");
 
useTreblle(app, {
apiKey: "_YOUR_API_KEY_",
projectId: "_YOUR_PROJECT_ID_",
showErrors: false, // Set true to enable debug mode
});

A boolean that allows you to debug Treblle locally - false by default

Mask sensitive data

1// DON'T FORGET TO LOAD THE REQUIRED JS MODULES
2const express = require("express");
3const { useTreblle } = require("treblle");
4 
5useTreblle(app, {
6 apiKey: "_YOUR_API_KEY_",
7 projectId: "_YOUR_PROJECT_ID_",
8 additionalFieldsToMask: ["secret", "private", "user_ssn"]
9});

PRO TIP: Data is masked before it even leaves your server

Monitor only specific environments

1// DON'T FORGET TO LOAD THE REQUIRED JS MODULES
2const express = require("express");
3const { useTreblle } = require("treblle");
4 
5const app = express();
6app.use(express.json());
7 
8// MONITOR ONLY the "production" ENVIROMENT
9if(process.env.NODE_ENV === "production") {
10 useTreblle(app, {
11 apiKey: "_YOUR_API_KEY_",
12 projectId: "_YOUR_PROJECT_ID_",
13 });
14}

Need help getting started with Treblle on your API?

Book a meeting