# Forest Factory API – Web Page Forms Extractor

> Forest Factory API – Web Page Forms Extractor is a paid API for AI agents from http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-22).

Fetches and extracts all HTML forms from a public URL, returning structured form metadata including field counts and rendering details.

## Facts

- Endpoint: POST https://http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run/page/forms?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-22
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/forest-factory-api-web-page-forms-extractor-a92cee2f
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Zy3PbO9Lyz-mfephCmc8d

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability forest-factory-api-web-page-forms-extractor-a92cee2f -d '<json body>'
```

Example prompt: Can you extract all the forms from https://example.com/contact and tell me how many there are and what fields they contain?

## When to prefer this

Use this endpoint when you need to programmatically detect or inventory HTML forms on a public web page, especially for automation workflows that depend on form presence (e.g. login detection, scraper setup, accessibility audits). Prefer this over generic web scraping endpoints when your goal is specifically form metadata extraction with structured output.

## Known failure modes

- URL is not publicly accessible or returns a non-200 status — form data will be empty or an error is returned
- Payment not signed — returns HTTP 402 with an x402 PAYMENT-REQUIRED challenge
- URL pattern does not match http/https scheme — request is rejected by schema validation
- Page uses heavy client-side rendering that the provider cannot execute — rendered_javascript may be false and forms may be missed
- URL exceeds 2048 characters — request rejected by schema validation

## How this service works

Machine-readable contract for active Forest paid capabilities. Unsigned paid calls return HTTP 402 with a PAYMENT-REQUIRED x402 challenge.

## Output

Returns a JSON object with an array of detected forms, the total form count, total returned field count, whether JavaScript rendering was used, the source URL inspected, and metadata including cache hit/miss status, provider name, timestamp, and response duration in milliseconds.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "url": {
   "type": "string",
   "pattern": "^https?://",
   "maxLength": 2048,
   "minLength": 1,
   "description": "Public HTTP(S) URL to inspect, resolve, or compare."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "data": {
   "forms": [],
   "truncated": false,
   "form_count": 0,
   "source_url": "example",
   "rendered_javascript": false,
   "returned_field_count": 0
  },
  "meta": {
   "cache": "miss",
   "provider": "safe-http",
   "checked_at": "2026-01-01T00:00:00.000Z",
   "duration_ms": 0
  },
  "version": "1",
  "capability": "web.page-forms"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/forest-factory-api-web-page-forms-extractor-a92cee2f/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run](https://www.zero.xyz/host/http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run/llms.txt)
