# 用主题组件还是插件进行外部API调用更合适？

**URL:** https://meta.discourse.org/t/is-a-theme-component-or-plugin-best-for-external-api-calls/364145
**Category:** Development
**Created:** [2025年四月30日 12:38 UTC](https://meta.discourse.org/t/is-a-theme-component-or-plugin-best-for-external-api-calls/364145 "2025-04-30T12:38:28Z")
**Posts on this page:** 1
**Showing post:** 4

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [2025年四月30日 12:53 UTC](https://meta.discourse.org/t/is-a-theme-component-or-plugin-best-for-external-api-calls/364145/4 "2025-04-30T12:53:27Z")

</div>

您或许可以利用 API 中公开的用户字段来解决。

如果不行，您就需要一个插件。

但您需要弄清楚谁可以看到什么。

例如，这是否是用户保密信息，或者其他人可以查看等。

请参阅：

> [@Private custom user fields...?](https://meta.discourse.org/t/private-custom-user-fields/232136?u=merefield):
>
> [The FAQ](https://meta.discourse.org/t/how-to-create-and-configure-custom-user-fields/113192) isn’t crystal clear about this, so I want to get confirmation. If I have a custom user field that is neither: Show[n] on public profile Show[n] on user card Then it’s effectively private, visible only to the user, admins & moderators?

---

_[View the full topic](https://meta.discourse.org/t/is-a-theme-component-or-plugin-best-for-external-api-calls/364145)._
