slee.pt

A dead simple API for delayed responses.
Perfect for testing timeouts, loading states, and async behavior.

Quick Start

With Payload

POST to the delay path with your data - it will be echoed back:

curl -X POST https://slee.pt/5s \
  -H "Content-Type: application/json" \
  -d '{"data": {"message": "Hello!"}}'

Your payload will be returned after 5 seconds.

Without Payload

Payload is optional - just POST with an empty body:

curl -X POST https://slee.pt/3s \
  -H "Content-Type: application/json" \
  -d '{}'

Perfect for simple timeout testing.

Supported Time Formats

Format

240→ 240 seconds (default)
5s→ 5 seconds
2m→ 2 minutes
1h→ 1 hour
500ms→ 500 milliseconds

Limits

  • Maximum delay: 5 minutes (300s)
  • Minimum delay: 0ms
  • Decimal values supported: 1.5s

Response Format

All successful responses return JSON with the following structure:

{
  "success": true,
  "delayed_by": 5000,
  "requested_delay": "5s",
  "timestamp": "2025-11-19T02:30:45.123Z",
  "data": {
    "message": "Your custom payload"
  },
  "url": null
}

Code Examples

JavaScript / TypeScript

async function testDelay() {
  const response = await fetch('https://slee.pt/3s', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({
      data: { userId: 123, action: 'test' }
    })
  });

  const result = await response.json();
  console.log(result);
  // Your data is returned after 3 seconds
}

Python

import requests

response = requests.post(
    'https://slee.pt/5s',
    json={'data': {'user_id': 123, 'action': 'test'}}
)

result = response.json()
print(result)
# Your data is returned after 5 seconds

wget (Alpine/Minimal Builds)

Perfect for Alpine-based Docker containers and minimal Linux distributions

wget --post-data='{"data": {"test": "value"}}' \
  --header='Content-Type: application/json' \
  --timeout=180 \
  -O response.json \
  https://slee.pt/2m

Go

package main

import (
    "bytes"
    "encoding/json"
    "net/http"
)

func main() {
    payload := map[string]interface{}{
        "data": map[string]interface{}{"userId": 123},
    }

    body, _ := json.Marshal(payload)
    resp, _ := http.Post(
        "https://slee.pt/2s",
        "application/json",
        bytes.NewBuffer(body),
    )
    defer resp.Body.Close()
}

Rust

use reqwest;
use serde_json::json;

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let client = reqwest::Client::new();
    let res = client
        .post("https://slee.pt/4s")
        .json(&json!({"data": {"userId": 123}}))
        .send()
        .await?;

    let body = res.json::<serde_json::Value>().await?;
    println!("{:?}", body);
    Ok(())
}

FAQ

Is there a rate limit?

Currently there are no rate limits, but please use responsibly.

What is the maximum delay?

The maximum delay is 5 minutes (300 seconds) to prevent timeout issues.

Can I pass custom data?

Yes! Include a "data" field in your POST request body, and it will be returned in the response after the delay. The payload is completely optional - you can POST with an empty body {} if you just need a delay.

Is this service free?

Yes, completely free and open for testing purposes.

Can I use this in production?

This service is intended for development and testing. For production, consider self-hosting or using a dedicated service.

Built with Next.js • Open source • No tracking