# ユーザーサブグループとタグ API
呼び出し方法Open APIドキュメントの呼び出し方法の説明を参照してください。
# 条件付きグループまたはラベルを追加
インターフェイス URL
/open/user-cluster-add?token=xxx
リクエスト方法
POST
コンテンツタイプ
application/json
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
以下に異なる状況で要求 body の例を示す
**1.****条件付きグループの追加**
要求 Body パラメーター
{
  "projectId": 102,
  "clusterName": "recent_7_days_consume",
  "clusterCatalog": "catalog_cluster",
  "clusterType": "cluster_by_static_condition",
  "displayName": "recent_7_days_consume",
  "qp": {
    "events": [
      {
        "comparator": "greater",
        "eventName": "consume_item",
        "num": "4",
        "recentDay": "1-7",
        "taPropQuota": {
          "analysis": "TIMES"
        }
      }
    ],
    "event_relation": "and",
    "filts": [
      {
        "columnName": "user_level",
        "comparator": "equal",
        "ftv": [
          "3"
        ],
        "tableType": "user"
      }
    ],
    "relation": "and",
    "event_user_relation": "and"
  }
}
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| projectId | 102 | String | はい | プロジェクトID | 
| clusterName | recent_7_days_consume | String | はい | サブグループ名(文字数のみで、長さは24を超えることはできません) | 
| clusterCatalog | catalog_cluster | String | いいえ | グループタイプ カタログクラスタ catalog_tag:タグ | 
| clusterType | cluster_by_static_condition | String | いいえ | グループタイプ cluster_by_dynamic_condition:動的条件によるユーザーベースの更新 cluster_by_static_condition:静的条件付きユーザグループ cluster_by_result:結果のグループ化 cluster_by_import:アップロードIDグループ cluster_by_dynamic_sql:動的SQLクラスタリング cluster_by_static_sql:静的SQLクラスタリング tag_by_dynamic_condition:動的条件によるユーザラベルの更新 tag_by_static_condition:静的条件ユーザラベル tag_by_import:アップロードIDタグ tag_by_dynamic_sql:動的SQLタグ tag_by_static_sql:静的SQLタグ | 
| displayName | recent_7_days_consume | String | はい | グループ表示名(最大50文字まで) | 
| qp | - | Object | いいえ | グループの定義 | 
| ∟ events | - | List | いいえ | イベント参加条件一覧 | 
| ∟ comparator | greater | String | はい | モデルクエリAPIのフィルター式の演算子の説明を参照してください | 
| ∟ eventName | consume_item | String | はい | イベント名 | 
| ∟ num | 4 | String | いいえ | フィルタ値 | 
| ∟ recentDay | 1-7 | String | いいえ | 相対時間 | 
| ∟ taPropQuota | - | Object | はい | イベントインジケータ | 
| ∟ analysis | TIMES | String | いいえ | 分析の角度は、イベント分析モデルAPIの集約メソッドanalysis値のリストを参照してください | 
| ∟ event_relation | and | String | いいえ | 参加イベント条件間の論理関係(and, or) | 
| ∟ filts | - | List | いいえ | ユーザー属性条件一覧 | 
| ∟ columnName | user_level | String | はい | フィールド名 | 
| ∟ comparator | equal | String | モデルクエリAPIのフィルター式の演算子の説明を参照してください | |
| ∟ ftv | ["3"] | List | いいえ | フィルタ値リスト | 
| ∟ tableType | user | String | はい | event:イベントプロパティ、user:ユーザープロパティ | 
| ∟ relation | and | String | いいえ | ユーザー属性条件間の論理関係 | 
| ∟ event_user_relation | and | String | いいえ | 参加イベント条件リストとユーザ属性条件リストとの論理関係 | 
条件ラベルを追加
subConditionTabType フィールドの説明:
| フィールド | 説明 | 
|---|---|
| tag_condition_default | カスタム条件ラベル | 
| tag_condition_by_firstlast_event | 最初の最後の特徴ラベル | 
tagQp フィールドにはラベル定義が含まれています。
| フィールド | 説明 | 
|---|---|
| userTagValueDefs | カスタム条件ラベル | 
| userTagConFirstLastEventDef | 最初の最後の特徴ラベル | 
2.カスタム条件ラベル
userTagValueDefs フィールドの説明:
| フィールド | 説明 | 
|---|---|
| tagValue | タグ値 | 
| userClusterDef | ラベル値は定義に一致し、フィールド定義はUserClusterDef | 
- Request body (application/json)
{
  "projectId": 102,
  "clusterName": "tag_20200615_1",
  "clusterCatalog": "catalog_tag",
  "clusterType": "tag_by_static_condition",
  "subConditionTabType" : "tag_condition_default",
  "displayName": "标签_20200615_1",
  "tagQp": {
    "userTagValueDefs": [
      {
        "tagRemark": "",
        "tagValue": "标签值1",
        "userClusterDef": {
          "event_relation": "and",
          "event_user_relation": "and",
          "events": [
            {
              "eventName": "player_register",
              "num": "4",
              "recentDay": "1-30",
              "relation": "and",
              "taPropQuota": {
                "analysis": "TIMES"
              },
              "comparator": "greater"
            }
          ],
          "filts": [],
          "relation": "and"
        }
      },
      {
        "tagRemark": "",
        "tagValue": "标签值2",
        "userClusterDef": {
          "event_relation": "and",
          "event_user_relation": "and",
          "events": [
            {
              "eventName": "fight_success",
              "num": "0",
              "recentDay": "1-30",
              "relation": "and",
              "taPropQuota": {
                "analysis": "TIMES"
              }
              "uceCalcuSymbol": "greater"
            }
          ],
          "filts": [],
          "relation": "and"
        }
      }
    ]
  }
}
3.最初の最後の特徴タグ
- Request body (application/json)
{
  "projectId": 2,
  "clusterName": "tag_test_20200615_1",
  "clusterCatalog": "catalog_tag",
  "clusterType": "tag_by_static_condition",
  "subConditionTabType": "tag_condition_by_firstlast_event",
  "displayName": "标签_test",
  "tagQp": {
    "userTagConFirstLastEventDef": {
      "userTagConFirstLastEvent": {
        "calcPropVo": {
          "isCalc": false,
          "property": {
            "columnName": "#vp@test_num",
            "tableType": "event"
          }
        },
        "eventName": "pay",
        "isFirstEvent": true,
        "recentDay": "0-1",
        "filts": [
          {
            "columnName": "#os",
            "comparator": "equal",
            "ftv": [
              "android"
            ],
            "tableType": "event"
          }
        ],
        "relation": "and"
      }
    }
  }
}
4.指標値ラベル(バージョン 3.2.1 からサポート)
- Request body (application/json)
{
  "projectId": 2,
  "clusterName": "tag_test_20200615_1",
  "clusterCatalog": "catalog_tag",
  "clusterType": "tag_by_static_condition",
  "subConditionTabType": "tag_condition_by_quotation",
  "displayName": "标签_test",
  "tagQp": {
    "userTagConQuotaDef": {
      "userTagConQuotaEvent": {
        "type": "normal",
        "quota": "activity_reward",
        "analysis": "DISTINCT",
        "eventName": "activity_attend",
        "recentDay": "0-1",
        "filts": [
          {
            "columnName": "#os",
            "comparator": "equal",
            "ftv": [
              "android"
            ],
            "tableType": "event"
          }
        ],
        "relation": "and"
      }
    }
  }
}
成功応答の例
{
    "data": 970,
    "return_code": 0,
    "return_message": "success"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| data | 970 | Object | 成功の数 | 
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
# グループまたはラベルの詳細クエリ
clusterId または clusterName で詳細を問い合わせる
インターフェイス URL
/open/user-cluster-detail?token=xxx&projectId=102&clusterId=970
/open/user-cluster-detail?token=xxx&projectId=102&clusterName=recent_7_days_consume
リクエスト方法
GET
コンテンツタイプ
application/json
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
| projectId | 0 | Integer | はい | プロジェクトID | 
| clusterId | 970 | integer | いいえ | グループID | 
| clusterName | recent_7_days_consume | String | いいえ | サブグループ名 | 
成功応答の例
{
  "data": {
    "clusterName": "recent_7_days_consume",
    "clusterType": "cluster_by_static_condition",
    "displayName": "recent_7_days_consume",
    "id": 970,
    "progress": 1,
    "projectId": 102,
    "refreshTime": "2020-01-10 10:51:14",
    "userClusterDef": {
      "event_relation": "and",
      "event_user_relation": "and",
      "events": [
        {
          "comparator": "greater",
          "endTime": "2020-01-09 00:00:00",
          "eventName": "consume_item",
          "num": "4",
          "recentDay": "1-7",
          "startTime": "2020-01-03 00:00:00",
          "taPropQuota": {
            "analysis": "TIMES"
          }
        }
      ],
      "filts": [
        {
          "columnName": "user_level",
          "comparator": "equal",
          "ftv": [
            "3"
          ],
          "tableType": "user"
        }
      ],
      "relation": "and"
    },
    "userId": 13,
    "usersNum": 0
  },
  "return_code": 0,
  "return_message": "success"
}
| パラメーター名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
| data | - | Object | 結果を返す | 
| ∟ clusterName | recent_7_days_consume | String | サブグループ名 | 
| ∟ clusterType | cluster_by_static_condition | String | グループタイプ cluster_by_dynamic_condition:動的条件によるユーザーベースの更新 cluster_by_static_condition:静的条件付きユーザグループ cluster_by_result:結果のグループ化 cluster_by_import:アップロードIDグループ cluster_by_dynamic_sql:動的SQLクラスタリング cluster_by_static_sql:静的SQLクラスタリング tag_by_dynamic_condition:動的条件によるユーザラベルの更新 tag_by_static_condition:静的条件ユーザラベル tag_by_import:アップロードIDタグ tag_by_dynamic_sql:動的SQLタグ tag_by_static_sql:静的SQLタグ | 
| ∟ displayName | recent_7_days_consume | String | グループ表示名 | 
| ∟ id | 970 | Integer | パーティションID | 
| ∟ progress | 1 | Integer | タスク実行の進捗状況、100は実行成功、0-99は現在の計算の進捗状況、-1は実行失敗 | 
| ∟ projectId | 102 | Integer | 所属プロジェクトID | 
| ∟ refreshTime | 2020-01-10 10:51:14 | String | グループリフレッシュ時間 | 
| ∟ userId | 13 | Integer | サブグループ所属userId | 
| ∟ usersNum | 0 | Integer | グループユーザー数 | 
| ∟ userClusterDef | - | Object | 条件付きグループ定義 | 
| ∟ event_relation | and | String | イベントを行った属性リストのフィルタ条件論理関係 | 
| ∟ event_user_relation | and | String | イベントとユーザー属性の間のフィルタリング条件の論理関係 | 
| ∟ events | - | List | やったこと条件一覧 | 
| ∟ comparator | greater | String | モデルクエリAPIのフィルター式の演算子の説明を参照してください | 
| ∟ endTime | 2020-01-09 00:00:00 | String | 開始時間 | 
| ∟ eventName | consume_item | String | イベント名 | 
| ∟ num | 4 | String | |
| ∟ recentDay | 1-7 | String | 相対時間 | 
| ∟ startTime | 2020-01-03 00:00:00 | String | 終了時間 | 
| ∟ taPropQuota | - | Object | イベントインジケータ | 
| ∟ analysis | TIMES | String | 分析の角度は、イベント分析モデルAPIの集約メソッドanalysis値のリストを参照してください | 
| ∟ filts | - | List | ユーザー属性条件一覧 | 
| ∟ columnName | String | user_level | フィールド名 | 
| ∟ comparator | String | equal | モデルクエリAPIのフィルター式の演算子の説明を参照してください | 
| ∟ ftv | List | ["3"] | フィルタ値リスト | 
| ∟ tableType | user | String | event:イベントプロパティ、user:ユーザープロパティ | 
| ∟ relation | and | String | ユーザ属性リストのフィルタ条件論理関係 | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
| 結果フィールド | 説明 | 
|---|---|
| userClusterDef | グループ定義、同じqp | 
| userTagDef | タグ定義とtagQp | 
# 条件付きグループまたはラベル定義の更新
インターフェイス URL
/open/user-cluster-update?token=xxx&clusterId=970
リクエスト方法
POST
コンテンツタイプ
application/json
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
| clusterId | 970 | integer | いいえ | グループID | 
要求 Body パラメーター
{
  "clusterCatalog": "catalog_cluster",
  "clusterType": "cluster_by_static_condition",
  "displayName": "recent_7_days_consume",
  "projectId": 102,
  "qp": {
    "event_relation": "and",
    "event_user_relation": "and",
    "events": [
      {
        "comparator": "greater",
        "endTime": "2020-01-09 00:00:00",
        "eventName": "consume_item",
        "num": "4",
        "recentDay": "1-7",
        "startTime": "2020-01-03 00:00:00",
        "taPropQuota": {
          "analysis": "TIMES"
        }
      }
    ],
    "filts": [
      {
        "columnName": "user_level",
        "comparator": "equal",
        "ftv": [
          "3"
        ],
        "tableType": "user"
      }
    ],
    "relation": "and"
  }
}
パラメータ説明同インタフェース条件付きグループまたはラベル
成功応答の例
{
    "return_code": 0,
    "return_message": "success"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
# 名前に基づいて条件グループまたはラベル定義
インターフェイス URL
/open/user-cluster-update-by-name?token=xxx&projectId=xxx&clusterName= recent_7_days_consume
リクエスト方法
POST
コンテンツタイプ
application/json
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
| clusterId | 970 | integer | いいえ | グループID | 
要求 Body パラメーター
{
  "clusterCatalog": "catalog_cluster",
  "clusterType": "cluster_by_static_condition",
  "displayName": "recent_7_days_consume",
  "projectId": 102,
  "qp": {
    "event_relation": "and",
    "event_user_relation": "and",
    "events": [
      {
        "comparator": "greater",
        "endTime": "2020-01-09 00:00:00",
        "eventName": "consume_item",
        "num": "4",
        "recentDay": "1-7",
        "startTime": "2020-01-03 00:00:00",
        "taPropQuota": {
          "analysis": "TIMES"
        }
      }
    ],
    "filts": [
      {
        "columnName": "user_level",
        "comparator": "equal",
        "ftv": [
          "3"
        ],
        "tableType": "user"
      }
    ],
    "relation": "and"
  }
}
パラメータ説明インターフェースと条件付きグループまたはラベル
成功応答の例
{
    "return_code": 0,
    "return_message": "success"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
# グループまたはタグの削除
インターフェイス URL
/open/user-cluster-delete?token=xxx&projectId=102&clusterId=970
リクエスト方法
POST
コンテンツタイプ
application/json
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
| projectId | 102 | Integer | はい | プロジェクトID | 
| clusterId | 970 | Integer | はい | グループID | 
成功応答の例
{
    "return_code": 0,
    "return_message": "success"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
# 名前に基づいてグループまたはラベルを削除
インターフェイス URL
/open/delete-user-cluster-by-name?token=xxx&projectId=102&clusterName= recent_7_days_consume
リクエスト方法
POST
コンテンツタイプ
application/json
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
| projectId | 102 | Integer | はい | プロジェクトID | 
| clusterName | recent_7_days_consume | Integer | はい | サブグループ名 | 
成功応答の例
{
    "return_code": 0,
    "return_message": "success"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
# クラスタリングとタグリストクエリ
インターフェイス URL
/open/user-cluster-list?token=xxx
リクエスト方法
POST
コンテンツタイプ
application/json
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
要求 Body パラメーター
{
  "clusterCatalog": "catalog_cluster",
  "clusterTypes": [
    "cluster_by_dynamic_condition",
    "cluster_by_static_condition"
  ],
  "pagerHeader": {
    "pageNum": 1,
    "pageSize": 10
  },
  "projectId": 102
}
| パラメーター名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| clusterCatalog | catalog_cluster | String | はい | パラメーターの説明 | 
| clusterTypes | ["cluster_by_dynamic_condition"] | List | はい | クラスタータイプ | 
| pagerHeader | - | Object | いいえ | ページング情報 | 
| ∟ pageNum | 1 | Integer | いいえ | 何ページ目 | 
| ∟ pageSize | 10 | Integer | いいえ | ページサイズ | 
| projectId | 102 | Integer | はい | プロジェクトID | 
成功応答の例
{
    "data": {
        "pagerResult": {
            "pageNum": 1,
            "pageSize": 10,
            "totalNum": 2
        },
        "userClusters": [
            {
                "clusterCatalog": "catalog_cluster",
                "clusterName": "xuzz_ces",
                "clusterType": "cluster_by_static_condition",
                "displayName": "用户数",
                "historyDataStatus": 0,
                "id": 905,
                "mainColumnName": "",
                "progress": 100,
                "projectId": 102,
                "refreshDelay": 0,
                "refreshTime": "2019-11-01 15:08:31",
                "remarks": "2134",
                "selectType": "string",
                "status": 1,
                "uploadFileName": "",
                "userId": 108,
                "userName": "自动化测试__sync",
                "usersNum": 4665
            },
            {
                "clusterCatalog": "catalog_cluster",
                "clusterName": "test",
                "clusterType": "cluster_by_static_condition",
                "displayName": "test",
                "historyDataStatus": 0,
                "id": 183,
                "mainColumnName": "",
                "progress": 100,
                "projectId": 102,
                "refreshDelay": 0,
                "refreshTime": "2019-11-01 15:05:28",
                "remarks": "test",
                "selectType": "string",
                "status": 1,
                "uploadFileName": "",
                "userId": 108,
                "userName": "自动化测试__sync",
                "usersNum": 5603
            }
        ]
    },
    "return_code": 0,
    "return_message": "success"
}
| パラメーター名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
| data | - | Object | 結果を返す | 
| ∟ pagerResult | - | Object | ページング結果 | 
| ∟ pageNum | 1 | Integer | 現在のページ | 
| ∟ pageSize | 10 | Integer | ページごとのエントリ | 
| ∟ totalNum | 2 | Integer | 総本数 | 
| ∟ userClusters | - | Object | グループリスト | 
| ∟ clusterCatalog | catalog_cluster | String | グループタイプ カタログクラスタ catalog_tag:タグ | 
| ∟ clusterName | xuzz_ces | String | サブグループ名 | 
| ∟ clusterType | cluster_by_static_condition | String | グループタイプ cluster_by_dynamic_condition:動的条件によるユーザーベースの更新 cluster_by_static_condition:静的条件付きユーザグループ cluster_by_result:結果のグループ化 cluster_by_import:アップロードIDグループ cluster_by_dynamic_sql:動的SQLクラスタリング cluster_by_static_sql:静的SQLクラスタリング tag_by_dynamic_condition:動的条件によるユーザラベルの更新 tag_by_static_condition:静的条件ユーザラベル tag_by_import:アップロードIDタグ tag_by_dynamic_sql:動的SQLタグ tag_by_static_sql:静的SQLタグ | 
| ∟ displayName | ユーザー数 | String | グループ表示名 | 
| ∟ historyDataStatus | 0 | Integer | 履歴バージョンデータがあるかどうか | 
| ∟ id | 905 | Integer | パーティションID | 
| ∟ mainColumnName | String | IDグループアソシエーションプロパティ | |
| ∟ progress | 100 | Integer | タスク実行の進捗状況、100は実行成功、0-99は現在の計算の進捗状況、-1は実行失敗 | 
| ∟ projectId | 102 | Integer | 所属プロジェクトID | 
| ∟ refreshDelay | 0 | Long | シャントリフレッシュ遅延 | 
| ∟ refreshTime | 2019-11-01 15:08:31 | String | グループリフレッシュ時間 | 
| ∟ remarks | 2134 | String | グループ備考 | 
| ∟ selectType | string | String | タグの種類 | 
| ∟ status | 1 | Integer | グループ化状態、0:無効、1:有効 | 
| ∟ uploadFileName | String | テキストをアップロード | |
| ∟ userId | 108 | Integer | サブグループ所属userId | 
| ∟ userName | 自動テスト__sync | String | グループ所属userName | 
| ∟ usersNum | 4665 | Integer | グループユーザー数 | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
# 条件付きグループまたはラベル
インターフェイス URL
/open/user-cluster-refresh?token=xxx&projectId=102&clusterId=970
/open/user-cluster-refresh-by-name?token=xxx&projectId=102&clusterName=recent_7_days_consume
リクエスト方法
POST
コンテンツタイプ
application/json
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
| projectId | 102 | Integer | はい | プロジェクトID | 
| clusterId | 970 | integer | いいえ | グループID | 
| clusterName | recent_7_days_consume | String | いいえ | サブグループ名 | 
成功応答の例
{
    "return_code": 0,
    "return_message": "success"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
# クエリの更新の進捗状況
更新の送信後、更新の進捗状況を確認できます
/open/user-cluster-refresh-progress?token=xxx&projectId=102&clusterId=970
/open/user-cluster-refresh-progress-by-name?token=xxx&projectId=102&clusterName=recent_7_days_consume
リクエスト方法
GET
コンテンツタイプ
application/json
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
| projectId | 102 | Integer | はい | プロジェクトID | 
| clusterId | 970 | integer | いいえ | グループID | 
| clusterName | recent_7_days_consume | String | いいえ | サブグループ名 | 
成功応答の例
{
  "data": {
    "progress": 80,
  },
  "return_code": 0,
  "return_message": "success"
}
| パラメーター名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| data | - | Object | 結果を返す | 
| ∟ progress | 100 | Integer | 値範囲[0,100]をとると、100はリフレッシュ完了 | 
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
# アップロード ID グループまたはラベル
インターフェイス URL
/open/import-id-cluster-add?token=xxx&projectId=102&displayName=xxxx&mainColumnName=#account_id
リクエスト方法
POST
コンテンツタイプ
text/csv
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
| projectId | 102 | Integer | はい | プロジェクトID | 
| displayName | xxx | String | はい | グループ表示名(最大50文字) | 
| mainColumnName | #account_id | String | はい | グループ化関連プロパティ | 
| clusterCatalog | String | いいえ | 分類カテゴリ: catalog_cluster, catalog_tagデフォルトはcatalog_clusterです | |
| clusterName | String | いいえ | グループ名(最長24文字)、英数字で構成され、記入しないとシステムが生成 | |
| remarks | String | いいえ | グループ備考 | 
成功応答の例
{
    "data": {
        "clusterId": 1889,
        "tagValueNullNum": 0,
        "unmatchedNum": 0,
        "uploadNum": 5,
        "userNum": 5
    },
    "return_code": 0,
    "return_message": "success"
}
| パラメーター名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
| data | Object | 結果を返す | |
| ∟ clusterId | 1889 | Integer | ユーザサブグループID | 
| ∟ tagValueNullNum | 0 | Integer | Tag値がnullの行数 | 
| ∟ unmatchedNum | 0 | Integer | 一致しないレコード数 | 
| ∟ uploadNum | 5 | Integer | アップロードレコード数 | 
| ∟ userNum | 5 | Integer | ユーザー数 | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
curl 例(trace.txtSend/Recv 記述行の削除)
[root@ta1 ~]# curl --trace-ascii trace.txt --header 'Content-Type: text/csv' --data-binary '@test.csv' 'http://ta2:8992/open/import-id-cluster-add?token=bTOzKiTIozG4e19FgXphcA8dDV3DIY8RwdHTO7aSnBsRqSNaIk19BnBMecJDWibD&projectId=102&displayName=xxxx&mainColumnName=%23account_id'
{"data":{"clusterId":1889,"tagValueNullNum":0,"unmatchedNum":0,"uploadNum":5,"userNum":5},"return_code":0,"return_message":"success"}
[root@ta1 ~]#
[root@ta1 ~]#
[root@ta1 ~]# cat trace.txt
== Info: About to connect() to ta2 port 8992 (#0)
== Info:   Trying 10.81.129.35...
== Info: Connected to ta2 (10.81.129.35) port 8992 (#0)
0000: POST /open/import-id-cluster-add?token=bTOzKiTIozG4e19FgXphcA8dD
0040: V3DIY8RwdHTO7aSnBsRqSNaIk19BnBMecJDWibD&projectId=102&displayNam
0080: e=xxxx&mainColumnName=%23account_id HTTP/1.1
00ae: User-Agent: curl/7.29.0
00c7: Host: ta2:8992
00d7: Accept: */*
00e4: Content-Type: text/csv
00fc: Content-Length: 43
0110:
0000: j77639
0008: h84497
0010: g119426
0019: e154284
0022: f175355
== Info: upload completely sent off: 43 out of 43 bytes
0000: HTTP/1.1 200 OK
0000: Date: Thu, 05 Nov 2020 04:06:31 GMT
0000: Content-Type: application/json;charset=utf-8
0000: Content-Length: 148
0000:
0000: {"data":{"clusterId":1889,"tagValueNullNum":0,"unmatchedNum":0,"
0040: uploadNum":5,"userNum":5},"return_code":0,"return_message":"succ
0080: ess"}
== Info: Connection #0 to host ta2 left intact
# アップロード ID グループまたはラベル
インターフェイス URL
/open/import-id-cluster-modify?token=xxx&projectId=102&clusterId=970&displayName=xxx&remarks=xxx&mainColumnName=xxx
リクエスト方法
POST
コンテンツタイプ
text/csv
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
| projectId | 102 | Integer | はい | プロジェクトID | 
| clusterId | Integer | はい | グループID | |
| clusterName | String | はい | グループ名 | |
| displayName | String | いいえ | グループ表示名(最大50文字) | |
| mainColumnName | String | いいえ | グループ化関連プロパティ | |
| remarks | String | いいえ | グループ備考 | 
成功応答の例
{
    "data": "",
    "return_code": 0,
    "return_message": "success"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
| data | Object | 結果を返す | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
curl 例(trace.txtSend/Recv 記述行の削除)
[root@ta1 ~]# curl --trace-ascii trace.txt --header 'Content-Type: text/csv' --data-binary '@test.csv' 'http://ta2:8992/open/import-id-cluster-modify?token=bTOzKiTIozG4e19FgXphcA8dDV3DIY8RwdHTO7aSnBsRqSNaIk19BnBMecJDWibD&projectId=102&clusterId=1889&displayName=xxxx&mainColumnName=%23account_id'
{"data":{"clusterId":1889,"tagValueNullNum":0,"unmatchedNum":0,"uploadNum":5,"userNum":5},"return_code":0,"return_message":"success"}
[root@ta1 ~]#
[root@ta1 ~]#
[root@ta1 ~]# cat trace.txt
== Info: About to connect() to ta2 port 8992 (#0)
== Info:   Trying 10.81.129.35...
== Info: Connected to ta2 (10.81.129.35) port 8992 (#0)
0000: POST /open/import-id-cluster-modify?token=bTOzKiTIozG4e19FgXphcA
0040: 8dDV3DIY8RwdHTO7aSnBsRqSNaIk19BnBMecJDWibD&projectId=102&cluster
0080: Id=1889&displayName=xxxx&mainColumnName=%23account_id HTTP/1.1
00c0: User-Agent: curl/7.29.0
00d9: Host: ta2:8992
00e9: Accept: */*
00f6: Content-Type: text/csv
010e: Content-Length: 43
0122:
0000: j77639
0008: h84497
0010: g119426
0019: e154284
0022: f175355
== Info: upload completely sent off: 43 out of 43 bytes
0000: HTTP/1.1 200 OK
0000: Date: Thu, 05 Nov 2020 04:12:58 GMT
0000: Content-Type: application/json;charset=utf-8
0000: Content-Length: 148
0000:
0000: {"data":{"clusterId":1889,"tagValueNullNum":0,"unmatchedNum":0,"
0040: uploadNum":5,"userNum":5},"return_code":0,"return_message":"succ
0080: ess"}
== Info: Connection #0 to host ta2 left intact
# 名前に基づいてアップロード ID グループまたはラベル
インターフェイス URL
/open/import-id-cluster-modify-by-name?token=xxx&projectId=102&clusterName= recent_7_days_consume&displayName=xxxx&remarks=xxx&mainColumnName=xxx
リクエスト方法
POST
コンテンツタイプ
text/csv
Query パラメーター
| パラメータ名 | サンプル値 | パラメーターの種類 | 必須かどうか | パラメーターの説明 | 
|---|---|---|---|---|
| token | xxx | String | はい | トークン | 
| projectId | 102 | Integer | はい | プロジェクトID | 
| clusterName | recent_7_days_consume | String | はい | グループ名 | 
| displayName | String | いいえ | グループ表示名(最大50文字) | |
| mainColumnName | String | いいえ | グループ化関連プロパティ | |
| remarks | String | いいえ | グループ備考 | 
成功応答の例
{
    "data": "",
    "return_code": 0,
    "return_message": "success"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | 0 | Integer | リターンコード | 
| return_message | success | String | 戻る情報 | 
| data | Object | 結果を返す | 
エラー応答の例
{
    "return_code": -1008,
    "return_message": "参数(token)为空"
}
| パラメータ名 | サンプル値 | パラメーターの種類 | パラメーターの説明 | 
|---|---|---|---|
| return_code | -1008 | Integer | リターンコード | 
| return_message | パラメータ(token)は空です | String | 戻る情報 | 
