Folders

Create a folder

POST https://u2l.ai/api/v1/folders

Authorizations

Authorizationstringrequired

Bearer authentication header of the form Bearer <token>, where <token> is your U2L API key (u2l_live_...). Create one in the dashboard under Settings > API.

Body

namestringrequired

Folder name.

Response 201

idstring
namestring
linksCountinteger
createdAtstring

Errors

401 Missing or invalid API key.
422 The request body failed validation.
429 Rate limit exceeded. Check X-RateLimit-Reset for when the window resets.

See Rate Limits & Errors for the error envelope and per-plan limits.

curl -X POST https://u2l.ai/api/v1/folders \
  -H "Authorization: Bearer u2l_live_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
  "name": "Marketing campaigns"
}'
const response = await fetch("https://u2l.ai/api/v1/folders", {
  method: "POST",
  headers: {
    "Authorization": "Bearer u2l_live_your_api_key",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    "name": "Marketing campaigns"
  }),
});

const data = await response.json();
console.log(data);
import requests

response = requests.post(
    "https://u2l.ai/api/v1/folders",
    headers={"Authorization": "Bearer u2l_live_your_api_key"},
    json={
      "name": "Marketing campaigns"
    },
)

print(response.json())
package main

import (
	"fmt"
	"io"
	"net/http"
	"strings"
)

func main() {
	body := strings.NewReader(`{
  "name": "Marketing campaigns"
}`)
	req, _ := http.NewRequest("POST", "https://u2l.ai/api/v1/folders", body)
	req.Header.Set("Authorization", "Bearer u2l_live_your_api_key")
	req.Header.Set("Content-Type", "application/json")
	res, _ := http.DefaultClient.Do(req)
	defer res.Body.Close()

	data, _ := io.ReadAll(res.Body)
	fmt.Println(string(data))
}
{
  "id": "9f0c2f9e-3b7a-4c1d-8e5f-2a6b7c8d9e0f",
  "name": "Marketing campaigns",
  "linksCount": 0,
  "createdAt": "2026-07-20T10:30:00.000Z"
}