# Company Trust Profile (`company.trust_profile`)

Collects a company's stated security and compliance posture: SOC 2, ISO 27001, HIPAA and GDPR claims with the page and quote that state them, its trust center, security.txt, bug-bounty or disclosure policy, DMARC policy and HSTS.

Docs: https://primaryapi.com/docs/api-reference/company/trust_profile

- Endpoint: `POST https://api.primaryapi.com/v1/run/company.trust_profile`
- Category: Compliance & Records · Platform: `company` · Kind: lookup · Status: live
- Price: 1 credit per call. Every call costs the same, including calls that were retried automatically.
- Billing unit: per successful call
- Reliability: routed to a healthy upstream and retried automatically when an attempt fails; live 30-day status: `GET https://api.primaryapi.com/v1/status/apis?sku=company.trust_profile`
- Execution: synchronous (answers 202 only if it outlives the wait window)

## Input

| Field | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
| `domain` | string | yes |  | max 2048 chars | Company domain such as "stripe.com". A URL or email address is reduced to its domain; "www." is dropped. |
| `url` | string | no |  | max 2048 chars; format: uri | Trust-center or security page to read in addition to what is found on the site. |

Unknown fields are rejected with `400 invalid_input`. The routing controls `preferLatencyUnderMs` and `maxCredits` may be sent in the same JSON body.

## Output

When `output.found` is `true`, `output.data` has this shape:

| Field | Type | Description |
|---|---|---|
| `domain` | string |  |
| `trustCenter` | object \| null |  |
| `trustCenter.url` | string |  |
| `trustCenter.platform` | enum | Hosting platform detected from the page markup; self_hosted when none is recognised. |
| `claims` | object[] | Sorted by framework, then page. |
| `claims[].framework` | enum |  |
| `claims[].label` | string | Human label, e.g. "SOC 2 Type II", "ISO/IEC 27001". |
| `claims[].status` | enum | claimed = the page says the company holds / complies with it; in_progress = "working towards", "in progress"; mentioned = named without a claim (e.g. "we help customers comply with GDPR"). |
| `claims[].statedOn` | string | URL of the page that states it. |
| `claims[].quote` | string | The words on the page (at most 200 characters). |
| `claims[].source` | enum |  |
| `securityTxt` | object \| null | RFC 9116 security.txt, when published. |
| `securityTxt.url` | string |  |
| `securityTxt.contact` | string[] |  |
| `securityTxt.expires` | string \| null |  |
| `securityTxt.expired` | boolean \| null | Whether Expires is in the past (null when it has none). |
| `securityTxt.encryption` | string[] |  |
| `securityTxt.policy` | string[] |  |
| `securityTxt.acknowledgments` | string[] |  |
| `securityTxt.hiring` | string[] |  |
| `securityTxt.canonical` | string[] |  |
| `securityTxt.csaf` | string[] |  |
| `securityTxt.preferredLanguages` | string[] |  |
| `securityTxt.bugBounty` | boolean \| null | The Bug-Bounty field (IANA registry), when present. |
| `securityTxt.signed` | boolean | The file is an OpenPGP cleartext-signed message. |
| `vulnerabilityDisclosure` | object[] | Bug-bounty programmes and vulnerability-disclosure policies linked from the site or security.txt. |
| `vulnerabilityDisclosure[].url` | string |  |
| `vulnerabilityDisclosure[].kind` | enum |  |
| `vulnerabilityDisclosure[].platform` | string \| null | hackerone, bugcrowd, intigriti or yeswehack when hosted there. |
| `dmarc` | object \| null |  |
| `dmarc.record` | string |  |
| `dmarc.policy` | enum \| null |  |
| `dmarc.subdomainPolicy` | enum \| null |  |
| `dmarc.pct` | integer \| null |  |
| `hsts` | object \| null | Strict-Transport-Security sent by the home page over HTTPS. |
| `hsts.header` | string |  |
| `hsts.maxAge` | integer \| null |  |
| `hsts.includeSubDomains` | boolean |  |
| `hsts.preload` | boolean |  |
| `httpsHomepage` | boolean | The home page answered over HTTPS. |
| `pagesChecked` | string[] | Pages that were read for claims (sorted). |

When the thing you asked about does not exist (or a search matches nothing) the call still succeeds: `output.found` is `false`, `output.data` is `null` and `output.reason` says why (`not_found`, `private`, `no_results`, …). Misses are free unless the notes below say misses are billed.

## Example request

```bash
curl -sS -X POST "https://api.primaryapi.com/v1/run/company.trust_profile" \
  -H "Authorization: Bearer $PRIMARYAPI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"domain":"vercel.com"}'
```

## Example response

_Values are placeholders that follow the output schema; `credits` is what this call would cost at the usual price._

```json
{
  "output": {
    "found": true,
    "data": {
      "domain": "example.com",
      "trustCenter": {
        "url": "https://trust.example.com/",
        "platform": "safebase"
      },
      "claims": [
        {
          "framework": "iso27001",
          "label": "ISO/IEC 27001",
          "status": "claimed",
          "statedOn": "https://trust.example.com/",
          "quote": "ISO/IEC 27001",
          "source": "trust_center_data"
        },
        {
          "framework": "soc2",
          "label": "SOC 2 Type II",
          "status": "claimed",
          "statedOn": "https://trust.example.com/",
          "quote": "completed a SOC 2 Type 2 attestation for Security, Confidentiality, and Availability",
          "source": "trust_center_data"
        }
      ],
      "securityTxt": {
        "url": "https://example.com/.well-known/security.txt",
        "contact": [
          "mailto:security@example.com"
        ],
        "expires": "2027-06-30T00:00:00Z",
        "expired": false,
        "encryption": [],
        "policy": [
          "https://example.com/security/disclosure"
        ],
        "acknowledgments": [],
        "hiring": [],
        "canonical": [
          "https://example.com/.well-known/security.txt"
        ],
        "csaf": [],
        "preferredLanguages": [
          "en"
        ],
        "bugBounty": null,
        "signed": false
      },
      "vulnerabilityDisclosure": [
        {
          "url": "https://example.com/security/disclosure",
          "kind": "disclosure_policy",
          "platform": null
        }
      ],
      "dmarc": {
        "record": "v=DMARC1; p=reject; pct=100",
        "policy": "reject",
        "subdomainPolicy": null,
        "pct": 100
      },
      "hsts": {
        "header": "max-age=63072000; includeSubDomains; preload",
        "maxAge": 63072000,
        "includeSubDomains": true,
        "preload": true
      },
      "httpsHomepage": true,
      "pagesChecked": [
        "https://example.com/",
        "https://trust.example.com/"
      ]
    }
  },
  "provider": "PrimaryAPI",
  "credits": 1,
  "items": 1,
  "requestId": "req_01JBXK6Y2N9V8T4R3Q2P1M0A7Z"
}
```

## Pricing and reliability

- Usual price: 1 credit per call
- Price ceiling: the usual price, even when a call is retried. A quote’s `maxCredits` is the most a given call can cost; the `maxCredits` routing control caps it per call
- Live 30-day status, success rate, uptime and latency: `GET https://api.primaryapi.com/v1/status/apis?sku=company.trust_profile`

## Errors to handle

`invalid_input`, `unauthorized`, `insufficient_balance`, `key_limit_reached`, `trial_cap_reached`, `forbidden`, `not_found`, `idempotency_conflict`, `rate_limited`, `all_sources_failed`, `service_unavailable`, `timeout`. See https://primaryapi.com/docs/errors.

## Notes

Claims are reported exactly as the pages state them, never inferred: a framework the pages do not name is simply absent, and an absent claim does not mean the company lacks it (many publish reports only on request). Trust centers that render only in a browser are reported without claims. A domain that does not resolve is a free miss (reason domain_not_found). Pages are read the way a polite crawler would: robots.txt is honoured (a disallowed page is a free miss with reason robots_disallowed), requests are paced per site, and only facts, short quotes and source links are returned. Outputs are stable between runs of an unchanged page (sorted lists, normalised whitespace, no timestamps), so the API can be scheduled as a monitor that fires only when the content changes.

