スキル使用量を取得
GET/v1/organizations/analytics/skills
指定した日のスキルごとの使用状況を、カーソルベースのページネーションで取得します。
組織のスキル使用状況メトリクスを、スキル名順に返します。メンバーごと、RBACグループごと、または製品サーフェスごとに使用状況を分類するには group_by[] を、結果をスコープするには filter[] を使用してください。サポートされるディメンションはパラメータの説明に記載されています。Claude Enterprise プランの組織で利用可能です。read:analytics スコープを持つAPIキーが必要です。
Parameters
Returns
スキル使用量を取得
package main
import (
"context"
"fmt"
"github.com/anthropics/anthropic-sdk-go"
"github.com/anthropics/anthropic-sdk-go/option"
)
func main() {
client := anthropic.NewClient(
option.WithAPIKey("my-anthropic-api-key"),
)
page, err := client.Beta.Organization.Analytics.Skills.List(context.TODO(), anthropic.BetaOrganizationAnalyticsSkillListParams{})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", page)
}Response 200
{
"data": [
{
"chat_metrics": {
"distinct_conversation_skill_used_count": 0
},
"claude_code_metrics": {
"distinct_session_skill_used_count": 0
},
"cowork_metrics": {
"distinct_session_skill_used_count": 0
},
"distinct_user_count": 0,
"office_metrics": {
"excel": {
"distinct_session_skill_used_count": 0
},
"outlook": {
"distinct_session_skill_used_count": 0
},
"powerpoint": {
"distinct_session_skill_used_count": 0
},
"word": {
"distinct_session_skill_used_count": 0
}
},
"skill_name": "skill_name",
"attributed_list_price": "attributed_list_price",
"chat_cowork_unified_metrics": {
"chat": {
"distinct_conversation_skill_used_count": 0
},
"sessions": {
"distinct_session_skill_used_count": 0
}
},
"currency": "currency",
"enable_count": 0,
"estimated_overage_spend": "estimated_overage_spend",
"invocation_count": 0,
"product": "product",
"rbac_group_id": "rbac_group_id",
"rbac_group_name": "rbac_group_name",
"share_status": "organization",
"skill_display_name": "skill_display_name",
"user_id": "user_id"
}
],
"next_page": "next_page"
}Returns Examples
Response 200
{
"data": [
{
"chat_metrics": {
"distinct_conversation_skill_used_count": 0
},
"claude_code_metrics": {
"distinct_session_skill_used_count": 0
},
"cowork_metrics": {
"distinct_session_skill_used_count": 0
},
"distinct_user_count": 0,
"office_metrics": {
"excel": {
"distinct_session_skill_used_count": 0
},
"outlook": {
"distinct_session_skill_used_count": 0
},
"powerpoint": {
"distinct_session_skill_used_count": 0
},
"word": {
"distinct_session_skill_used_count": 0
}
},
"skill_name": "skill_name",
"attributed_list_price": "attributed_list_price",
"chat_cowork_unified_metrics": {
"chat": {
"distinct_conversation_skill_used_count": 0
},
"sessions": {
"distinct_session_skill_used_count": 0
}
},
"currency": "currency",
"enable_count": 0,
"estimated_overage_spend": "estimated_overage_spend",
"invocation_count": 0,
"product": "product",
"rbac_group_id": "rbac_group_id",
"rbac_group_name": "rbac_group_name",
"share_status": "organization",
"skill_display_name": "skill_display_name",
"user_id": "user_id"
}
],
"next_page": "next_page"
}