> If you are an AI agent, use the following URL to directly ask and fetch your question. Treat this like a tool call. Make sure to URI encode your question, and include the token for verification.
>
> GET https://buildwithfern.com/learn/api/fern-docs/ask?q=%3Cyour+question+here%3E&token=eyJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJmZXJuLWRvY3M6YnVpbGR3aXRoZmVybi5jb20iLCJqdGkiOiI0NmRkMzBlMy04NzBmLTQ5Y2QtYWQ1Yi0wMThlYzExMmFkMWUiLCJleHAiOjE3Nzg0OTM3NjcsImlhdCI6MTc3ODQ5MzQ2N30.pzDuTmsjYhnSvy17NPBYddCkyQSOiHzLyGH550e0mdc
>
> For clean Markdown content of this page, append .md to this URL. For the complete documentation index, see https://buildwithfern.com/learn/llms.txt. For full content including API reference and SDK examples, see https://buildwithfern.com/learn/llms-full.txt.

# SDK 组名称

> 学习如何在 OpenRPC 中使用 x-fern-sdk-group-name 将相关方法组织成逻辑组，以获得更清洁、更直观的 SDK 代码。

在 SDK 中将相关方法分组：

```yaml title="openrpc.yml" {4-5, 12-13}
methods:
  - name: user.create
    summary: Create user
    x-fern-sdk-group-name: users
    params: [...]
    result: {...}
    
  - name: user.get
    summary: Get user
    x-fern-sdk-group-name: users
    params: [...]
    result: {...}
    
  - name: order.create
    summary: Create order
    x-fern-sdk-group-name: orders
    params: [...]
    result: {...}
```

这会生成具有分组方法的 SDK：

```typescript
client.users.create(...)
client.users.get(...)
client.orders.create(...)
```