ONE companies:research
← Receivers

companies:research

companies family

Research a company from its own site and keep the result on the caller's record of that company: the homepage and up to five of its own pages (pricing, about, product, contact, blog) folded into one provenance-tracked profile. Plain fetches only: no model, no browser render, nothing invented; a field the site does not state is named in gaps. Without url it reads back what was kept. The answer is a summary; the full profile stays on the record

Effect
ask
Awaits an outcome — the call returns the response below.
Caller
manage_groups
The class of authority the caller must already hold, decided from the attested context with no round trip.
Cost
free
What one call costs, so you can budget before acting.
Reversible
yes
The effect can be undone by a later call.
Idempotent
yes
Safe to retry as-is.

Send it with your agent

One click hands your coding agent a prompt that registers the substrate, reads this contract, and makes the call. Launch opens the app; the others copy the prompt.

Claude Code
Codex
Cursor
Gemini CLI
Claude Desktop
ChatGPT
curl -X POST https://one.ie/api/ask/companies:research \
  -H "Authorization: Bearer $ONE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"data": { "gid": "group:co-01a2b3c4", "url": "byrnedental.ie" }}'

The key is never in a link. npx -y @oneie/cli login writes it to ~/.config/oneie/key on your machine.

Request

Validated before dispatch — an invalid payload is refused with the fix, never half-applied.

  • gid string required The company record: group:co-<id>, as companies:create and people:create answer it. Anything else is refused as not_a_company
  • url string optional The company's site: a domain or a full https URL. Omit to read the kept research back

Response

What comes back from the call.

  • ok boolean
  • stored boolean true when the research is on the record; false when the site could not be read and nothing was kept
  • url string
  • domain string
  • at number Epoch ms the site was read
  • thin boolean The homepage is a script shell, so a plain fetch saw less than the site holds
  • pages object[] Every page asked for, read or not
  • pagesCapped boolean true when the site had more candidate pages than the five read
  • summary object
  • profiles object[] The company's social accounts, one per platform
  • error string not_a_company · not_researched · no_db · invalid_url · blocked_url · timeout · fetch_failed:<status> · unreachable

Traffic

Every call to companies:research, counted where it is dispatched — over HTTP or in-process alike. Aggregate only — no actor, no payload, no workspace.

Counting…

Wiring

Every place in the open source that names companies:research, and the file that answers it. Read from the tree at build time — a receiver is reached by NAME through one door, so there is no import edge to follow and a grep is the honest shape of the question. Structure, not volume — the count is in Traffic above.

Called from

UI 2
  • one.ie/web/src/components/crm/AddPersonSheet.tsx:11
  • one.ie/web/src/components/crm/CompaniesTab.tsx:131
API route 1
  • one.ie/web/src/lib/receiver-index.generated.ts:113
→

Answered by

companies:research one.ie/web/src/lib/resolvers/groups.ts:411 Dispatched through POST /api/ask/companies:research, after the envelope validates the payload.

companies family · 1 more

JSON Schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "gid": {
      "type": "string",
      "description": "The company record: group:co-<id>, as companies:create and people:create answer it. Anything else is refused as not_a_company"
    },
    "url": {
      "description": "The company's site: a domain or a full https URL. Omit to read the kept research back",
      "type": "string"
    }
  },
  "required": [
    "gid"
  ]
}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "ok": {
      "type": "boolean"
    },
    "stored": {
      "description": "true when the research is on the record; false when the site could not be read and nothing was kept",
      "type": "boolean"
    },
    "url": {
      "type": "string"
    },
    "domain": {
      "type": "string"
    },
    "at": {
      "description": "Epoch ms the site was read",
      "type": "number"
    },
    "thin": {
      "description": "The homepage is a script shell, so a plain fetch saw less than the site holds",
      "type": "boolean"
    },
    "pages": {
      "description": "Every page asked for, read or not",
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "url": {
            "type": "string"
          },
          "ok": {
            "type": "boolean"
          },
          "error": {
            "type": "string"
          }
        },
        "required": [
          "url",
          "ok"
        ]
      }
    },
    "pagesCapped": {
      "description": "true when the site had more candidate pages than the five read",
      "type": "boolean"
    },
    "summary": {
      "type": "object",
      "properties": {
        "name": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "oneLiner": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "foundedYear": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ]
        },
        "products": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "locations": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "people": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "role": {
                "type": "string"
              }
            },
            "required": [
              "name",
              "role"
            ]
          }
        },
        "gaps": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "Profile fields the site did not answer"
        }
      },
      "required": [
        "name",
        "oneLiner",
        "foundedYear",
        "products",
        "locations",
        "people",
        "gaps"
      ]
    },
    "profiles": {
      "description": "The company's social accounts, one per platform",
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "platform": {
            "type": "string"
          },
          "url": {
            "type": "string"
          },
          "handle": {
            "type": "string"
          },
          "kind": {
            "type": "string",
            "enum": [
              "person",
              "company",
              "unknown"
            ]
          },
          "label": {
            "type": "string"
          }
        },
        "required": [
          "platform",
          "url",
          "handle",
          "kind",
          "label"
        ]
      }
    },
    "error": {
      "description": "not_a_company · not_researched · no_db · invalid_url · blocked_url · timeout · fetch_failed:<status> · unreachable",
      "type": "string"
    }
  },
  "required": [
    "ok"
  ]
}