# get_affiliate_partner_quality

Returns definitionVersion, scope, cohort, generatedAt, sourceAsOf, coverage, summaries, items and cursor metadata.

## Purpose

Compare accepted affiliate installation cohorts for authorized apps. Returns covered 30-day collection conversion, observed install retention at 30/90 days, exact collections and accrued referral commission per currency. Installation dates are UTC inclusive/exclusive; defaults last 90 days, limit 25. Unknown/stale coverage and immature cohorts are disclosed. Observational, read-only; no activation, causal attribution, profit, FX or payouts. Keep applied dates for cursor paging.

## Credentials and scope

Owner workspace credential, or an app-scoped affiliate credential with `programs:read`, `referrals:read`, `commissions:read`. The credential determines tool visibility. Owners may use `list_apps` to obtain their HeyCrust app UUID. App-scoped callers cannot call `list_apps`; omit `appId` to use the app bound to the authenticated key, or supply that known authorized UUID. An explicit foreign app is denied. The dashboard selector does not supply MCP arguments for you.

## Inputs

- `appId`: optional; string or null
- `programId`: optional; string; format: uuid
- `membershipId`: optional; string; format: uuid
- `installedFrom`: optional; string; format: date-time
- `installedTo`: optional; string; format: date-time
- `currency`: optional; string
- `limit`: optional; integer; minimum: 1; maximum: 100
- `cursor`: optional; string; maxLength: 1500

## Example request

The identifiers and merchant are fictional. Replace them with records returned for your own workspace; this example is schema-checked, not a promise that the fictional record exists.

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "get_affiliate_partner_quality",
    "arguments": {
      "appId": "11111111-1111-4111-8111-111111111111",
      "installedFrom": "2026-07-01T00:00:00Z",
      "installedTo": "2026-10-07T00:00:00Z",
      "currency": "USD",
      "limit": 25
    }
  }
}
```

POST this JSON to `https://heycrust.com/api/mcp` with `Content-Type: application/json` and `Authorization: Bearer <YOUR_CREDENTIAL>`. The tool result normally contains JSON encoded as text in `result.content`; inspect JSON-RPC errors and `result.isError` before using it.

## Result

Returns definitionVersion, scope, cohort, generatedAt, sourceAsOf, coverage, summaries, items and cursor metadata. Figures are observational; installation retention is not product activation. Exact currency groups are separate, and missing/stale/immature data remains disclosed.

## Effects and verification

Reads existing records or definitions. It does not create a payment or send a message. Verify the returned app/merchant identity and source coverage before interpreting the result.

## Troubleshooting

A missing tool can mean that the credential lacks its catalog or required scopes. Invalid arguments are different from unavailable source data or a record outside the workspace. A handler can return a business error even when the argument schema is valid. Read [MCP overview](/docs/mcp) and [Help](/docs/help).

## App-scoped example

With the three required read scopes, no owner-only setup call is needed. The key bounds this request to its own app:

```json
{
  "installedFrom": "2026-07-01T00:00:00Z",
  "installedTo": "2026-10-01T00:00:00Z",
  "limit": 25
}
```

Use these arguments for `get_affiliate_partner_quality` after client discovery. To inspect program/app context through REST, use [GET programs](/docs/api/get-programs) with the same scoped credential.
