# Tech stack

> POST /tech/stack reads a site's homepage and DNS after robots.txt and returns the CMS, analytics, CDN, hosting, frameworks and other technologies it uses.

`POST https://api.qelka.com/v1/tech/stack`

Detect the technologies behind a website: CMS, e-commerce platform, analytics, tag managers, advertising, CDN, hosting, web servers, frameworks, payments, chat, A/B testing, fonts, consent tools and email providers. Each lookup costs 1 credit when the homepage could be read; sites that cannot be read, errors and test keys are never billed.

## Request

| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| `url` | string | Yes | none | A domain (`example.com`) or a URL of the site, 1 to 2,048 characters. Only the host is used. |
| `fresh` | boolean | No | `false` | `true` skips the 7-day result cache and reads the site again. |

The same host rules as the [website endpoint](https://qelka.com/docs/api-reference/website) apply: public hosts only, robots.txt first, redirects to public hosts only, 6 seconds per request. Every snippet sets a 60-second client timeout.

```bash title="cURL"
curl https://api.qelka.com/v1/tech/stack \
  --max-time 60 \
  -H "Authorization: Bearer $QELKA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url": "allbirds.com"}'
```
```javascript title="Node.js"
const response = await fetch('https://api.qelka.com/v1/tech/stack', {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${process.env.QELKA_API_KEY}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({ url: 'allbirds.com' }),
  signal: AbortSignal.timeout(60_000),
})
const result = await response.json()
console.log(result)
```
```python title="Python"
import os

import requests

api_key = os.environ["QELKA_API_KEY"]
response = requests.post(
    "https://api.qelka.com/v1/tech/stack",
    headers={"Authorization": f"Bearer {api_key}"},
    json={"url": "allbirds.com"},
    timeout=60,
)
result = response.json()
print(result)
```
```php title="PHP"
<?php
$ch = curl_init('https://api.qelka.com/v1/tech/stack');
curl_setopt_array($ch, [
    CURLOPT_POST => true,
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer ' . getenv('QELKA_API_KEY'),
        'Content-Type: application/json',
    ],
    CURLOPT_POSTFIELDS => json_encode(['url' => 'allbirds.com']),
    CURLOPT_TIMEOUT => 60,
]);
$result = json_decode(curl_exec($ch), true);
print_r($result);
```
```go title="Go"
package main

import (
	"bytes"
	"encoding/json"
	"fmt"
	"net/http"
	"os"
	"time"
)

func main() {
	payload, _ := json.Marshal(map[string]any{"url": "allbirds.com"})
	request, _ := http.NewRequest(http.MethodPost, "https://api.qelka.com/v1/tech/stack", bytes.NewReader(payload))
	request.Header.Set("Authorization", "Bearer "+os.Getenv("QELKA_API_KEY"))
	request.Header.Set("Content-Type", "application/json")

	client := &http.Client{Timeout: 60 * time.Second}
	response, err := client.Do(request)
	if err != nil {
		panic(err)
	}
	defer response.Body.Close()

	var result map[string]any
	if err := json.NewDecoder(response.Body).Decode(&result); err != nil {
		panic(err)
	}
	fmt.Println(result)
}
```
```ruby title="Ruby"
require 'json'
require 'net/http'

uri = URI('https://api.qelka.com/v1/tech/stack')
request = Net::HTTP::Post.new(uri)
request['Authorization'] = "Bearer #{ENV.fetch('QELKA_API_KEY')}"
request['Content-Type'] = 'application/json'
request.body = JSON.generate({ url: 'allbirds.com' })

response = Net::HTTP.start(uri.host, uri.port, use_ssl: true, read_timeout: 60) do |http|
  http.request(request)
end
result = JSON.parse(response.body)
puts result
```

## Response

| Field | Type | Description |
|---|---|---|
| `id` | string | Identifier of this lookup. |
| `object` | string | Always `tech_stack`. |
| `input` | string | The `url` you sent, without surrounding spaces. |
| `url` | string | The homepage that was requested. |
| `final_url` | string or null | The homepage after redirects. `null` when it was not fetched. |
| `host` | string | Host of `final_url`, or of `url` when nothing was fetched. |
| `status` | string | `ok`, `robots_disallowed`, `unreachable`, `http_error` or `not_html`, as for the [website endpoint](https://qelka.com/docs/api-reference/website#act-on-the-status). |
| `http_status` | integer or null | HTTP status of the homepage. |
| `technologies` | array of objects | Technologies detected, grouped by category. Empty unless `status` is `ok`. |
| `technologies.slug` | string | Stable identifier, such as `shopify` or `google-tag-manager`. |
| `technologies.name` | string | Display name. |
| `technologies.category` | string | One of the [categories](#categories). |
| `technologies.version` | string or null | Version when the page states it in a generator tag, a header or an asset path. Never guessed. |
| `technologies.website` | string | Website of the technology. |
| `technologies.icon` | string or null | Slug of its mark in [Simple Icons](https://simpleicons.org) (CC0), such as `shopify`, or `null`. Draw it from the `simple-icons` package or its CDN. |
| `technologies.evidence` | array of strings | Where it was seen: `header`, `cookie`, `html`, `script`, `stylesheet`, `meta`, `dns` or `url`. |
| `shopify` | object or null | When Shopify is detected: `myshopify_domain` and `theme`, each a string or `null`. |
| `wordpress` | object or null | When WordPress is detected: `theme` (folder name) and `plugins` (folder names whose assets the homepage loads). |
| `credits_used` | integer | Credits debited for this call: 1 with a live key when the result is billed, else `0`. |
| `cached` | boolean | `true` when the answer came from the 7-day cache. |

```json title="Response"
{
  "id": "lkp_01M8CGE3QQRQVJ32DDB6FC7FG7",
  "object": "tech_stack",
  "input": "allbirds.com",
  "url": "https://allbirds.com/",
  "final_url": "https://www.allbirds.com/",
  "host": "www.allbirds.com",
  "status": "ok",
  "http_status": 200,
  "technologies": [
    {
      "slug": "shopify",
      "name": "Shopify",
      "category": "ecommerce",
      "version": null,
      "website": "https://www.shopify.com",
      "icon": "shopify",
      "evidence": ["header", "cookie", "html", "dns"]
    },
    {
      "slug": "microsoft-clarity",
      "name": "Microsoft Clarity",
      "category": "analytics",
      "version": null,
      "website": "https://clarity.microsoft.com",
      "icon": null,
      "evidence": ["html"]
    },
    {
      "slug": "google-tag-manager",
      "name": "Google Tag Manager",
      "category": "tag_manager",
      "version": null,
      "website": "https://tagmanager.google.com",
      "icon": "googletagmanager",
      "evidence": ["html"]
    },
    {
      "slug": "cloudflare",
      "name": "Cloudflare",
      "category": "cdn",
      "version": null,
      "website": "https://www.cloudflare.com",
      "icon": "cloudflare",
      "evidence": ["header"]
    },
    {
      "slug": "tailwind-css",
      "name": "Tailwind CSS",
      "category": "css_framework",
      "version": null,
      "website": "https://tailwindcss.com",
      "icon": "tailwindcss",
      "evidence": ["html"]
    },
    {
      "slug": "microsoft-365",
      "name": "Microsoft 365",
      "category": "email",
      "version": null,
      "website": "https://www.microsoft.com/microsoft-365",
      "icon": null,
      "evidence": ["dns"]
    }
  ],
  "shopify": {
    "myshopify_domain": "weareallbirds.myshopify.com",
    "theme": "allbirds-theme"
  },
  "wordpress": null,
  "credits_used": 1,
  "cached": false
}
```

## Categories

`cms`, `ecommerce`, `analytics`, `tag_manager`, `advertising`, `marketing_automation`, `cdn`, `hosting`, `web_server`, `programming_language`, `web_framework`, `javascript_framework`, `javascript_library`, `css_framework`, `static_site_generator`, `payment`, `chat`, `ab_testing`, `font`, `email`, `consent`, `security`, `monitoring`, `video`, `maps`, `search`, `reviews`, `forms`, `scheduling`, `accessibility`, `authentication` and `dns`. New categories can be added; treat an unknown one as other.

## How technologies are detected

1. robots.txt is read, then the homepage, without running any script. Up to 1,500 kB of HTML are read.
2. The CNAME of the host and the NS, MX and SPF records of the domain are looked up at the same time.
3. 449 in-house fingerprints are matched against the response headers, cookie names, HTML markers, script and stylesheet URLs, meta tags, final URL and DNS records. A technology can imply another, such as WordPress implying PHP.

The fingerprints are written from each technology's public documentation and asset hosts; none is copied from Wappalyzer, webappanalyzer or another GPL dataset. Tools that a tag manager or another script injects after load are not seen, and only the homepage is read: an empty category does not prove absence.

## Batch and bulk

Send up to 100 sites in one [batch](https://qelka.com/docs/api-reference/batch) with `"type": "tech_stack"`, or a CSV column of domains as a [bulk job](https://qelka.com/docs/api-reference/bulk): the output adds one column per main category (CMS, e-commerce, analytics, CDN, hosting, JavaScript framework, payment, email). The MCP tool is `detect_tech_stack`.
