Skip to Content

Treblle Docs

Getting StartedGetting Started

Quick Start

This quickstart helps you integrate the Treblle SDK into your API and get started with Treblle.

Create a Treblle Account

Go to the Treblle website and sign up for a free Treblle account .

Create Account

Create Your Workspace

After logging in, you’ll enter your Treblle account settings page. Click on the Treblle Platform button from the Apps section.

Account Settings

Create a new workspace by clicking on the “Create new workspace” button. You can also join an existing workspace by clicking on the “Join workspace” button.

Create Workspace

Team members can be invited to your workspace at this stage or at a later time.

Invite Team

The Treblle Homepage provides a bird’s-eye view of all your APIs and important metrics related to them. This is also where you can add new APIs.

Home Dashboard

Add an API

When you’re ready to add a new API, enter a logical API name and the base URL of the API.

Note

A base URL includes only the essential parts of the URL (scheme, domain, and optionally, port). Paths, queries, and fragments are excluded. Example: https://api.example.com 

To help with understanding the status of the API, it is also mandatory to add the environment type (Development, Staging, Production) and the framework being used.

Add New API

Based on what language and framework you are using, Treblle will provide you with the necessary SDK to integrate Treblle into your API.

As suggested by Treblle, follow the next steps and install the SDK .

Can’t find your platform? Check our complete integrations list.

Configure Your API

Add your Treblle credentials to your api:

TREBLLE_API_KEY=your_api_key TREBLLE_SDK_TOKEN=your_sdk_token

Enable Treblle

Add the Treblle middleware to your API routes. The exact implementation varies by platform, but here’s a general example:

Route::middleware(['treblle'])->group(function () { // Your API routes go here });

Observing your first API request in Treblle

Once you’ve added the Treblle API key and SDK token to your API middleware, Treblle will start capturing and monitoring all your API activities.

First Request

Once integrated, Treblle automatically provides you with:

Found a missing integration? Suggest it or contribute on GitHub 

The Treblle documentation is open source, and we welcome contributions from developers like you!

Last updated on