# List me

URL: https://docs.hanzo.ai/docs/openapi/affiliate/get-affiliate-me

> Answers the richer self-view: the same lifetime accrued, pending and paid commission and payout history, plus the caller's downline broken out by upline LEVEL — direct, second, third — each with the rate paid at that level and how many orgs sit there.

`GET /v1/affiliate/me`

> [Affiliate →](https://docs.hanzo.ai/docs/openapi/affiliate) · [All API references →](https://docs.hanzo.ai/docs/openapi) · [Get started →](https://docs.hanzo.ai/docs/guides)

|               |                                        |
| ------------- | -------------------------------------- |
| **Address**   | `https://api.hanzo.ai/v1/affiliate/me` |
| **Method**    | `GET`                                  |
| **Operation** | `get_affiliate_me`                     |
| **Auth**      | `Authorization: Bearer $HANZO_API_KEY` |

Answers the richer self-view: the same lifetime accrued, pending and paid
commission and payout history, plus the caller's downline broken out by upline
LEVEL — direct, second, third — each with the rate paid at that level and how
many orgs sit there.

Commission is MULTI-LEVEL: a referred org's spend pays up its referral chain,
three levels deep and no further. The direct level is the affiliate's own
negotiated rate; the second and third are platform-wide switches, read live,
so the schedule shown is the one actually in force rather than one compiled
in. A caller that has not applied still gets that schedule alongside
`isAffiliate:false`, so the console can show what it would earn.

Scoped to the validated org and nothing else, and refused without a
principal. A PURE READ — it reports the downline but accrues nothing.

## Request

`GET /v1/affiliate/me` takes no parameters and no body — the credential is the whole request.

## Response

| Status    | Body                    | Meaning |
| --------- | ----------------------- | ------- |
| `200`     | affiliate.affiliateSelf | ok      |
| `default` | problem-details         | refused |

`200` body — 28 fields.

| Field                      | In   | Type                    | Always | Description                                                                                                                           |
| -------------------------- | ---- | ----------------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------- |
| `accruedCents`             | body | integer (int64)         | —      | AccruedCents is lifetime commission accrued, in cents.                                                                                |
| `code`                     | body | string                  | —      | Code is the minted referral code, the slug the ?aff link carries.                                                                     |
| `defaultRateBps`           | body | integer (int64)         | —      | DefaultRateBps is the direct rate a new affiliate starts at, in basis points of margin (2000 = 20%).                                  |
| `downlineTotal`            | body | integer (int64)         | —      | DownlineTotal counts every org in the caller's downline across the levels.                                                            |
| `handle`                   | body | string                  | —      | Handle is the opt-in public leaderboard name.                                                                                         |
| `id`                       | body | string                  | —      | ID is the affiliate's server-minted handle, "aff\_"-prefixed.                                                                         |
| `isAffiliate`              | body | boolean                 | —      | IsAffiliate says whether the caller org has an affiliate record.                                                                      |
| `levels`                   | body | affiliate.levelView\[]  | —      | Levels is the caller's downline per upline level, with the rate paid there.                                                           |
| `levels[].downlineCount`   | body | integer (int64)         | —      | DownlineCount is how many orgs sit exactly this many hops below the caller.                                                           |
| `levels[].level`           | body | integer (int64)         | —      | Level is the upline distance from the org whose spend is being shared: 1 is the direct referrer, 2 and 3 the referrers above it.      |
| `levels[].rateBps`         | body | integer (int64)         | —      | RateBps is the commission paid at this level, in basis points OF Hanzo's margin (2000 = 20% of margin, never of the customer's bill). |
| `link`                     | body | string                  | —      | Link is the shareable ?aff URL built from the code.                                                                                   |
| `marginBps`                | body | integer (int64)         | —      | MarginBps is the platform gross-margin fraction, in basis points, that every rate here is a rate OF.                                  |
| `paidCents`                | body | integer (int64)         | —      | PaidCents is lifetime commission already paid out, in cents — credits grants and record-only cash disbursements alike.                |
| `payouts`                  | body | affiliate.remittance\[] | —      | Payouts is the payout history, newest first, bounded to the last 100 rows.                                                            |
| `payouts[].amountCents`    | body | integer (int64)         | —      | AmountCents is the amount disbursed, in cents.                                                                                        |
| `payouts[].createdAt`      | body | integer (int64)         | —      | CreatedAt is when the payout was recorded, Unix seconds UTC — when the balance moved, not necessarily when the cash landed.           |
| `payouts[].id`             | body | string                  | —      | ID is the payout row's server-minted handle, "apo\_"-prefixed.                                                                        |
| `payouts[].method`         | body | string                  | —      | Method is how it was settled.                                                                                                         |
| `payouts[].reference`      | body | string                  | —      | Reference is the operator's settlement note — a bank id, a ledger ref.                                                                |
| `payouts[].txn`            | body | string                  | —      | Txn is the commerce ledger transaction id, set ONLY where a "credits" payout actually issued the grant.                               |
| `pendingCents`             | body | integer (int64)         | —      | PendingCents is accrued minus paid, in cents — what the platform still owes and the ceiling on the next payout.                       |
| `rateBps`                  | body | integer (int64)         | —      | RateBps is the caller's OWN direct (level 1) commission rate, in basis points of margin.                                              |
| `schedule`                 | body | affiliate.levelView\[]  | —      | Schedule is the rate schedule quoted to a caller that has not applied.                                                                |
| `schedule[].downlineCount` | body | integer (int64)         | —      | DownlineCount is how many orgs sit exactly this many hops below the caller.                                                           |
| `schedule[].level`         | body | integer (int64)         | —      | Level is the upline distance from the org whose spend is being shared: 1 is the direct referrer, 2 and 3 the referrers above it.      |
| `schedule[].rateBps`       | body | integer (int64)         | —      | RateBps is the commission paid at this level, in basis points OF Hanzo's margin (2000 = 20% of margin, never of the customer's bill). |
| `status`                   | body | string                  | —      | Status is "applied", "approved" or "suspended"; absent for a caller that never applied.                                               |

Failure carries the platform error shape — see [Errors](https://docs.hanzo.ai/docs/errors).

## Examples

**CLI**

```bash
hanzo affiliate me get
```

**SDK**

**.ts**

```ts
import { Configuration, AffiliateApi } from 'hanzoai';

const api = new AffiliateApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.getAffiliateMe();
```

**.py**

```python
from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import AffiliateApi

client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = AffiliateApi(client).get_affiliate_me()
```

**.go**

```go
cfg := hanzoai.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := hanzoai.NewAPIClient(cfg)

resp, _, err := client.AffiliateAPI.GetAffiliateMe(context.Background()).Execute()
if err != nil {
	return err
}
```

**.rs**

```rust
use hanzo_client::apis::{configuration::Configuration, affiliate_api};

let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();

let result = affiliate_api::get_affiliate_me(&cfg, Default::default()).await?;
```

**.java**

```java
import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.AffiliateApi;

ApiClient client = new ApiClient();
client.setBearerToken(System.getenv("HANZO_API_KEY"));

var result = new AffiliateApi(client).getAffiliateMe();
```

**HTTP**

```bash
curl https://api.hanzo.ai/v1/affiliate/me \
  -H "Authorization: Bearer $HANZO_API_KEY"
```

**MCP**

Tool `affiliate`, op `get_affiliate_me` — POST the JSON-RPC envelope to `https://api.hanzo.ai/v1/mcp`.

```bash
curl -X POST https://api.hanzo.ai/v1/mcp \
  -H "Authorization: Bearer $HANZO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
       "jsonrpc": "2.0",
       "id": 1,
       "method": "tools/call",
       "params": {
         "name": "affiliate",
         "arguments": {
           "op": "get_affiliate_me",
           "input": {}
         }
       }
     }'
```

---

[Affiliate API](https://docs.hanzo.ai/docs/openapi/affiliate) · [All Hanzo APIs](https://docs.hanzo.ai/docs/openapi) · [Interactive reference](https://docs.hanzo.ai/docs/openapi/reference)
