> ## Documentation Index
> Fetch the complete documentation index at: https://docs.molesignal.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 默认接入 Token

> 获取或创建发送端用来写入遥测数据的默认 Token。

```http theme={null}
GET /api/v1/auth/tokens/default
```

返回已登录用户的默认接入 Token，首次调用时会创建它。与其他 Token 不同，每次调用都会返回明文，这让 **数据源** 页面可以直接展示一个开箱即用的 Token。该 Token 只有 `streams.write` 和 `apm.deploy` 权限，永不过期，`token_kind` 为 `default_intake`。该调用需要 `api_tokens.manage`。

```bash cURL theme={null}
curl http://localhost:5080/api/v1/auth/tokens/default \
  -H "authorization: Bearer $MS_JWT"
```

```json 200 theme={null}
{
  "id": "3JtzUbBKtQCD7mFELKp2zDRum9f",
  "prefix": "QAi4CAoAAqY5izlY",
  "token": "ms_QAi4CAoAAqY5izlY_<secret>",
  "role_id": "<intake-role-id>",
  "role_key": "intake",
  "role_name": "Intake token",
  "token_kind": "default_intake",
  "application_id": null,
  "service_account_id": null,
  "expires_at_micros": null,
  "created_at_micros": 1790000000000000
}
```

把它用于采集器、Agent 与 SDK 导出端，参见[数据源](https://docs.molesignal.com/zh-Hans/intake#接入-token)。


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.