
語言 🇹🇼 繁體中文
快速上手
用法
彙總
稽核日誌
從評論封鎖
檢查被封鎖的評論
評論
網域設定
電子郵件範本
事件日誌
動態貼文
檢舉評論
標籤
版主
通知數量
通知
頁面
待處理的 Webhook 事件
問題設定
問題結果
問題結果彙總
單一登入使用者
訂閱
租戶每日使用量
租戶方案
租戶使用者
租戶
上傳圖片
使用者徽章進度
使用者徽章
使用者通知
使用者在線狀態
使用者搜尋
使用者
投票
FastComments Go SDK
這是 FastComments 的官方 Go SDK。
FastComments API 的官方 Go SDK
儲存庫
安裝 
go get github.com/fastcomments/fastcomments-go
使用 API 用戶端
公共 API (無需驗證)
PublicAPI 允許未經驗證地存取公開端點:
package main
import (
"context"
"fmt"
"github.com/fastcomments/fastcomments-go/client"
)
func main() {
config := client.NewConfiguration()
apiClient := client.NewAPIClient(config)
// 使用 PublicAPI 取得評論
response, httpResp, err := apiClient.PublicAPI.GetCommentsPublic(
context.Background(),
"your-tenant-id",
).UrlId("your-page-url-id").Execute()
if err != nil {
panic(err)
}
fmt.Printf("Status: %d\n", httpResp.StatusCode)
fmt.Printf("Comments: %+v\n", response)
}
Default API (需要 API 金鑰)
DefaultAPI 需要使用您的 API 金鑰進行驗證:
package main
import (
"context"
"fmt"
"github.com/fastcomments/fastcomments-go/client"
)
func main() {
config := client.NewConfiguration()
apiClient := client.NewAPIClient(config)
// 建立帶有 API 金鑰的已驗證 context
auth := context.WithValue(
context.Background(),
client.ContextAPIKeys,
map[string]client.APIKey{
"api_key": {Key: "your-api-key-here"},
},
)
// 使用已驗證的 DefaultAPI 取得評論
response, httpResp, err := apiClient.DefaultAPI.GetComments(auth).
TenantId("your-tenant-id").
UrlId("your-page-url-id").
Execute()
if err != nil {
panic(err)
}
fmt.Printf("Status: %d\n", httpResp.StatusCode)
fmt.Printf("Comments: %+v\n", response)
}
用法 
簡單 SSO
package main
import (
"context"
"fmt"
"github.com/fastcomments/fastcomments-go/client"
"github.com/fastcomments/fastcomments-go/sso"
)
func main() {
// 建立簡單 SSO 令牌
user := &sso.SimpleSSOUserData{
UserID: "user-123",
Email: "user@example.com",
Avatar: "https://example.com/avatar.jpg",
}
ssoInstance := sso.NewSimple(user)
token, err := ssoInstance.CreateToken()
if err != nil {
panic(err)
}
fmt.Println("SSO Token:", token)
// 使用 SSO 令牌進行經過驗證的 API 呼叫
config := client.NewConfiguration()
apiClient := client.NewAPIClient(config)
response, httpResp, err := apiClient.PublicAPI.GetCommentsPublic(
context.Background(),
"your-tenant-id",
).UrlId("your-page-url-id").Sso(token).Execute()
if err != nil {
panic(err)
}
fmt.Printf("Status: %d\n", httpResp.StatusCode)
fmt.Printf("Comments: %+v\n", response)
}
安全 SSO
package main
import (
"context"
"fmt"
"github.com/fastcomments/fastcomments-go/client"
"github.com/fastcomments/fastcomments-go/sso"
)
func main() {
// 建立安全 SSO 令牌
user := &sso.SecureSSOUserData{
UserID: "user-123",
Email: "user@example.com",
Username: "johndoe",
Avatar: "https://example.com/avatar.jpg",
}
apiKey := "your-api-key"
ssoInstance, err := sso.NewSecure(apiKey, user)
if err != nil {
panic(err)
}
token, err := ssoInstance.CreateToken()
if err != nil {
panic(err)
}
fmt.Println("Secure SSO Token:", token)
// 使用 SSO 令牌進行經過驗證的 API 呼叫
config := client.NewConfiguration()
apiClient := client.NewAPIClient(config)
response, httpResp, err := apiClient.PublicAPI.GetCommentsPublic(
context.Background(),
"your-tenant-id",
).UrlId("your-page-url-id").Sso(token).Execute()
if err != nil {
panic(err)
}
fmt.Printf("Status: %d\n", httpResp.StatusCode)
fmt.Printf("Comments: %+v\n", response)
}
彙總 
透過將文件分組(如果提供了 groupBy)並套用多個操作來彙總文件。 支援不同的操作(例如 sum、countDistinct、avg 等)。
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| parentTenantId | string | query | 否 | |
| includeStats | boolean | query | 否 |
回應
範例

取得稽核日誌 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| limit | number | query | 否 | |
| skip | number | query | 否 | |
| order | string | query | 否 | |
| after | number | query | 否 | |
| before | number | query | 否 |
回應
範例

從評論封鎖(公開) 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| commentId | string | path | 是 | |
| sso | string | query | 否 |
回應
回傳: BlockFromCommentPublic200Response
範例

解除評論封鎖(公開) 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | 查詢 | 是 | |
| commentId | string | 路徑 | 是 | |
| sso | string | 查詢 | 否 |
回應
回傳: UnBlockCommentPublic200Response
範例

檢查被封鎖的評論 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| commentIds | string | query | 是 | 以逗號分隔的評論 ID 列表。 |
| sso | string | query | 否 |
回應
回傳: CheckedCommentsForBlocked200Response
範例

從評論封鎖使用者 
參數
| 名稱 | 型別 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| userId | string | query | 否 | |
| anonUserId | string | query | 否 |
回應
回傳: BlockFromCommentPublic200Response
範例

建立評論(公開) 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| urlId | string | query | 是 | |
| broadcastId | string | query | 是 | |
| sessionId | string | query | 否 | |
| sso | string | query | 否 |
回應
回傳: CreateCommentPublic200Response
範例

刪除評論 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| contextUserId | string | query | 否 | |
| isLive | boolean | query | 否 |
回應
Returns: DeleteComment200Response
範例

刪除評論(公開) 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| commentId | string | path | 是 | |
| broadcastId | string | query | 是 | |
| editKey | string | query | 否 | |
| sso | string | query | 否 |
回應
回傳: DeleteCommentPublic200Response
範例

刪除評論投票 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| commentId | string | path | 是 | |
| voteId | string | path | 是 | |
| urlId | string | query | 是 | |
| broadcastId | string | query | 是 | |
| editKey | string | query | 否 | |
| sso | string | query | 否 |
回應
回傳: DeleteCommentVote200Response
範例

檢舉評論 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| id | string | path | Yes | |
| userId | string | query | No | |
| anonUserId | string | query | No |
回應
範例

取得評論 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
範例

取得評論列表 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| page | integer | query | No | |
| limit | integer | query | No | |
| skip | integer | query | No | |
| asTree | boolean | query | No | |
| skipChildren | integer | query | No | |
| limitChildren | integer | query | No | |
| maxTreeDepth | integer | query | No | |
| urlId | string | query | No | |
| userId | string | query | No | |
| anonUserId | string | query | No | |
| contextUserId | string | query | No | |
| hashTag | string | query | No | |
| parentId | string | query | No | |
| direction | string | query | No |
回應
範例

取得公開評論 
req tenantId urlId
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| urlId | string | query | 是 | |
| page | integer | query | 否 | |
| direction | string | query | 否 | |
| sso | string | query | 否 | |
| skip | integer | query | 否 | |
| skipChildren | integer | query | 否 | |
| limit | integer | query | 否 | |
| limitChildren | integer | query | 否 | |
| countChildren | boolean | query | 否 | |
| fetchPageForCommentId | string | query | 否 | |
| includeConfig | boolean | query | 否 | |
| countAll | boolean | query | 否 | |
| includei10n | boolean | query | 否 | |
| locale | string | query | 否 | |
| modules | string | query | 否 | |
| isCrawler | boolean | query | 否 | |
| includeNotificationCount | boolean | query | 否 | |
| asTree | boolean | query | 否 | |
| maxTreeDepth | integer | query | 否 | |
| useFullTranslationIds | boolean | query | 否 | |
| parentId | string | query | 否 | |
| searchText | string | query | 否 | |
| hashTags | array | query | 否 | |
| userId | string | query | 否 | |
| customConfigStr | string | query | 否 | |
| afterCommentId | string | query | 否 | |
| beforeCommentId | string | query | 否 |
回應
回傳: GetCommentsPublic200Response
範例

取得評論文字 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| commentId | string | path | 是 | |
| editKey | string | query | 否 | |
| sso | string | query | 否 |
回應
範例

取得評論投票使用者名稱 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| commentId | string | path | 是 | |
| dir | integer | query | 是 | |
| sso | string | query | 否 |
回應
回傳:GetCommentVoteUserNames200Response
範例

鎖定評論 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | 路徑 | 是 | |
| commentId | string | 路徑 | 是 | |
| broadcastId | string | 查詢 | 是 | |
| sso | string | 查詢 | 否 |
回應
範例

置頂評論 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| commentId | string | path | 是 | |
| broadcastId | string | query | 是 | |
| sso | string | query | 否 |
回應
範例

儲存評論 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| isLive | boolean | query | 否 | |
| doSpamCheck | boolean | query | 否 | |
| sendEmails | boolean | query | 否 | |
| populateNotifications | boolean | query | 否 |
回應
範例

批次儲存評論 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| isLive | boolean | query | 否 | |
| doSpamCheck | boolean | query | 否 | |
| sendEmails | boolean | query | 否 | |
| populateNotifications | boolean | query | 否 |
回應
回傳: []SaveComment200Response
範例

設定評論文字 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | path | Yes | |
| commentId | string | path | Yes | |
| broadcastId | string | query | Yes | |
| editKey | string | query | No | |
| sso | string | query | No |
回應
範例

解除從評論封鎖使用者 
參數
| 名稱 | 型別 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| userId | string | query | 否 | |
| anonUserId | string | query | 否 |
回應
回傳: UnBlockCommentPublic200Response
範例

取消檢舉評論 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| userId | string | query | 否 | |
| anonUserId | string | query | 否 |
回應
範例

解除鎖定評論 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | path | Yes | |
| commentId | string | path | Yes | |
| broadcastId | string | query | Yes | |
| sso | string | query | No |
回應
範例

取消置頂評論 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | 路徑 | 是 | |
| commentId | string | 路徑 | 是 | |
| broadcastId | string | 查詢 | 是 | |
| sso | string | 查詢 | 否 |
回傳
範例

更新評論 
參數
| 名稱 | 型別 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| contextUserId | string | query | 否 | |
| doSpamCheck | boolean | query | 否 | |
| isLive | boolean | query | 否 |
回應
回傳: FlagCommentPublic200Response
範例

對評論投票 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| commentId | string | path | 是 | |
| urlId | string | query | 是 | |
| broadcastId | string | query | 是 | |
| sessionId | string | query | 否 | |
| sso | string | query | 否 |
回應
範例

新增網域設定 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 |
回應
範例

刪除網域設定 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| domain | string | path | 是 |
回應
回傳: DeleteDomainConfig200Response
範例

取得網域設定 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| domain | string | path | 是 |
回應
回傳: GetDomainConfig200Response
範例

取得網域設定清單 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 |
回應
回傳: GetDomainConfigs200Response
範例

部分更新網域設定 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | 查詢 | 是 | |
| domainToUpdate | string | 路徑 | 是 |
回應
回傳: GetDomainConfig200Response
範例

覆寫網域設定 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| domainToUpdate | string | path | 是 |
回應
回傳: GetDomainConfig200Response
範例

建立電子郵件範本 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 |
回應
回傳: CreateEmailTemplate200Response
範例

刪除電子郵件範本 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

刪除電子郵件範本渲染錯誤 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| id | string | path | Yes | |
| errorId | string | path | Yes |
回應
回傳: FlagCommentPublic200Response
範例

取得電子郵件範本 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| id | string | path | Yes |
回應
回傳: GetEmailTemplate200Response
範例

取得電子郵件範本定義 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 |
回應
回傳: GetEmailTemplateDefinitions200Response
範例

取得電子郵件範本渲染錯誤 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| skip | number | query | 否 |
回應
回傳: GetEmailTemplateRenderErrors200Response
範例

取得電子郵件範本列表 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| skip | number | query | 否 |
回傳
Returns: GetEmailTemplates200Response
範例

渲染電子郵件範本 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| locale | string | query | 否 |
回應
回傳: RenderEmailTemplate200Response
範例

更新電子郵件範本 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

取得事件日誌 
req tenantId urlId userIdWS
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| urlId | string | query | 是 | |
| userIdWS | string | query | 是 | |
| startTime | integer | query | 是 | |
| endTime | integer | query | 是 |
回應
範例

取得全域事件日誌 
req tenantId urlId userIdWS
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| urlId | string | query | 是 | |
| userIdWS | string | query | 是 | |
| startTime | integer | query | 是 | |
| endTime | integer | query | 是 |
回應
範例

建立動態貼文 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| broadcastId | string | query | 否 | |
| isLive | boolean | query | 否 | |
| doSpamCheck | boolean | query | 否 | |
| skipDupCheck | boolean | query | 否 |
回應
範例

建立動態貼文(公開) 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | path | Yes | |
| broadcastId | string | query | No | |
| sso | string | query | No |
回應
回傳: CreateFeedPostPublic200Response
範例

刪除動態貼文(公開) 
參數
| 名稱 | 類型 | 位置 | 是否必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| postId | string | path | 是 | |
| broadcastId | string | query | 否 | |
| sso | string | query | 否 |
回應
回傳: DeleteFeedPostPublic200Response
範例

取得動態貼文 
請求 tenantId afterId
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| afterId | string | query | 否 | |
| limit | integer | query | 否 | |
| tags | array | query | 否 |
回應
範例

取得公開動態貼文 
req tenantId afterId
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| afterId | string | query | 否 | |
| limit | integer | query | 否 | |
| tags | array | query | 否 | |
| sso | string | query | 否 | |
| isCrawler | boolean | query | 否 | |
| includeUserInfo | boolean | query | 否 |
回應
回傳: GetFeedPostsPublic200Response
範例

取得動態貼文統計 
參數
| 名稱 | Type | Location | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| postIds | array | query | 是 | |
| sso | string | query | 否 |
回應
回傳: GetFeedPostsStats200Response
範例

取得使用者反應(公開) 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| postIds | array | query | 否 | |
| sso | string | query | 否 |
回應
回傳:GetUserReactsPublic200Response
範例

對動態貼文反應(公開) 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| postId | string | path | 是 | |
| isUndo | boolean | query | 否 | |
| broadcastId | string | query | 否 | |
| sso | string | query | 否 |
回應
返回: ReactFeedPostPublic200Response
範例

更新動態貼文 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

更新動態貼文(公開) 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | path | Yes | |
| postId | string | path | Yes | |
| broadcastId | string | query | No | |
| sso | string | query | No |
回應
回傳: CreateFeedPostPublic200Response
範例

公開檢舉評論 
參數
| 名稱 | 型別 | 位置 | 必要 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| commentId | string | path | 是 | |
| isFlagged | boolean | query | 是 | |
| sso | string | query | 否 |
回應
回傳: FlagCommentPublic200Response
範例

新增標籤 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 否 |
回傳
範例

批次新增標籤 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | No |
回傳
Returns: AddHashTagsBulk200Response
範例

刪除標籤 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tag | string | path | 是 | |
| tenantId | string | query | 否 |
回應
回傳: FlagCommentPublic200Response
範例

取得標籤 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| page | number | query | 否 |
回傳
範例

部分更新標籤 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tag | string | 路徑 | 是 | |
| tenantId | string | 查詢 | 否 |
回應
範例

建立版主 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | Yes |
回應
回傳: CreateModerator200Response
範例

刪除版主 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | 查詢 | 是 | |
| id | string | 路徑 | 是 | |
| sendEmail | string | 查詢 | 否 |
回應
回傳: FlagCommentPublic200Response
範例

取得版主 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
範例

取得版主列表 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| skip | number | query | No |
回應
範例

發送邀請 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| fromName | string | query | 是 |
回應
回傳: FlagCommentPublic200Response
範例

更新版主 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

刪除通知數量 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

取得快取的通知數量 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回傳
回傳: GetCachedNotificationCount200Response
範例

取得通知數量 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| userId | string | query | 否 | |
| urlId | string | query | 否 | |
| fromCommentId | string | query | 否 | |
| viewed | boolean | query | 否 | |
| type | string | query | 否 |
回應
回傳: GetNotificationCount200Response
範例

取得通知 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| userId | string | query | 否 | |
| urlId | string | query | 否 | |
| fromCommentId | string | query | 否 | |
| viewed | boolean | query | 否 | |
| type | string | query | 否 | |
| skip | number | query | 否 |
回應
回傳: GetNotifications200Response
範例

更新通知 
參數
| 名稱 | 型別 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| userId | string | query | 否 |
回應
回傳: FlagCommentPublic200Response
範例

新增頁面 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | Yes |
回應
範例

刪除頁面 
參數
| 名稱 | Type | Location | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
範例

以 URL ID 取得頁面 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| urlId | string | query | 是 |
回應
範例

取得頁面列表 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 |
回應
範例

部分更新頁面 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
範例

刪除待處理的 Webhook 事件 
參數
| 名稱 | 型別 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

取得待處理的 Webhook 事件數量 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| commentId | string | query | 否 | |
| externalId | string | query | 否 | |
| eventType | string | query | 否 | |
| type | string | query | 否 | |
| domain | string | query | 否 | |
| attemptCountGT | number | query | 否 |
回應
回傳: GetPendingWebhookEventCount200Response
範例

取得待處理的 Webhook 事件 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| commentId | string | query | 否 | |
| externalId | string | query | 否 | |
| eventType | string | query | 否 | |
| type | string | query | 否 | |
| domain | string | query | 否 | |
| attemptCountGT | number | query | 否 | |
| skip | number | query | 否 |
回應
回傳: GetPendingWebhookEvents200Response
範例

建立問題設定 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 |
回應
回傳: CreateQuestionConfig200Response
範例

刪除問題設定 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | 查詢 | 是 | |
| id | string | 路徑 | 是 |
回應
回傳: FlagCommentPublic200Response
範例

取得問題設定 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| id | string | path | Yes |
回應
回傳: GetQuestionConfig200Response
範例

取得問題設定列表 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| skip | number | query | 否 |
回應
回傳: GetQuestionConfigs200Response
範例

更新問題設定 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

建立問題結果 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | Yes |
回應
回傳: CreateQuestionResult200Response
範例

刪除問題結果 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| id | string | path | Yes |
回應
回傳: FlagCommentPublic200Response
範例

取得問題結果 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| id | string | path | Yes |
回應
回傳: GetQuestionResult200Response
範例

取得問題結果列表 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| urlId | string | query | 否 | |
| userId | string | query | 否 | |
| startDate | string | query | 否 | |
| questionId | string | query | 否 | |
| questionIds | string | query | 否 | |
| skip | number | query | 否 |
回應
回傳: GetQuestionResults200Response
範例

更新問題結果 
參數
| 名稱 | 型別 | 位置 | 必須 | 描述 |
|---|---|---|---|---|
| tenantId | string | 查詢 | 是 | |
| id | string | 路徑 | 是 |
回應
回傳: FlagCommentPublic200Response
範例

彙總問題結果 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| questionId | string | query | 否 | |
| questionIds | array | query | 否 | |
| urlId | string | query | 否 | |
| timeBucket | string | query | 否 | |
| startDate | string | query | 否 | |
| forceRecalculate | boolean | query | 否 |
回應
回傳: AggregateQuestionResults200Response
範例

批次彙總問題結果 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| forceRecalculate | boolean | query | 否 |
回應
回傳: BulkAggregateQuestionResults200Response
範例

將評論與問題結果結合 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| questionId | string | query | 否 | |
| questionIds | array | query | 否 | |
| urlId | string | query | 否 | |
| startDate | string | query | 否 | |
| forceRecalculate | boolean | query | 否 | |
| minValue | number | query | 否 | |
| maxValue | number | query | 否 | |
| limit | number | query | 否 |
回應
回傳: CombineCommentsWithQuestionResults200Response
範例

新增單一登入使用者 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 |
回應
範例

刪除單一登入使用者 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| deleteComments | boolean | query | 否 | |
| commentDeleteMode | string | query | 否 |
回應
範例

以電子郵件取得單一登入使用者 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| string | path | 是 |
回應
回傳: GetSSOUserByEmailAPIResponse
範例

以 ID 取得單一登入使用者 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
範例

取得單一登入使用者列表 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| skip | integer | query | 否 |
回應
範例

部分更新單一登入使用者 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| id | string | path | Yes | |
| updateComments | boolean | query | No |
回應
範例

建立或更新單一登入使用者 
參數
| 名稱 | 型別 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| id | string | path | Yes | |
| updateComments | boolean | query | No |
回應
範例

建立訂閱 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | 查詢 | 是 |
回應
回傳: CreateSubscriptionAPIResponse
範例

刪除訂閱 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| id | string | path | Yes | |
| userId | string | query | No |
回應
回傳: DeleteSubscriptionAPIResponse
範例

取得訂閱列表 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| userId | string | query | 否 |
回應
回傳: GetSubscriptionsAPIResponse
範例

取得租戶每日使用量 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| yearNumber | number | query | 否 | |
| monthNumber | number | query | 否 | |
| dayNumber | number | query | 否 | |
| skip | number | query | 否 |
回應
回傳: GetTenantDailyUsages200Response
範例

建立租戶方案 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 |
回應
回傳: CreateTenantPackage200Response
範例

刪除租戶方案 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

取得租戶方案 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: GetTenantPackage200Response
範例

取得租戶方案列表 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| skip | number | query | 否 |
回應
回傳: GetTenantPackages200Response
範例

取代租戶方案 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

更新租戶方案 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

建立租戶使用者 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | Yes |
回應
回傳: CreateTenantUser200Response
範例

刪除租戶使用者 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| deleteComments | string | query | 否 | |
| commentDeleteMode | string | query | 否 |
回應
回傳:FlagCommentPublic200Response
範例

取得租戶使用者 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
範例

取得租戶使用者列表 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| skip | number | query | 否 |
回應
範例

取代租戶使用者 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| id | string | path | Yes | |
| updateComments | string | query | No |
回應
回傳: FlagCommentPublic200Response
範例

發送登入連結 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| redirectURL | string | query | 否 |
回傳
Returns: FlagCommentPublic200Response
範例

更新租戶使用者 
參數
| 名稱 | 類型 | 位置 | 必要 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| updateComments | string | query | 否 |
回應
回傳:FlagCommentPublic200Response
範例

建立租戶 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 |
回應
範例

刪除租戶 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| sure | string | query | 否 |
回應
回傳: FlagCommentPublic200Response
範例

取得租戶 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | 查詢 | 是 | |
| id | string | 路徑 | 是 |
回應
範例

取得租戶列表 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| meta | string | query | 否 | |
| skip | number | query | 否 |
回應
範例

更新租戶 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: FlagCommentPublic200Response
範例

上傳圖片 
上傳並調整影像大小
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| sizePreset | string | query | 否 | 大小預設:"Default" (1000x1000px) 或 "CrossPlatform" (為熱門裝置建立尺寸) |
| urlId | string | query | 否 | 上傳發生的頁面 ID,用於設定 |
回應
範例

依 ID 取得使用者徽章進度 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: GetUserBadgeProgressById200Response
範例

依使用者 ID 取得徽章進度 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| userId | string | path | Yes |
回應
回傳: GetUserBadgeProgressById200Response
範例

取得使用者徽章進度列表 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| userId | string | query | No | |
| limit | number | query | No | |
| skip | number | query | No |
回應
回傳: GetUserBadgeProgressList200Response
範例

建立使用者徽章 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 |
回應
回傳: CreateUserBadge200Response
範例

刪除使用者徽章 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
回傳: UpdateUserBadge200Response
範例

取得使用者徽章 
參數
| 名稱 | 型別 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
範例

取得使用者徽章列表 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| userId | string | query | 否 | |
| badgeId | string | query | 否 | |
| type | number | query | 否 | |
| displayedOnComments | boolean | query | 否 | |
| limit | number | query | 否 | |
| skip | number | query | 否 |
回應
範例

更新使用者徽章 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回傳
回傳: UpdateUserBadge200Response
範例

取得使用者通知數量 
參數
| 名稱 | Type | Location | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| sso | string | query | 否 |
回應
回傳:GetUserNotificationCount200Response
範例

取得使用者通知 
參數
| 名稱 | Type | Location | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| pageSize | integer | query | 否 | |
| afterId | string | query | 否 | |
| includeContext | boolean | query | 否 | |
| afterCreatedAt | integer | query | 否 | |
| unreadOnly | boolean | query | 否 | |
| dmOnly | boolean | query | 否 | |
| noDm | boolean | query | 否 | |
| includeTranslations | boolean | query | 否 | |
| sso | string | query | 否 |
回應
回傳: GetUserNotifications200Response
範例

重設使用者通知數量 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| sso | string | query | 否 |
回應
回傳: ResetUserNotifications200Response
範例

重設使用者通知 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| afterId | string | query | 否 | |
| afterCreatedAt | integer | query | 否 | |
| unreadOnly | boolean | query | 否 | |
| dmOnly | boolean | query | 否 | |
| noDm | boolean | query | 否 | |
| sso | string | query | 否 |
回應
回傳: ResetUserNotifications200Response
範例

更新使用者評論通知訂閱狀態 
啟用或停用特定評論的通知。
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | 查詢 | 是 | |
| notificationId | string | 路徑 | 是 | |
| optedInOrOut | string | 路徑 | 是 | |
| commentId | string | 查詢 | 是 | |
| sso | string | 查詢 | 否 |
回應
回傳:UpdateUserNotificationStatus200Response
範例

更新使用者頁面通知訂閱狀態 
啟用或停用對頁面的通知。當使用者訂閱某個頁面時,系統會為新的根評論建立通知,並且還會
參數
| 名稱 | 類型 | 位置 | 是否必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| urlId | string | query | 是 | |
| url | string | query | 是 | |
| pageTitle | string | query | 是 | |
| subscribedOrUnsubscribed | string | path | 是 | |
| sso | string | query | 否 |
回應
回傳: UpdateUserNotificationStatus200Response
範例

更新使用者通知狀態 
參數
| 名稱 | 型別 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| notificationId | string | path | 是 | |
| newStatus | string | path | 是 | |
| sso | string | query | 否 |
回應
回傳: UpdateUserNotificationStatus200Response
範例

取得使用者在線狀態 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| urlIdWS | string | query | 是 | |
| userIds | string | query | 是 |
回應
回傳: GetUserPresenceStatuses200Response
範例

搜尋使用者 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | path | 是 | |
| urlId | string | query | 是 | |
| usernameStartsWith | string | query | 是 | |
| mentionGroupIds | array | query | 否 | |
| sso | string | query | 否 |
回應
範例

取得使用者 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 |
回應
範例

建立投票 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| commentId | string | query | 是 | |
| direction | string | query | 是 | |
| userId | string | query | 否 | |
| anonUserId | string | query | 否 |
回應
範例

刪除投票 
參數
| Name | Type | Location | Required | Description |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| id | string | path | 是 | |
| editKey | string | query | 否 |
回應
回傳: DeleteCommentVote200Response
範例

取得投票 
參數
| 名稱 | 類型 | 位置 | 必填 | 描述 |
|---|---|---|---|---|
| tenantId | string | query | Yes | |
| urlId | string | query | Yes |
回應
範例

取得使用者的投票 
參數
| 名稱 | 類型 | 位置 | 必填 | 說明 |
|---|---|---|---|---|
| tenantId | string | query | 是 | |
| urlId | string | query | 是 | |
| userId | string | query | 否 | |
| anonUserId | string | query | 否 |
回應
範例

需要幫助嗎?
如果您在使用 Go SDK 時遇到任何問題或有任何疑問,請:
貢獻
歡迎任何貢獻!請造訪 GitHub 儲存庫 以查看貢獻指南。