> ## Documentation Index
> Fetch the complete documentation index at: https://deepline.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Context.dev: Contextdev Get Web Fonts

> Find the fonts a website uses, with families, fallbacks, and how often each appears. Includes inputs, outputs, SDK V2 examples, and Deepline cost.

Find the fonts a website uses, with families, fallbacks, and how often each appears.

> [!NOTE]
>
> Tool ID: `contextdev_get_web_fonts`

## Run this action

Use the TypeScript SDK for one call. Use `ctx.tools.execute(...)` inside a Play for durable calls, scheduled calls, or CSV processing.

```ts theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
import { Deepline } from 'deepline';

const deepline = await Deepline.connect();
const result = await deepline.tools.execute(
  'contextdev_get_web_fonts',
  {
    "directUrl": "https://example.com/resource",
    "domain": "example.com",
    "maxAgeMs": 7776000000
  },
);

console.log(result.toolResponse.raw);
```

### CLI

```bash theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
deepline run contextdev_get_web_fonts --input '{
  "directUrl": "https://example.com/resource",
  "domain": "example.com",
  "maxAgeMs": 7776000000
}'
```

## Example response

The SDK returns this shape at `result.toolResponse.raw`. The example values illustrate the response.

```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
{
  "data": {
    "status": "example",
    "domain": "example.com",
    "fonts": [
      {
        "font": "example",
        "uses": [
          "example"
        ],
        "fallbacks": [
          "example"
        ],
        "num_elements": 123,
        "num_words": 123,
        "percent_words": 123,
        "percent_elements": 123
      }
    ],
    "code": 123,
    "cache_metadata": {
      "status": "hit",
      "age_ms": 123
    },
    "request_id": "123e4567-e89b-42d3-a456-426614174000"
  }
}
```

Use `deepline describe contextdev_get_web_fonts --json` for the latest machine-readable contract.

## Input reference

Identify fonts and available font files used by a website.

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `payload.directUrl` | `string` | No | — | Exact page to inspect. Provide either `domain` or `directUrl`. Format: `uri`. |
| `payload.domain` | `string` | No | — | Domain name to extract fonts from (e.g., 'example.com', 'google.com'). The domain will be automatically normalized and validated. You must provide either 'domain' or 'directUrl', but not both. Minimum length: 3. |
| `payload.maxAgeMs` | `integer` | No | `7776000000` | Maximum age of cached brand data in ms. Defaults to 3 months. clamped to 0–1 year. `0` refreshes. |
| `payload.timeoutOpts` | `object` | No | — | Request deadline and what to return when it passes. |
| `payload.tags` | `array` | No | — | Comma-separated labels for filtering usage, e.g. `production,team-alpha`. Maximum items: 20. |
| `payload.timeoutMS` | `integer` | No | — | Deprecated: use timeoutOpts.milliseconds. Request deadline in milliseconds. sent as timeoutOpts with the "fail" behavior. Minimum: 1. Maximum: 300000. |

<details>
  <summary>Show raw input schema</summary>

  ### Input JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "description": "Identify fonts and available font files used by a website.",
    "properties": {
      "directUrl": {
        "type": "string",
        "description": "Exact page to inspect. Provide either `domain` or `directUrl`.",
        "format": "uri"
      },
      "domain": {
        "type": "string",
        "description": "Domain name to extract fonts from (e.g., 'example.com', 'google.com'). The domain will be automatically normalized and validated. You must provide either 'domain' or 'directUrl', but not both.",
        "minLength": 3
      },
      "maxAgeMs": {
        "type": [
          "integer",
          "null"
        ],
        "description": "Maximum age of cached brand data in ms. Defaults to 3 months; clamped to 0–1 year. `0` refreshes.",
        "default": 7776000000
      },
      "timeoutOpts": {
        "type": "object",
        "description": "Request deadline and what to return when it passes.",
        "properties": {
          "milliseconds": {
            "type": "integer",
            "description": "Deadline in milliseconds.",
            "minimum": 1,
            "maximum": 300000
          },
          "behavior": {
            "type": "string",
            "description": "\"fail\" returns 408 at the deadline. \"return-partial\" returns available results; inspect the response’s partial flag. \"return-partial\" requires at least 5000 ms. On POST /web/scrape, an output that is not ready in time fails with error_code REQUEST_TIMEOUT inside a 200 response under either behavior; 408 is returned only when the whole request cannot respond by the deadline.",
            "default": "fail",
            "enum": [
              "fail",
              "return-partial"
            ]
          }
        },
        "required": [
          "milliseconds"
        ],
        "additionalProperties": false
      },
      "tags": {
        "type": "array",
        "description": "Comma-separated labels for filtering usage, e.g. `production,team-alpha`.",
        "maxItems": 20,
        "items": {
          "type": "string",
          "minLength": 1,
          "maxLength": 50
        }
      },
      "timeoutMS": {
        "type": "integer",
        "description": "Deprecated: use timeoutOpts.milliseconds. Request deadline in milliseconds; sent as timeoutOpts with the \"fail\" behavior.",
        "minimum": 1,
        "maximum": 300000
      }
    },
    "required": [],
    "additionalProperties": false
  }
  ```
</details>

## Output reference

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `result.data` | `object` | Yes | — | — |
| `result.data.finalDOMState` | `"loaded" \| "still-loading"` | No | — | Allowed: `loaded`, `still-loading`. |
| `result.data.status` | `string` | Yes | — | — |
| `result.data.domain` | `string` | Yes | — | — |
| `result.data.fonts` | `array` | Yes | — | — |
| `result.data.fonts[].font` | `string` | Yes | — | — |
| `result.data.fonts[].uses` | `array` | Yes | — | — |
| `result.data.fonts[].fallbacks` | `array` | Yes | — | — |
| `result.data.fonts[].num_elements` | `number` | Yes | — | — |
| `result.data.fonts[].num_words` | `number` | Yes | — | — |
| `result.data.fonts[].percent_words` | `number` | Yes | — | — |
| `result.data.fonts[].percent_elements` | `number` | Yes | — | — |
| `result.data.fontLinks` | `record` | No | — | — |
| `result.data.code` | `integer` | Yes | — | — |
| `result.data.cache_metadata` | `object` | Yes | — | — |
| `result.data.cache_metadata.status` | `"hit" \| "miss" \| "zdr"` | Yes | — | Allowed: `hit`, `miss`, `zdr`. |
| `result.data.cache_metadata.age_ms` | `integer` | Yes | — | Minimum: 0. |
| `result.data.key_metadata` | `object` | No | — | — |
| `result.data.request_id` | `string` | Yes | — | Format: `uuid`. |
| `result.meta` | `object` | No | — | — |

<details>
  <summary>Show raw output schema</summary>

  ### Output JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "properties": {
      "data": {
        "type": "object",
        "properties": {
          "finalDOMState": {
            "type": "string",
            "enum": [
              "loaded",
              "still-loading"
            ]
          },
          "status": {
            "type": "string"
          },
          "domain": {
            "type": "string"
          },
          "fonts": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "font": {
                  "type": "string"
                },
                "uses": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "fallbacks": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "num_elements": {
                  "type": "number"
                },
                "num_words": {
                  "type": "number"
                },
                "percent_words": {
                  "type": "number"
                },
                "percent_elements": {
                  "type": "number"
                }
              },
              "required": [
                "font",
                "uses",
                "fallbacks",
                "num_elements",
                "num_words",
                "percent_words",
                "percent_elements"
              ],
              "additionalProperties": false
            }
          },
          "fontLinks": {
            "type": "object",
            "additionalProperties": {
              "type": "object",
              "properties": {
                "type": {
                  "type": "string",
                  "enum": [
                    "google",
                    "custom"
                  ]
                },
                "files": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "string"
                  }
                },
                "faces": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "url": {
                        "type": "string"
                      },
                      "style": {
                        "type": "string"
                      },
                      "weight": {
                        "type": "string"
                      },
                      "width": {
                        "type": "string"
                      },
                      "unicodeRange": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "url",
                      "style",
                      "weight"
                    ],
                    "additionalProperties": false
                  }
                },
                "category": {
                  "type": "string"
                },
                "displayName": {
                  "type": "string"
                }
              },
              "required": [
                "type"
              ],
              "additionalProperties": false
            }
          },
          "code": {
            "type": "integer"
          },
          "cache_metadata": {
            "type": "object",
            "properties": {
              "status": {
                "type": "string",
                "enum": [
                  "hit",
                  "miss",
                  "zdr"
                ]
              },
              "age_ms": {
                "type": "integer",
                "minimum": 0
              }
            },
            "required": [
              "status",
              "age_ms"
            ],
            "additionalProperties": false
          },
          "key_metadata": {
            "type": "object",
            "properties": {},
            "required": [],
            "additionalProperties": false
          },
          "request_id": {
            "type": "string",
            "format": "uuid"
          }
        },
        "required": [
          "status",
          "domain",
          "fonts",
          "code",
          "cache_metadata",
          "request_id"
        ],
        "additionalProperties": false
      },
      "meta": {
        "type": "object",
        "additionalProperties": true
      }
    },
    "required": [
      "data"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Deepline cost

* Pricing model: `provider_usage` (provider usage).
* Estimated Deepline credits: `0.01` per pricing unit.

## Related documentation

* [Connect integrations](https://deepline.com/docs/integrations.md)
* [SDK V2 quickstart](https://deepline.com/docs/sdk-v2/quickstart.md)
* [SDK reference](https://deepline.com/docs/sdk-v2/sdk-reference.md)
* [Run tools across a CSV](https://deepline.com/docs/sdk-v2/batch-csv.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.