From 47640daae02515c9d7d3f8817ef9f49c5ebce6c7 Mon Sep 17 00:00:00 2001 From: arunma Date: Fri, 8 Sep 2023 17:11:37 +0800 Subject: [PATCH 01/16] feat: support rum datasource --- go.mod | 2 +- go.sum | 10 + tencentcloud/data_source_tc_rum_custom_url.go | 339 ++ .../data_source_tc_rum_custom_url_test.go | 53 + tencentcloud/data_source_tc_rum_event_url.go | 328 ++ .../data_source_tc_rum_event_url_test.go | 52 + tencentcloud/data_source_tc_rum_fetch_url.go | 372 ++ .../data_source_tc_rum_fetch_url_info.go | 339 ++ .../data_source_tc_rum_fetch_url_info_test.go | 53 + .../data_source_tc_rum_fetch_url_test.go | 56 + tencentcloud/data_source_tc_rum_group_log.go | 151 + .../data_source_tc_rum_group_log_test.go | 36 + tencentcloud/data_source_tc_rum_log_list.go | 140 + .../data_source_tc_rum_log_list_test.go | 35 + .../data_source_tc_rum_log_url_statistics.go | 317 ++ ...a_source_tc_rum_log_url_statistics_test.go | 51 + .../data_source_tc_rum_performance_page.go | 343 ++ ...ata_source_tc_rum_performance_page_test.go | 53 + .../data_source_tc_rum_pv_url_info.go | 317 ++ .../data_source_tc_rum_pv_url_info_test.go | 51 + .../data_source_tc_rum_pv_url_statistics.go | 328 ++ ...ta_source_tc_rum_pv_url_statistics_test.go | 52 + .../data_source_tc_rum_report_count.go | 141 + .../data_source_tc_rum_report_count_test.go | 35 + ...ta_source_tc_rum_rum_log_stats_log_list.go | 129 + ...urce_tc_rum_rum_log_stats_log_list_test.go | 34 + tencentcloud/data_source_tc_rum_scores.go | 263 ++ .../data_source_tc_rum_scores_test.go | 34 + .../data_source_tc_rum_set_url_statistics.go | 339 ++ ...a_source_tc_rum_set_url_statistics_test.go | 53 + tencentcloud/data_source_tc_rum_sign.go | 143 + tencentcloud/data_source_tc_rum_sign_test.go | 32 + .../data_source_tc_rum_static_project.go | 345 ++ .../data_source_tc_rum_static_project_test.go | 53 + .../data_source_tc_rum_static_resource.go | 339 ++ ...data_source_tc_rum_static_resource_test.go | 53 + tencentcloud/data_source_tc_rum_static_url.go | 339 ++ .../data_source_tc_rum_static_url_test.go | 53 + tencentcloud/data_source_tc_rum_taw_area.go | 210 + .../data_source_tc_rum_taw_area_test.go | 33 + .../data_source_tc_rum_web_vitals_page.go | 328 ++ ...data_source_tc_rum_web_vitals_page_test.go | 52 + tencentcloud/provider.go | 42 + tencentcloud/service_tencentcloud_rum.go | 1652 ++++++++ .../tencentcloud/rum/v20210622/client.go | 864 ++++- .../tencentcloud/rum/v20210622/errors.go | 9 + .../tencentcloud/rum/v20210622/models.go | 3382 +++++++++++------ vendor/modules.txt | 2 +- website/docs/d/rum_custom_url.html.markdown | 79 + website/docs/d/rum_event_url.html.markdown | 77 + website/docs/d/rum_fetch_url.html.markdown | 85 + .../docs/d/rum_fetch_url_info.html.markdown | 79 + website/docs/d/rum_group_log.html.markdown | 45 + website/docs/d/rum_log_list.html.markdown | 43 + .../d/rum_log_url_statistics.html.markdown | 75 + .../docs/d/rum_performance_page.html.markdown | 79 + website/docs/d/rum_pv_url_info.html.markdown | 75 + .../d/rum_pv_url_statistics.html.markdown | 77 + website/docs/d/rum_report_count.html.markdown | 43 + .../rum_rum_log_stats_log_list.html.markdown | 41 + website/docs/d/rum_scores.html.markdown | 55 + .../d/rum_set_url_statistics.html.markdown | 79 + website/docs/d/rum_sign.html.markdown | 41 + .../docs/d/rum_static_project.html.markdown | 79 + .../docs/d/rum_static_resource.html.markdown | 79 + website/docs/d/rum_static_url.html.markdown | 79 + website/docs/d/rum_taw_area.html.markdown | 46 + .../docs/d/rum_web_vitals_page.html.markdown | 77 + website/tencentcloud.erb | 60 + 69 files changed, 12613 insertions(+), 1217 deletions(-) create mode 100644 tencentcloud/data_source_tc_rum_custom_url.go create mode 100644 tencentcloud/data_source_tc_rum_custom_url_test.go create mode 100644 tencentcloud/data_source_tc_rum_event_url.go create mode 100644 tencentcloud/data_source_tc_rum_event_url_test.go create mode 100644 tencentcloud/data_source_tc_rum_fetch_url.go create mode 100644 tencentcloud/data_source_tc_rum_fetch_url_info.go create mode 100644 tencentcloud/data_source_tc_rum_fetch_url_info_test.go create mode 100644 tencentcloud/data_source_tc_rum_fetch_url_test.go create mode 100644 tencentcloud/data_source_tc_rum_group_log.go create mode 100644 tencentcloud/data_source_tc_rum_group_log_test.go create mode 100644 tencentcloud/data_source_tc_rum_log_list.go create mode 100644 tencentcloud/data_source_tc_rum_log_list_test.go create mode 100644 tencentcloud/data_source_tc_rum_log_url_statistics.go create mode 100644 tencentcloud/data_source_tc_rum_log_url_statistics_test.go create mode 100644 tencentcloud/data_source_tc_rum_performance_page.go create mode 100644 tencentcloud/data_source_tc_rum_performance_page_test.go create mode 100644 tencentcloud/data_source_tc_rum_pv_url_info.go create mode 100644 tencentcloud/data_source_tc_rum_pv_url_info_test.go create mode 100644 tencentcloud/data_source_tc_rum_pv_url_statistics.go create mode 100644 tencentcloud/data_source_tc_rum_pv_url_statistics_test.go create mode 100644 tencentcloud/data_source_tc_rum_report_count.go create mode 100644 tencentcloud/data_source_tc_rum_report_count_test.go create mode 100644 tencentcloud/data_source_tc_rum_rum_log_stats_log_list.go create mode 100644 tencentcloud/data_source_tc_rum_rum_log_stats_log_list_test.go create mode 100644 tencentcloud/data_source_tc_rum_scores.go create mode 100644 tencentcloud/data_source_tc_rum_scores_test.go create mode 100644 tencentcloud/data_source_tc_rum_set_url_statistics.go create mode 100644 tencentcloud/data_source_tc_rum_set_url_statistics_test.go create mode 100644 tencentcloud/data_source_tc_rum_sign.go create mode 100644 tencentcloud/data_source_tc_rum_sign_test.go create mode 100644 tencentcloud/data_source_tc_rum_static_project.go create mode 100644 tencentcloud/data_source_tc_rum_static_project_test.go create mode 100644 tencentcloud/data_source_tc_rum_static_resource.go create mode 100644 tencentcloud/data_source_tc_rum_static_resource_test.go create mode 100644 tencentcloud/data_source_tc_rum_static_url.go create mode 100644 tencentcloud/data_source_tc_rum_static_url_test.go create mode 100644 tencentcloud/data_source_tc_rum_taw_area.go create mode 100644 tencentcloud/data_source_tc_rum_taw_area_test.go create mode 100644 tencentcloud/data_source_tc_rum_web_vitals_page.go create mode 100644 tencentcloud/data_source_tc_rum_web_vitals_page_test.go create mode 100644 website/docs/d/rum_custom_url.html.markdown create mode 100644 website/docs/d/rum_event_url.html.markdown create mode 100644 website/docs/d/rum_fetch_url.html.markdown create mode 100644 website/docs/d/rum_fetch_url_info.html.markdown create mode 100644 website/docs/d/rum_group_log.html.markdown create mode 100644 website/docs/d/rum_log_list.html.markdown create mode 100644 website/docs/d/rum_log_url_statistics.html.markdown create mode 100644 website/docs/d/rum_performance_page.html.markdown create mode 100644 website/docs/d/rum_pv_url_info.html.markdown create mode 100644 website/docs/d/rum_pv_url_statistics.html.markdown create mode 100644 website/docs/d/rum_report_count.html.markdown create mode 100644 website/docs/d/rum_rum_log_stats_log_list.html.markdown create mode 100644 website/docs/d/rum_scores.html.markdown create mode 100644 website/docs/d/rum_set_url_statistics.html.markdown create mode 100644 website/docs/d/rum_sign.html.markdown create mode 100644 website/docs/d/rum_static_project.html.markdown create mode 100644 website/docs/d/rum_static_resource.html.markdown create mode 100644 website/docs/d/rum_static_url.html.markdown create mode 100644 website/docs/d/rum_taw_area.html.markdown create mode 100644 website/docs/d/rum_web_vitals_page.html.markdown diff --git a/go.mod b/go.mod index 43ad4a56a3..004f72ad71 100644 --- a/go.mod +++ b/go.mod @@ -73,7 +73,7 @@ require ( github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/privatedns v1.0.751 github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/pts v1.0.533 github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/redis v1.0.657 - github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum v1.0.542 + github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum v1.0.744 github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/scf v1.0.729 github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/ses v1.0.748 github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/sms v1.0.486 diff --git a/go.sum b/go.sum index 8d8b81ee47..18a4ac9732 100644 --- a/go.sum +++ b/go.sum @@ -876,6 +876,12 @@ github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.729/go.mod github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.730/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.734/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.736/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.737 h1:Y/mD9PJbMkjzJiuZsJnzUk31OPCXvch7WSFbs9kKRyw= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.737/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.743 h1:P6Pql3W1aEtHK4l2W8L1ExcZ0pA/mlgr1c6K6ROkSCs= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.743/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.744 h1:mnGB6/dYZWwiffjzCQgyCte/lg2PHWMX8Cln0y3TbcE= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.744/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.745/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.748/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.750/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= @@ -967,6 +973,10 @@ github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/redis v1.0.657 h1:9p/4/ github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/redis v1.0.657/go.mod h1:CPc7SSKl8I21UmhTf2AVYZqZfy8MbDr/RrMsSqMkOAM= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum v1.0.542 h1:/U0rTVKXD7Y8Opw6OtnqSDPnWiP3zMMAlxOKayII/5Q= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum v1.0.542/go.mod h1:QF1J13hmuMY5gMrBopRFmHWFs/KsLr5uCNBRJt5aA1M= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum v1.0.744 h1:Z6xqpgnVPQfw2Yx/c2z6n30LfNodK4JEgMca1WpfOrY= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum v1.0.744/go.mod h1:prlrCvxmnWH4yCkA5cIIjGZMMuuvPs5EuCx1rV+F8jk= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/scf v1.0.664 h1:57r4xDd0t9zQw8tLO9k13gYy/EYYGtFV3fMPx1BJinY= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/scf v1.0.664/go.mod h1:dFFSCohvDzW2jidqjb5GFDhQD/2AfM1tZ8ijkuJUr9Y= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/scf v1.0.729 h1:UWTpLpN3UngFNTuMosxSMCcmuoLksvuc9tt7ulCe0D8= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/scf v1.0.729/go.mod h1:P5cLcaPdmOiRhv79OAvAKf+9JTg/64N7ZxwZHBW2mZA= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/ses v1.0.748 h1:pG2i5MHLmDkn8RC5wGjqRUx2db4L79JmV7qJyFzK5cs= diff --git a/tencentcloud/data_source_tc_rum_custom_url.go b/tencentcloud/data_source_tc_rum_custom_url.go new file mode 100644 index 0000000000..148387b79d --- /dev/null +++ b/tencentcloud/data_source_tc_rum_custom_url.go @@ -0,0 +1,339 @@ +/* +Use this data source to query detailed information of rum custom_url + +Example Usage + +```hcl +data "tencentcloud_rum_custom_url" "custom_url" { + start_time = 1625444040 + type = "top" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" +} +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumCustomUrl() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumCustomUrlRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Data Type. `top`: CostType Sorting order by top, `nettype`: CostType Sorting order by nettype, `allcount`: CostType allcount, `day`: CostType group by day, `condition`: CostType Sorting in condition, `pagepv`: CostType Sorting order by pagepv, `area`: CostType query in area, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "cost_type": { + Optional: true, + Type: schema.TypeString, + Description: "The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile, `90`: 90th percentile, `95`: 95th percentile, `99`: 99th percentile, `99.5`: 99.5th percentile, `avg`: Mean.", + }, + + "url": { + Optional: true, + Type: schema.TypeString, + Description: "The URL Key where the data reporting takes place.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumCustomUrlRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_custom_url.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("cost_type"); ok { + paramMap["CostType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("url"); ok { + paramMap["Url"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumCustomUrlByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_custom_url_test.go b/tencentcloud/data_source_tc_rum_custom_url_test.go new file mode 100644 index 0000000000..b2dc8561b2 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_custom_url_test.go @@ -0,0 +1,53 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumCustomUrlDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumCustomUrlDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_custom_url.custom_url")), + }, + }, + }) +} + +const testAccRumCustomUrlDataSource = ` + +data "tencentcloud_rum_custom_url" "custom_url" { + start_time = 1625444040 + type = "top" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + } + +` diff --git a/tencentcloud/data_source_tc_rum_event_url.go b/tencentcloud/data_source_tc_rum_event_url.go new file mode 100644 index 0000000000..4b9720bfad --- /dev/null +++ b/tencentcloud/data_source_tc_rum_event_url.go @@ -0,0 +1,328 @@ +/* +Use this data source to query detailed information of rum event_url + +Example Usage + +```hcl +data "tencentcloud_rum_event_url" "event_url" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + name = "test" + env = "production" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumEventUrl() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumEventUrlRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Data Type. `allcount`:CostType allcount, `day`:CostType group by day, `condition`:CostType group by condition, `ckuv`:CostType group by uv, `ckpv`:CostType group by pv, `nettype`: CostType sort by nettype, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "name": { + Optional: true, + Type: schema.TypeString, + Description: "Event name for data reporting.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumEventUrlRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_event_url.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("name"); ok { + paramMap["Name"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumEventUrlByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_event_url_test.go b/tencentcloud/data_source_tc_rum_event_url_test.go new file mode 100644 index 0000000000..a223e2aabd --- /dev/null +++ b/tencentcloud/data_source_tc_rum_event_url_test.go @@ -0,0 +1,52 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumEventUrlDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumEventUrlDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_event_url.event_url")), + }, + }, + }) +} + +const testAccRumEventUrlDataSource = ` + +data "tencentcloud_rum_event_url" "event_url" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + name = "test" + env = "production" + } + +` diff --git a/tencentcloud/data_source_tc_rum_fetch_url.go b/tencentcloud/data_source_tc_rum_fetch_url.go new file mode 100644 index 0000000000..23efa02746 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_fetch_url.go @@ -0,0 +1,372 @@ +/* +Use this data source to query detailed information of rum fetch_url + +Example Usage + +```hcl +data "tencentcloud_rum_fetch_url" "fetch_url" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + status = "200" + ret = "0" + net_status = "0" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumFetchUrl() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumFetchUrlRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Data Type. `allcount`:CostType allcount, `day`:CostType group by day, `count40x`: CostType Sorting order by statusCode(40x) count, `count50x`: CostType Sorting order by statusCode(50x) count, `count5xand4x`: CostType Sorting order by statusCode(40x) count and statusCode(50x) count, `top`:CostType Sorting order by top, `nettype`: CostType sort by nettype, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "cost_type": { + Optional: true, + Type: schema.TypeString, + Description: "The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean.", + }, + + "url": { + Optional: true, + Type: schema.TypeString, + Description: "The URL Key where the data reporting takes place.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "status": { + Optional: true, + Type: schema.TypeString, + Description: "HTTP protocol response code.", + }, + + "ret": { + Optional: true, + Type: schema.TypeString, + Description: "Remote request response body code.", + }, + + "net_status": { + Optional: true, + Type: schema.TypeString, + Description: "The network status where the data reporting takes place.`0`: noraml, `1`: week, `2`: disconnection, `3`: unknown.", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumFetchUrlRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_fetch_url.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("cost_type"); ok { + paramMap["CostType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("url"); ok { + paramMap["Url"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("status"); ok { + paramMap["Status"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ret"); ok { + paramMap["Ret"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_status"); ok { + paramMap["NetStatus"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumFetchUrlByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_fetch_url_info.go b/tencentcloud/data_source_tc_rum_fetch_url_info.go new file mode 100644 index 0000000000..8b9fa567a4 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_fetch_url_info.go @@ -0,0 +1,339 @@ +/* +Use this data source to query detailed information of rum fetch_url_info + +Example Usage + +```hcl +data "tencentcloud_rum_fetch_url_info" "fetch_url_info" { + start_time = 1625444040 + type = "top" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumFetchUrlInfo() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumFetchUrlInfoRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Data type. `top`: CostType Sorting order by top.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "cost_type": { + Optional: true, + Type: schema.TypeString, + Description: "The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean.", + }, + + "url": { + Optional: true, + Type: schema.TypeString, + Description: "The URL Key where the data reporting takes place.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumFetchUrlInfoRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_fetch_url_info.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("cost_type"); ok { + paramMap["CostType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("url"); ok { + paramMap["Url"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumFetchUrlInfoByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_fetch_url_info_test.go b/tencentcloud/data_source_tc_rum_fetch_url_info_test.go new file mode 100644 index 0000000000..b301865493 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_fetch_url_info_test.go @@ -0,0 +1,53 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumFetchUrlInfoDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumFetchUrlInfoDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_fetch_url_info.fetch_url_info")), + }, + }, + }) +} + +const testAccRumFetchUrlInfoDataSource = ` + +data "tencentcloud_rum_fetch_url_info" "fetch_url_info" { + start_time = 1625444040 + type = "top" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + } + +` diff --git a/tencentcloud/data_source_tc_rum_fetch_url_test.go b/tencentcloud/data_source_tc_rum_fetch_url_test.go new file mode 100644 index 0000000000..d0067bf350 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_fetch_url_test.go @@ -0,0 +1,56 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumFetchUrlDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumFetchUrlDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_fetch_url.fetch_url")), + }, + }, + }) +} + +const testAccRumFetchUrlDataSource = ` + +data "tencentcloud_rum_fetch_url" "fetch_url" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + status = "200" + ret = "0" + net_status = "0" + } + +` diff --git a/tencentcloud/data_source_tc_rum_group_log.go b/tencentcloud/data_source_tc_rum_group_log.go new file mode 100644 index 0000000000..1cb6ec1338 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_group_log.go @@ -0,0 +1,151 @@ +/* +Use this data source to query detailed information of rum group_log + +Example Usage + +```hcl +data "tencentcloud_rum_group_log" "group_log" { + order_by = "desc" + start_time = 1625444040000 + query = "id:123 AND type:"log"" + end_time = 1625454840000 + project_id = 1 + group_field = "level" + } +``` +*/ +package tencentcloud + +import ( + "context" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumGroupLog() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumGroupLogRead, + Schema: map[string]*schema.Schema{ + "order_by": { + Required: true, + Type: schema.TypeString, + Description: "Sorting method. `desc`:Descending order; `asc`: Ascending order.", + }, + + "start_time": { + Required: true, + Type: schema.TypeString, + Description: "Start time but is represented using a timestamp in milliseconds.", + }, + + "query": { + Required: true, + Type: schema.TypeString, + Description: "Log Query syntax statement.", + }, + + "end_time": { + Required: true, + Type: schema.TypeString, + Description: "End time but is represented using a timestamp in milliseconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "group_field": { + Required: true, + Type: schema.TypeString, + Description: "The field used for group.", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumGroupLogRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_group_log.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime string + endTime string + ) + + paramMap := make(map[string]interface{}) + if v, ok := d.GetOk("order_by"); ok { + paramMap["OrderBy"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("start_time"); ok { + startTime = v.(string) + paramMap["StartTime"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("query"); ok { + paramMap["Query"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("end_time"); ok { + endTime = v.(string) + paramMap["EndTime"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("group_field"); ok { + paramMap["GroupField"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumGroupLogByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{startTime, endTime, ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_group_log_test.go b/tencentcloud/data_source_tc_rum_group_log_test.go new file mode 100644 index 0000000000..405fa80e42 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_group_log_test.go @@ -0,0 +1,36 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumGroupLogDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumGroupLogDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_group_log.group_log")), + }, + }, + }) +} + +const testAccRumGroupLogDataSource = ` + +data "tencentcloud_rum_group_log" "group_log" { + order_by = "desc" + start_time = 1625444040000 + query = "id:123 AND type:"log"" + end_time = 1625454840000 + i_d = 1 + group_field = "level" + } + +` diff --git a/tencentcloud/data_source_tc_rum_log_list.go b/tencentcloud/data_source_tc_rum_log_list.go new file mode 100644 index 0000000000..d343fcbdce --- /dev/null +++ b/tencentcloud/data_source_tc_rum_log_list.go @@ -0,0 +1,140 @@ +/* +Use this data source to query detailed information of rum log_list + +Example Usage + +```hcl +data "tencentcloud_rum_log_list" "log_list" { + order_by = "desc" + start_time = 1625444040000 + query = "id:123 AND type:"log"" + end_time = 1625454840000 + project_id = 1 + } +``` +*/ +package tencentcloud + +import ( + "context" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumLogList() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumLogListRead, + Schema: map[string]*schema.Schema{ + "order_by": { + Required: true, + Type: schema.TypeString, + Description: "Sorting method. `desc`:Descending order; `asc`: Ascending order.", + }, + + "start_time": { + Required: true, + Type: schema.TypeString, + Description: "Start time but is represented using a timestamp in milliseconds.", + }, + + "query": { + Required: true, + Type: schema.TypeString, + Description: "Log Query syntax statement.", + }, + + "end_time": { + Required: true, + Type: schema.TypeString, + Description: "End time but is represented using a timestamp in milliseconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumLogListRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_log_list.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime string + endTime string + ) + + paramMap := make(map[string]interface{}) + if v, ok := d.GetOk("order_by"); ok { + paramMap["OrderBy"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("start_time"); ok { + startTime = v.(string) + paramMap["StartTime"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("query"); ok { + paramMap["Query"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("end_time"); ok { + endTime = v.(string) + paramMap["EndTime"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumLogListByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{startTime, endTime, ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_log_list_test.go b/tencentcloud/data_source_tc_rum_log_list_test.go new file mode 100644 index 0000000000..0dc3a5b727 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_log_list_test.go @@ -0,0 +1,35 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumLogListDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumLogListDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_log_list.log_list")), + }, + }, + }) +} + +const testAccRumLogListDataSource = ` + +data "tencentcloud_rum_log_list" "log_list" { + order_by = "desc" + start_time = 1625444040000 + query = "id:123 AND type:"log"" + end_time = 1625454840000 + i_d = 1 + } + +` diff --git a/tencentcloud/data_source_tc_rum_log_url_statistics.go b/tencentcloud/data_source_tc_rum_log_url_statistics.go new file mode 100644 index 0000000000..667c640386 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_log_url_statistics.go @@ -0,0 +1,317 @@ +/* +Use this data source to query detailed information of rum log_url_statistics + +Example Usage + +```hcl +data "tencentcloud_rum_log_url_statistics" "log_url_statistics" { + start_time = 1625444040 + type = "analysis" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + env = "production" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumLogUrlStatistics() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumLogUrlStatisticsRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Data Type. `analysis`:query analysis data, `compare`:query compare data, `allcount`:query allcount, `condition`:query in condition, `nettype`: CostType sort by nettype, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumLogUrlStatisticsRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_log_url_statistics.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumLogUrlStatisticsByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_log_url_statistics_test.go b/tencentcloud/data_source_tc_rum_log_url_statistics_test.go new file mode 100644 index 0000000000..3256104ffd --- /dev/null +++ b/tencentcloud/data_source_tc_rum_log_url_statistics_test.go @@ -0,0 +1,51 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumLogUrlStatisticsDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumLogUrlStatisticsDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_log_url_statistics.log_url_statistics")), + }, + }, + }) +} + +const testAccRumLogUrlStatisticsDataSource = ` + +data "tencentcloud_rum_log_url_statistics" "log_url_statistics" { + start_time = 1625444040 + type = "analysis" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + env = "production" + } + +` diff --git a/tencentcloud/data_source_tc_rum_performance_page.go b/tencentcloud/data_source_tc_rum_performance_page.go new file mode 100644 index 0000000000..d41077d1cc --- /dev/null +++ b/tencentcloud/data_source_tc_rum_performance_page.go @@ -0,0 +1,343 @@ +/* +Use this data source to query detailed information of rum performance_page + +Example Usage + +```hcl +data "tencentcloud_rum_performance_page" "performance_page" { + project_id = 1 + start_time = 1625444040 + end_time = 1625454840 + type = "pagepv" + level = "1" + isp = "中国电信" + area = "广州市" + net_type = "2" + platform = "2" + device = "Apple - iPhone" + version_num = "1.0" + ext_first = "ext1" + ext_second = "ext2" + ext_third = "ext3" + is_abroad = "0" + browser = "Chrome(79.0)" + os = "Windows - 10" + engine = "Blink(79.0)" + brand = "Apple" + from = "https://user.qzone.qq.com/" + cost_type = "50" + env = "production" + net_status = "0" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumPerformancePage() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumPerformancePageRead, + Schema: map[string]*schema.Schema{ + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Data Type. `pagepv`: CostType query by pagepv, `allcount`: CostType query allcount, `falls`: CostType query by falls, `samp`: CostType query by samp, `day`: CostType query by day, `nettype`: CostType query by nettype, `performance`: CostType query by performance `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "cost_type": { + Optional: true, + Type: schema.TypeString, + Description: "The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "net_status": { + Optional: true, + Type: schema.TypeString, + Description: "The network status where the data reporting takes place.`0`: noraml, `1`: week, `2`: disconnection, `3`: unknown.", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumPerformancePageRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_performance_page.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("cost_type"); ok { + paramMap["CostType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_status"); ok { + paramMap["NetStatus"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumPerformancePageByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_performance_page_test.go b/tencentcloud/data_source_tc_rum_performance_page_test.go new file mode 100644 index 0000000000..c58143abe1 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_performance_page_test.go @@ -0,0 +1,53 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumPerformancePageDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumPerformancePageDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_performance_page.performance_page")), + }, + }, + }) +} + +const testAccRumPerformancePageDataSource = ` + +data "tencentcloud_rum_performance_page" "performance_page" { + i_d = 1 + start_time = 1625444040 + end_time = 1625454840 + type = "pagepv" + level = "1" + isp = "中国电信" + area = "广州市" + net_type = "2" + platform = "2" + device = "Apple - iPhone" + version_num = "1.0" + ext_first = "ext1" + ext_second = "ext2" + ext_third = "ext3" + is_abroad = "0" + browser = "Chrome(79.0)" + os = "Windows - 10" + engine = "Blink(79.0)" + brand = "Apple" + from = "https://user.qzone.qq.com/" + cost_type = "50" + env = "production" + net_status = "0" + } + +` diff --git a/tencentcloud/data_source_tc_rum_pv_url_info.go b/tencentcloud/data_source_tc_rum_pv_url_info.go new file mode 100644 index 0000000000..6a770c4498 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_pv_url_info.go @@ -0,0 +1,317 @@ +/* +Use this data source to query detailed information of rum pv_url_info + +Example Usage + +```hcl +data "tencentcloud_rum_pv_url_info" "pv_url_info" { + start_time = 1625444040 + type = "pagepv" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + env = "production" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumPvUrlInfo() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumPvUrlInfoRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Type value is fixed, please always pass `pagepv`.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumPvUrlInfoRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_pv_url_info.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumPvUrlInfoByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_pv_url_info_test.go b/tencentcloud/data_source_tc_rum_pv_url_info_test.go new file mode 100644 index 0000000000..ebb0b2b240 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_pv_url_info_test.go @@ -0,0 +1,51 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumPvUrlInfoDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumPvUrlInfoDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_pv_url_info.pv_url_info")), + }, + }, + }) +} + +const testAccRumPvUrlInfoDataSource = ` + +data "tencentcloud_rum_pv_url_info" "pv_url_info" { + start_time = 1625444040 + type = "pagepv" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + env = "production" + } + +` diff --git a/tencentcloud/data_source_tc_rum_pv_url_statistics.go b/tencentcloud/data_source_tc_rum_pv_url_statistics.go new file mode 100644 index 0000000000..c521205432 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_pv_url_statistics.go @@ -0,0 +1,328 @@ +/* +Use this data source to query detailed information of rum pv_url_statistics + +Example Usage + +```hcl +data "tencentcloud_rum_pv_url_statistics" "pv_url_statistics" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + env = "production" + group_by_type = 1 + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumPvUrlStatistics() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumPvUrlStatisticsRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Date Type. `allcount`:CostType allcount, `day`:CostType group by day, `vp`: CostType group by vp, `ckuv`:CostType group by uv, `ckpv`:CostType group by pv, `ckwau`:CostType group by ckwau, `ckmau`:CostType group by ckmau, `condition`:CostType group by condition, `nettype`: CostType sort by nettype, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "group_by_type": { + Optional: true, + Type: schema.TypeInt, + Description: "Query groupby type `1`: 1m, `2`: 5m, `3`: 30m, `4`: 1h, `5`: 1d.", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumPvUrlStatisticsRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_pv_url_statistics.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("group_by_type"); v != nil { + paramMap["GroupByType"] = helper.IntInt64(v.(int)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumPvUrlStatisticsByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_pv_url_statistics_test.go b/tencentcloud/data_source_tc_rum_pv_url_statistics_test.go new file mode 100644 index 0000000000..9f173c25a6 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_pv_url_statistics_test.go @@ -0,0 +1,52 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumPvUrlStatisticsDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumPvUrlStatisticsDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_pv_url_statistics.pv_url_statistics")), + }, + }, + }) +} + +const testAccRumPvUrlStatisticsDataSource = ` + +data "tencentcloud_rum_pv_url_statistics" "pv_url_statistics" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + env = "production" + group_by_type = 1 + } + +` diff --git a/tencentcloud/data_source_tc_rum_report_count.go b/tencentcloud/data_source_tc_rum_report_count.go new file mode 100644 index 0000000000..bd4bee4297 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_report_count.go @@ -0,0 +1,141 @@ +/* +Use this data source to query detailed information of rum report_count + +Example Usage + +```hcl +data "tencentcloud_rum_report_count" "report_count" { + start_time = 1625444040 + end_time = 1625454840 + project_id = 1 + report_type = "log" + instance_id = "rum-xxx" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumReportCount() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumReportCountRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "report_type": { + Optional: true, + Type: schema.TypeString, + Description: "Report type, empty is meaning all type count. `log`:log report count, `pv`:pv report count, `event`:event report count, `speed`:speed report count, `performance`:performance report count, `custom`:custom report count, `webvitals`:webvitals report count, `miniProgramData`:miniProgramData report count.", + }, + + "instance_id": { + Optional: true, + Type: schema.TypeString, + Description: "Instance ID.", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumReportCountRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_report_count.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("report_type"); ok { + paramMap["ReportType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("instance_id"); ok { + paramMap["InstanceID"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumReportCountByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_report_count_test.go b/tencentcloud/data_source_tc_rum_report_count_test.go new file mode 100644 index 0000000000..4e8befa0d5 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_report_count_test.go @@ -0,0 +1,35 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumReportCountDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumReportCountDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_report_count.report_count")), + }, + }, + }) +} + +const testAccRumReportCountDataSource = ` + +data "tencentcloud_rum_report_count" "report_count" { + start_time = 1625444040 + end_time = 1625454840 + i_d = 1 + report_type = "log" + instance_i_d = "rum-xxx" + } + +` diff --git a/tencentcloud/data_source_tc_rum_rum_log_stats_log_list.go b/tencentcloud/data_source_tc_rum_rum_log_stats_log_list.go new file mode 100644 index 0000000000..c166a6f7b3 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_rum_log_stats_log_list.go @@ -0,0 +1,129 @@ +/* +Use this data source to query detailed information of rum rum_log_stats_log_list + +Example Usage + +```hcl +data "tencentcloud_rum_rum_log_stats_log_list" "rum_log_stats_log_list" { + start_time = 1625444040 + query = "id:123 AND type:"log"" + end_time = 1625454840 + project_id = 1 + } +``` +*/ +package tencentcloud + +import ( + "context" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumRumLogStatsLogList() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumRumLogStatsLogListRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeString, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "query": { + Required: true, + Type: schema.TypeString, + Description: "Log Query syntax statement.", + }, + + "end_time": { + Required: true, + Type: schema.TypeString, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumRumLogStatsLogListRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_rum_log_stats_log_list.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime string + endTime string + ) + + paramMap := make(map[string]interface{}) + if v, ok := d.GetOk("start_time"); ok { + startTime = v.(string) + paramMap["StartTime"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("end_time"); ok { + endTime = v.(string) + paramMap["EndTime"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("query"); ok { + paramMap["Query"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumRumLogStatsLogListByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{startTime, endTime, ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_rum_log_stats_log_list_test.go b/tencentcloud/data_source_tc_rum_rum_log_stats_log_list_test.go new file mode 100644 index 0000000000..9d2a01e56b --- /dev/null +++ b/tencentcloud/data_source_tc_rum_rum_log_stats_log_list_test.go @@ -0,0 +1,34 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumRumLogStatsLogListDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumRumLogStatsLogListDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_rum_log_stats_log_list.rum_log_stats_log_list")), + }, + }, + }) +} + +const testAccRumRumLogStatsLogListDataSource = ` + +data "tencentcloud_rum_rum_log_stats_log_list" "rum_log_stats_log_list" { + start_time = 1625444040 + query = "id:123 AND type:"log"" + end_time = 1625454840 + i_d = 1 + } + +` diff --git a/tencentcloud/data_source_tc_rum_scores.go b/tencentcloud/data_source_tc_rum_scores.go new file mode 100644 index 0000000000..5f6803e277 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_scores.go @@ -0,0 +1,263 @@ +/* +Use this data source to query detailed information of rum scores + +Example Usage + +```hcl +data "tencentcloud_rum_scores" "scores" { + end_time = "2023082215" + start_time = "2023082214" + project_id = 1 + is_demo = 1 + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + rum "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumScores() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumScoresRead, + Schema: map[string]*schema.Schema{ + "end_time": { + Required: true, + Type: schema.TypeString, + Description: "End time.", + }, + + "start_time": { + Required: true, + Type: schema.TypeString, + Description: "Start time.", + }, + + "project_id": { + Optional: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "is_demo": { + Optional: true, + Type: schema.TypeInt, + Description: "Get data from demo. This parameter is deprecated.", + }, + + "score_set": { + Computed: true, + Type: schema.TypeList, + Description: "Score list.", + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "static_duration": { + Type: schema.TypeString, + Computed: true, + Description: "Duration.", + }, + "page_pv": { + Type: schema.TypeString, + Computed: true, + Description: "Pv.", + }, + "api_fail": { + Type: schema.TypeString, + Computed: true, + Description: "The number of failed api.", + }, + "api_num": { + Type: schema.TypeString, + Computed: true, + Description: "The number of all request api.", + }, + "static_fail": { + Type: schema.TypeString, + Computed: true, + Description: "The number of failed request static resource.", + }, + "project_id": { + Type: schema.TypeInt, + Computed: true, + Description: "Project ID.", + }, + "page_uv": { + Type: schema.TypeString, + Computed: true, + Description: "User view.", + }, + "api_duration": { + Type: schema.TypeString, + Computed: true, + Description: "The mean duration of api request.", + }, + "score": { + Type: schema.TypeString, + Computed: true, + Description: "The score of project.", + }, + "page_error": { + Type: schema.TypeString, + Computed: true, + Description: "The number of exception which happend on page.", + }, + "static_num": { + Type: schema.TypeString, + Computed: true, + Description: "The number of static resource on page.", + }, + "record_num": { + Type: schema.TypeInt, + Computed: true, + Description: "The number of record.", + }, + "page_duration": { + Type: schema.TypeString, + Computed: true, + Description: "The duration of page load.", + }, + "create_time": { + Type: schema.TypeString, + Computed: true, + Description: "Project record created time.", + }, + }, + }, + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumScoresRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_scores.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + paramMap := make(map[string]interface{}) + if v, ok := d.GetOk("end_time"); ok { + paramMap["EndTime"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("start_time"); ok { + paramMap["StartTime"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("is_demo"); v != nil { + paramMap["IsDemo"] = helper.IntInt64(v.(int)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var scoreSet []*rum.ScoreInfo + + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + result, e := service.DescribeRumScoresByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + scoreSet = result + return nil + }) + if err != nil { + return err + } + + ids := make([]string, 0, len(scoreSet)) + tmpList := make([]map[string]interface{}, 0, len(scoreSet)) + + if scoreSet != nil { + for _, scoreInfo := range scoreSet { + scoreInfoMap := map[string]interface{}{} + + if scoreInfo.StaticDuration != nil { + scoreInfoMap["static_duration"] = scoreInfo.StaticDuration + } + + if scoreInfo.PagePv != nil { + scoreInfoMap["page_pv"] = scoreInfo.PagePv + } + + if scoreInfo.ApiFail != nil { + scoreInfoMap["api_fail"] = scoreInfo.ApiFail + } + + if scoreInfo.ApiNum != nil { + scoreInfoMap["api_num"] = scoreInfo.ApiNum + } + + if scoreInfo.StaticFail != nil { + scoreInfoMap["static_fail"] = scoreInfo.StaticFail + } + + if scoreInfo.ProjectID != nil { + scoreInfoMap["project_id"] = scoreInfo.ProjectID + } + + if scoreInfo.PageUv != nil { + scoreInfoMap["page_uv"] = scoreInfo.PageUv + } + + if scoreInfo.ApiDuration != nil { + scoreInfoMap["api_duration"] = scoreInfo.ApiDuration + } + + if scoreInfo.Score != nil { + scoreInfoMap["score"] = scoreInfo.Score + } + + if scoreInfo.PageError != nil { + scoreInfoMap["page_error"] = scoreInfo.PageError + } + + if scoreInfo.StaticNum != nil { + scoreInfoMap["static_num"] = scoreInfo.StaticNum + } + + if scoreInfo.RecordNum != nil { + scoreInfoMap["record_num"] = scoreInfo.RecordNum + } + + if scoreInfo.PageDuration != nil { + scoreInfoMap["page_duration"] = scoreInfo.PageDuration + } + + if scoreInfo.CreateTime != nil { + scoreInfoMap["create_time"] = scoreInfo.CreateTime + } + + ids = append(ids, strconv.FormatInt(*scoreInfo.ProjectID, 10)) + tmpList = append(tmpList, scoreInfoMap) + } + + _ = d.Set("score_set", tmpList) + } + + d.SetId(helper.DataResourceIdsHash(ids)) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), tmpList); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_scores_test.go b/tencentcloud/data_source_tc_rum_scores_test.go new file mode 100644 index 0000000000..23bafefe10 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_scores_test.go @@ -0,0 +1,34 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumScoresDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumScoresDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_scores.scores")), + }, + }, + }) +} + +const testAccRumScoresDataSource = ` + +data "tencentcloud_rum_scores" "scores" { + end_time = "2023082215" + start_time = "2023082214" + i_d = 1 + is_demo = 1 + } + +` diff --git a/tencentcloud/data_source_tc_rum_set_url_statistics.go b/tencentcloud/data_source_tc_rum_set_url_statistics.go new file mode 100644 index 0000000000..2a8c1175dc --- /dev/null +++ b/tencentcloud/data_source_tc_rum_set_url_statistics.go @@ -0,0 +1,339 @@ +/* +Use this data source to query detailed information of rum set_url_statistics + +Example Usage + +```hcl +data "tencentcloud_rum_set_url_statistics" "set_url_statistics" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + env = "production" + package_type = "loadPackage" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumSetUrlStatistics() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumSetUrlStatisticsRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Data Type. `allcount`:CostType allcount, `data`: CostType group by data, `component`:miniProgram component, `day`:query data in day, `nettype`:query data group by nettype, `performance`:query data group by performance, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "cost_type": { + Optional: true, + Type: schema.TypeString, + Description: "The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "package_type": { + Optional: true, + Type: schema.TypeString, + Description: "Package Type.", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumSetUrlStatisticsRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_set_url_statistics.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("cost_type"); ok { + paramMap["CostType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("package_type"); ok { + paramMap["PackageType"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumSetUrlStatisticsByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_set_url_statistics_test.go b/tencentcloud/data_source_tc_rum_set_url_statistics_test.go new file mode 100644 index 0000000000..d7b4850cad --- /dev/null +++ b/tencentcloud/data_source_tc_rum_set_url_statistics_test.go @@ -0,0 +1,53 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumSetUrlStatisticsDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumSetUrlStatisticsDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_set_url_statistics.set_url_statistics")), + }, + }, + }) +} + +const testAccRumSetUrlStatisticsDataSource = ` + +data "tencentcloud_rum_set_url_statistics" "set_url_statistics" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + env = "production" + package_type = "loadPackage" + } + +` diff --git a/tencentcloud/data_source_tc_rum_sign.go b/tencentcloud/data_source_tc_rum_sign.go new file mode 100644 index 0000000000..cfae8d1509 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_sign.go @@ -0,0 +1,143 @@ +/* +Use this data source to query detailed information of rum sign + +Example Usage + +```hcl +data "tencentcloud_rum_sign" "sign" { + timeout = 1800 + file_type = web + } +``` +*/ +package tencentcloud + +import ( + "context" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + rum "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumSign() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumSignRead, + Schema: map[string]*schema.Schema{ + "timeout": { + Optional: true, + Type: schema.TypeInt, + Description: "Timeout duration.", + }, + + "file_type": { + Optional: true, + Type: schema.TypeInt, + Description: "Bucket type. `web`:web project; `app`:app project.", + }, + + "secret_key": { + Computed: true, + Type: schema.TypeString, + Description: "Temporary access key.", + }, + + "secret_id": { + Computed: true, + Type: schema.TypeString, + Description: "Temporary access key ID.", + }, + + "session_token": { + Computed: true, + Type: schema.TypeString, + Description: "Temporary access key token.", + }, + + "start_time": { + Computed: true, + Type: schema.TypeInt, + Description: "Start timestamp.", + }, + + "expired_time": { + Computed: true, + Type: schema.TypeInt, + Description: "Expiration timestamp.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumSignRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_sign.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("timeout"); v != nil { + paramMap["Timeout"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("file_type"); v != nil { + paramMap["FileType"] = helper.IntInt64(v.(int)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *rum.DescribeReleaseFileSignResponseParams + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumSignByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var token string + if result != nil { + if result.SecretKey != nil { + _ = d.Set("secret_key", result.SecretKey) + } + + if result.SecretID != nil { + _ = d.Set("secret_id", result.SecretID) + } + + if result.SessionToken != nil { + token = *result.SessionToken + _ = d.Set("session_token", result.SessionToken) + } + + if result.StartTime != nil { + _ = d.Set("start_time", result.StartTime) + } + + if result.ExpiredTime != nil { + _ = d.Set("expired_time", result.ExpiredTime) + } + } + + d.SetId(helper.DataResourceIdsHash([]string{token})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_sign_test.go b/tencentcloud/data_source_tc_rum_sign_test.go new file mode 100644 index 0000000000..bd4905425f --- /dev/null +++ b/tencentcloud/data_source_tc_rum_sign_test.go @@ -0,0 +1,32 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumSignDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumSignDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_sign.sign")), + }, + }, + }) +} + +const testAccRumSignDataSource = ` + +data "tencentcloud_rum_sign" "sign" { + timeout = 1800 + file_type = web + } + +` diff --git a/tencentcloud/data_source_tc_rum_static_project.go b/tencentcloud/data_source_tc_rum_static_project.go new file mode 100644 index 0000000000..92fb95a50e --- /dev/null +++ b/tencentcloud/data_source_tc_rum_static_project.go @@ -0,0 +1,345 @@ +/* +Use this data source to query detailed information of rum static_project + +Example Usage + +```hcl +data "tencentcloud_rum_static_project" "static_project" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumStaticProject() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumStaticProjectRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Data Type. `allcount`: CostType allcount, `day`: CostType group by day, `condition`: CostType Sorting in condition, `area`: CostType query in area, `nettype`: CostType sort by nettype, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "cost_type": { + Optional: true, + Type: schema.TypeString, + Description: "The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean.", + }, + + "url": { + Optional: true, + Type: schema.TypeString, + Description: "The URL Key where the data reporting takes place.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumStaticProjectRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_static_project.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("cost_type"); ok { + paramMap["CostType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("url"); ok { + urlSet := v.(*schema.Set).List() + urlList := make([]*string, 0) + for i := range urlSet { + url := urlSet[i].(string) + urlList = append(urlList, helper.String(url)) + } + paramMap["Url"] = urlList + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumStaticProjectByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_static_project_test.go b/tencentcloud/data_source_tc_rum_static_project_test.go new file mode 100644 index 0000000000..b1ade6754f --- /dev/null +++ b/tencentcloud/data_source_tc_rum_static_project_test.go @@ -0,0 +1,53 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumStaticProjectDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumStaticProjectDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_static_project.static_project")), + }, + }, + }) +} + +const testAccRumStaticProjectDataSource = ` + +data "tencentcloud_rum_static_project" "static_project" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + } + +` diff --git a/tencentcloud/data_source_tc_rum_static_resource.go b/tencentcloud/data_source_tc_rum_static_resource.go new file mode 100644 index 0000000000..27641a7b95 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_static_resource.go @@ -0,0 +1,339 @@ +/* +Use this data source to query detailed information of rum static_resource + +Example Usage + +```hcl +data "tencentcloud_rum_static_resource" "static_resource" { + start_time = 1625444040 + type = "top" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumStaticResource() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumStaticResourceRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Data Type. `top`: CostType Sorting order by top, `count40x`: CostType Sorting order by statusCode(40x) count, `nettype`: CostType Sorting order by nettype, `allcount`: CostType allcount, `day`: CostType group by day, `condition`: CostType Sorting in condition, `pagepv`: CostType Sorting order by pagepv, `area`: CostType query in area, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "cost_type": { + Optional: true, + Type: schema.TypeString, + Description: "The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean.", + }, + + "url": { + Optional: true, + Type: schema.TypeString, + Description: "The URL Key where the data reporting takes place.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumStaticResourceRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_static_resource.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("cost_type"); ok { + paramMap["CostType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("url"); ok { + paramMap["Url"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumStaticResourceByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_static_resource_test.go b/tencentcloud/data_source_tc_rum_static_resource_test.go new file mode 100644 index 0000000000..985a703d21 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_static_resource_test.go @@ -0,0 +1,53 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumStaticResourceDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumStaticResourceDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_static_resource.static_resource")), + }, + }, + }) +} + +const testAccRumStaticResourceDataSource = ` + +data "tencentcloud_rum_static_resource" "static_resource" { + start_time = 1625444040 + type = "top" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + } + +` diff --git a/tencentcloud/data_source_tc_rum_static_url.go b/tencentcloud/data_source_tc_rum_static_url.go new file mode 100644 index 0000000000..e74bf84fa5 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_static_url.go @@ -0,0 +1,339 @@ +/* +Use this data source to query detailed information of rum static_url + +Example Usage + +```hcl +data "tencentcloud_rum_static_url" "static_url" { + start_time = 1625444040 + type = "pagepv" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumStaticUrl() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumStaticUrlRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "type": { + Required: true, + Type: schema.TypeString, + Description: "Query Data Type. `pagepv`: CostType query by pagepv, `nettype`: CostType group by nettype, `version`: CostType group by version, `platform`: CostType group by platform, `isp`: CostType group by isp, `region`: CostType group by region, `device`: CostType group by device, `browser`: CostType group by browser, `ext1`: CostType group by ext1, `ext2`: CostType group by ext2, `ext3`: CostType group by ext3, `ret`: CostType group by ret, `status`: CostType group by status, `from`: CostType group by from, `url`: CostType group by url, `env`: CostType group by env.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "cost_type": { + Optional: true, + Type: schema.TypeString, + Description: "The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean.", + }, + + "url": { + Optional: true, + Type: schema.TypeString, + Description: "The URL Key where the data reporting takes place.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumStaticUrlRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_static_url.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("cost_type"); ok { + paramMap["CostType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("url"); ok { + paramMap["Url"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumStaticUrlByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_static_url_test.go b/tencentcloud/data_source_tc_rum_static_url_test.go new file mode 100644 index 0000000000..1e0eadd632 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_static_url_test.go @@ -0,0 +1,53 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumStaticUrlDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumStaticUrlDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_static_url.static_url")), + }, + }, + }) +} + +const testAccRumStaticUrlDataSource = ` + +data "tencentcloud_rum_static_url" "static_url" { + start_time = 1625444040 + type = "pagepv" + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + } + +` diff --git a/tencentcloud/data_source_tc_rum_taw_area.go b/tencentcloud/data_source_tc_rum_taw_area.go new file mode 100644 index 0000000000..c950da4b9c --- /dev/null +++ b/tencentcloud/data_source_tc_rum_taw_area.go @@ -0,0 +1,210 @@ +/* +Use this data source to query detailed information of rum taw_area + +Example Usage + +```hcl +data "tencentcloud_rum_taw_area" "taw_area" { + area_ids = + area_keys = + area_statuses = + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + rum "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumTawArea() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumTawAreaRead, + Schema: map[string]*schema.Schema{ + "area_ids": { + Optional: true, + Type: schema.TypeSet, + Elem: &schema.Schema{ + Type: schema.TypeInt, + }, + Description: "Area id.", + }, + + "area_keys": { + Optional: true, + Type: schema.TypeSet, + Elem: &schema.Schema{ + Type: schema.TypeString, + }, + Description: "Area key.", + }, + + "area_statuses": { + Optional: true, + Type: schema.TypeSet, + Elem: &schema.Schema{ + Type: schema.TypeInt, + }, + Description: "Area status `1`:valid; `2`:invalid.", + }, + + "area_set": { + Computed: true, + Type: schema.TypeList, + Description: "Area list.", + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "area_id": { + Type: schema.TypeInt, + Computed: true, + Description: "Area id.", + }, + "area_status": { + Type: schema.TypeInt, + Computed: true, + Description: "Area status `1`:&#39;valid&#39;; `2`:&#39;invalid&#39;.", + }, + "area_name": { + Type: schema.TypeString, + Computed: true, + Description: "Area name.", + }, + "area_key": { + Type: schema.TypeString, + Computed: true, + Description: "Area key.", + }, + "area_region_id": { + Type: schema.TypeString, + Computed: true, + Description: "Area code id.", + }, + "area_region_code": { + Type: schema.TypeString, + Computed: true, + Description: "Area code.", + }, + "area_abbr": { + Type: schema.TypeString, + Computed: true, + Description: "Region abbreviation.", + }, + }, + }, + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumTawAreaRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_taw_area.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + paramMap := make(map[string]interface{}) + if v, ok := d.GetOk("area_ids"); ok { + areaIdsSet := v.(*schema.Set).List() + areaList := make([]*int64, 0) + for i := range areaIdsSet { + areaIds := areaIdsSet[i].(int) + areaList = append(areaList, helper.IntInt64(areaIds)) + } + paramMap["AreaIds"] = areaList + } + + if v, ok := d.GetOk("area_keys"); ok { + areaKeysSet := v.(*schema.Set).List() + paramMap["AreaKeys"] = helper.InterfacesStringsPoint(areaKeysSet) + } + + if v, ok := d.GetOk("area_statuses"); ok { + areaStatusesSet := v.(*schema.Set).List() + areaList := make([]*int64, 0) + for i := range areaStatusesSet { + areaStatuses := areaStatusesSet[i].(int) + areaList = append(areaList, helper.IntInt64(areaStatuses)) + } + paramMap["AreaStatuses"] = areaList + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var areaSet []*rum.RumAreaInfo + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + result, e := service.DescribeRumTawAreaByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + areaSet = result + return nil + }) + if err != nil { + return err + } + + ids := make([]string, 0, len(areaSet)) + tmpList := make([]map[string]interface{}, 0, len(areaSet)) + + if areaSet != nil { + for _, rumAreaInfo := range areaSet { + rumAreaInfoMap := map[string]interface{}{} + + if rumAreaInfo.AreaId != nil { + rumAreaInfoMap["area_id"] = rumAreaInfo.AreaId + } + + if rumAreaInfo.AreaStatus != nil { + rumAreaInfoMap["area_status"] = rumAreaInfo.AreaStatus + } + + if rumAreaInfo.AreaName != nil { + rumAreaInfoMap["area_name"] = rumAreaInfo.AreaName + } + + if rumAreaInfo.AreaKey != nil { + rumAreaInfoMap["area_key"] = rumAreaInfo.AreaKey + } + + if rumAreaInfo.AreaRegionID != nil { + rumAreaInfoMap["area_region_id"] = rumAreaInfo.AreaRegionID + } + + if rumAreaInfo.AreaRegionCode != nil { + rumAreaInfoMap["area_region_code"] = rumAreaInfo.AreaRegionCode + } + + if rumAreaInfo.AreaAbbr != nil { + rumAreaInfoMap["area_abbr"] = rumAreaInfo.AreaAbbr + } + + ids = append(ids, strconv.FormatInt(*rumAreaInfo.AreaId, 10)) + tmpList = append(tmpList, rumAreaInfoMap) + } + + _ = d.Set("area_set", tmpList) + } + + d.SetId(helper.DataResourceIdsHash(ids)) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), tmpList); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_taw_area_test.go b/tencentcloud/data_source_tc_rum_taw_area_test.go new file mode 100644 index 0000000000..ce093673b8 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_taw_area_test.go @@ -0,0 +1,33 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumTawAreaDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumTawAreaDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_taw_area.taw_area")), + }, + }, + }) +} + +const testAccRumTawAreaDataSource = ` + +data "tencentcloud_rum_taw_area" "taw_area" { + area_ids = + area_keys = + area_statuses = + } + +` diff --git a/tencentcloud/data_source_tc_rum_web_vitals_page.go b/tencentcloud/data_source_tc_rum_web_vitals_page.go new file mode 100644 index 0000000000..b9d32d485f --- /dev/null +++ b/tencentcloud/data_source_tc_rum_web_vitals_page.go @@ -0,0 +1,328 @@ +/* +Use this data source to query detailed information of rum web_vitals_page + +Example Usage + +```hcl +data "tencentcloud_rum_web_vitals_page" "web_vitals_page" { + start_time = 1625444040 + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + type = "from" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + env = "production" + } +``` +*/ +package tencentcloud + +import ( + "context" + "strconv" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" + "github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper" +) + +func dataSourceTencentCloudRumWebVitalsPage() *schema.Resource { + return &schema.Resource{ + Read: dataSourceTencentCloudRumWebVitalsPageRead, + Schema: map[string]*schema.Schema{ + "start_time": { + Required: true, + Type: schema.TypeInt, + Description: "Start time but is represented using a timestamp in seconds.", + }, + + "end_time": { + Required: true, + Type: schema.TypeInt, + Description: "End time but is represented using a timestamp in seconds.", + }, + + "project_id": { + Required: true, + Type: schema.TypeInt, + Description: "Project ID.", + }, + + "ext_second": { + Optional: true, + Type: schema.TypeString, + Description: "Second Expansion parameter.", + }, + + "engine": { + Optional: true, + Type: schema.TypeString, + Description: "The browser engine used for data reporting.", + }, + + "isp": { + Optional: true, + Type: schema.TypeString, + Description: "The internet service provider used for data reporting.", + }, + + "from": { + Optional: true, + Type: schema.TypeString, + Description: "The source page of the data reporting.", + }, + + "level": { + Optional: true, + Type: schema.TypeString, + Description: "Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log).", + }, + + "type": { + Optional: true, + Type: schema.TypeString, + Description: "Query Data Type(from or empty). `from`: CostType query by from.", + }, + + "brand": { + Optional: true, + Type: schema.TypeString, + Description: "The mobile phone brand used for data reporting.", + }, + + "area": { + Optional: true, + Type: schema.TypeString, + Description: "The region where the data reporting takes place.", + }, + + "version_num": { + Optional: true, + Type: schema.TypeString, + Description: "The SDK version used for data reporting.", + }, + + "platform": { + Optional: true, + Type: schema.TypeString, + Description: "The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other).", + }, + + "ext_third": { + Optional: true, + Type: schema.TypeString, + Description: "Third Expansion parameter.", + }, + + "ext_first": { + Optional: true, + Type: schema.TypeString, + Description: "First Expansion parameter.", + }, + + "net_type": { + Optional: true, + Type: schema.TypeString, + Description: "The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown).", + }, + + "device": { + Optional: true, + Type: schema.TypeString, + Description: "The device used for data reporting.", + }, + + "is_abroad": { + Optional: true, + Type: schema.TypeString, + Description: "Whether it is non-China region.`1`: yes; `0`: no.", + }, + + "os": { + Optional: true, + Type: schema.TypeString, + Description: "The operating system used for data reporting.", + }, + + "browser": { + Optional: true, + Type: schema.TypeString, + Description: "The browser type used for data reporting.", + }, + + "cost_type": { + Optional: true, + Type: schema.TypeString, + Description: "The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean.", + }, + + "env": { + Optional: true, + Type: schema.TypeString, + Description: "The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env).", + }, + + "result": { + Computed: true, + Type: schema.TypeString, + Description: "Return value.", + }, + + "result_output_file": { + Type: schema.TypeString, + Optional: true, + Description: "Used to save results.", + }, + }, + } +} + +func dataSourceTencentCloudRumWebVitalsPageRead(d *schema.ResourceData, meta interface{}) error { + defer logElapsed("data_source.tencentcloud_rum_web_vitals_page.read")() + defer inconsistentCheck(d, meta)() + + logId := getLogId(contextNil) + + ctx := context.WithValue(context.TODO(), logIdKey, logId) + + var ( + startTime int + endTime int + ) + + paramMap := make(map[string]interface{}) + if v, _ := d.GetOk("start_time"); v != nil { + startTime = v.(int) + paramMap["StartTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("end_time"); v != nil { + endTime = v.(int) + paramMap["EndTime"] = helper.IntInt64(v.(int)) + } + + if v, _ := d.GetOk("project_id"); v != nil { + paramMap["ID"] = helper.IntInt64(v.(int)) + } + + if v, ok := d.GetOk("ext_second"); ok { + paramMap["ExtSecond"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("engine"); ok { + paramMap["Engine"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("isp"); ok { + paramMap["Isp"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("from"); ok { + paramMap["From"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("level"); ok { + paramMap["Level"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("type"); ok { + paramMap["Type"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("brand"); ok { + paramMap["Brand"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("area"); ok { + paramMap["Area"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("version_num"); ok { + paramMap["VersionNum"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("platform"); ok { + paramMap["Platform"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_third"); ok { + paramMap["ExtThird"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("ext_first"); ok { + paramMap["ExtFirst"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("net_type"); ok { + paramMap["NetType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("device"); ok { + paramMap["Device"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("is_abroad"); ok { + paramMap["IsAbroad"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("os"); ok { + paramMap["Os"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("browser"); ok { + paramMap["Browser"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("cost_type"); ok { + paramMap["CostType"] = helper.String(v.(string)) + } + + if v, ok := d.GetOk("env"); ok { + paramMap["Env"] = helper.String(v.(string)) + } + + service := RumService{client: meta.(*TencentCloudClient).apiV3Conn} + + var result *string + err := resource.Retry(readRetryTimeout, func() *resource.RetryError { + response, e := service.DescribeRumWebVitalsPageByFilter(ctx, paramMap) + if e != nil { + return retryError(e) + } + result = response + return nil + }) + if err != nil { + return err + } + + var ids string + if result != nil { + ids = *result + _ = d.Set("result", result) + } + + d.SetId(helper.DataResourceIdsHash([]string{strconv.Itoa(startTime), strconv.Itoa(endTime), ids})) + output, ok := d.GetOk("result_output_file") + if ok && output.(string) != "" { + if e := writeToFile(output.(string), result); e != nil { + return e + } + } + return nil +} diff --git a/tencentcloud/data_source_tc_rum_web_vitals_page_test.go b/tencentcloud/data_source_tc_rum_web_vitals_page_test.go new file mode 100644 index 0000000000..149a622357 --- /dev/null +++ b/tencentcloud/data_source_tc_rum_web_vitals_page_test.go @@ -0,0 +1,52 @@ +package tencentcloud + +import ( + "testing" + + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" +) + +func TestAccTencentCloudRumWebVitalsPageDataSource_basic(t *testing.T) { + t.Parallel() + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccRumWebVitalsPageDataSource, + Check: resource.ComposeTestCheckFunc(testAccCheckTencentCloudDataSourceID("data.tencentcloud_rum_web_vitals_page.web_vitals_page")), + }, + }, + }) +} + +const testAccRumWebVitalsPageDataSource = ` + +data "tencentcloud_rum_web_vitals_page" "web_vitals_page" { + start_time = 1625444040 + end_time = 1625454840 + i_d = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + type = "from" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + env = "production" + } + +` diff --git a/tencentcloud/provider.go b/tencentcloud/provider.go index 0d35ebac6c..653712666a 100644 --- a/tencentcloud/provider.go +++ b/tencentcloud/provider.go @@ -1358,6 +1358,26 @@ Real User Monitoring(RUM) tencentcloud_rum_offline_log_config tencentcloud_rum_whitelist tencentcloud_rum_taw_instance + tencentcloud_rum_custom_url + tencentcloud_rum_event_url + tencentcloud_rum_fetch_url_info + tencentcloud_rum_fetch_url + tencentcloud_rum_group_log + tencentcloud_rum_log_list + tencentcloud_rum_log_url_statistics + tencentcloud_rum_performance_page + tencentcloud_rum_pv_url_info + tencentcloud_rum_pv_url_statistics + tencentcloud_rum_report_count + tencentcloud_rum_rum_log_stats_log_list + tencentcloud_rum_scores + tencentcloud_rum_set_url_statistics + tencentcloud_rum_sign + tencentcloud_rum_static_project + tencentcloud_rum_static_resource + tencentcloud_rum_static_url + tencentcloud_rum_taw_area + tencentcloud_rum_web_vitals_page Resource tencentcloud_rum_project tencentcloud_rum_taw_instance @@ -2314,6 +2334,28 @@ func Provider() *schema.Provider { "tencentcloud_rum_offline_log_config": dataSourceTencentCloudRumOfflineLogConfig(), "tencentcloud_rum_whitelist": dataSourceTencentCloudRumWhitelist(), "tencentcloud_rum_taw_instance": dataSourceTencentCloudRumTawInstance(), + "tencentcloud_rum_custom_url": dataSourceTencentCloudRumCustomUrl(), + "tencentcloud_rum_event_url": dataSourceTencentCloudRumEventUrl(), + "tencentcloud_rum_fetch_url_info": dataSourceTencentCloudRumFetchUrlInfo(), + "tencentcloud_rum_fetch_url": dataSourceTencentCloudRumFetchUrl(), + "tencentcloud_rum_group_log": dataSourceTencentCloudRumGroupLog(), + "tencentcloud_rum_log_list": dataSourceTencentCloudRumLogList(), + "tencentcloud_rum_log_url_statistics": dataSourceTencentCloudRumLogUrlStatistics(), + "tencentcloud_rum_performance_page": dataSourceTencentCloudRumPerformancePage(), + "tencentcloud_rum_pv_url_info": dataSourceTencentCloudRumPvUrlInfo(), + "tencentcloud_rum_pv_url_statistics": dataSourceTencentCloudRumPvUrlStatistics(), + "tencentcloud_rum_report_count": dataSourceTencentCloudRumReportCount(), + "tencentcloud_rum_rum_log_stats_log_list": dataSourceTencentCloudRumRumLogStatsLogList(), + "tencentcloud_rum_scores": dataSourceTencentCloudRumScores(), + "tencentcloud_rum_set_url_statistics": dataSourceTencentCloudRumSetUrlStatistics(), + "tencentcloud_rum_sign": dataSourceTencentCloudRumSign(), + "tencentcloud_rum_static_project": dataSourceTencentCloudRumStaticProject(), + "tencentcloud_rum_static_resource": dataSourceTencentCloudRumStaticResource(), + "tencentcloud_rum_static_url": dataSourceTencentCloudRumStaticUrl(), + "tencentcloud_rum_taw_area": dataSourceTencentCloudRumTawArea(), + "tencentcloud_rum_web_vitals_page": dataSourceTencentCloudRumWebVitalsPage(), + "tencentcloud_rum_log_export": dataSourceTencentCloudRumLogExport(), + "tencentcloud_rum_log_export_list": dataSourceTencentCloudRumLogExportList(), "tencentcloud_dnspod_records": dataSourceTencentCloudDnspodRecords(), "tencentcloud_tat_command": dataSourceTencentCloudTatCommand(), "tencentcloud_tat_invoker": dataSourceTencentCloudTatInvoker(), diff --git a/tencentcloud/service_tencentcloud_rum.go b/tencentcloud/service_tencentcloud_rum.go index 026f298919..9bebb779b2 100644 --- a/tencentcloud/service_tencentcloud_rum.go +++ b/tencentcloud/service_tencentcloud_rum.go @@ -482,3 +482,1655 @@ func (me *RumService) DescribeRumTawInstanceByFilter(ctx context.Context, param } return } + +func (me *RumService) DescribeRumCustomUrlByFilter(ctx context.Context, param map[string]interface{}) (customUrl *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataCustomUrlRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "CostType" { + request.CostType = v.(*string) + } + if k == "Url" { + request.Url = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataCustomUrl(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + customUrl = response.Response.Result + + return +} + +func (me *RumService) DescribeRumSetUrlStatisticsByFilter(ctx context.Context, param map[string]interface{}) (setUrlStatistics *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataSetUrlStatisticsRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "CostType" { + request.CostType = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + if k == "PackageType" { + request.PackageType = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataSetUrlStatistics(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + setUrlStatistics = response.Response.Result + + return +} + +func (me *RumService) DescribeRumEventUrlByFilter(ctx context.Context, param map[string]interface{}) (eventUrl *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataEventUrlRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "Name" { + request.Name = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + + response, err := me.client.UseRumClient().DescribeDataEventUrl(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + eventUrl = response.Response.Result + + return +} + +func (me *RumService) DescribeRumFetchUrlByFilter(ctx context.Context, param map[string]interface{}) (fetchUrl *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataFetchUrlRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "CostType" { + request.CostType = v.(*string) + } + if k == "Url" { + request.Url = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + if k == "Status" { + request.Status = v.(*string) + } + if k == "Ret" { + request.Ret = v.(*string) + } + if k == "NetStatus" { + request.NetStatus = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataFetchUrl(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + fetchUrl = response.Response.Result + + return +} +func (me *RumService) DescribeRumFetchUrlInfoByFilter(ctx context.Context, param map[string]interface{}) (fetchUrlInfo *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataFetchUrlInfoRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "CostType" { + request.CostType = v.(*string) + } + if k == "Url" { + request.Url = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataFetchUrlInfo(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + fetchUrlInfo = response.Response.Result + + return +} +func (me *RumService) DescribeRumLogUrlInfoByFilter(ctx context.Context, param map[string]interface{}) (logUrlInfo *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataLogUrlInfoRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "ID" { + request.ID = v.(*int64) + } + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataLogUrlInfo(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + logUrlInfo = response.Response.Result + + return +} +func (me *RumService) DescribeRumLogUrlStatisticsByFilter(ctx context.Context, param map[string]interface{}) (logUrlStatistics *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataLogUrlStatisticsRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataLogUrlStatistics(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + logUrlStatistics = response.Response.Result + + return +} +func (me *RumService) DescribeRumPerformancePageByFilter(ctx context.Context, param map[string]interface{}) (performancePage *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataPerformancePageRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "ID" { + request.ID = v.(*int64) + } + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "CostType" { + request.CostType = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + if k == "NetStatus" { + request.NetStatus = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataPerformancePage(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + performancePage = response.Response.Result + + return +} +func (me *RumService) DescribeRumPvUrlInfoByFilter(ctx context.Context, param map[string]interface{}) (pvUrlInfo *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataPvUrlInfoRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataPvUrlInfo(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + pvUrlInfo = response.Response.Result + + return +} +func (me *RumService) DescribeRumPvUrlStatisticsByFilter(ctx context.Context, param map[string]interface{}) (pvUrlStatistics *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataPvUrlStatisticsRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + if k == "GroupByType" { + request.GroupByType = v.(*int64) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataPvUrlStatistics(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + pvUrlStatistics = response.Response.Result + + return +} +func (me *RumService) DescribeRumReportCountByFilter(ctx context.Context, param map[string]interface{}) (reportCount *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataReportCountRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ReportType" { + request.ReportType = v.(*string) + } + if k == "InstanceID" { + request.InstanceID = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataReportCount(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + reportCount = response.Response.Result + + return +} + +func (me *RumService) DescribeRumStaticProjectByFilter(ctx context.Context, param map[string]interface{}) (staticProject *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataStaticProjectRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "CostType" { + request.CostType = v.(*string) + } + if k == "Url" { + request.Url = v.([]*string) + } + if k == "Env" { + request.Env = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataStaticProject(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + staticProject = response.Response.Result + + return +} +func (me *RumService) DescribeRumStaticResourceByFilter(ctx context.Context, param map[string]interface{}) (staticResource *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataStaticResourceRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "CostType" { + request.CostType = v.(*string) + } + if k == "Url" { + request.Url = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataStaticResource(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + staticResource = response.Response.Result + + return +} +func (me *RumService) DescribeRumStaticUrlByFilter(ctx context.Context, param map[string]interface{}) (staticUrl *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataStaticUrlRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "CostType" { + request.CostType = v.(*string) + } + if k == "Url" { + request.Url = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataStaticUrl(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + staticUrl = response.Response.Result + + return +} +func (me *RumService) DescribeRumWebVitalsPageByFilter(ctx context.Context, param map[string]interface{}) (webVitalsPage *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeDataWebVitalsPageRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*int64) + } + if k == "EndTime" { + request.EndTime = v.(*int64) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "ExtSecond" { + request.ExtSecond = v.(*string) + } + if k == "Engine" { + request.Engine = v.(*string) + } + if k == "Isp" { + request.Isp = v.(*string) + } + if k == "From" { + request.From = v.(*string) + } + if k == "Level" { + request.Level = v.(*string) + } + if k == "Type" { + request.Type = v.(*string) + } + if k == "Brand" { + request.Brand = v.(*string) + } + if k == "Area" { + request.Area = v.(*string) + } + if k == "VersionNum" { + request.VersionNum = v.(*string) + } + if k == "Platform" { + request.Platform = v.(*string) + } + if k == "ExtThird" { + request.ExtThird = v.(*string) + } + if k == "ExtFirst" { + request.ExtFirst = v.(*string) + } + if k == "NetType" { + request.NetType = v.(*string) + } + if k == "Device" { + request.Device = v.(*string) + } + if k == "IsAbroad" { + request.IsAbroad = v.(*string) + } + if k == "Os" { + request.Os = v.(*string) + } + if k == "Browser" { + request.Browser = v.(*string) + } + if k == "CostType" { + request.CostType = v.(*string) + } + if k == "Env" { + request.Env = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeDataWebVitalsPage(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + webVitalsPage = response.Response.Result + + return +} + +func (me *RumService) DescribeRumGroupLogByFilter(ctx context.Context, param map[string]interface{}) (groupLog *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeRumGroupLogRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "OrderBy" { + request.OrderBy = v.(*string) + } + if k == "StartTime" { + request.StartTime = v.(*string) + } + if k == "Query" { + request.Query = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*string) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "GroupField" { + request.GroupField = v.(*string) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeRumGroupLog(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + groupLog = response.Response.Result + + return +} + +func (me *RumService) DescribeRumLogListByFilter(ctx context.Context, param map[string]interface{}) (logList *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeRumLogListRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "OrderBy" { + request.OrderBy = v.(*string) + } + if k == "StartTime" { + request.StartTime = v.(*string) + } + if k == "Query" { + request.Query = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*string) + } + if k == "ID" { + request.ID = v.(*int64) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeRumLogList(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + logList = response.Response.Result + + return +} +func (me *RumService) DescribeRumRumLogStatsLogListByFilter(ctx context.Context, param map[string]interface{}) (rumLogStatsLogList *string, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeRumStatsLogListRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "StartTime" { + request.StartTime = v.(*string) + } + if k == "Query" { + request.Query = v.(*string) + } + if k == "EndTime" { + request.EndTime = v.(*string) + } + if k == "ID" { + request.ID = v.(*int64) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeRumStatsLogList(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || response.Response == nil { + return + } + + rumLogStatsLogList = response.Response.Result + + return +} +func (me *RumService) DescribeRumSignByFilter(ctx context.Context, param map[string]interface{}) (sign *rum.DescribeReleaseFileSignResponseParams, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeReleaseFileSignRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "Timeout" { + request.Timeout = v.(*int64) + } + if k == "FileType" { + request.FileType = v.(*int64) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeReleaseFileSign(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil { + return + } + + sign = response.Response + + return +} +func (me *RumService) DescribeRumScoresByFilter(ctx context.Context, param map[string]interface{}) (scores []*rum.ScoreInfo, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeScoresRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "EndTime" { + request.EndTime = v.(*string) + } + if k == "StartTime" { + request.StartTime = v.(*string) + } + if k == "ID" { + request.ID = v.(*int64) + } + if k == "IsDemo" { + request.IsDemo = v.(*int64) + } + } + + ratelimit.Check(request.GetAction()) + response, err := me.client.UseRumClient().DescribeScores(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || len(response.Response.ScoreSet) < 1 { + return + } + + scores = response.Response.ScoreSet + + return +} + +func (me *RumService) DescribeRumTawAreaByFilter(ctx context.Context, param map[string]interface{}) (tawArea []*rum.RumAreaInfo, errRet error) { + var ( + logId = getLogId(ctx) + request = rum.NewDescribeTawAreasRequest() + ) + + defer func() { + if errRet != nil { + log.Printf("[CRITAL]%s api[%s] fail, request body [%s], reason[%s]\n", logId, request.GetAction(), request.ToJsonString(), errRet.Error()) + } + }() + + for k, v := range param { + if k == "AreaIds" { + } + if k == "AreaKeys" { + request.AreaKeys = v.([]*string) + } + if k == "AreaStatuses" { + } + } + + ratelimit.Check(request.GetAction()) + + var ( + offset int64 = 0 + limit int64 = 20 + ) + for { + request.Offset = &offset + request.Limit = &limit + response, err := me.client.UseRumClient().DescribeTawAreas(request) + if err != nil { + errRet = err + return + } + log.Printf("[DEBUG]%s api[%s] success, request body [%s], response body [%s]\n", logId, request.GetAction(), request.ToJsonString(), response.ToJsonString()) + + if response == nil || len(response.Response.AreaSet) < 1 { + break + } + tawArea = append(tawArea, response.Response.AreaSet...) + if len(response.Response.AreaSet) < int(limit) { + break + } + + offset += limit + } + + return +} diff --git a/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/client.go b/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/client.go index 7a9bf471eb..e3853473a4 100644 --- a/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/client.go +++ b/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/client.go @@ -180,7 +180,7 @@ func NewCreateProjectResponse() (response *CreateProjectResponse) { } // CreateProject -// 创建项目(归属于某个团队) +// 创建 RUM 应用(归属于某个团队) // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -197,7 +197,7 @@ func (c *Client) CreateProject(request *CreateProjectRequest) (response *CreateP } // CreateProject -// 创建项目(归属于某个团队) +// 创建 RUM 应用(归属于某个团队) // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -418,11 +418,15 @@ func NewCreateTawInstanceResponse() (response *CreateTawInstanceResponse) { } // CreateTawInstance -// 创建Rum实例 +// 创建 RUM 业务系统 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" // FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CHARGENOBALANCE = "FailedOperation.ChargeNoBalance" +// FAILEDOPERATION_CHARGENOPAYRIGHT = "FailedOperation.ChargeNoPayRight" +// FAILEDOPERATION_CHARGEPARAMINVALID = "FailedOperation.ChargeParamInvalid" +// FAILEDOPERATION_INFRASTRUCTUREERROR = "FailedOperation.InfrastructureError" // INTERNALERROR = "InternalError" // INVALIDPARAMETER = "InvalidParameter" // RESOURCENOTFOUND = "ResourceNotFound" @@ -431,11 +435,15 @@ func (c *Client) CreateTawInstance(request *CreateTawInstanceRequest) (response } // CreateTawInstance -// 创建Rum实例 +// 创建 RUM 业务系统 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" // FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CHARGENOBALANCE = "FailedOperation.ChargeNoBalance" +// FAILEDOPERATION_CHARGENOPAYRIGHT = "FailedOperation.ChargeNoPayRight" +// FAILEDOPERATION_CHARGEPARAMINVALID = "FailedOperation.ChargeParamInvalid" +// FAILEDOPERATION_INFRASTRUCTUREERROR = "FailedOperation.InfrastructureError" // INTERNALERROR = "InternalError" // INVALIDPARAMETER = "InvalidParameter" // RESOURCENOTFOUND = "ResourceNotFound" @@ -1125,6 +1133,204 @@ func (c *Client) DeleteWhitelistWithContext(ctx context.Context, request *Delete return } +func NewDescribeAppDimensionMetricsRequest() (request *DescribeAppDimensionMetricsRequest) { + request = &DescribeAppDimensionMetricsRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "DescribeAppDimensionMetrics") + + + return +} + +func NewDescribeAppDimensionMetricsResponse() (response *DescribeAppDimensionMetricsResponse) { + response = &DescribeAppDimensionMetricsResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// DescribeAppDimensionMetrics +// 用于查询 app 监控多维分析数据 +// +// 可能返回的错误码: +// FAILEDOPERATION = "FailedOperation" +// RESOURCENOTFOUND = "ResourceNotFound" +func (c *Client) DescribeAppDimensionMetrics(request *DescribeAppDimensionMetricsRequest) (response *DescribeAppDimensionMetricsResponse, err error) { + return c.DescribeAppDimensionMetricsWithContext(context.Background(), request) +} + +// DescribeAppDimensionMetrics +// 用于查询 app 监控多维分析数据 +// +// 可能返回的错误码: +// FAILEDOPERATION = "FailedOperation" +// RESOURCENOTFOUND = "ResourceNotFound" +func (c *Client) DescribeAppDimensionMetricsWithContext(ctx context.Context, request *DescribeAppDimensionMetricsRequest) (response *DescribeAppDimensionMetricsResponse, err error) { + if request == nil { + request = NewDescribeAppDimensionMetricsRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("DescribeAppDimensionMetrics require credential") + } + + request.SetContext(ctx) + + response = NewDescribeAppDimensionMetricsResponse() + err = c.Send(request, response) + return +} + +func NewDescribeAppMetricsDataRequest() (request *DescribeAppMetricsDataRequest) { + request = &DescribeAppMetricsDataRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "DescribeAppMetricsData") + + + return +} + +func NewDescribeAppMetricsDataResponse() (response *DescribeAppMetricsDataResponse) { + response = &DescribeAppMetricsDataResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// DescribeAppMetricsData +// 获取 app 监控指标数据 +// +// 可能返回的错误码: +// FAILEDOPERATION = "FailedOperation" +// RESOURCENOTFOUND = "ResourceNotFound" +func (c *Client) DescribeAppMetricsData(request *DescribeAppMetricsDataRequest) (response *DescribeAppMetricsDataResponse, err error) { + return c.DescribeAppMetricsDataWithContext(context.Background(), request) +} + +// DescribeAppMetricsData +// 获取 app 监控指标数据 +// +// 可能返回的错误码: +// FAILEDOPERATION = "FailedOperation" +// RESOURCENOTFOUND = "ResourceNotFound" +func (c *Client) DescribeAppMetricsDataWithContext(ctx context.Context, request *DescribeAppMetricsDataRequest) (response *DescribeAppMetricsDataResponse, err error) { + if request == nil { + request = NewDescribeAppMetricsDataRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("DescribeAppMetricsData require credential") + } + + request.SetContext(ctx) + + response = NewDescribeAppMetricsDataResponse() + err = c.Send(request, response) + return +} + +func NewDescribeAppSingleCaseDetailListRequest() (request *DescribeAppSingleCaseDetailListRequest) { + request = &DescribeAppSingleCaseDetailListRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "DescribeAppSingleCaseDetailList") + + + return +} + +func NewDescribeAppSingleCaseDetailListResponse() (response *DescribeAppSingleCaseDetailListResponse) { + response = &DescribeAppSingleCaseDetailListResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// DescribeAppSingleCaseDetailList +// 查询 app 监控个例样本详情列表 +// +// 可能返回的错误码: +// FAILEDOPERATION = "FailedOperation" +func (c *Client) DescribeAppSingleCaseDetailList(request *DescribeAppSingleCaseDetailListRequest) (response *DescribeAppSingleCaseDetailListResponse, err error) { + return c.DescribeAppSingleCaseDetailListWithContext(context.Background(), request) +} + +// DescribeAppSingleCaseDetailList +// 查询 app 监控个例样本详情列表 +// +// 可能返回的错误码: +// FAILEDOPERATION = "FailedOperation" +func (c *Client) DescribeAppSingleCaseDetailListWithContext(ctx context.Context, request *DescribeAppSingleCaseDetailListRequest) (response *DescribeAppSingleCaseDetailListResponse, err error) { + if request == nil { + request = NewDescribeAppSingleCaseDetailListRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("DescribeAppSingleCaseDetailList require credential") + } + + request.SetContext(ctx) + + response = NewDescribeAppSingleCaseDetailListResponse() + err = c.Send(request, response) + return +} + +func NewDescribeAppSingleCaseListRequest() (request *DescribeAppSingleCaseListRequest) { + request = &DescribeAppSingleCaseListRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "DescribeAppSingleCaseList") + + + return +} + +func NewDescribeAppSingleCaseListResponse() (response *DescribeAppSingleCaseListResponse) { + response = &DescribeAppSingleCaseListResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// DescribeAppSingleCaseList +// 查询 app 监控个例聚合列表 +// +// 可能返回的错误码: +// FAILEDOPERATION = "FailedOperation" +// RESOURCENOTFOUND = "ResourceNotFound" +func (c *Client) DescribeAppSingleCaseList(request *DescribeAppSingleCaseListRequest) (response *DescribeAppSingleCaseListResponse, err error) { + return c.DescribeAppSingleCaseListWithContext(context.Background(), request) +} + +// DescribeAppSingleCaseList +// 查询 app 监控个例聚合列表 +// +// 可能返回的错误码: +// FAILEDOPERATION = "FailedOperation" +// RESOURCENOTFOUND = "ResourceNotFound" +func (c *Client) DescribeAppSingleCaseListWithContext(ctx context.Context, request *DescribeAppSingleCaseListRequest) (response *DescribeAppSingleCaseListResponse, err error) { + if request == nil { + request = NewDescribeAppSingleCaseListRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("DescribeAppSingleCaseList require credential") + } + + request.SetContext(ctx) + + response = NewDescribeAppSingleCaseListResponse() + err = c.Send(request, response) + return +} + func NewDescribeDataRequest() (request *DescribeDataRequest) { request = &DescribeDataRequest{ BaseRequest: &tchttp.BaseRequest{}, @@ -2916,7 +3122,7 @@ func NewDescribeLogListResponse() (response *DescribeLogListResponse) { } // DescribeLogList -// 获取项目下的日志列表(实例创建的项目下的日志列表) +// (已下线,请用DescribeRumLogList) // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -2944,7 +3150,7 @@ func (c *Client) DescribeLogList(request *DescribeLogListRequest) (response *Des } // DescribeLogList -// 获取项目下的日志列表(实例创建的项目下的日志列表) +// (已下线,请用DescribeRumLogList) // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -3146,7 +3352,7 @@ func NewDescribeProjectLimitsResponse() (response *DescribeProjectLimitsResponse } // DescribeProjectLimits -// 获取项目上报率列表 +// 获取应用上报抽样信息 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -3176,7 +3382,7 @@ func (c *Client) DescribeProjectLimits(request *DescribeProjectLimitsRequest) (r } // DescribeProjectLimits -// 获取项目上报率列表 +// 获取应用上报抽样信息 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -3476,7 +3682,7 @@ func NewDescribeReleaseFilesResponse() (response *DescribeReleaseFilesResponse) } // DescribeReleaseFiles -// 获取项目对应sourcemap文件列表 +// 获取应用对应sourcemap文件列表 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -3505,7 +3711,7 @@ func (c *Client) DescribeReleaseFiles(request *DescribeReleaseFilesRequest) (res } // DescribeReleaseFiles -// 获取项目对应sourcemap文件列表 +// 获取应用对应sourcemap文件列表 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -3545,26 +3751,26 @@ func (c *Client) DescribeReleaseFilesWithContext(ctx context.Context, request *D return } -func NewDescribeScoresRequest() (request *DescribeScoresRequest) { - request = &DescribeScoresRequest{ +func NewDescribeRumGroupLogRequest() (request *DescribeRumGroupLogRequest) { + request = &DescribeRumGroupLogRequest{ BaseRequest: &tchttp.BaseRequest{}, } - request.Init().WithApiInfo("rum", APIVersion, "DescribeScores") + request.Init().WithApiInfo("rum", APIVersion, "DescribeRumGroupLog") return } -func NewDescribeScoresResponse() (response *DescribeScoresResponse) { - response = &DescribeScoresResponse{ +func NewDescribeRumGroupLogResponse() (response *DescribeRumGroupLogResponse) { + response = &DescribeRumGroupLogResponse{ BaseResponse: &tchttp.BaseResponse{}, } return } -// DescribeScores -// 获取首页分数列表 +// DescribeRumGroupLog +// 获取项目下的日志聚合信息 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -3587,12 +3793,12 @@ func NewDescribeScoresResponse() (response *DescribeScoresResponse) { // UNAUTHORIZEDOPERATION = "UnauthorizedOperation" // UNKNOWNPARAMETER = "UnknownParameter" // UNSUPPORTEDOPERATION = "UnsupportedOperation" -func (c *Client) DescribeScores(request *DescribeScoresRequest) (response *DescribeScoresResponse, err error) { - return c.DescribeScoresWithContext(context.Background(), request) +func (c *Client) DescribeRumGroupLog(request *DescribeRumGroupLogRequest) (response *DescribeRumGroupLogResponse, err error) { + return c.DescribeRumGroupLogWithContext(context.Background(), request) } -// DescribeScores -// 获取首页分数列表 +// DescribeRumGroupLog +// 获取项目下的日志聚合信息 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -3615,136 +3821,568 @@ func (c *Client) DescribeScores(request *DescribeScoresRequest) (response *Descr // UNAUTHORIZEDOPERATION = "UnauthorizedOperation" // UNKNOWNPARAMETER = "UnknownParameter" // UNSUPPORTEDOPERATION = "UnsupportedOperation" -func (c *Client) DescribeScoresWithContext(ctx context.Context, request *DescribeScoresRequest) (response *DescribeScoresResponse, err error) { +func (c *Client) DescribeRumGroupLogWithContext(ctx context.Context, request *DescribeRumGroupLogRequest) (response *DescribeRumGroupLogResponse, err error) { if request == nil { - request = NewDescribeScoresRequest() + request = NewDescribeRumGroupLogRequest() } if c.GetCredential() == nil { - return nil, errors.New("DescribeScores require credential") + return nil, errors.New("DescribeRumGroupLog require credential") } request.SetContext(ctx) - response = NewDescribeScoresResponse() + response = NewDescribeRumGroupLogResponse() err = c.Send(request, response) return } -func NewDescribeTawAreasRequest() (request *DescribeTawAreasRequest) { - request = &DescribeTawAreasRequest{ +func NewDescribeRumLogExportRequest() (request *DescribeRumLogExportRequest) { + request = &DescribeRumLogExportRequest{ BaseRequest: &tchttp.BaseRequest{}, } - request.Init().WithApiInfo("rum", APIVersion, "DescribeTawAreas") + request.Init().WithApiInfo("rum", APIVersion, "DescribeRumLogExport") return } -func NewDescribeTawAreasResponse() (response *DescribeTawAreasResponse) { - response = &DescribeTawAreasResponse{ +func NewDescribeRumLogExportResponse() (response *DescribeRumLogExportResponse) { + response = &DescribeRumLogExportResponse{ BaseResponse: &tchttp.BaseResponse{}, } return } -// DescribeTawAreas -// 查询片区信息 +// DescribeRumLogExport +// 获取项目下的日志列表(实例创建的项目下的日志列表) // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" +// DRYRUNOPERATION = "DryRunOperation" // FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" // INTERNALERROR = "InternalError" // INVALIDPARAMETER = "InvalidParameter" -func (c *Client) DescribeTawAreas(request *DescribeTawAreasRequest) (response *DescribeTawAreasResponse, err error) { - return c.DescribeTawAreasWithContext(context.Background(), request) +// INVALIDPARAMETERVALUE = "InvalidParameterValue" +// LIMITEXCEEDED = "LimitExceeded" +// MISSINGPARAMETER = "MissingParameter" +// OPERATIONDENIED = "OperationDenied" +// REQUESTLIMITEXCEEDED = "RequestLimitExceeded" +// RESOURCEINUSE = "ResourceInUse" +// RESOURCEINSUFFICIENT = "ResourceInsufficient" +// RESOURCENOTFOUND = "ResourceNotFound" +// RESOURCEUNAVAILABLE = "ResourceUnavailable" +// RESOURCESSOLDOUT = "ResourcesSoldOut" +// UNAUTHORIZEDOPERATION = "UnauthorizedOperation" +// UNKNOWNPARAMETER = "UnknownParameter" +// UNSUPPORTEDOPERATION = "UnsupportedOperation" +func (c *Client) DescribeRumLogExport(request *DescribeRumLogExportRequest) (response *DescribeRumLogExportResponse, err error) { + return c.DescribeRumLogExportWithContext(context.Background(), request) } -// DescribeTawAreas -// 查询片区信息 +// DescribeRumLogExport +// 获取项目下的日志列表(实例创建的项目下的日志列表) // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" +// DRYRUNOPERATION = "DryRunOperation" // FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" // INTERNALERROR = "InternalError" // INVALIDPARAMETER = "InvalidParameter" -func (c *Client) DescribeTawAreasWithContext(ctx context.Context, request *DescribeTawAreasRequest) (response *DescribeTawAreasResponse, err error) { +// INVALIDPARAMETERVALUE = "InvalidParameterValue" +// LIMITEXCEEDED = "LimitExceeded" +// MISSINGPARAMETER = "MissingParameter" +// OPERATIONDENIED = "OperationDenied" +// REQUESTLIMITEXCEEDED = "RequestLimitExceeded" +// RESOURCEINUSE = "ResourceInUse" +// RESOURCEINSUFFICIENT = "ResourceInsufficient" +// RESOURCENOTFOUND = "ResourceNotFound" +// RESOURCEUNAVAILABLE = "ResourceUnavailable" +// RESOURCESSOLDOUT = "ResourcesSoldOut" +// UNAUTHORIZEDOPERATION = "UnauthorizedOperation" +// UNKNOWNPARAMETER = "UnknownParameter" +// UNSUPPORTEDOPERATION = "UnsupportedOperation" +func (c *Client) DescribeRumLogExportWithContext(ctx context.Context, request *DescribeRumLogExportRequest) (response *DescribeRumLogExportResponse, err error) { if request == nil { - request = NewDescribeTawAreasRequest() + request = NewDescribeRumLogExportRequest() } if c.GetCredential() == nil { - return nil, errors.New("DescribeTawAreas require credential") + return nil, errors.New("DescribeRumLogExport require credential") } request.SetContext(ctx) - response = NewDescribeTawAreasResponse() + response = NewDescribeRumLogExportResponse() err = c.Send(request, response) return } -func NewDescribeTawInstancesRequest() (request *DescribeTawInstancesRequest) { - request = &DescribeTawInstancesRequest{ +func NewDescribeRumLogExportsRequest() (request *DescribeRumLogExportsRequest) { + request = &DescribeRumLogExportsRequest{ BaseRequest: &tchttp.BaseRequest{}, } - request.Init().WithApiInfo("rum", APIVersion, "DescribeTawInstances") + request.Init().WithApiInfo("rum", APIVersion, "DescribeRumLogExports") return } -func NewDescribeTawInstancesResponse() (response *DescribeTawInstancesResponse) { - response = &DescribeTawInstancesResponse{ +func NewDescribeRumLogExportsResponse() (response *DescribeRumLogExportsResponse) { + response = &DescribeRumLogExportsResponse{ BaseResponse: &tchttp.BaseResponse{}, } return } -// DescribeTawInstances -// 查询实例信息 +// DescribeRumLogExports +// 获取项目下的日志导出列表 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" +// DRYRUNOPERATION = "DryRunOperation" // FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" // INTERNALERROR = "InternalError" // INVALIDPARAMETER = "InvalidParameter" -func (c *Client) DescribeTawInstances(request *DescribeTawInstancesRequest) (response *DescribeTawInstancesResponse, err error) { - return c.DescribeTawInstancesWithContext(context.Background(), request) +// INVALIDPARAMETERVALUE = "InvalidParameterValue" +// LIMITEXCEEDED = "LimitExceeded" +// MISSINGPARAMETER = "MissingParameter" +// OPERATIONDENIED = "OperationDenied" +// REQUESTLIMITEXCEEDED = "RequestLimitExceeded" +// RESOURCEINUSE = "ResourceInUse" +// RESOURCEINSUFFICIENT = "ResourceInsufficient" +// RESOURCENOTFOUND = "ResourceNotFound" +// RESOURCEUNAVAILABLE = "ResourceUnavailable" +// RESOURCESSOLDOUT = "ResourcesSoldOut" +// UNAUTHORIZEDOPERATION = "UnauthorizedOperation" +// UNKNOWNPARAMETER = "UnknownParameter" +// UNSUPPORTEDOPERATION = "UnsupportedOperation" +func (c *Client) DescribeRumLogExports(request *DescribeRumLogExportsRequest) (response *DescribeRumLogExportsResponse, err error) { + return c.DescribeRumLogExportsWithContext(context.Background(), request) } -// DescribeTawInstances -// 查询实例信息 +// DescribeRumLogExports +// 获取项目下的日志导出列表 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" +// DRYRUNOPERATION = "DryRunOperation" // FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" // INTERNALERROR = "InternalError" // INVALIDPARAMETER = "InvalidParameter" -func (c *Client) DescribeTawInstancesWithContext(ctx context.Context, request *DescribeTawInstancesRequest) (response *DescribeTawInstancesResponse, err error) { +// INVALIDPARAMETERVALUE = "InvalidParameterValue" +// LIMITEXCEEDED = "LimitExceeded" +// MISSINGPARAMETER = "MissingParameter" +// OPERATIONDENIED = "OperationDenied" +// REQUESTLIMITEXCEEDED = "RequestLimitExceeded" +// RESOURCEINUSE = "ResourceInUse" +// RESOURCEINSUFFICIENT = "ResourceInsufficient" +// RESOURCENOTFOUND = "ResourceNotFound" +// RESOURCEUNAVAILABLE = "ResourceUnavailable" +// RESOURCESSOLDOUT = "ResourcesSoldOut" +// UNAUTHORIZEDOPERATION = "UnauthorizedOperation" +// UNKNOWNPARAMETER = "UnknownParameter" +// UNSUPPORTEDOPERATION = "UnsupportedOperation" +func (c *Client) DescribeRumLogExportsWithContext(ctx context.Context, request *DescribeRumLogExportsRequest) (response *DescribeRumLogExportsResponse, err error) { if request == nil { - request = NewDescribeTawInstancesRequest() + request = NewDescribeRumLogExportsRequest() } if c.GetCredential() == nil { - return nil, errors.New("DescribeTawInstances require credential") + return nil, errors.New("DescribeRumLogExports require credential") } request.SetContext(ctx) - response = NewDescribeTawInstancesResponse() + response = NewDescribeRumLogExportsResponse() err = c.Send(request, response) return } -func NewDescribeUvListRequest() (request *DescribeUvListRequest) { - request = &DescribeUvListRequest{ +func NewDescribeRumLogListRequest() (request *DescribeRumLogListRequest) { + request = &DescribeRumLogListRequest{ BaseRequest: &tchttp.BaseRequest{}, } - request.Init().WithApiInfo("rum", APIVersion, "DescribeUvList") + request.Init().WithApiInfo("rum", APIVersion, "DescribeRumLogList") + + + return +} + +func NewDescribeRumLogListResponse() (response *DescribeRumLogListResponse) { + response = &DescribeRumLogListResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// DescribeRumLogList +// 获取项目下的日志列表(实例创建的项目下的日志列表) +// +// 可能返回的错误码: +// AUTHFAILURE = "AuthFailure" +// DRYRUNOPERATION = "DryRunOperation" +// FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" +// INTERNALERROR = "InternalError" +// INVALIDPARAMETER = "InvalidParameter" +// INVALIDPARAMETERVALUE = "InvalidParameterValue" +// LIMITEXCEEDED = "LimitExceeded" +// MISSINGPARAMETER = "MissingParameter" +// OPERATIONDENIED = "OperationDenied" +// REQUESTLIMITEXCEEDED = "RequestLimitExceeded" +// RESOURCEINUSE = "ResourceInUse" +// RESOURCEINSUFFICIENT = "ResourceInsufficient" +// RESOURCENOTFOUND = "ResourceNotFound" +// RESOURCEUNAVAILABLE = "ResourceUnavailable" +// RESOURCESSOLDOUT = "ResourcesSoldOut" +// UNAUTHORIZEDOPERATION = "UnauthorizedOperation" +// UNKNOWNPARAMETER = "UnknownParameter" +// UNSUPPORTEDOPERATION = "UnsupportedOperation" +func (c *Client) DescribeRumLogList(request *DescribeRumLogListRequest) (response *DescribeRumLogListResponse, err error) { + return c.DescribeRumLogListWithContext(context.Background(), request) +} + +// DescribeRumLogList +// 获取项目下的日志列表(实例创建的项目下的日志列表) +// +// 可能返回的错误码: +// AUTHFAILURE = "AuthFailure" +// DRYRUNOPERATION = "DryRunOperation" +// FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" +// INTERNALERROR = "InternalError" +// INVALIDPARAMETER = "InvalidParameter" +// INVALIDPARAMETERVALUE = "InvalidParameterValue" +// LIMITEXCEEDED = "LimitExceeded" +// MISSINGPARAMETER = "MissingParameter" +// OPERATIONDENIED = "OperationDenied" +// REQUESTLIMITEXCEEDED = "RequestLimitExceeded" +// RESOURCEINUSE = "ResourceInUse" +// RESOURCEINSUFFICIENT = "ResourceInsufficient" +// RESOURCENOTFOUND = "ResourceNotFound" +// RESOURCEUNAVAILABLE = "ResourceUnavailable" +// RESOURCESSOLDOUT = "ResourcesSoldOut" +// UNAUTHORIZEDOPERATION = "UnauthorizedOperation" +// UNKNOWNPARAMETER = "UnknownParameter" +// UNSUPPORTEDOPERATION = "UnsupportedOperation" +func (c *Client) DescribeRumLogListWithContext(ctx context.Context, request *DescribeRumLogListRequest) (response *DescribeRumLogListResponse, err error) { + if request == nil { + request = NewDescribeRumLogListRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("DescribeRumLogList require credential") + } + + request.SetContext(ctx) + + response = NewDescribeRumLogListResponse() + err = c.Send(request, response) + return +} + +func NewDescribeRumStatsLogListRequest() (request *DescribeRumStatsLogListRequest) { + request = &DescribeRumStatsLogListRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "DescribeRumStatsLogList") + + + return +} + +func NewDescribeRumStatsLogListResponse() (response *DescribeRumStatsLogListResponse) { + response = &DescribeRumStatsLogListResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// DescribeRumStatsLogList +// 获取项目下的日志列表,分钟级 +// +// 可能返回的错误码: +// AUTHFAILURE = "AuthFailure" +// DRYRUNOPERATION = "DryRunOperation" +// FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" +// INTERNALERROR = "InternalError" +// INVALIDPARAMETER = "InvalidParameter" +// INVALIDPARAMETERVALUE = "InvalidParameterValue" +// LIMITEXCEEDED = "LimitExceeded" +// MISSINGPARAMETER = "MissingParameter" +// OPERATIONDENIED = "OperationDenied" +// REQUESTLIMITEXCEEDED = "RequestLimitExceeded" +// RESOURCEINUSE = "ResourceInUse" +// RESOURCEINSUFFICIENT = "ResourceInsufficient" +// RESOURCENOTFOUND = "ResourceNotFound" +// RESOURCEUNAVAILABLE = "ResourceUnavailable" +// RESOURCESSOLDOUT = "ResourcesSoldOut" +// UNAUTHORIZEDOPERATION = "UnauthorizedOperation" +// UNKNOWNPARAMETER = "UnknownParameter" +// UNSUPPORTEDOPERATION = "UnsupportedOperation" +func (c *Client) DescribeRumStatsLogList(request *DescribeRumStatsLogListRequest) (response *DescribeRumStatsLogListResponse, err error) { + return c.DescribeRumStatsLogListWithContext(context.Background(), request) +} + +// DescribeRumStatsLogList +// 获取项目下的日志列表,分钟级 +// +// 可能返回的错误码: +// AUTHFAILURE = "AuthFailure" +// DRYRUNOPERATION = "DryRunOperation" +// FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" +// INTERNALERROR = "InternalError" +// INVALIDPARAMETER = "InvalidParameter" +// INVALIDPARAMETERVALUE = "InvalidParameterValue" +// LIMITEXCEEDED = "LimitExceeded" +// MISSINGPARAMETER = "MissingParameter" +// OPERATIONDENIED = "OperationDenied" +// REQUESTLIMITEXCEEDED = "RequestLimitExceeded" +// RESOURCEINUSE = "ResourceInUse" +// RESOURCEINSUFFICIENT = "ResourceInsufficient" +// RESOURCENOTFOUND = "ResourceNotFound" +// RESOURCEUNAVAILABLE = "ResourceUnavailable" +// RESOURCESSOLDOUT = "ResourcesSoldOut" +// UNAUTHORIZEDOPERATION = "UnauthorizedOperation" +// UNKNOWNPARAMETER = "UnknownParameter" +// UNSUPPORTEDOPERATION = "UnsupportedOperation" +func (c *Client) DescribeRumStatsLogListWithContext(ctx context.Context, request *DescribeRumStatsLogListRequest) (response *DescribeRumStatsLogListResponse, err error) { + if request == nil { + request = NewDescribeRumStatsLogListRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("DescribeRumStatsLogList require credential") + } + + request.SetContext(ctx) + + response = NewDescribeRumStatsLogListResponse() + err = c.Send(request, response) + return +} + +func NewDescribeScoresRequest() (request *DescribeScoresRequest) { + request = &DescribeScoresRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "DescribeScores") + + + return +} + +func NewDescribeScoresResponse() (response *DescribeScoresResponse) { + response = &DescribeScoresResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// DescribeScores +// 获取首页分数列表 +// +// 可能返回的错误码: +// AUTHFAILURE = "AuthFailure" +// DRYRUNOPERATION = "DryRunOperation" +// FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" +// INTERNALERROR = "InternalError" +// INVALIDPARAMETER = "InvalidParameter" +// INVALIDPARAMETERVALUE = "InvalidParameterValue" +// LIMITEXCEEDED = "LimitExceeded" +// MISSINGPARAMETER = "MissingParameter" +// OPERATIONDENIED = "OperationDenied" +// REQUESTLIMITEXCEEDED = "RequestLimitExceeded" +// RESOURCEINUSE = "ResourceInUse" +// RESOURCEINSUFFICIENT = "ResourceInsufficient" +// RESOURCENOTFOUND = "ResourceNotFound" +// RESOURCEUNAVAILABLE = "ResourceUnavailable" +// RESOURCESSOLDOUT = "ResourcesSoldOut" +// UNAUTHORIZEDOPERATION = "UnauthorizedOperation" +// UNKNOWNPARAMETER = "UnknownParameter" +// UNSUPPORTEDOPERATION = "UnsupportedOperation" +func (c *Client) DescribeScores(request *DescribeScoresRequest) (response *DescribeScoresResponse, err error) { + return c.DescribeScoresWithContext(context.Background(), request) +} + +// DescribeScores +// 获取首页分数列表 +// +// 可能返回的错误码: +// AUTHFAILURE = "AuthFailure" +// DRYRUNOPERATION = "DryRunOperation" +// FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" +// INTERNALERROR = "InternalError" +// INVALIDPARAMETER = "InvalidParameter" +// INVALIDPARAMETERVALUE = "InvalidParameterValue" +// LIMITEXCEEDED = "LimitExceeded" +// MISSINGPARAMETER = "MissingParameter" +// OPERATIONDENIED = "OperationDenied" +// REQUESTLIMITEXCEEDED = "RequestLimitExceeded" +// RESOURCEINUSE = "ResourceInUse" +// RESOURCEINSUFFICIENT = "ResourceInsufficient" +// RESOURCENOTFOUND = "ResourceNotFound" +// RESOURCEUNAVAILABLE = "ResourceUnavailable" +// RESOURCESSOLDOUT = "ResourcesSoldOut" +// UNAUTHORIZEDOPERATION = "UnauthorizedOperation" +// UNKNOWNPARAMETER = "UnknownParameter" +// UNSUPPORTEDOPERATION = "UnsupportedOperation" +func (c *Client) DescribeScoresWithContext(ctx context.Context, request *DescribeScoresRequest) (response *DescribeScoresResponse, err error) { + if request == nil { + request = NewDescribeScoresRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("DescribeScores require credential") + } + + request.SetContext(ctx) + + response = NewDescribeScoresResponse() + err = c.Send(request, response) + return +} + +func NewDescribeTawAreasRequest() (request *DescribeTawAreasRequest) { + request = &DescribeTawAreasRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "DescribeTawAreas") + + + return +} + +func NewDescribeTawAreasResponse() (response *DescribeTawAreasResponse) { + response = &DescribeTawAreasResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// DescribeTawAreas +// 查询片区信息 +// +// 可能返回的错误码: +// AUTHFAILURE = "AuthFailure" +// FAILEDOPERATION = "FailedOperation" +// INTERNALERROR = "InternalError" +// INVALIDPARAMETER = "InvalidParameter" +func (c *Client) DescribeTawAreas(request *DescribeTawAreasRequest) (response *DescribeTawAreasResponse, err error) { + return c.DescribeTawAreasWithContext(context.Background(), request) +} + +// DescribeTawAreas +// 查询片区信息 +// +// 可能返回的错误码: +// AUTHFAILURE = "AuthFailure" +// FAILEDOPERATION = "FailedOperation" +// INTERNALERROR = "InternalError" +// INVALIDPARAMETER = "InvalidParameter" +func (c *Client) DescribeTawAreasWithContext(ctx context.Context, request *DescribeTawAreasRequest) (response *DescribeTawAreasResponse, err error) { + if request == nil { + request = NewDescribeTawAreasRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("DescribeTawAreas require credential") + } + + request.SetContext(ctx) + + response = NewDescribeTawAreasResponse() + err = c.Send(request, response) + return +} + +func NewDescribeTawInstancesRequest() (request *DescribeTawInstancesRequest) { + request = &DescribeTawInstancesRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "DescribeTawInstances") + + + return +} + +func NewDescribeTawInstancesResponse() (response *DescribeTawInstancesResponse) { + response = &DescribeTawInstancesResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// DescribeTawInstances +// 查询实例信息 +// +// 可能返回的错误码: +// AUTHFAILURE = "AuthFailure" +// FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" +// INTERNALERROR = "InternalError" +// INVALIDPARAMETER = "InvalidParameter" +func (c *Client) DescribeTawInstances(request *DescribeTawInstancesRequest) (response *DescribeTawInstancesResponse, err error) { + return c.DescribeTawInstancesWithContext(context.Background(), request) +} + +// DescribeTawInstances +// 查询实例信息 +// +// 可能返回的错误码: +// AUTHFAILURE = "AuthFailure" +// FAILEDOPERATION = "FailedOperation" +// FAILEDOPERATION_DATABASEEXCEPTION = "FailedOperation.DataBaseException" +// INTERNALERROR = "InternalError" +// INVALIDPARAMETER = "InvalidParameter" +func (c *Client) DescribeTawInstancesWithContext(ctx context.Context, request *DescribeTawInstancesRequest) (response *DescribeTawInstancesResponse, err error) { + if request == nil { + request = NewDescribeTawInstancesRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("DescribeTawInstances require credential") + } + + request.SetContext(ctx) + + response = NewDescribeTawInstancesResponse() + err = c.Send(request, response) + return +} + +func NewDescribeUvListRequest() (request *DescribeUvListRequest) { + request = &DescribeUvListRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "DescribeUvList") return @@ -3928,7 +4566,7 @@ func NewModifyInstanceResponse() (response *ModifyInstanceResponse) { } // ModifyInstance -// 修改实例信息 +// 修改 RUM 业务系统 // // 可能返回的错误码: // FAILEDOPERATION = "FailedOperation" @@ -3948,7 +4586,7 @@ func (c *Client) ModifyInstance(request *ModifyInstanceRequest) (response *Modif } // ModifyInstance -// 修改实例信息 +// 修改 RUM 业务系统 // // 可能返回的错误码: // FAILEDOPERATION = "FailedOperation" @@ -3998,7 +4636,7 @@ func NewModifyProjectResponse() (response *ModifyProjectResponse) { } // ModifyProject -// 修改 rum 项目信息 +// 修改 RUM 应用信息 // // 可能返回的错误码: // FAILEDOPERATION = "FailedOperation" @@ -4008,7 +4646,7 @@ func (c *Client) ModifyProject(request *ModifyProjectRequest) (response *ModifyP } // ModifyProject -// 修改 rum 项目信息 +// 修改 RUM 应用信息 // // 可能返回的错误码: // FAILEDOPERATION = "FailedOperation" @@ -4138,7 +4776,7 @@ func NewResumeInstanceResponse() (response *ResumeInstanceResponse) { } // ResumeInstance -// 恢复实例 +// 恢复 RUM 业务系统,恢复后,用户可以正常使用和上报数据 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -4159,7 +4797,7 @@ func (c *Client) ResumeInstance(request *ResumeInstanceRequest) (response *Resum } // ResumeInstance -// 恢复实例 +// 恢复 RUM 业务系统,恢复后,用户可以正常使用和上报数据 // // 可能返回的错误码: // AUTHFAILURE = "AuthFailure" @@ -4191,6 +4829,54 @@ func (c *Client) ResumeInstanceWithContext(ctx context.Context, request *ResumeI return } +func NewResumeProjectRequest() (request *ResumeProjectRequest) { + request = &ResumeProjectRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "ResumeProject") + + + return +} + +func NewResumeProjectResponse() (response *ResumeProjectResponse) { + response = &ResumeProjectResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// ResumeProject +// 恢复应用使用与上报数据 +// +// 可能返回的错误码: +// RESOURCENOTFOUND = "ResourceNotFound" +func (c *Client) ResumeProject(request *ResumeProjectRequest) (response *ResumeProjectResponse, err error) { + return c.ResumeProjectWithContext(context.Background(), request) +} + +// ResumeProject +// 恢复应用使用与上报数据 +// +// 可能返回的错误码: +// RESOURCENOTFOUND = "ResourceNotFound" +func (c *Client) ResumeProjectWithContext(ctx context.Context, request *ResumeProjectRequest) (response *ResumeProjectResponse, err error) { + if request == nil { + request = NewResumeProjectRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("ResumeProject require credential") + } + + request.SetContext(ctx) + + response = NewResumeProjectResponse() + err = c.Send(request, response) + return +} + func NewStopInstanceRequest() (request *StopInstanceRequest) { request = &StopInstanceRequest{ BaseRequest: &tchttp.BaseRequest{}, @@ -4264,3 +4950,53 @@ func (c *Client) StopInstanceWithContext(ctx context.Context, request *StopInsta err = c.Send(request, response) return } + +func NewStopProjectRequest() (request *StopProjectRequest) { + request = &StopProjectRequest{ + BaseRequest: &tchttp.BaseRequest{}, + } + + request.Init().WithApiInfo("rum", APIVersion, "StopProject") + + + return +} + +func NewStopProjectResponse() (response *StopProjectResponse) { + response = &StopProjectResponse{ + BaseResponse: &tchttp.BaseResponse{}, + } + return +} + +// StopProject +// 停止项目使用与上报数据 +// +// 可能返回的错误码: +// FAILEDOPERATION = "FailedOperation" +// RESOURCENOTFOUND = "ResourceNotFound" +func (c *Client) StopProject(request *StopProjectRequest) (response *StopProjectResponse, err error) { + return c.StopProjectWithContext(context.Background(), request) +} + +// StopProject +// 停止项目使用与上报数据 +// +// 可能返回的错误码: +// FAILEDOPERATION = "FailedOperation" +// RESOURCENOTFOUND = "ResourceNotFound" +func (c *Client) StopProjectWithContext(ctx context.Context, request *StopProjectRequest) (response *StopProjectResponse, err error) { + if request == nil { + request = NewStopProjectRequest() + } + + if c.GetCredential() == nil { + return nil, errors.New("StopProject require credential") + } + + request.SetContext(ctx) + + response = NewStopProjectResponse() + err = c.Send(request, response) + return +} diff --git a/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/errors.go b/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/errors.go index 456c25067d..7e4b421ffd 100644 --- a/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/errors.go +++ b/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/errors.go @@ -26,6 +26,15 @@ const ( // 操作失败。 FAILEDOPERATION = "FailedOperation" + // 计费相关 - 账户余额不足。 + FAILEDOPERATION_CHARGENOBALANCE = "FailedOperation.ChargeNoBalance" + + // 计费相关 - 账户没有付费权限。 + FAILEDOPERATION_CHARGENOPAYRIGHT = "FailedOperation.ChargeNoPayRight" + + // 计费相关 - 计费参数无效。 + FAILEDOPERATION_CHARGEPARAMINVALID = "FailedOperation.ChargeParamInvalid" + // CLS调用失败 FAILEDOPERATION_CLSCALLFAIL = "FailedOperation.ClsCallFail" diff --git a/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/models.go b/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/models.go index c54ae87c60..1f9347e611 100644 --- a/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/models.go +++ b/vendor/github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622/models.go @@ -15,58 +15,58 @@ package v20210622 import ( - "encoding/json" tcerr "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common/errors" tchttp "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common/http" + "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common/json" ) // Predefined struct for user type CreateLogExportRequestParams struct { // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 日志导出起始时间 - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 日志导出结束时间 - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` // 日志导出检索语句 - Query *string `json:"Query,omitempty" name:"Query"` + Query *string `json:"Query,omitnil" name:"Query"` // 日志导出数量, 最大值1000万 - Count *int64 `json:"Count,omitempty" name:"Count"` + Count *int64 `json:"Count,omitnil" name:"Count"` // 日志导出时间排序。desc,asc,默认为desc - Order *string `json:"Order,omitempty" name:"Order"` + Order *string `json:"Order,omitnil" name:"Order"` // 日志导出数据格式。json,csv,默认为json - Format *string `json:"Format,omitempty" name:"Format"` + Format *string `json:"Format,omitnil" name:"Format"` } type CreateLogExportRequest struct { *tchttp.BaseRequest // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 日志导出起始时间 - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 日志导出结束时间 - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` // 日志导出检索语句 - Query *string `json:"Query,omitempty" name:"Query"` + Query *string `json:"Query,omitnil" name:"Query"` // 日志导出数量, 最大值1000万 - Count *int64 `json:"Count,omitempty" name:"Count"` + Count *int64 `json:"Count,omitnil" name:"Count"` // 日志导出时间排序。desc,asc,默认为desc - Order *string `json:"Order,omitempty" name:"Order"` + Order *string `json:"Order,omitnil" name:"Order"` // 日志导出数据格式。json,csv,默认为json - Format *string `json:"Format,omitempty" name:"Format"` + Format *string `json:"Format,omitnil" name:"Format"` } func (r *CreateLogExportRequest) ToJsonString() string { @@ -97,10 +97,10 @@ func (r *CreateLogExportRequest) FromJsonString(s string) error { // Predefined struct for user type CreateLogExportResponseParams struct { // 日志导出ID - ExportID *string `json:"ExportID,omitempty" name:"ExportID"` + ExportID *string `json:"ExportID,omitnil" name:"ExportID"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type CreateLogExportResponse struct { @@ -122,20 +122,20 @@ func (r *CreateLogExportResponse) FromJsonString(s string) error { // Predefined struct for user type CreateOfflineLogConfigRequestParams struct { // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` // 需要监听的用户唯一标示(aid 或 uin) - UniqueID *string `json:"UniqueID,omitempty" name:"UniqueID"` + UniqueID *string `json:"UniqueID,omitnil" name:"UniqueID"` } type CreateOfflineLogConfigRequest struct { *tchttp.BaseRequest // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` // 需要监听的用户唯一标示(aid 或 uin) - UniqueID *string `json:"UniqueID,omitempty" name:"UniqueID"` + UniqueID *string `json:"UniqueID,omitnil" name:"UniqueID"` } func (r *CreateOfflineLogConfigRequest) ToJsonString() string { @@ -161,10 +161,10 @@ func (r *CreateOfflineLogConfigRequest) FromJsonString(s string) error { // Predefined struct for user type CreateOfflineLogConfigResponseParams struct { // 接口返回信息 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type CreateOfflineLogConfigResponse struct { @@ -186,56 +186,56 @@ func (r *CreateOfflineLogConfigResponse) FromJsonString(s string) error { // Predefined struct for user type CreateProjectRequestParams struct { // 创建的项目名(不为空且最长为 200) - Name *string `json:"Name,omitempty" name:"Name"` + Name *string `json:"Name,omitnil" name:"Name"` // 业务系统 ID - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 项目抽样率(大于等于 0) - Rate *string `json:"Rate,omitempty" name:"Rate"` + Rate *string `json:"Rate,omitnil" name:"Rate"` // 是否开启聚类 - EnableURLGroup *uint64 `json:"EnableURLGroup,omitempty" name:"EnableURLGroup"` + EnableURLGroup *uint64 `json:"EnableURLGroup,omitnil" name:"EnableURLGroup"` // 项目类型("web", "mp", "android", "ios", "node", "hippy", "weex", "viola", "rn") - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 项目对应仓库地址(可选,最长为 256) - Repo *string `json:"Repo,omitempty" name:"Repo"` + Repo *string `json:"Repo,omitnil" name:"Repo"` // 项目对应网页地址(可选,最长为 256) - URL *string `json:"URL,omitempty" name:"URL"` + URL *string `json:"URL,omitnil" name:"URL"` // 创建的项目描述(可选,最长为 1000) - Desc *string `json:"Desc,omitempty" name:"Desc"` + Desc *string `json:"Desc,omitnil" name:"Desc"` } type CreateProjectRequest struct { *tchttp.BaseRequest // 创建的项目名(不为空且最长为 200) - Name *string `json:"Name,omitempty" name:"Name"` + Name *string `json:"Name,omitnil" name:"Name"` // 业务系统 ID - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 项目抽样率(大于等于 0) - Rate *string `json:"Rate,omitempty" name:"Rate"` + Rate *string `json:"Rate,omitnil" name:"Rate"` // 是否开启聚类 - EnableURLGroup *uint64 `json:"EnableURLGroup,omitempty" name:"EnableURLGroup"` + EnableURLGroup *uint64 `json:"EnableURLGroup,omitnil" name:"EnableURLGroup"` // 项目类型("web", "mp", "android", "ios", "node", "hippy", "weex", "viola", "rn") - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 项目对应仓库地址(可选,最长为 256) - Repo *string `json:"Repo,omitempty" name:"Repo"` + Repo *string `json:"Repo,omitnil" name:"Repo"` // 项目对应网页地址(可选,最长为 256) - URL *string `json:"URL,omitempty" name:"URL"` + URL *string `json:"URL,omitnil" name:"URL"` // 创建的项目描述(可选,最长为 1000) - Desc *string `json:"Desc,omitempty" name:"Desc"` + Desc *string `json:"Desc,omitnil" name:"Desc"` } func (r *CreateProjectRequest) ToJsonString() string { @@ -267,13 +267,13 @@ func (r *CreateProjectRequest) FromJsonString(s string) error { // Predefined struct for user type CreateProjectResponseParams struct { // 项目 id - ID *uint64 `json:"ID,omitempty" name:"ID"` + ID *uint64 `json:"ID,omitnil" name:"ID"` // 项目唯一key - Key *string `json:"Key,omitempty" name:"Key"` + Key *string `json:"Key,omitnil" name:"Key"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type CreateProjectResponse struct { @@ -295,20 +295,20 @@ func (r *CreateProjectResponse) FromJsonString(s string) error { // Predefined struct for user type CreateReleaseFileRequestParams struct { // 项目 id - ProjectID *int64 `json:"ProjectID,omitempty" name:"ProjectID"` + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` // 文件信息列表 - Files []*ReleaseFile `json:"Files,omitempty" name:"Files"` + Files []*ReleaseFile `json:"Files,omitnil" name:"Files"` } type CreateReleaseFileRequest struct { *tchttp.BaseRequest // 项目 id - ProjectID *int64 `json:"ProjectID,omitempty" name:"ProjectID"` + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` // 文件信息列表 - Files []*ReleaseFile `json:"Files,omitempty" name:"Files"` + Files []*ReleaseFile `json:"Files,omitnil" name:"Files"` } func (r *CreateReleaseFileRequest) ToJsonString() string { @@ -334,10 +334,10 @@ func (r *CreateReleaseFileRequest) FromJsonString(s string) error { // Predefined struct for user type CreateReleaseFileResponseParams struct { // 调用结果 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type CreateReleaseFileResponse struct { @@ -359,20 +359,20 @@ func (r *CreateReleaseFileResponse) FromJsonString(s string) error { // Predefined struct for user type CreateStarProjectRequestParams struct { // 实例ID:taw-123 - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } type CreateStarProjectRequest struct { *tchttp.BaseRequest // 实例ID:taw-123 - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } func (r *CreateStarProjectRequest) ToJsonString() string { @@ -398,10 +398,10 @@ func (r *CreateStarProjectRequest) FromJsonString(s string) error { // Predefined struct for user type CreateStarProjectResponseParams struct { // 接口返回信息 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type CreateStarProjectResponse struct { @@ -423,62 +423,80 @@ func (r *CreateStarProjectResponse) FromJsonString(s string) error { // Predefined struct for user type CreateTawInstanceRequestParams struct { // 片区Id,(至少大于0) - AreaId *int64 `json:"AreaId,omitempty" name:"AreaId"` + AreaId *int64 `json:"AreaId,omitnil" name:"AreaId"` - // 计费类型, (1=后付费,2=预付费) - ChargeType *int64 `json:"ChargeType,omitempty" name:"ChargeType"` + // 计费类型, (1=后付费) + ChargeType *int64 `json:"ChargeType,omitnil" name:"ChargeType"` // 数据保存时间,(至少大于0) - DataRetentionDays *int64 `json:"DataRetentionDays,omitempty" name:"DataRetentionDays"` + DataRetentionDays *int64 `json:"DataRetentionDays,omitnil" name:"DataRetentionDays"` // 实例名称,(最大长度不超过255字节) - InstanceName *string `json:"InstanceName,omitempty" name:"InstanceName"` + InstanceName *string `json:"InstanceName,omitnil" name:"InstanceName"` // 标签列表 - Tags []*Tag `json:"Tags,omitempty" name:"Tags"` + Tags []*Tag `json:"Tags,omitnil" name:"Tags"` // 实例描述,(最大长度不超过1024字节) - InstanceDesc *string `json:"InstanceDesc,omitempty" name:"InstanceDesc"` + InstanceDesc *string `json:"InstanceDesc,omitnil" name:"InstanceDesc"` // 每天数据上报量 - CountNum *string `json:"CountNum,omitempty" name:"CountNum"` + CountNum *string `json:"CountNum,omitnil" name:"CountNum"` // 数据存储时长计费 - PeriodRetain *string `json:"PeriodRetain,omitempty" name:"PeriodRetain"` + PeriodRetain *string `json:"PeriodRetain,omitnil" name:"PeriodRetain"` // 实例购买渠道("cdn" 等) - BuyingChannel *string `json:"BuyingChannel,omitempty" name:"BuyingChannel"` + BuyingChannel *string `json:"BuyingChannel,omitnil" name:"BuyingChannel"` + + // 预付费资源包类型(仅预付费需要) + ResourcePackageType *uint64 `json:"ResourcePackageType,omitnil" name:"ResourcePackageType"` + + // 预付费资源包数量(仅预付费需要) + ResourcePackageNum *uint64 `json:"ResourcePackageNum,omitnil" name:"ResourcePackageNum"` + + // 实例类型 1:原web相关类型 2:app端类型 + InstanceType *int64 `json:"InstanceType,omitnil" name:"InstanceType"` } type CreateTawInstanceRequest struct { *tchttp.BaseRequest // 片区Id,(至少大于0) - AreaId *int64 `json:"AreaId,omitempty" name:"AreaId"` + AreaId *int64 `json:"AreaId,omitnil" name:"AreaId"` - // 计费类型, (1=后付费,2=预付费) - ChargeType *int64 `json:"ChargeType,omitempty" name:"ChargeType"` + // 计费类型, (1=后付费) + ChargeType *int64 `json:"ChargeType,omitnil" name:"ChargeType"` // 数据保存时间,(至少大于0) - DataRetentionDays *int64 `json:"DataRetentionDays,omitempty" name:"DataRetentionDays"` + DataRetentionDays *int64 `json:"DataRetentionDays,omitnil" name:"DataRetentionDays"` // 实例名称,(最大长度不超过255字节) - InstanceName *string `json:"InstanceName,omitempty" name:"InstanceName"` + InstanceName *string `json:"InstanceName,omitnil" name:"InstanceName"` // 标签列表 - Tags []*Tag `json:"Tags,omitempty" name:"Tags"` + Tags []*Tag `json:"Tags,omitnil" name:"Tags"` // 实例描述,(最大长度不超过1024字节) - InstanceDesc *string `json:"InstanceDesc,omitempty" name:"InstanceDesc"` + InstanceDesc *string `json:"InstanceDesc,omitnil" name:"InstanceDesc"` // 每天数据上报量 - CountNum *string `json:"CountNum,omitempty" name:"CountNum"` + CountNum *string `json:"CountNum,omitnil" name:"CountNum"` // 数据存储时长计费 - PeriodRetain *string `json:"PeriodRetain,omitempty" name:"PeriodRetain"` + PeriodRetain *string `json:"PeriodRetain,omitnil" name:"PeriodRetain"` // 实例购买渠道("cdn" 等) - BuyingChannel *string `json:"BuyingChannel,omitempty" name:"BuyingChannel"` + BuyingChannel *string `json:"BuyingChannel,omitnil" name:"BuyingChannel"` + + // 预付费资源包类型(仅预付费需要) + ResourcePackageType *uint64 `json:"ResourcePackageType,omitnil" name:"ResourcePackageType"` + + // 预付费资源包数量(仅预付费需要) + ResourcePackageNum *uint64 `json:"ResourcePackageNum,omitnil" name:"ResourcePackageNum"` + + // 实例类型 1:原web相关类型 2:app端类型 + InstanceType *int64 `json:"InstanceType,omitnil" name:"InstanceType"` } func (r *CreateTawInstanceRequest) ToJsonString() string { @@ -502,6 +520,9 @@ func (r *CreateTawInstanceRequest) FromJsonString(s string) error { delete(f, "CountNum") delete(f, "PeriodRetain") delete(f, "BuyingChannel") + delete(f, "ResourcePackageType") + delete(f, "ResourcePackageNum") + delete(f, "InstanceType") if len(f) > 0 { return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "CreateTawInstanceRequest has unknown keys!", "") } @@ -511,10 +532,14 @@ func (r *CreateTawInstanceRequest) FromJsonString(s string) error { // Predefined struct for user type CreateTawInstanceResponseParams struct { // 实例Id - InstanceId *string `json:"InstanceId,omitempty" name:"InstanceId"` + InstanceId *string `json:"InstanceId,omitnil" name:"InstanceId"` + + // 预付费订单 id + // 注意:此字段可能返回 null,表示取不到有效值。 + DealName *string `json:"DealName,omitnil" name:"DealName"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type CreateTawInstanceResponse struct { @@ -536,32 +561,32 @@ func (r *CreateTawInstanceResponse) FromJsonString(s string) error { // Predefined struct for user type CreateWhitelistRequestParams struct { // 实例ID:taw-123 - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 备注 - Remark *string `json:"Remark,omitempty" name:"Remark"` + Remark *string `json:"Remark,omitnil" name:"Remark"` // uin:业务方标识 - WhitelistUin *string `json:"WhitelistUin,omitempty" name:"WhitelistUin"` + WhitelistUin *string `json:"WhitelistUin,omitnil" name:"WhitelistUin"` // 业务方标识 - Aid *string `json:"Aid,omitempty" name:"Aid"` + Aid *string `json:"Aid,omitnil" name:"Aid"` } type CreateWhitelistRequest struct { *tchttp.BaseRequest // 实例ID:taw-123 - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 备注 - Remark *string `json:"Remark,omitempty" name:"Remark"` + Remark *string `json:"Remark,omitnil" name:"Remark"` // uin:业务方标识 - WhitelistUin *string `json:"WhitelistUin,omitempty" name:"WhitelistUin"` + WhitelistUin *string `json:"WhitelistUin,omitnil" name:"WhitelistUin"` // 业务方标识 - Aid *string `json:"Aid,omitempty" name:"Aid"` + Aid *string `json:"Aid,omitnil" name:"Aid"` } func (r *CreateWhitelistRequest) ToJsonString() string { @@ -589,13 +614,13 @@ func (r *CreateWhitelistRequest) FromJsonString(s string) error { // Predefined struct for user type CreateWhitelistResponseParams struct { // 消息 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 白名单ID - ID *uint64 `json:"ID,omitempty" name:"ID"` + ID *uint64 `json:"ID,omitnil" name:"ID"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type CreateWhitelistResponse struct { @@ -617,14 +642,14 @@ func (r *CreateWhitelistResponse) FromJsonString(s string) error { // Predefined struct for user type DeleteInstanceRequestParams struct { // 需要删除的实例id - InstanceId *string `json:"InstanceId,omitempty" name:"InstanceId"` + InstanceId *string `json:"InstanceId,omitnil" name:"InstanceId"` } type DeleteInstanceRequest struct { *tchttp.BaseRequest // 需要删除的实例id - InstanceId *string `json:"InstanceId,omitempty" name:"InstanceId"` + InstanceId *string `json:"InstanceId,omitnil" name:"InstanceId"` } func (r *DeleteInstanceRequest) ToJsonString() string { @@ -649,7 +674,7 @@ func (r *DeleteInstanceRequest) FromJsonString(s string) error { // Predefined struct for user type DeleteInstanceResponseParams struct { // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DeleteInstanceResponse struct { @@ -671,20 +696,20 @@ func (r *DeleteInstanceResponse) FromJsonString(s string) error { // Predefined struct for user type DeleteLogExportRequestParams struct { // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 日志导出ID - ExportID *string `json:"ExportID,omitempty" name:"ExportID"` + ExportID *string `json:"ExportID,omitnil" name:"ExportID"` } type DeleteLogExportRequest struct { *tchttp.BaseRequest // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 日志导出ID - ExportID *string `json:"ExportID,omitempty" name:"ExportID"` + ExportID *string `json:"ExportID,omitnil" name:"ExportID"` } func (r *DeleteLogExportRequest) ToJsonString() string { @@ -711,10 +736,10 @@ func (r *DeleteLogExportRequest) FromJsonString(s string) error { type DeleteLogExportResponseParams struct { // 是否成功,成功则为success;失败则直接返回Error,不返回该参数 // 注意:此字段可能返回 null,表示取不到有效值。 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DeleteLogExportResponse struct { @@ -736,20 +761,20 @@ func (r *DeleteLogExportResponse) FromJsonString(s string) error { // Predefined struct for user type DeleteOfflineLogConfigRequestParams struct { // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` // 用户唯一标示(uin or aid) - UniqueID *string `json:"UniqueID,omitempty" name:"UniqueID"` + UniqueID *string `json:"UniqueID,omitnil" name:"UniqueID"` } type DeleteOfflineLogConfigRequest struct { *tchttp.BaseRequest // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` // 用户唯一标示(uin or aid) - UniqueID *string `json:"UniqueID,omitempty" name:"UniqueID"` + UniqueID *string `json:"UniqueID,omitnil" name:"UniqueID"` } func (r *DeleteOfflineLogConfigRequest) ToJsonString() string { @@ -775,10 +800,10 @@ func (r *DeleteOfflineLogConfigRequest) FromJsonString(s string) error { // Predefined struct for user type DeleteOfflineLogConfigResponseParams struct { // 接口调用信息 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DeleteOfflineLogConfigResponse struct { @@ -800,20 +825,20 @@ func (r *DeleteOfflineLogConfigResponse) FromJsonString(s string) error { // Predefined struct for user type DeleteOfflineLogRecordRequestParams struct { // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` // 离线日志文件 id - FileID *string `json:"FileID,omitempty" name:"FileID"` + FileID *string `json:"FileID,omitnil" name:"FileID"` } type DeleteOfflineLogRecordRequest struct { *tchttp.BaseRequest // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` // 离线日志文件 id - FileID *string `json:"FileID,omitempty" name:"FileID"` + FileID *string `json:"FileID,omitnil" name:"FileID"` } func (r *DeleteOfflineLogRecordRequest) ToJsonString() string { @@ -839,10 +864,10 @@ func (r *DeleteOfflineLogRecordRequest) FromJsonString(s string) error { // Predefined struct for user type DeleteOfflineLogRecordResponseParams struct { // 接口调用信息 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DeleteOfflineLogRecordResponse struct { @@ -864,14 +889,14 @@ func (r *DeleteOfflineLogRecordResponse) FromJsonString(s string) error { // Predefined struct for user type DeleteProjectRequestParams struct { // 需要删除的项目 ID - ID *uint64 `json:"ID,omitempty" name:"ID"` + ID *uint64 `json:"ID,omitnil" name:"ID"` } type DeleteProjectRequest struct { *tchttp.BaseRequest // 需要删除的项目 ID - ID *uint64 `json:"ID,omitempty" name:"ID"` + ID *uint64 `json:"ID,omitnil" name:"ID"` } func (r *DeleteProjectRequest) ToJsonString() string { @@ -896,10 +921,10 @@ func (r *DeleteProjectRequest) FromJsonString(s string) error { // Predefined struct for user type DeleteProjectResponseParams struct { // 操作信息 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DeleteProjectResponse struct { @@ -921,14 +946,14 @@ func (r *DeleteProjectResponse) FromJsonString(s string) error { // Predefined struct for user type DeleteReleaseFileRequestParams struct { // 文件 id - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } type DeleteReleaseFileRequest struct { *tchttp.BaseRequest // 文件 id - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } func (r *DeleteReleaseFileRequest) ToJsonString() string { @@ -953,10 +978,10 @@ func (r *DeleteReleaseFileRequest) FromJsonString(s string) error { // Predefined struct for user type DeleteReleaseFileResponseParams struct { // 接口请求返回字符串 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DeleteReleaseFileResponse struct { @@ -978,20 +1003,20 @@ func (r *DeleteReleaseFileResponse) FromJsonString(s string) error { // Predefined struct for user type DeleteStarProjectRequestParams struct { // 实例ID:taw-123 - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } type DeleteStarProjectRequest struct { *tchttp.BaseRequest // 实例ID:taw-123 - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } func (r *DeleteStarProjectRequest) ToJsonString() string { @@ -1018,10 +1043,10 @@ func (r *DeleteStarProjectRequest) FromJsonString(s string) error { type DeleteStarProjectResponseParams struct { // 返回消息 // 注意:此字段可能返回 null,表示取不到有效值。 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DeleteStarProjectResponse struct { @@ -1043,20 +1068,20 @@ func (r *DeleteStarProjectResponse) FromJsonString(s string) error { // Predefined struct for user type DeleteWhitelistRequestParams struct { // 实例ID - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 名单ID - ID *string `json:"ID,omitempty" name:"ID"` + ID *string `json:"ID,omitnil" name:"ID"` } type DeleteWhitelistRequest struct { *tchttp.BaseRequest // 实例ID - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 名单ID - ID *string `json:"ID,omitempty" name:"ID"` + ID *string `json:"ID,omitnil" name:"ID"` } func (r *DeleteWhitelistRequest) ToJsonString() string { @@ -1082,10 +1107,10 @@ func (r *DeleteWhitelistRequest) FromJsonString(s string) error { // Predefined struct for user type DeleteWhitelistResponseParams struct { // 消息success - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DeleteWhitelistResponse struct { @@ -1104,149 +1129,615 @@ func (r *DeleteWhitelistResponse) FromJsonString(s string) error { return json.Unmarshal([]byte(s), &r) } +// Predefined struct for user +type DescribeAppDimensionMetricsRequestParams struct { + // app 项目ID + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` + + // 查询的表名 + From *string `json:"From,omitnil" name:"From"` + + // 查询指标 fields + Fields *string `json:"Fields,omitnil" name:"Fields"` + + // 查询的过滤条件 + Filter *string `json:"Filter,omitnil" name:"Filter"` + + // 查询简单过滤条件 + FilterSimple *string `json:"FilterSimple,omitnil" name:"FilterSimple"` + + // group by 条件 + GroupBy []*string `json:"GroupBy,omitnil" name:"GroupBy"` + + // order by 条件 + OrderBy []*string `json:"OrderBy,omitnil" name:"OrderBy"` + + // limit 参数 + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // offset 参数 + Offset *int64 `json:"Offset,omitnil" name:"Offset"` + + // 业务上下文参数 + BusinessContext *string `json:"BusinessContext,omitnil" name:"BusinessContext"` +} + +type DescribeAppDimensionMetricsRequest struct { + *tchttp.BaseRequest + + // app 项目ID + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` + + // 查询的表名 + From *string `json:"From,omitnil" name:"From"` + + // 查询指标 fields + Fields *string `json:"Fields,omitnil" name:"Fields"` + + // 查询的过滤条件 + Filter *string `json:"Filter,omitnil" name:"Filter"` + + // 查询简单过滤条件 + FilterSimple *string `json:"FilterSimple,omitnil" name:"FilterSimple"` + + // group by 条件 + GroupBy []*string `json:"GroupBy,omitnil" name:"GroupBy"` + + // order by 条件 + OrderBy []*string `json:"OrderBy,omitnil" name:"OrderBy"` + + // limit 参数 + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // offset 参数 + Offset *int64 `json:"Offset,omitnil" name:"Offset"` + + // 业务上下文参数 + BusinessContext *string `json:"BusinessContext,omitnil" name:"BusinessContext"` +} + +func (r *DescribeAppDimensionMetricsRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeAppDimensionMetricsRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "ProjectID") + delete(f, "From") + delete(f, "Fields") + delete(f, "Filter") + delete(f, "FilterSimple") + delete(f, "GroupBy") + delete(f, "OrderBy") + delete(f, "Limit") + delete(f, "Offset") + delete(f, "BusinessContext") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeAppDimensionMetricsRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeAppDimensionMetricsResponseParams struct { + // 查询数据返回 + Data *string `json:"Data,omitnil" name:"Data"` + + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type DescribeAppDimensionMetricsResponse struct { + *tchttp.BaseResponse + Response *DescribeAppDimensionMetricsResponseParams `json:"Response"` +} + +func (r *DescribeAppDimensionMetricsResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeAppDimensionMetricsResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeAppMetricsDataRequestParams struct { + // app 项目ID + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` + + // 查询的表名 + From *string `json:"From,omitnil" name:"From"` + + // 查询指标 field + Fields *string `json:"Fields,omitnil" name:"Fields"` + + // 查询的过滤条件 + Filter *string `json:"Filter,omitnil" name:"Filter"` + + // 查询简单过滤条件 + FilterSimple *string `json:"FilterSimple,omitnil" name:"FilterSimple"` + + // group by 条件 + GroupBy []*string `json:"GroupBy,omitnil" name:"GroupBy"` + + // order by 条件 + OrderBy []*string `json:"OrderBy,omitnil" name:"OrderBy"` + + // limit 参数 + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // offset 参数 + Offset *int64 `json:"Offset,omitnil" name:"Offset"` + + // group by 参数 + GroupByModifier *string `json:"GroupByModifier,omitnil" name:"GroupByModifier"` +} + +type DescribeAppMetricsDataRequest struct { + *tchttp.BaseRequest + + // app 项目ID + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` + + // 查询的表名 + From *string `json:"From,omitnil" name:"From"` + + // 查询指标 field + Fields *string `json:"Fields,omitnil" name:"Fields"` + + // 查询的过滤条件 + Filter *string `json:"Filter,omitnil" name:"Filter"` + + // 查询简单过滤条件 + FilterSimple *string `json:"FilterSimple,omitnil" name:"FilterSimple"` + + // group by 条件 + GroupBy []*string `json:"GroupBy,omitnil" name:"GroupBy"` + + // order by 条件 + OrderBy []*string `json:"OrderBy,omitnil" name:"OrderBy"` + + // limit 参数 + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // offset 参数 + Offset *int64 `json:"Offset,omitnil" name:"Offset"` + + // group by 参数 + GroupByModifier *string `json:"GroupByModifier,omitnil" name:"GroupByModifier"` +} + +func (r *DescribeAppMetricsDataRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeAppMetricsDataRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "ProjectID") + delete(f, "From") + delete(f, "Fields") + delete(f, "Filter") + delete(f, "FilterSimple") + delete(f, "GroupBy") + delete(f, "OrderBy") + delete(f, "Limit") + delete(f, "Offset") + delete(f, "GroupByModifier") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeAppMetricsDataRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeAppMetricsDataResponseParams struct { + // 查询数据返回 + Data *string `json:"Data,omitnil" name:"Data"` + + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type DescribeAppMetricsDataResponse struct { + *tchttp.BaseResponse + Response *DescribeAppMetricsDataResponseParams `json:"Response"` +} + +func (r *DescribeAppMetricsDataResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeAppMetricsDataResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeAppSingleCaseDetailListRequestParams struct { + // app 项目ID + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` + + // 查询的表名 + From *string `json:"From,omitnil" name:"From"` + + // 查询指标 field + Fields *string `json:"Fields,omitnil" name:"Fields"` + + // 查询的过滤条件 + Filter *string `json:"Filter,omitnil" name:"Filter"` + + // 查询简单过滤条件 + FilterSimple *string `json:"FilterSimple,omitnil" name:"FilterSimple"` + + // group by 条件 + GroupBy []*string `json:"GroupBy,omitnil" name:"GroupBy"` + + // order by 条件 + OrderBy []*string `json:"OrderBy,omitnil" name:"OrderBy"` + + // limit 参数 + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // offset 参数 + Offset *int64 `json:"Offset,omitnil" name:"Offset"` +} + +type DescribeAppSingleCaseDetailListRequest struct { + *tchttp.BaseRequest + + // app 项目ID + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` + + // 查询的表名 + From *string `json:"From,omitnil" name:"From"` + + // 查询指标 field + Fields *string `json:"Fields,omitnil" name:"Fields"` + + // 查询的过滤条件 + Filter *string `json:"Filter,omitnil" name:"Filter"` + + // 查询简单过滤条件 + FilterSimple *string `json:"FilterSimple,omitnil" name:"FilterSimple"` + + // group by 条件 + GroupBy []*string `json:"GroupBy,omitnil" name:"GroupBy"` + + // order by 条件 + OrderBy []*string `json:"OrderBy,omitnil" name:"OrderBy"` + + // limit 参数 + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // offset 参数 + Offset *int64 `json:"Offset,omitnil" name:"Offset"` +} + +func (r *DescribeAppSingleCaseDetailListRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeAppSingleCaseDetailListRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "ProjectID") + delete(f, "From") + delete(f, "Fields") + delete(f, "Filter") + delete(f, "FilterSimple") + delete(f, "GroupBy") + delete(f, "OrderBy") + delete(f, "Limit") + delete(f, "Offset") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeAppSingleCaseDetailListRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeAppSingleCaseDetailListResponseParams struct { + // 查询数据返回 + Data *string `json:"Data,omitnil" name:"Data"` + + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type DescribeAppSingleCaseDetailListResponse struct { + *tchttp.BaseResponse + Response *DescribeAppSingleCaseDetailListResponseParams `json:"Response"` +} + +func (r *DescribeAppSingleCaseDetailListResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeAppSingleCaseDetailListResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeAppSingleCaseListRequestParams struct { + // app 项目 ID + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` + + // 查询的表名 + From *string `json:"From,omitnil" name:"From"` + + // 查询指标 field + Fields *string `json:"Fields,omitnil" name:"Fields"` + + // 查询的过滤条件 + Filter *string `json:"Filter,omitnil" name:"Filter"` + + // 查询简单过滤条件 + FilterSimple *string `json:"FilterSimple,omitnil" name:"FilterSimple"` + + // group by 条件 + GroupBy []*string `json:"GroupBy,omitnil" name:"GroupBy"` + + // order by 条件 + OrderBy []*string `json:"OrderBy,omitnil" name:"OrderBy"` + + // limit 参数 + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // offset 参数 + Offset *int64 `json:"Offset,omitnil" name:"Offset"` +} + +type DescribeAppSingleCaseListRequest struct { + *tchttp.BaseRequest + + // app 项目 ID + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` + + // 查询的表名 + From *string `json:"From,omitnil" name:"From"` + + // 查询指标 field + Fields *string `json:"Fields,omitnil" name:"Fields"` + + // 查询的过滤条件 + Filter *string `json:"Filter,omitnil" name:"Filter"` + + // 查询简单过滤条件 + FilterSimple *string `json:"FilterSimple,omitnil" name:"FilterSimple"` + + // group by 条件 + GroupBy []*string `json:"GroupBy,omitnil" name:"GroupBy"` + + // order by 条件 + OrderBy []*string `json:"OrderBy,omitnil" name:"OrderBy"` + + // limit 参数 + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // offset 参数 + Offset *int64 `json:"Offset,omitnil" name:"Offset"` +} + +func (r *DescribeAppSingleCaseListRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeAppSingleCaseListRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "ProjectID") + delete(f, "From") + delete(f, "Fields") + delete(f, "Filter") + delete(f, "FilterSimple") + delete(f, "GroupBy") + delete(f, "OrderBy") + delete(f, "Limit") + delete(f, "Offset") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeAppSingleCaseListRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeAppSingleCaseListResponseParams struct { + // 查询数据返回 + Data *string `json:"Data,omitnil" name:"Data"` + + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type DescribeAppSingleCaseListResponse struct { + *tchttp.BaseResponse + Response *DescribeAppSingleCaseListResponseParams `json:"Response"` +} + +func (r *DescribeAppSingleCaseListResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeAppSingleCaseListResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + // Predefined struct for user type DescribeDataCustomUrlRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // top:资源top视图,allcount:性能视图,day:14天数据,condition:条件列表,pagepv:性能视图,area:请求速度分布,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 自定义测速的key的值 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } type DescribeDataCustomUrlRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // top:资源top视图,allcount:性能视图,day:14天数据,condition:条件列表,pagepv:性能视图,area:请求速度分布,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 自定义测速的key的值 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } func (r *DescribeDataCustomUrlRequest) ToJsonString() string { @@ -1293,10 +1784,10 @@ func (r *DescribeDataCustomUrlRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataCustomUrlResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataCustomUrlResponse struct { @@ -1318,140 +1809,140 @@ func (r *DescribeDataCustomUrlResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataEventUrlRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,day:14天数据,condition:条件列表,ckuv:获取uv趋势,ckpv:获取pv趋势,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 筛选条件 - Name *string `json:"Name,omitempty" name:"Name"` + Name *string `json:"Name,omitnil" name:"Name"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } type DescribeDataEventUrlRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,day:14天数据,condition:条件列表,ckuv:获取uv趋势,ckpv:获取pv趋势,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 筛选条件 - Name *string `json:"Name,omitempty" name:"Name"` + Name *string `json:"Name,omitnil" name:"Name"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } func (r *DescribeDataEventUrlRequest) ToJsonString() string { @@ -1497,10 +1988,10 @@ func (r *DescribeDataEventUrlRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataEventUrlResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataEventUrlResponse struct { @@ -1522,158 +2013,158 @@ func (r *DescribeDataEventUrlResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataFetchProjectRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,day:14天数据,condition:条件列表,area:请求速度分布,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` // httpcode响应码 - Status *string `json:"Status,omitempty" name:"Status"` + Status *string `json:"Status,omitnil" name:"Status"` // retcode - Ret *string `json:"Ret,omitempty" name:"Ret"` + Ret *string `json:"Ret,omitnil" name:"Ret"` } type DescribeDataFetchProjectRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,day:14天数据,condition:条件列表,area:请求速度分布,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` // httpcode响应码 - Status *string `json:"Status,omitempty" name:"Status"` + Status *string `json:"Status,omitnil" name:"Status"` // retcode - Ret *string `json:"Ret,omitempty" name:"Ret"` + Ret *string `json:"Ret,omitnil" name:"Ret"` } func (r *DescribeDataFetchProjectRequest) ToJsonString() string { @@ -1722,10 +2213,10 @@ func (r *DescribeDataFetchProjectRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataFetchProjectResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataFetchProjectResponse struct { @@ -1747,146 +2238,146 @@ func (r *DescribeDataFetchProjectResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataFetchUrlInfoRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 类型 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } type DescribeDataFetchUrlInfoRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 类型 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } func (r *DescribeDataFetchUrlInfoRequest) ToJsonString() string { @@ -1933,10 +2424,10 @@ func (r *DescribeDataFetchUrlInfoRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataFetchUrlInfoResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataFetchUrlInfoResponse struct { @@ -1958,164 +2449,164 @@ func (r *DescribeDataFetchUrlInfoResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataFetchUrlRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,day:14天数据,count40x:40X视图,count50x:50X视图,count5xand4x:40∑50视图,top:资源top视图,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` // httpcode响应码 - Status *string `json:"Status,omitempty" name:"Status"` + Status *string `json:"Status,omitnil" name:"Status"` // retcode - Ret *string `json:"Ret,omitempty" name:"Ret"` + Ret *string `json:"Ret,omitnil" name:"Ret"` // 网络状态 - NetStatus *string `json:"NetStatus,omitempty" name:"NetStatus"` + NetStatus *string `json:"NetStatus,omitnil" name:"NetStatus"` } type DescribeDataFetchUrlRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,day:14天数据,count40x:40X视图,count50x:50X视图,count5xand4x:40∑50视图,top:资源top视图,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` // httpcode响应码 - Status *string `json:"Status,omitempty" name:"Status"` + Status *string `json:"Status,omitnil" name:"Status"` // retcode - Ret *string `json:"Ret,omitempty" name:"Ret"` + Ret *string `json:"Ret,omitnil" name:"Ret"` // 网络状态 - NetStatus *string `json:"NetStatus,omitempty" name:"NetStatus"` + NetStatus *string `json:"NetStatus,omitnil" name:"NetStatus"` } func (r *DescribeDataFetchUrlRequest) ToJsonString() string { @@ -2165,10 +2656,10 @@ func (r *DescribeDataFetchUrlRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataFetchUrlResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataFetchUrlResponse struct { @@ -2190,26 +2681,26 @@ func (r *DescribeDataFetchUrlResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataLogUrlInfoRequestParams struct { // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 时间戳 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 时间戳 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` } type DescribeDataLogUrlInfoRequest struct { *tchttp.BaseRequest // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 时间戳 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 时间戳 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` } func (r *DescribeDataLogUrlInfoRequest) ToJsonString() string { @@ -2236,10 +2727,10 @@ func (r *DescribeDataLogUrlInfoRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataLogUrlInfoResponseParams struct { // 返回字符串 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataLogUrlInfoResponse struct { @@ -2261,134 +2752,134 @@ func (r *DescribeDataLogUrlInfoResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataLogUrlStatisticsRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // analysis:异常分析,compare:异常列表对比,allcount:性能视图,condition:条件列表,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 环境区分 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } type DescribeDataLogUrlStatisticsRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // analysis:异常分析,compare:异常列表对比,allcount:性能视图,condition:条件列表,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 环境区分 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } func (r *DescribeDataLogUrlStatisticsRequest) ToJsonString() string { @@ -2433,10 +2924,10 @@ func (r *DescribeDataLogUrlStatisticsRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataLogUrlStatisticsResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataLogUrlStatisticsResponse struct { @@ -2458,146 +2949,146 @@ func (r *DescribeDataLogUrlStatisticsResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataPerformancePageRequestParams struct { // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // pagepv:性能视图,allcount:性能视图,falls:页面加载瀑布图,samp:首屏时间,day:14天数据,nettype:网络/平台视图,performance:页面性能TOP视图,version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:ISP视图/地区视图/浏览器视图等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 环境变量 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` // 网络状态 - NetStatus *string `json:"NetStatus,omitempty" name:"NetStatus"` + NetStatus *string `json:"NetStatus,omitnil" name:"NetStatus"` } type DescribeDataPerformancePageRequest struct { *tchttp.BaseRequest // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // pagepv:性能视图,allcount:性能视图,falls:页面加载瀑布图,samp:首屏时间,day:14天数据,nettype:网络/平台视图,performance:页面性能TOP视图,version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:ISP视图/地区视图/浏览器视图等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 环境变量 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` // 网络状态 - NetStatus *string `json:"NetStatus,omitempty" name:"NetStatus"` + NetStatus *string `json:"NetStatus,omitnil" name:"NetStatus"` } func (r *DescribeDataPerformancePageRequest) ToJsonString() string { @@ -2644,10 +3135,10 @@ func (r *DescribeDataPerformancePageRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataPerformancePageResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataPerformancePageResponse struct { @@ -2669,140 +3160,140 @@ func (r *DescribeDataPerformancePageResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataPerformanceProjectRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,falls:页面加载瀑布图,samp:首屏时间,day:14天数据,nettype:网络/平台视图,performance:页面性能TOP视图,condition:条件列表,area:请求速度分布,version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:ISP视图/地区视图/浏览器视图等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } type DescribeDataPerformanceProjectRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,falls:页面加载瀑布图,samp:首屏时间,day:14天数据,nettype:网络/平台视图,performance:页面性能TOP视图,condition:条件列表,area:请求速度分布,version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:ISP视图/地区视图/浏览器视图等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } func (r *DescribeDataPerformanceProjectRequest) ToJsonString() string { @@ -2848,10 +3339,10 @@ func (r *DescribeDataPerformanceProjectRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataPerformanceProjectResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataPerformanceProjectResponse struct { @@ -2873,134 +3364,134 @@ func (r *DescribeDataPerformanceProjectResponse) FromJsonString(s string) error // Predefined struct for user type DescribeDataPvUrlInfoRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 类型 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } type DescribeDataPvUrlInfoRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 类型 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } func (r *DescribeDataPvUrlInfoRequest) ToJsonString() string { @@ -3045,10 +3536,10 @@ func (r *DescribeDataPvUrlInfoRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataPvUrlInfoResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataPvUrlInfoResponse struct { @@ -3070,134 +3561,142 @@ func (r *DescribeDataPvUrlInfoResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataPvUrlStatisticsRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,day:14天数据,vp:性能,ckuv:uv,ckpv:pv,condition:条件列表,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` + + // group by 参数值枚举1:1m 2:5m 3:30m 4:1h + // 5:1d + GroupByType *int64 `json:"GroupByType,omitnil" name:"GroupByType"` } type DescribeDataPvUrlStatisticsRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,day:14天数据,vp:性能,ckuv:uv,ckpv:pv,condition:条件列表,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` + + // group by 参数值枚举1:1m 2:5m 3:30m 4:1h + // 5:1d + GroupByType *int64 `json:"GroupByType,omitnil" name:"GroupByType"` } func (r *DescribeDataPvUrlStatisticsRequest) ToJsonString() string { @@ -3233,6 +3732,7 @@ func (r *DescribeDataPvUrlStatisticsRequest) FromJsonString(s string) error { delete(f, "Os") delete(f, "Browser") delete(f, "Env") + delete(f, "GroupByType") if len(f) > 0 { return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeDataPvUrlStatisticsRequest has unknown keys!", "") } @@ -3242,10 +3742,10 @@ func (r *DescribeDataPvUrlStatisticsRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataPvUrlStatisticsResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataPvUrlStatisticsResponse struct { @@ -3267,38 +3767,38 @@ func (r *DescribeDataPvUrlStatisticsResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataReportCountRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 上报类型 - ReportType *string `json:"ReportType,omitempty" name:"ReportType"` + ReportType *string `json:"ReportType,omitnil" name:"ReportType"` // 实例ID - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` } type DescribeDataReportCountRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 上报类型 - ReportType *string `json:"ReportType,omitempty" name:"ReportType"` + ReportType *string `json:"ReportType,omitnil" name:"ReportType"` // 实例ID - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` } func (r *DescribeDataReportCountRequest) ToJsonString() string { @@ -3327,10 +3827,10 @@ func (r *DescribeDataReportCountRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataReportCountResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataReportCountResponse struct { @@ -3352,20 +3852,20 @@ func (r *DescribeDataReportCountResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataRequestParams struct { // 查询字符串 - Query *string `json:"Query,omitempty" name:"Query"` + Query *string `json:"Query,omitnil" name:"Query"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } type DescribeDataRequest struct { *tchttp.BaseRequest // 查询字符串 - Query *string `json:"Query,omitempty" name:"Query"` + Query *string `json:"Query,omitnil" name:"Query"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } func (r *DescribeDataRequest) ToJsonString() string { @@ -3391,10 +3891,10 @@ func (r *DescribeDataRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataResponseParams struct { // 返回字符串 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataResponse struct { @@ -3416,146 +3916,146 @@ func (r *DescribeDataResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataSetUrlStatisticsRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,data:小程序,component:小程序相关,day:14天数据,nettype:网络/平台视图,performance:页面性能TOP视图,version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:ISP视图/地区视图/浏览器视图等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` // 获取package - PackageType *string `json:"PackageType,omitempty" name:"PackageType"` + PackageType *string `json:"PackageType,omitnil" name:"PackageType"` } type DescribeDataSetUrlStatisticsRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,data:小程序,component:小程序相关,day:14天数据,nettype:网络/平台视图,performance:页面性能TOP视图,version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:ISP视图/地区视图/浏览器视图等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` // 获取package - PackageType *string `json:"PackageType,omitempty" name:"PackageType"` + PackageType *string `json:"PackageType,omitnil" name:"PackageType"` } func (r *DescribeDataSetUrlStatisticsRequest) ToJsonString() string { @@ -3602,10 +4102,10 @@ func (r *DescribeDataSetUrlStatisticsRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataSetUrlStatisticsResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataSetUrlStatisticsResponse struct { @@ -3627,146 +4127,146 @@ func (r *DescribeDataSetUrlStatisticsResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataStaticProjectRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,day:14天数据,condition:条件列表,area:请求速度分布,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url []*string `json:"Url,omitempty" name:"Url"` + Url []*string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } type DescribeDataStaticProjectRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // allcount:性能视图,day:14天数据,condition:条件列表,area:请求速度分布,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图/ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url []*string `json:"Url,omitempty" name:"Url"` + Url []*string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } func (r *DescribeDataStaticProjectRequest) ToJsonString() string { @@ -3813,10 +4313,10 @@ func (r *DescribeDataStaticProjectRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataStaticProjectResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataStaticProjectResponse struct { @@ -3838,146 +4338,146 @@ func (r *DescribeDataStaticProjectResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataStaticResourceRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // top:资源top视图,count40x:40X视图,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图//ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } type DescribeDataStaticResourceRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // top:资源top视图,count40x:40X视图,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图//ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } func (r *DescribeDataStaticResourceRequest) ToJsonString() string { @@ -4024,10 +4524,10 @@ func (r *DescribeDataStaticResourceRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataStaticResourceResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataStaticResourceResponse struct { @@ -4049,146 +4549,146 @@ func (r *DescribeDataStaticResourceResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataStaticUrlRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // pagepv:性能视图,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图//ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } type DescribeDataStaticUrlRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // pagepv:性能视图,nettype/version/platform/isp/region/device/browser/ext1/ext2/ext3/ret/status/from/url/env/:网络平台视图/Version视图/设备视图/ISP视图/地区视图/浏览器视图//ext1视图等等 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算方式 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 来源 - Url *string `json:"Url,omitempty" name:"Url"` + Url *string `json:"Url,omitnil" name:"Url"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } func (r *DescribeDataStaticUrlRequest) ToJsonString() string { @@ -4235,10 +4735,10 @@ func (r *DescribeDataStaticUrlRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataStaticUrlResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataStaticUrlResponse struct { @@ -4260,140 +4760,140 @@ func (r *DescribeDataStaticUrlResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeDataWebVitalsPageRequestParams struct { // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 类型暂无 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } type DescribeDataWebVitalsPageRequest struct { *tchttp.BaseRequest // 开始时间 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 结束时间 - EndTime *int64 `json:"EndTime,omitempty" name:"EndTime"` + EndTime *int64 `json:"EndTime,omitnil" name:"EndTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 自定义2 - ExtSecond *string `json:"ExtSecond,omitempty" name:"ExtSecond"` + ExtSecond *string `json:"ExtSecond,omitnil" name:"ExtSecond"` // 浏览器引擎 - Engine *string `json:"Engine,omitempty" name:"Engine"` + Engine *string `json:"Engine,omitnil" name:"Engine"` // 运营商 - Isp *string `json:"Isp,omitempty" name:"Isp"` + Isp *string `json:"Isp,omitnil" name:"Isp"` // 来源页面 - From *string `json:"From,omitempty" name:"From"` + From *string `json:"From,omitnil" name:"From"` // 日志等级 - Level *string `json:"Level,omitempty" name:"Level"` + Level *string `json:"Level,omitnil" name:"Level"` // 类型暂无 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 品牌 - Brand *string `json:"Brand,omitempty" name:"Brand"` + Brand *string `json:"Brand,omitnil" name:"Brand"` // 地区 - Area *string `json:"Area,omitempty" name:"Area"` + Area *string `json:"Area,omitnil" name:"Area"` // 版本 - VersionNum *string `json:"VersionNum,omitempty" name:"VersionNum"` + VersionNum *string `json:"VersionNum,omitnil" name:"VersionNum"` // 平台 - Platform *string `json:"Platform,omitempty" name:"Platform"` + Platform *string `json:"Platform,omitnil" name:"Platform"` // 自定义3 - ExtThird *string `json:"ExtThird,omitempty" name:"ExtThird"` + ExtThird *string `json:"ExtThird,omitnil" name:"ExtThird"` // 自定义1 - ExtFirst *string `json:"ExtFirst,omitempty" name:"ExtFirst"` + ExtFirst *string `json:"ExtFirst,omitnil" name:"ExtFirst"` // 网络类型 - NetType *string `json:"NetType,omitempty" name:"NetType"` + NetType *string `json:"NetType,omitnil" name:"NetType"` // 机型 - Device *string `json:"Device,omitempty" name:"Device"` + Device *string `json:"Device,omitnil" name:"Device"` // 是否海外 - IsAbroad *string `json:"IsAbroad,omitempty" name:"IsAbroad"` + IsAbroad *string `json:"IsAbroad,omitnil" name:"IsAbroad"` // 操作系统 - Os *string `json:"Os,omitempty" name:"Os"` + Os *string `json:"Os,omitnil" name:"Os"` // 浏览器 - Browser *string `json:"Browser,omitempty" name:"Browser"` + Browser *string `json:"Browser,omitnil" name:"Browser"` // 耗时计算 - CostType *string `json:"CostType,omitempty" name:"CostType"` + CostType *string `json:"CostType,omitnil" name:"CostType"` // 环境 - Env *string `json:"Env,omitempty" name:"Env"` + Env *string `json:"Env,omitnil" name:"Env"` } func (r *DescribeDataWebVitalsPageRequest) ToJsonString() string { @@ -4439,10 +4939,10 @@ func (r *DescribeDataWebVitalsPageRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeDataWebVitalsPageResponseParams struct { // 返回值 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeDataWebVitalsPageResponse struct { @@ -4464,20 +4964,20 @@ func (r *DescribeDataWebVitalsPageResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeErrorRequestParams struct { // 日期 - Date *string `json:"Date,omitempty" name:"Date"` + Date *string `json:"Date,omitnil" name:"Date"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } type DescribeErrorRequest struct { *tchttp.BaseRequest // 日期 - Date *string `json:"Date,omitempty" name:"Date"` + Date *string `json:"Date,omitnil" name:"Date"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } func (r *DescribeErrorRequest) ToJsonString() string { @@ -4503,16 +5003,16 @@ func (r *DescribeErrorRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeErrorResponseParams struct { // 内容 - Content *string `json:"Content,omitempty" name:"Content"` + Content *string `json:"Content,omitnil" name:"Content"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 时间 - CreateTime *string `json:"CreateTime,omitempty" name:"CreateTime"` + CreateTime *string `json:"CreateTime,omitnil" name:"CreateTime"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeErrorResponse struct { @@ -4534,14 +5034,14 @@ func (r *DescribeErrorResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeLogExportsRequestParams struct { // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } type DescribeLogExportsRequest struct { *tchttp.BaseRequest // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } func (r *DescribeLogExportsRequest) ToJsonString() string { @@ -4566,10 +5066,10 @@ func (r *DescribeLogExportsRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeLogExportsResponseParams struct { // 日志导出记录列表 - LogExportSet []*LogExport `json:"LogExportSet,omitempty" name:"LogExportSet"` + LogExportSet []*LogExport `json:"LogExportSet,omitnil" name:"LogExportSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeLogExportsResponse struct { @@ -4591,56 +5091,56 @@ func (r *DescribeLogExportsResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeLogListRequestParams struct { // 排序方式 desc asc(必填) - Sort *string `json:"Sort,omitempty" name:"Sort"` + Sort *string `json:"Sort,omitnil" name:"Sort"` // searchlog histogram(必填) - ActionType *string `json:"ActionType,omitempty" name:"ActionType"` + ActionType *string `json:"ActionType,omitnil" name:"ActionType"` // 项目ID(必填) - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 开始时间(必填) - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 单次查询返回的原始日志条数,最大值为100(必填) - Limit *int64 `json:"Limit,omitempty" name:"Limit"` + Limit *int64 `json:"Limit,omitnil" name:"Limit"` // 上下文,加载更多日志时使用,透传上次返回的 Context 值,获取后续的日志内容,总计最多可获取1万条原始日志。过期时间1小时 - Context *string `json:"Context,omitempty" name:"Context"` + Context *string `json:"Context,omitnil" name:"Context"` // 查询语句,参考控制台请求参数,语句长度最大为4096(必填)例:"id:120001 AND type:\"log\"" - Query *string `json:"Query,omitempty" name:"Query"` + Query *string `json:"Query,omitnil" name:"Query"` // 结束时间(必填) - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` } type DescribeLogListRequest struct { *tchttp.BaseRequest // 排序方式 desc asc(必填) - Sort *string `json:"Sort,omitempty" name:"Sort"` + Sort *string `json:"Sort,omitnil" name:"Sort"` // searchlog histogram(必填) - ActionType *string `json:"ActionType,omitempty" name:"ActionType"` + ActionType *string `json:"ActionType,omitnil" name:"ActionType"` // 项目ID(必填) - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 开始时间(必填) - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 单次查询返回的原始日志条数,最大值为100(必填) - Limit *int64 `json:"Limit,omitempty" name:"Limit"` + Limit *int64 `json:"Limit,omitnil" name:"Limit"` // 上下文,加载更多日志时使用,透传上次返回的 Context 值,获取后续的日志内容,总计最多可获取1万条原始日志。过期时间1小时 - Context *string `json:"Context,omitempty" name:"Context"` + Context *string `json:"Context,omitnil" name:"Context"` // 查询语句,参考控制台请求参数,语句长度最大为4096(必填)例:"id:120001 AND type:\"log\"" - Query *string `json:"Query,omitempty" name:"Query"` + Query *string `json:"Query,omitnil" name:"Query"` // 结束时间(必填) - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` } func (r *DescribeLogListRequest) ToJsonString() string { @@ -4672,10 +5172,10 @@ func (r *DescribeLogListRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeLogListResponseParams struct { // 返回字符串 - Result *string `json:"Result,omitempty" name:"Result"` + Result *string `json:"Result,omitnil" name:"Result"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeLogListResponse struct { @@ -4697,14 +5197,14 @@ func (r *DescribeLogListResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeOfflineLogConfigsRequestParams struct { // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` } type DescribeOfflineLogConfigsRequest struct { *tchttp.BaseRequest // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` } func (r *DescribeOfflineLogConfigsRequest) ToJsonString() string { @@ -4729,13 +5229,13 @@ func (r *DescribeOfflineLogConfigsRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeOfflineLogConfigsResponseParams struct { // 接口调用信息 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 用户唯一标示数组 - UniqueIDSet []*string `json:"UniqueIDSet,omitempty" name:"UniqueIDSet"` + UniqueIDSet []*string `json:"UniqueIDSet,omitnil" name:"UniqueIDSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeOfflineLogConfigsResponse struct { @@ -4757,14 +5257,14 @@ func (r *DescribeOfflineLogConfigsResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeOfflineLogRecordsRequestParams struct { // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` } type DescribeOfflineLogRecordsRequest struct { *tchttp.BaseRequest // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` } func (r *DescribeOfflineLogRecordsRequest) ToJsonString() string { @@ -4789,13 +5289,13 @@ func (r *DescribeOfflineLogRecordsRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeOfflineLogRecordsResponseParams struct { // 接口调用信息 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 记录 ID 数组 - RecordSet []*string `json:"RecordSet,omitempty" name:"RecordSet"` + RecordSet []*string `json:"RecordSet,omitnil" name:"RecordSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeOfflineLogRecordsResponse struct { @@ -4817,20 +5317,20 @@ func (r *DescribeOfflineLogRecordsResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeOfflineLogsRequestParams struct { // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` // 离线日志文件 id 列表 - FileIDs []*string `json:"FileIDs,omitempty" name:"FileIDs"` + FileIDs []*string `json:"FileIDs,omitnil" name:"FileIDs"` } type DescribeOfflineLogsRequest struct { *tchttp.BaseRequest // 项目唯一上报 key - ProjectKey *string `json:"ProjectKey,omitempty" name:"ProjectKey"` + ProjectKey *string `json:"ProjectKey,omitnil" name:"ProjectKey"` // 离线日志文件 id 列表 - FileIDs []*string `json:"FileIDs,omitempty" name:"FileIDs"` + FileIDs []*string `json:"FileIDs,omitnil" name:"FileIDs"` } func (r *DescribeOfflineLogsRequest) ToJsonString() string { @@ -4856,13 +5356,13 @@ func (r *DescribeOfflineLogsRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeOfflineLogsResponseParams struct { // 接口调用返回信息 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 日志列表 - LogSet []*string `json:"LogSet,omitempty" name:"LogSet"` + LogSet []*string `json:"LogSet,omitnil" name:"LogSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeOfflineLogsResponse struct { @@ -4884,14 +5384,14 @@ func (r *DescribeOfflineLogsResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeProjectLimitsRequestParams struct { // 项目ID - ProjectID *int64 `json:"ProjectID,omitempty" name:"ProjectID"` + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` } type DescribeProjectLimitsRequest struct { *tchttp.BaseRequest // 项目ID - ProjectID *int64 `json:"ProjectID,omitempty" name:"ProjectID"` + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` } func (r *DescribeProjectLimitsRequest) ToJsonString() string { @@ -4916,10 +5416,10 @@ func (r *DescribeProjectLimitsRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeProjectLimitsResponseParams struct { // 上报率数组列表 - ProjectLimitSet []*ProjectLimit `json:"ProjectLimitSet,omitempty" name:"ProjectLimitSet"` + ProjectLimitSet []*ProjectLimit `json:"ProjectLimitSet,omitnil" name:"ProjectLimitSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeProjectLimitsResponse struct { @@ -4941,32 +5441,32 @@ func (r *DescribeProjectLimitsResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeProjectsRequestParams struct { // 分页每页数目,整型 - Limit *uint64 `json:"Limit,omitempty" name:"Limit"` + Limit *uint64 `json:"Limit,omitnil" name:"Limit"` // 分页页码,整型 - Offset *uint64 `json:"Offset,omitempty" name:"Offset"` + Offset *uint64 `json:"Offset,omitnil" name:"Offset"` // 过滤参数;demo模式传{"Name": "IsDemo", "Values":["1"]} - Filters []*Filter `json:"Filters,omitempty" name:"Filters"` + Filters []*Filter `json:"Filters,omitnil" name:"Filters"` // 该参数已废弃,demo模式请在Filters内注明 - IsDemo *int64 `json:"IsDemo,omitempty" name:"IsDemo"` + IsDemo *int64 `json:"IsDemo,omitnil" name:"IsDemo"` } type DescribeProjectsRequest struct { *tchttp.BaseRequest // 分页每页数目,整型 - Limit *uint64 `json:"Limit,omitempty" name:"Limit"` + Limit *uint64 `json:"Limit,omitnil" name:"Limit"` // 分页页码,整型 - Offset *uint64 `json:"Offset,omitempty" name:"Offset"` + Offset *uint64 `json:"Offset,omitnil" name:"Offset"` // 过滤参数;demo模式传{"Name": "IsDemo", "Values":["1"]} - Filters []*Filter `json:"Filters,omitempty" name:"Filters"` + Filters []*Filter `json:"Filters,omitnil" name:"Filters"` // 该参数已废弃,demo模式请在Filters内注明 - IsDemo *int64 `json:"IsDemo,omitempty" name:"IsDemo"` + IsDemo *int64 `json:"IsDemo,omitnil" name:"IsDemo"` } func (r *DescribeProjectsRequest) ToJsonString() string { @@ -4994,13 +5494,13 @@ func (r *DescribeProjectsRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeProjectsResponseParams struct { // 列表总数 - TotalCount *uint64 `json:"TotalCount,omitempty" name:"TotalCount"` + TotalCount *uint64 `json:"TotalCount,omitnil" name:"TotalCount"` // 项目列表 - ProjectSet []*RumProject `json:"ProjectSet,omitempty" name:"ProjectSet"` + ProjectSet []*RumProject `json:"ProjectSet,omitnil" name:"ProjectSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeProjectsResponse struct { @@ -5022,32 +5522,32 @@ func (r *DescribeProjectsResponse) FromJsonString(s string) error { // Predefined struct for user type DescribePvListRequestParams struct { // ID - ProjectId *int64 `json:"ProjectId,omitempty" name:"ProjectId"` + ProjectId *int64 `json:"ProjectId,omitnil" name:"ProjectId"` // 结束时间 - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` // 开始时间 - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 获取day:d, 获取min则不填 - Dimension *string `json:"Dimension,omitempty" name:"Dimension"` + Dimension *string `json:"Dimension,omitnil" name:"Dimension"` } type DescribePvListRequest struct { *tchttp.BaseRequest // ID - ProjectId *int64 `json:"ProjectId,omitempty" name:"ProjectId"` + ProjectId *int64 `json:"ProjectId,omitnil" name:"ProjectId"` // 结束时间 - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` // 开始时间 - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 获取day:d, 获取min则不填 - Dimension *string `json:"Dimension,omitempty" name:"Dimension"` + Dimension *string `json:"Dimension,omitnil" name:"Dimension"` } func (r *DescribePvListRequest) ToJsonString() string { @@ -5076,10 +5576,10 @@ func (r *DescribePvListRequest) FromJsonString(s string) error { type DescribePvListResponseParams struct { // pv列表 // 注意:此字段可能返回 null,表示取不到有效值。 - ProjectPvSet []*RumPvInfo `json:"ProjectPvSet,omitempty" name:"ProjectPvSet"` + ProjectPvSet []*RumPvInfo `json:"ProjectPvSet,omitnil" name:"ProjectPvSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribePvListResponse struct { @@ -5101,14 +5601,20 @@ func (r *DescribePvListResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeReleaseFileSignRequestParams struct { // 超时时间,不填默认是 5 分钟 - Timeout *int64 `json:"Timeout,omitempty" name:"Timeout"` + Timeout *int64 `json:"Timeout,omitnil" name:"Timeout"` + + // bucket类型,不填默认web,2:app + FileType *int64 `json:"FileType,omitnil" name:"FileType"` } type DescribeReleaseFileSignRequest struct { *tchttp.BaseRequest // 超时时间,不填默认是 5 分钟 - Timeout *int64 `json:"Timeout,omitempty" name:"Timeout"` + Timeout *int64 `json:"Timeout,omitnil" name:"Timeout"` + + // bucket类型,不填默认web,2:app + FileType *int64 `json:"FileType,omitnil" name:"FileType"` } func (r *DescribeReleaseFileSignRequest) ToJsonString() string { @@ -5124,6 +5630,7 @@ func (r *DescribeReleaseFileSignRequest) FromJsonString(s string) error { return err } delete(f, "Timeout") + delete(f, "FileType") if len(f) > 0 { return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeReleaseFileSignRequest has unknown keys!", "") } @@ -5133,22 +5640,22 @@ func (r *DescribeReleaseFileSignRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeReleaseFileSignResponseParams struct { // 临时密钥key - SecretKey *string `json:"SecretKey,omitempty" name:"SecretKey"` + SecretKey *string `json:"SecretKey,omitnil" name:"SecretKey"` // 临时密钥 id - SecretID *string `json:"SecretID,omitempty" name:"SecretID"` + SecretID *string `json:"SecretID,omitnil" name:"SecretID"` // 临时密钥临时 token - SessionToken *string `json:"SessionToken,omitempty" name:"SessionToken"` + SessionToken *string `json:"SessionToken,omitnil" name:"SessionToken"` // 开始时间戳 - StartTime *int64 `json:"StartTime,omitempty" name:"StartTime"` + StartTime *int64 `json:"StartTime,omitnil" name:"StartTime"` // 过期时间戳 - ExpiredTime *int64 `json:"ExpiredTime,omitempty" name:"ExpiredTime"` + ExpiredTime *int64 `json:"ExpiredTime,omitnil" name:"ExpiredTime"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeReleaseFileSignResponse struct { @@ -5170,20 +5677,20 @@ func (r *DescribeReleaseFileSignResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeReleaseFilesRequestParams struct { // 项目 id - ProjectID *int64 `json:"ProjectID,omitempty" name:"ProjectID"` + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` // 文件版本 - FileVersion *string `json:"FileVersion,omitempty" name:"FileVersion"` + FileVersion *string `json:"FileVersion,omitnil" name:"FileVersion"` } type DescribeReleaseFilesRequest struct { *tchttp.BaseRequest // 项目 id - ProjectID *int64 `json:"ProjectID,omitempty" name:"ProjectID"` + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` // 文件版本 - FileVersion *string `json:"FileVersion,omitempty" name:"FileVersion"` + FileVersion *string `json:"FileVersion,omitnil" name:"FileVersion"` } func (r *DescribeReleaseFilesRequest) ToJsonString() string { @@ -5209,10 +5716,10 @@ func (r *DescribeReleaseFilesRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeReleaseFilesResponseParams struct { // 文件信息列表 - Files []*ReleaseFile `json:"Files,omitempty" name:"Files"` + Files []*ReleaseFile `json:"Files,omitnil" name:"Files"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeReleaseFilesResponse struct { @@ -5232,34 +5739,487 @@ func (r *DescribeReleaseFilesResponse) FromJsonString(s string) error { } // Predefined struct for user -type DescribeScoresRequestParams struct { - // 结束时间 - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` +type DescribeRumGroupLogRequestParams struct { + // 排序方式 desc asc(必填) + OrderBy *string `json:"OrderBy,omitnil" name:"OrderBy"` - // 开始时间 - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + // 开始时间(必填) + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` + + // 单次查询返回的原始日志条数,最大值为100(必填) + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // 页数,第几页 + Page *int64 `json:"Page,omitnil" name:"Page"` + + // 查询语句,参考控制台请求参数,语句长度最大为4096(必填) + Query *string `json:"Query,omitnil" name:"Query"` + + // 结束时间(必填) + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` + + // 项目ID(必填) + ID *int64 `json:"ID,omitnil" name:"ID"` + + // 聚合字段 + GroupField *string `json:"GroupField,omitnil" name:"GroupField"` +} + +type DescribeRumGroupLogRequest struct { + *tchttp.BaseRequest + + // 排序方式 desc asc(必填) + OrderBy *string `json:"OrderBy,omitnil" name:"OrderBy"` + + // 开始时间(必填) + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` + + // 单次查询返回的原始日志条数,最大值为100(必填) + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // 页数,第几页 + Page *int64 `json:"Page,omitnil" name:"Page"` + + // 查询语句,参考控制台请求参数,语句长度最大为4096(必填) + Query *string `json:"Query,omitnil" name:"Query"` + + // 结束时间(必填) + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` + + // 项目ID(必填) + ID *int64 `json:"ID,omitnil" name:"ID"` + + // 聚合字段 + GroupField *string `json:"GroupField,omitnil" name:"GroupField"` +} + +func (r *DescribeRumGroupLogRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeRumGroupLogRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "OrderBy") + delete(f, "StartTime") + delete(f, "Limit") + delete(f, "Page") + delete(f, "Query") + delete(f, "EndTime") + delete(f, "ID") + delete(f, "GroupField") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeRumGroupLogRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeRumGroupLogResponseParams struct { + // 返回字符串 + Result *string `json:"Result,omitnil" name:"Result"` + + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type DescribeRumGroupLogResponse struct { + *tchttp.BaseResponse + Response *DescribeRumGroupLogResponseParams `json:"Response"` +} + +func (r *DescribeRumGroupLogResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeRumGroupLogResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeRumLogExportRequestParams struct { + // 导出标识name + Name *string `json:"Name,omitnil" name:"Name"` + + // 开始时间(必填) + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` + + // 查询语句,参考控制台请求参数,语句长度最大为4096(必填) + Query *string `json:"Query,omitnil" name:"Query"` + + // 结束时间(必填) + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` + + // 项目ID(必填) + ID *int64 `json:"ID,omitnil" name:"ID"` + + // field条件 + Fields []*string `json:"Fields,omitnil" name:"Fields"` +} + +type DescribeRumLogExportRequest struct { + *tchttp.BaseRequest + + // 导出标识name + Name *string `json:"Name,omitnil" name:"Name"` + + // 开始时间(必填) + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` + + // 查询语句,参考控制台请求参数,语句长度最大为4096(必填) + Query *string `json:"Query,omitnil" name:"Query"` + + // 结束时间(必填) + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` + + // 项目ID(必填) + ID *int64 `json:"ID,omitnil" name:"ID"` + + // field条件 + Fields []*string `json:"Fields,omitnil" name:"Fields"` +} + +func (r *DescribeRumLogExportRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeRumLogExportRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "Name") + delete(f, "StartTime") + delete(f, "Query") + delete(f, "EndTime") + delete(f, "ID") + delete(f, "Fields") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeRumLogExportRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeRumLogExportResponseParams struct { + // 返回字符串 + Result *string `json:"Result,omitnil" name:"Result"` + + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type DescribeRumLogExportResponse struct { + *tchttp.BaseResponse + Response *DescribeRumLogExportResponseParams `json:"Response"` +} + +func (r *DescribeRumLogExportResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeRumLogExportResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeRumLogExportsRequestParams struct { + // 页面大小 + PageSize *int64 `json:"PageSize,omitnil" name:"PageSize"` + + // 页数,第几页 + PageNum *int64 `json:"PageNum,omitnil" name:"PageNum"` + + // 项目ID(必填) + ID *int64 `json:"ID,omitnil" name:"ID"` +} + +type DescribeRumLogExportsRequest struct { + *tchttp.BaseRequest + + // 页面大小 + PageSize *int64 `json:"PageSize,omitnil" name:"PageSize"` + + // 页数,第几页 + PageNum *int64 `json:"PageNum,omitnil" name:"PageNum"` + + // 项目ID(必填) + ID *int64 `json:"ID,omitnil" name:"ID"` +} + +func (r *DescribeRumLogExportsRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeRumLogExportsRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "PageSize") + delete(f, "PageNum") + delete(f, "ID") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeRumLogExportsRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeRumLogExportsResponseParams struct { + // 返回字符串 + Result *string `json:"Result,omitnil" name:"Result"` + + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type DescribeRumLogExportsResponse struct { + *tchttp.BaseResponse + Response *DescribeRumLogExportsResponseParams `json:"Response"` +} + +func (r *DescribeRumLogExportsResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeRumLogExportsResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeRumLogListRequestParams struct { + // 排序方式 desc asc(必填) + OrderBy *string `json:"OrderBy,omitnil" name:"OrderBy"` + + // 开始时间(必填)格式为时间戳 毫秒 + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` + + // 单次查询返回的原始日志条数,最大值为100(必填) + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // 页数,第几页 + Page *int64 `json:"Page,omitnil" name:"Page"` + + // 查询语句,参考控制台请求参数,语句长度最大为4096(必填) + Query *string `json:"Query,omitnil" name:"Query"` + + // 结束时间(必填)格式为时间戳 毫秒 + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` + + // 项目ID(必填) + ID *int64 `json:"ID,omitnil" name:"ID"` +} + +type DescribeRumLogListRequest struct { + *tchttp.BaseRequest + + // 排序方式 desc asc(必填) + OrderBy *string `json:"OrderBy,omitnil" name:"OrderBy"` + + // 开始时间(必填)格式为时间戳 毫秒 + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` + + // 单次查询返回的原始日志条数,最大值为100(必填) + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // 页数,第几页 + Page *int64 `json:"Page,omitnil" name:"Page"` + + // 查询语句,参考控制台请求参数,语句长度最大为4096(必填) + Query *string `json:"Query,omitnil" name:"Query"` + + // 结束时间(必填)格式为时间戳 毫秒 + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` + + // 项目ID(必填) + ID *int64 `json:"ID,omitnil" name:"ID"` +} + +func (r *DescribeRumLogListRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeRumLogListRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "OrderBy") + delete(f, "StartTime") + delete(f, "Limit") + delete(f, "Page") + delete(f, "Query") + delete(f, "EndTime") + delete(f, "ID") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeRumLogListRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeRumLogListResponseParams struct { + // 返回字符串 + Result *string `json:"Result,omitnil" name:"Result"` + + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type DescribeRumLogListResponse struct { + *tchttp.BaseResponse + Response *DescribeRumLogListResponseParams `json:"Response"` +} + +func (r *DescribeRumLogListResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeRumLogListResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeRumStatsLogListRequestParams struct { + // 开始时间(必填) + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` + + // 单次查询返回的原始日志条数,最大值为100(必填) + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // 查询语句,参考控制台请求参数,语句长度最大为4096(必填) + Query *string `json:"Query,omitnil" name:"Query"` + + // 结束时间(必填) + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` + + // 项目ID(必填) + ID *int64 `json:"ID,omitnil" name:"ID"` +} + +type DescribeRumStatsLogListRequest struct { + *tchttp.BaseRequest + + // 开始时间(必填) + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` + + // 单次查询返回的原始日志条数,最大值为100(必填) + Limit *int64 `json:"Limit,omitnil" name:"Limit"` + + // 查询语句,参考控制台请求参数,语句长度最大为4096(必填) + Query *string `json:"Query,omitnil" name:"Query"` + + // 结束时间(必填) + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` + + // 项目ID(必填) + ID *int64 `json:"ID,omitnil" name:"ID"` +} + +func (r *DescribeRumStatsLogListRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeRumStatsLogListRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "StartTime") + delete(f, "Limit") + delete(f, "Query") + delete(f, "EndTime") + delete(f, "ID") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "DescribeRumStatsLogListRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeRumStatsLogListResponseParams struct { + // 返回字符串 + Result *string `json:"Result,omitnil" name:"Result"` + + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type DescribeRumStatsLogListResponse struct { + *tchttp.BaseResponse + Response *DescribeRumStatsLogListResponseParams `json:"Response"` +} + +func (r *DescribeRumStatsLogListResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *DescribeRumStatsLogListResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type DescribeScoresRequestParams struct { + // 结束时间 + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` + + // 开始时间 + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 该参数已废弃 - IsDemo *int64 `json:"IsDemo,omitempty" name:"IsDemo"` + IsDemo *int64 `json:"IsDemo,omitnil" name:"IsDemo"` } type DescribeScoresRequest struct { *tchttp.BaseRequest // 结束时间 - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` // 开始时间 - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 项目ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 该参数已废弃 - IsDemo *int64 `json:"IsDemo,omitempty" name:"IsDemo"` + IsDemo *int64 `json:"IsDemo,omitnil" name:"IsDemo"` } func (r *DescribeScoresRequest) ToJsonString() string { @@ -5287,10 +6247,10 @@ func (r *DescribeScoresRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeScoresResponseParams struct { // 数组 - ScoreSet []*ScoreInfo `json:"ScoreSet,omitempty" name:"ScoreSet"` + ScoreSet []*ScoreInfo `json:"ScoreSet,omitnil" name:"ScoreSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeScoresResponse struct { @@ -5312,38 +6272,38 @@ func (r *DescribeScoresResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeTawAreasRequestParams struct { // 片区Id - AreaIds []*int64 `json:"AreaIds,omitempty" name:"AreaIds"` + AreaIds []*int64 `json:"AreaIds,omitnil" name:"AreaIds"` // 片区Key - AreaKeys []*string `json:"AreaKeys,omitempty" name:"AreaKeys"` + AreaKeys []*string `json:"AreaKeys,omitnil" name:"AreaKeys"` // 分页Limit - Limit *int64 `json:"Limit,omitempty" name:"Limit"` + Limit *int64 `json:"Limit,omitnil" name:"Limit"` // 片区状态(1=有效,2=无效) - AreaStatuses []*int64 `json:"AreaStatuses,omitempty" name:"AreaStatuses"` + AreaStatuses []*int64 `json:"AreaStatuses,omitnil" name:"AreaStatuses"` // 分页Offset - Offset *int64 `json:"Offset,omitempty" name:"Offset"` + Offset *int64 `json:"Offset,omitnil" name:"Offset"` } type DescribeTawAreasRequest struct { *tchttp.BaseRequest // 片区Id - AreaIds []*int64 `json:"AreaIds,omitempty" name:"AreaIds"` + AreaIds []*int64 `json:"AreaIds,omitnil" name:"AreaIds"` // 片区Key - AreaKeys []*string `json:"AreaKeys,omitempty" name:"AreaKeys"` + AreaKeys []*string `json:"AreaKeys,omitnil" name:"AreaKeys"` // 分页Limit - Limit *int64 `json:"Limit,omitempty" name:"Limit"` + Limit *int64 `json:"Limit,omitnil" name:"Limit"` // 片区状态(1=有效,2=无效) - AreaStatuses []*int64 `json:"AreaStatuses,omitempty" name:"AreaStatuses"` + AreaStatuses []*int64 `json:"AreaStatuses,omitnil" name:"AreaStatuses"` // 分页Offset - Offset *int64 `json:"Offset,omitempty" name:"Offset"` + Offset *int64 `json:"Offset,omitnil" name:"Offset"` } func (r *DescribeTawAreasRequest) ToJsonString() string { @@ -5372,13 +6332,13 @@ func (r *DescribeTawAreasRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeTawAreasResponseParams struct { // 片区总数 - TotalCount *int64 `json:"TotalCount,omitempty" name:"TotalCount"` + TotalCount *int64 `json:"TotalCount,omitnil" name:"TotalCount"` // 片区列表 - AreaSet []*RumAreaInfo `json:"AreaSet,omitempty" name:"AreaSet"` + AreaSet []*RumAreaInfo `json:"AreaSet,omitnil" name:"AreaSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeTawAreasResponse struct { @@ -5400,62 +6360,62 @@ func (r *DescribeTawAreasResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeTawInstancesRequestParams struct { // 计费状态 - ChargeStatuses []*int64 `json:"ChargeStatuses,omitempty" name:"ChargeStatuses"` + ChargeStatuses []*int64 `json:"ChargeStatuses,omitnil" name:"ChargeStatuses"` // 计费类型 - ChargeTypes []*int64 `json:"ChargeTypes,omitempty" name:"ChargeTypes"` + ChargeTypes []*int64 `json:"ChargeTypes,omitnil" name:"ChargeTypes"` // 分页Limit - Limit *int64 `json:"Limit,omitempty" name:"Limit"` + Limit *int64 `json:"Limit,omitnil" name:"Limit"` // 分页Offset - Offset *int64 `json:"Offset,omitempty" name:"Offset"` + Offset *int64 `json:"Offset,omitnil" name:"Offset"` // 片区Id - AreaIds []*int64 `json:"AreaIds,omitempty" name:"AreaIds"` + AreaIds []*int64 `json:"AreaIds,omitnil" name:"AreaIds"` - // 实例状态(1=创建中,2=运行中,3=异常,4=重启中,5=停止中,6=已停止,7=销毁中,8=已销毁) - InstanceStatuses []*int64 `json:"InstanceStatuses,omitempty" name:"InstanceStatuses"` + // 实例状态(1=创建中,2=运行中,3=异常,4=重启中,5=停止中,6=已停止,7=销毁中,8=已销毁), 该参数已废弃,请在Filters内注明 + InstanceStatuses []*int64 `json:"InstanceStatuses,omitnil" name:"InstanceStatuses"` - // 实例Id - InstanceIds []*string `json:"InstanceIds,omitempty" name:"InstanceIds"` + // 实例Id, 该参数已废弃,请在Filters内注明 + InstanceIds []*string `json:"InstanceIds,omitnil" name:"InstanceIds"` // 过滤参数;demo模式传{"Name": "IsDemo", "Values":["1"]} - Filters []*Filter `json:"Filters,omitempty" name:"Filters"` + Filters []*Filter `json:"Filters,omitnil" name:"Filters"` // 该参数已废弃,demo模式请在Filters内注明 - IsDemo *int64 `json:"IsDemo,omitempty" name:"IsDemo"` + IsDemo *int64 `json:"IsDemo,omitnil" name:"IsDemo"` } type DescribeTawInstancesRequest struct { *tchttp.BaseRequest // 计费状态 - ChargeStatuses []*int64 `json:"ChargeStatuses,omitempty" name:"ChargeStatuses"` + ChargeStatuses []*int64 `json:"ChargeStatuses,omitnil" name:"ChargeStatuses"` // 计费类型 - ChargeTypes []*int64 `json:"ChargeTypes,omitempty" name:"ChargeTypes"` + ChargeTypes []*int64 `json:"ChargeTypes,omitnil" name:"ChargeTypes"` // 分页Limit - Limit *int64 `json:"Limit,omitempty" name:"Limit"` + Limit *int64 `json:"Limit,omitnil" name:"Limit"` // 分页Offset - Offset *int64 `json:"Offset,omitempty" name:"Offset"` + Offset *int64 `json:"Offset,omitnil" name:"Offset"` // 片区Id - AreaIds []*int64 `json:"AreaIds,omitempty" name:"AreaIds"` + AreaIds []*int64 `json:"AreaIds,omitnil" name:"AreaIds"` - // 实例状态(1=创建中,2=运行中,3=异常,4=重启中,5=停止中,6=已停止,7=销毁中,8=已销毁) - InstanceStatuses []*int64 `json:"InstanceStatuses,omitempty" name:"InstanceStatuses"` + // 实例状态(1=创建中,2=运行中,3=异常,4=重启中,5=停止中,6=已停止,7=销毁中,8=已销毁), 该参数已废弃,请在Filters内注明 + InstanceStatuses []*int64 `json:"InstanceStatuses,omitnil" name:"InstanceStatuses"` - // 实例Id - InstanceIds []*string `json:"InstanceIds,omitempty" name:"InstanceIds"` + // 实例Id, 该参数已废弃,请在Filters内注明 + InstanceIds []*string `json:"InstanceIds,omitnil" name:"InstanceIds"` // 过滤参数;demo模式传{"Name": "IsDemo", "Values":["1"]} - Filters []*Filter `json:"Filters,omitempty" name:"Filters"` + Filters []*Filter `json:"Filters,omitnil" name:"Filters"` // 该参数已废弃,demo模式请在Filters内注明 - IsDemo *int64 `json:"IsDemo,omitempty" name:"IsDemo"` + IsDemo *int64 `json:"IsDemo,omitnil" name:"IsDemo"` } func (r *DescribeTawInstancesRequest) ToJsonString() string { @@ -5488,13 +6448,13 @@ func (r *DescribeTawInstancesRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeTawInstancesResponseParams struct { // 实例列表 - InstanceSet []*RumInstanceInfo `json:"InstanceSet,omitempty" name:"InstanceSet"` + InstanceSet []*RumInstanceInfo `json:"InstanceSet,omitnil" name:"InstanceSet"` // 实例总数 - TotalCount *int64 `json:"TotalCount,omitempty" name:"TotalCount"` + TotalCount *int64 `json:"TotalCount,omitnil" name:"TotalCount"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeTawInstancesResponse struct { @@ -5516,32 +6476,32 @@ func (r *DescribeTawInstancesResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeUvListRequestParams struct { // ID - ProjectId *int64 `json:"ProjectId,omitempty" name:"ProjectId"` + ProjectId *int64 `json:"ProjectId,omitnil" name:"ProjectId"` // 结束时间 - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` // 开始时间 - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 获取day:d, min:m - Dimension *string `json:"Dimension,omitempty" name:"Dimension"` + Dimension *string `json:"Dimension,omitnil" name:"Dimension"` } type DescribeUvListRequest struct { *tchttp.BaseRequest // ID - ProjectId *int64 `json:"ProjectId,omitempty" name:"ProjectId"` + ProjectId *int64 `json:"ProjectId,omitnil" name:"ProjectId"` // 结束时间 - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` // 开始时间 - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 获取day:d, min:m - Dimension *string `json:"Dimension,omitempty" name:"Dimension"` + Dimension *string `json:"Dimension,omitnil" name:"Dimension"` } func (r *DescribeUvListRequest) ToJsonString() string { @@ -5569,10 +6529,10 @@ func (r *DescribeUvListRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeUvListResponseParams struct { // uv列表 - ProjectUvSet []*RumUvInfo `json:"ProjectUvSet,omitempty" name:"ProjectUvSet"` + ProjectUvSet []*RumUvInfo `json:"ProjectUvSet,omitnil" name:"ProjectUvSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeUvListResponse struct { @@ -5594,14 +6554,14 @@ func (r *DescribeUvListResponse) FromJsonString(s string) error { // Predefined struct for user type DescribeWhitelistsRequestParams struct { // 实例instance-ID - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` } type DescribeWhitelistsRequest struct { *tchttp.BaseRequest // 实例instance-ID - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` } func (r *DescribeWhitelistsRequest) ToJsonString() string { @@ -5626,10 +6586,10 @@ func (r *DescribeWhitelistsRequest) FromJsonString(s string) error { // Predefined struct for user type DescribeWhitelistsResponseParams struct { // 白名单列表 - WhitelistSet []*Whitelist `json:"WhitelistSet,omitempty" name:"WhitelistSet"` + WhitelistSet []*Whitelist `json:"WhitelistSet,omitnil" name:"WhitelistSet"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type DescribeWhitelistsResponse struct { @@ -5650,73 +6610,73 @@ func (r *DescribeWhitelistsResponse) FromJsonString(s string) error { type Filter struct { // 一个或者多个过滤值。 - Values []*string `json:"Values,omitempty" name:"Values"` + Values []*string `json:"Values,omitnil" name:"Values"` // 过滤键的名称。 - Name *string `json:"Name,omitempty" name:"Name"` + Name *string `json:"Name,omitnil" name:"Name"` } type LogExport struct { // 日志导出路径 - CosPath *string `json:"CosPath,omitempty" name:"CosPath"` + CosPath *string `json:"CosPath,omitnil" name:"CosPath"` // 日志导出数量 - Count *int64 `json:"Count,omitempty" name:"Count"` + Count *int64 `json:"Count,omitnil" name:"Count"` // 日志导出任务创建时间 - CreateTime *string `json:"CreateTime,omitempty" name:"CreateTime"` + CreateTime *string `json:"CreateTime,omitnil" name:"CreateTime"` // 日志导出任务ID - ExportID *string `json:"ExportID,omitempty" name:"ExportID"` + ExportID *string `json:"ExportID,omitnil" name:"ExportID"` // 日志导出文件名 - FileName *string `json:"FileName,omitempty" name:"FileName"` + FileName *string `json:"FileName,omitnil" name:"FileName"` // 日志文件大小 - FileSize *int64 `json:"FileSize,omitempty" name:"FileSize"` + FileSize *int64 `json:"FileSize,omitnil" name:"FileSize"` // 日志导出格式 - Format *string `json:"Format,omitempty" name:"Format"` + Format *string `json:"Format,omitnil" name:"Format"` // 日志导出时间排序 - Order *string `json:"Order,omitempty" name:"Order"` + Order *string `json:"Order,omitnil" name:"Order"` // 日志导出查询语句 - Query *string `json:"Query,omitempty" name:"Query"` + Query *string `json:"Query,omitnil" name:"Query"` // 日志导出起始时间 - StartTime *string `json:"StartTime,omitempty" name:"StartTime"` + StartTime *string `json:"StartTime,omitnil" name:"StartTime"` // 日志导出结束时间 - EndTime *string `json:"EndTime,omitempty" name:"EndTime"` + EndTime *string `json:"EndTime,omitnil" name:"EndTime"` // 日志下载状态。Queuing:导出正在排队中,Processing:导出正在进行中,Complete:导出完成,Failed:导出失败,Expired:日志导出已过期(三天有效期)。 - Status *string `json:"Status,omitempty" name:"Status"` + Status *string `json:"Status,omitnil" name:"Status"` } // Predefined struct for user type ModifyInstanceRequestParams struct { // 要修改的实例id - InstanceId *string `json:"InstanceId,omitempty" name:"InstanceId"` + InstanceId *string `json:"InstanceId,omitnil" name:"InstanceId"` // 新的实例名称(长度最大不超过255) - InstanceName *string `json:"InstanceName,omitempty" name:"InstanceName"` + InstanceName *string `json:"InstanceName,omitnil" name:"InstanceName"` // 新的实例描述(长度最大不超过1024) - InstanceDesc *string `json:"InstanceDesc,omitempty" name:"InstanceDesc"` + InstanceDesc *string `json:"InstanceDesc,omitnil" name:"InstanceDesc"` } type ModifyInstanceRequest struct { *tchttp.BaseRequest // 要修改的实例id - InstanceId *string `json:"InstanceId,omitempty" name:"InstanceId"` + InstanceId *string `json:"InstanceId,omitnil" name:"InstanceId"` // 新的实例名称(长度最大不超过255) - InstanceName *string `json:"InstanceName,omitempty" name:"InstanceName"` + InstanceName *string `json:"InstanceName,omitnil" name:"InstanceName"` // 新的实例描述(长度最大不超过1024) - InstanceDesc *string `json:"InstanceDesc,omitempty" name:"InstanceDesc"` + InstanceDesc *string `json:"InstanceDesc,omitnil" name:"InstanceDesc"` } func (r *ModifyInstanceRequest) ToJsonString() string { @@ -5743,7 +6703,7 @@ func (r *ModifyInstanceRequest) FromJsonString(s string) error { // Predefined struct for user type ModifyInstanceResponseParams struct { // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type ModifyInstanceResponse struct { @@ -5765,38 +6725,38 @@ func (r *ModifyInstanceResponse) FromJsonString(s string) error { // Predefined struct for user type ModifyProjectLimitRequestParams struct { // 项目ID - ProjectID *int64 `json:"ProjectID,omitempty" name:"ProjectID"` + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` // 项目接口 - ProjectInterface *string `json:"ProjectInterface,omitempty" name:"ProjectInterface"` + ProjectInterface *string `json:"ProjectInterface,omitnil" name:"ProjectInterface"` // 上报比例 10代表10% - ReportRate *int64 `json:"ReportRate,omitempty" name:"ReportRate"` + ReportRate *int64 `json:"ReportRate,omitnil" name:"ReportRate"` // 上报类型 1:比例 2:上报量 - ReportType *int64 `json:"ReportType,omitempty" name:"ReportType"` + ReportType *int64 `json:"ReportType,omitnil" name:"ReportType"` // 主键ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } type ModifyProjectLimitRequest struct { *tchttp.BaseRequest // 项目ID - ProjectID *int64 `json:"ProjectID,omitempty" name:"ProjectID"` + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` // 项目接口 - ProjectInterface *string `json:"ProjectInterface,omitempty" name:"ProjectInterface"` + ProjectInterface *string `json:"ProjectInterface,omitnil" name:"ProjectInterface"` // 上报比例 10代表10% - ReportRate *int64 `json:"ReportRate,omitempty" name:"ReportRate"` + ReportRate *int64 `json:"ReportRate,omitnil" name:"ReportRate"` // 上报类型 1:比例 2:上报量 - ReportType *int64 `json:"ReportType,omitempty" name:"ReportType"` + ReportType *int64 `json:"ReportType,omitnil" name:"ReportType"` // 主键ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } func (r *ModifyProjectLimitRequest) ToJsonString() string { @@ -5826,10 +6786,10 @@ func (r *ModifyProjectLimitRequest) FromJsonString(s string) error { type ModifyProjectLimitResponseParams struct { // 返回信息 // 注意:此字段可能返回 null,表示取不到有效值。 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type ModifyProjectLimitResponse struct { @@ -5851,62 +6811,62 @@ func (r *ModifyProjectLimitResponse) FromJsonString(s string) error { // Predefined struct for user type ModifyProjectRequestParams struct { // 项目 id - ID *uint64 `json:"ID,omitempty" name:"ID"` + ID *uint64 `json:"ID,omitnil" name:"ID"` // 项目名(可选,不为空且最长为 200) - Name *string `json:"Name,omitempty" name:"Name"` + Name *string `json:"Name,omitnil" name:"Name"` // 项目网页地址(可选,最长为 256) - URL *string `json:"URL,omitempty" name:"URL"` + URL *string `json:"URL,omitnil" name:"URL"` // 项目仓库地址(可选,最长为 256) - Repo *string `json:"Repo,omitempty" name:"Repo"` + Repo *string `json:"Repo,omitnil" name:"Repo"` // 项目需要转移到的实例 id(可选) - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 项目采样率(可选) - Rate *string `json:"Rate,omitempty" name:"Rate"` + Rate *string `json:"Rate,omitnil" name:"Rate"` // 是否开启聚类(可选) - EnableURLGroup *uint64 `json:"EnableURLGroup,omitempty" name:"EnableURLGroup"` + EnableURLGroup *uint64 `json:"EnableURLGroup,omitnil" name:"EnableURLGroup"` // 项目类型(可接受值为 "web", "mp", "android", "ios", "node", "hippy", "weex", "viola", "rn") - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 项目描述(可选,最长为 1000) - Desc *string `json:"Desc,omitempty" name:"Desc"` + Desc *string `json:"Desc,omitnil" name:"Desc"` } type ModifyProjectRequest struct { *tchttp.BaseRequest // 项目 id - ID *uint64 `json:"ID,omitempty" name:"ID"` + ID *uint64 `json:"ID,omitnil" name:"ID"` // 项目名(可选,不为空且最长为 200) - Name *string `json:"Name,omitempty" name:"Name"` + Name *string `json:"Name,omitnil" name:"Name"` // 项目网页地址(可选,最长为 256) - URL *string `json:"URL,omitempty" name:"URL"` + URL *string `json:"URL,omitnil" name:"URL"` // 项目仓库地址(可选,最长为 256) - Repo *string `json:"Repo,omitempty" name:"Repo"` + Repo *string `json:"Repo,omitnil" name:"Repo"` // 项目需要转移到的实例 id(可选) - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 项目采样率(可选) - Rate *string `json:"Rate,omitempty" name:"Rate"` + Rate *string `json:"Rate,omitnil" name:"Rate"` // 是否开启聚类(可选) - EnableURLGroup *uint64 `json:"EnableURLGroup,omitempty" name:"EnableURLGroup"` + EnableURLGroup *uint64 `json:"EnableURLGroup,omitnil" name:"EnableURLGroup"` // 项目类型(可接受值为 "web", "mp", "android", "ios", "node", "hippy", "weex", "viola", "rn") - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 项目描述(可选,最长为 1000) - Desc *string `json:"Desc,omitempty" name:"Desc"` + Desc *string `json:"Desc,omitnil" name:"Desc"` } func (r *ModifyProjectRequest) ToJsonString() string { @@ -5939,13 +6899,13 @@ func (r *ModifyProjectRequest) FromJsonString(s string) error { // Predefined struct for user type ModifyProjectResponseParams struct { // 操作信息 - Msg *string `json:"Msg,omitempty" name:"Msg"` + Msg *string `json:"Msg,omitnil" name:"Msg"` // 项目id - ID *uint64 `json:"ID,omitempty" name:"ID"` + ID *uint64 `json:"ID,omitnil" name:"ID"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type ModifyProjectResponse struct { @@ -5966,50 +6926,50 @@ func (r *ModifyProjectResponse) FromJsonString(s string) error { type ProjectLimit struct { // 接口 - ProjectInterface *string `json:"ProjectInterface,omitempty" name:"ProjectInterface"` + ProjectInterface *string `json:"ProjectInterface,omitnil" name:"ProjectInterface"` // 上报率 - ReportRate *int64 `json:"ReportRate,omitempty" name:"ReportRate"` + ReportRate *int64 `json:"ReportRate,omitnil" name:"ReportRate"` // 上报类型 1:上报率 2:上报量限制 - ReportType *int64 `json:"ReportType,omitempty" name:"ReportType"` + ReportType *int64 `json:"ReportType,omitnil" name:"ReportType"` // 主键ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 项目ID - ProjectID *int64 `json:"ProjectID,omitempty" name:"ProjectID"` + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` } type ReleaseFile struct { // 文件版本 - Version *string `json:"Version,omitempty" name:"Version"` + Version *string `json:"Version,omitnil" name:"Version"` // 文件唯一 key - FileKey *string `json:"FileKey,omitempty" name:"FileKey"` + FileKey *string `json:"FileKey,omitnil" name:"FileKey"` // 文件名 - FileName *string `json:"FileName,omitempty" name:"FileName"` + FileName *string `json:"FileName,omitnil" name:"FileName"` // 文件哈希值 - FileHash *string `json:"FileHash,omitempty" name:"FileHash"` + FileHash *string `json:"FileHash,omitnil" name:"FileHash"` // 文件 id // 注意:此字段可能返回 null,表示取不到有效值。 - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` } // Predefined struct for user type ResumeInstanceRequestParams struct { // 需要恢复的实例id - InstanceId *string `json:"InstanceId,omitempty" name:"InstanceId"` + InstanceId *string `json:"InstanceId,omitnil" name:"InstanceId"` } type ResumeInstanceRequest struct { *tchttp.BaseRequest // 需要恢复的实例id - InstanceId *string `json:"InstanceId,omitempty" name:"InstanceId"` + InstanceId *string `json:"InstanceId,omitnil" name:"InstanceId"` } func (r *ResumeInstanceRequest) ToJsonString() string { @@ -6034,7 +6994,7 @@ func (r *ResumeInstanceRequest) FromJsonString(s string) error { // Predefined struct for user type ResumeInstanceResponseParams struct { // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type ResumeInstanceResponse struct { @@ -6053,197 +7013,263 @@ func (r *ResumeInstanceResponse) FromJsonString(s string) error { return json.Unmarshal([]byte(s), &r) } +// Predefined struct for user +type ResumeProjectRequestParams struct { + // 项目 id + ProjectId *int64 `json:"ProjectId,omitnil" name:"ProjectId"` +} + +type ResumeProjectRequest struct { + *tchttp.BaseRequest + + // 项目 id + ProjectId *int64 `json:"ProjectId,omitnil" name:"ProjectId"` +} + +func (r *ResumeProjectRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *ResumeProjectRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "ProjectId") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "ResumeProjectRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type ResumeProjectResponseParams struct { + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type ResumeProjectResponse struct { + *tchttp.BaseResponse + Response *ResumeProjectResponseParams `json:"Response"` +} + +func (r *ResumeProjectResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *ResumeProjectResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + type RumAreaInfo struct { // 片区Id - AreaId *int64 `json:"AreaId,omitempty" name:"AreaId"` + AreaId *int64 `json:"AreaId,omitnil" name:"AreaId"` // 片区状态(1=有效,2=无效) - AreaStatus *int64 `json:"AreaStatus,omitempty" name:"AreaStatus"` + AreaStatus *int64 `json:"AreaStatus,omitnil" name:"AreaStatus"` // 片区名称 - AreaName *string `json:"AreaName,omitempty" name:"AreaName"` + AreaName *string `json:"AreaName,omitnil" name:"AreaName"` // 片区Key - AreaKey *string `json:"AreaKey,omitempty" name:"AreaKey"` + AreaKey *string `json:"AreaKey,omitnil" name:"AreaKey"` // 地域码表 id - AreaRegionID *string `json:"AreaRegionID,omitempty" name:"AreaRegionID"` + AreaRegionID *string `json:"AreaRegionID,omitnil" name:"AreaRegionID"` // 地域码表 code 如 ap-xxx(xxx 为地域词) - AreaRegionCode *string `json:"AreaRegionCode,omitempty" name:"AreaRegionCode"` + AreaRegionCode *string `json:"AreaRegionCode,omitnil" name:"AreaRegionCode"` // 地域缩写 - AreaAbbr *string `json:"AreaAbbr,omitempty" name:"AreaAbbr"` + AreaAbbr *string `json:"AreaAbbr,omitnil" name:"AreaAbbr"` } type RumInstanceInfo struct { // 实例状态(1=创建中,2=运行中,3=异常,4=重启中,5=停止中,6=已停止,7=已删除) - InstanceStatus *int64 `json:"InstanceStatus,omitempty" name:"InstanceStatus"` + InstanceStatus *int64 `json:"InstanceStatus,omitnil" name:"InstanceStatus"` // 片区Id - AreaId *int64 `json:"AreaId,omitempty" name:"AreaId"` + AreaId *int64 `json:"AreaId,omitnil" name:"AreaId"` // 标签列表 - Tags []*Tag `json:"Tags,omitempty" name:"Tags"` + Tags []*Tag `json:"Tags,omitnil" name:"Tags"` // 实例Id - InstanceId *string `json:"InstanceId,omitempty" name:"InstanceId"` + InstanceId *string `json:"InstanceId,omitnil" name:"InstanceId"` // 集群Id - ClusterId *int64 `json:"ClusterId,omitempty" name:"ClusterId"` + ClusterId *int64 `json:"ClusterId,omitnil" name:"ClusterId"` // 实例描述 - InstanceDesc *string `json:"InstanceDesc,omitempty" name:"InstanceDesc"` + InstanceDesc *string `json:"InstanceDesc,omitnil" name:"InstanceDesc"` // 计费状态(1=使用中,2=已过期,3=已销毁,4=分配中,5=分配失败) - ChargeStatus *int64 `json:"ChargeStatus,omitempty" name:"ChargeStatus"` + ChargeStatus *int64 `json:"ChargeStatus,omitnil" name:"ChargeStatus"` // 计费类型(1=免费版,2=预付费,3=后付费) - ChargeType *int64 `json:"ChargeType,omitempty" name:"ChargeType"` + ChargeType *int64 `json:"ChargeType,omitnil" name:"ChargeType"` // 更新时间 - UpdatedAt *string `json:"UpdatedAt,omitempty" name:"UpdatedAt"` + UpdatedAt *string `json:"UpdatedAt,omitnil" name:"UpdatedAt"` // 数据保留时间(天) - DataRetentionDays *int64 `json:"DataRetentionDays,omitempty" name:"DataRetentionDays"` + DataRetentionDays *int64 `json:"DataRetentionDays,omitnil" name:"DataRetentionDays"` // 实例名称 - InstanceName *string `json:"InstanceName,omitempty" name:"InstanceName"` + InstanceName *string `json:"InstanceName,omitnil" name:"InstanceName"` // 创建时间 - CreatedAt *string `json:"CreatedAt,omitempty" name:"CreatedAt"` + CreatedAt *string `json:"CreatedAt,omitnil" name:"CreatedAt"` + + // 实例类型 1:原web相关类型 2:app端类型 + // 注意:此字段可能返回 null,表示取不到有效值。 + InstanceType *int64 `json:"InstanceType,omitnil" name:"InstanceType"` } type RumProject struct { // 项目名 - Name *string `json:"Name,omitempty" name:"Name"` + Name *string `json:"Name,omitnil" name:"Name"` // 创建者 id - Creator *string `json:"Creator,omitempty" name:"Creator"` + Creator *string `json:"Creator,omitnil" name:"Creator"` // 实例 id - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 项目类型 - Type *string `json:"Type,omitempty" name:"Type"` + Type *string `json:"Type,omitnil" name:"Type"` // 创建时间 - CreateTime *string `json:"CreateTime,omitempty" name:"CreateTime"` + CreateTime *string `json:"CreateTime,omitnil" name:"CreateTime"` // 项目仓库地址 // 注意:此字段可能返回 null,表示取不到有效值。 - Repo *string `json:"Repo,omitempty" name:"Repo"` + Repo *string `json:"Repo,omitnil" name:"Repo"` // 项目网址地址 // 注意:此字段可能返回 null,表示取不到有效值。 - URL *string `json:"URL,omitempty" name:"URL"` + URL *string `json:"URL,omitnil" name:"URL"` // 项目采样频率 - Rate *string `json:"Rate,omitempty" name:"Rate"` + Rate *string `json:"Rate,omitnil" name:"Rate"` // 项目唯一key(长度 12 位) - Key *string `json:"Key,omitempty" name:"Key"` + Key *string `json:"Key,omitnil" name:"Key"` // 是否开启url聚类 - EnableURLGroup *int64 `json:"EnableURLGroup,omitempty" name:"EnableURLGroup"` + EnableURLGroup *int64 `json:"EnableURLGroup,omitnil" name:"EnableURLGroup"` // 实例名 - InstanceName *string `json:"InstanceName,omitempty" name:"InstanceName"` + InstanceName *string `json:"InstanceName,omitnil" name:"InstanceName"` // 项目 ID - ID *int64 `json:"ID,omitempty" name:"ID"` + ID *int64 `json:"ID,omitnil" name:"ID"` // 实例 key - InstanceKey *string `json:"InstanceKey,omitempty" name:"InstanceKey"` + InstanceKey *string `json:"InstanceKey,omitnil" name:"InstanceKey"` // 项目描述 // 注意:此字段可能返回 null,表示取不到有效值。 - Desc *string `json:"Desc,omitempty" name:"Desc"` + Desc *string `json:"Desc,omitnil" name:"Desc"` // 是否星标 1:是 0:否 // 注意:此字段可能返回 null,表示取不到有效值。 - IsStar *int64 `json:"IsStar,omitempty" name:"IsStar"` + IsStar *int64 `json:"IsStar,omitnil" name:"IsStar"` // 项目状态(1 创建中,2 运行中,3 异常,4 重启中,5 停止中,6 已停止, 7 销毁中,8 已销毁) // 注意:此字段可能返回 null,表示取不到有效值。 - ProjectStatus *int64 `json:"ProjectStatus,omitempty" name:"ProjectStatus"` + ProjectStatus *int64 `json:"ProjectStatus,omitnil" name:"ProjectStatus"` + + // 日志接入点,用户忽略。 + // 注意:此字段可能返回 null,表示取不到有效值。 + AccessPoint *string `json:"AccessPoint,omitnil" name:"AccessPoint"` } type RumPvInfo struct { // 项目ID - ProjectId *int64 `json:"ProjectId,omitempty" name:"ProjectId"` + ProjectId *int64 `json:"ProjectId,omitnil" name:"ProjectId"` // pv访问量 // 注意:此字段可能返回 null,表示取不到有效值。 - Pv *string `json:"Pv,omitempty" name:"Pv"` + Pv *string `json:"Pv,omitnil" name:"Pv"` // 时间 - CreateTime *string `json:"CreateTime,omitempty" name:"CreateTime"` + CreateTime *string `json:"CreateTime,omitnil" name:"CreateTime"` } type RumUvInfo struct { // 项目ID - ProjectId *int64 `json:"ProjectId,omitempty" name:"ProjectId"` + ProjectId *int64 `json:"ProjectId,omitnil" name:"ProjectId"` // uv访问量 - Uv *string `json:"Uv,omitempty" name:"Uv"` + Uv *string `json:"Uv,omitnil" name:"Uv"` // 创建时间 - CreateTime *string `json:"CreateTime,omitempty" name:"CreateTime"` + CreateTime *string `json:"CreateTime,omitnil" name:"CreateTime"` } type ScoreInfo struct { // duration - StaticDuration *string `json:"StaticDuration,omitempty" name:"StaticDuration"` + StaticDuration *string `json:"StaticDuration,omitnil" name:"StaticDuration"` // pv - PagePv *string `json:"PagePv,omitempty" name:"PagePv"` + PagePv *string `json:"PagePv,omitnil" name:"PagePv"` // 失败 - ApiFail *string `json:"ApiFail,omitempty" name:"ApiFail"` + ApiFail *string `json:"ApiFail,omitnil" name:"ApiFail"` // 请求 - ApiNum *string `json:"ApiNum,omitempty" name:"ApiNum"` + ApiNum *string `json:"ApiNum,omitnil" name:"ApiNum"` // fail - StaticFail *string `json:"StaticFail,omitempty" name:"StaticFail"` + StaticFail *string `json:"StaticFail,omitnil" name:"StaticFail"` // 项目id - ProjectID *int64 `json:"ProjectID,omitempty" name:"ProjectID"` + ProjectID *int64 `json:"ProjectID,omitnil" name:"ProjectID"` // uv - PageUv *string `json:"PageUv,omitempty" name:"PageUv"` + PageUv *string `json:"PageUv,omitnil" name:"PageUv"` // 请求次数 - ApiDuration *string `json:"ApiDuration,omitempty" name:"ApiDuration"` + ApiDuration *string `json:"ApiDuration,omitnil" name:"ApiDuration"` // 分数 - Score *string `json:"Score,omitempty" name:"Score"` + Score *string `json:"Score,omitnil" name:"Score"` // error - PageError *string `json:"PageError,omitempty" name:"PageError"` + PageError *string `json:"PageError,omitnil" name:"PageError"` // num - StaticNum *string `json:"StaticNum,omitempty" name:"StaticNum"` + StaticNum *string `json:"StaticNum,omitnil" name:"StaticNum"` // num - RecordNum *int64 `json:"RecordNum,omitempty" name:"RecordNum"` + RecordNum *int64 `json:"RecordNum,omitnil" name:"RecordNum"` // Duration - PageDuration *string `json:"PageDuration,omitempty" name:"PageDuration"` + PageDuration *string `json:"PageDuration,omitnil" name:"PageDuration"` + + // 时间 + // 注意:此字段可能返回 null,表示取不到有效值。 + CreateTime *string `json:"CreateTime,omitnil" name:"CreateTime"` } // Predefined struct for user type StopInstanceRequestParams struct { // 需要停止的实例id - InstanceId *string `json:"InstanceId,omitempty" name:"InstanceId"` + InstanceId *string `json:"InstanceId,omitnil" name:"InstanceId"` } type StopInstanceRequest struct { *tchttp.BaseRequest // 需要停止的实例id - InstanceId *string `json:"InstanceId,omitempty" name:"InstanceId"` + InstanceId *string `json:"InstanceId,omitnil" name:"InstanceId"` } func (r *StopInstanceRequest) ToJsonString() string { @@ -6268,7 +7294,7 @@ func (r *StopInstanceRequest) FromJsonString(s string) error { // Predefined struct for user type StopInstanceResponseParams struct { // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 - RequestId *string `json:"RequestId,omitempty" name:"RequestId"` + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` } type StopInstanceResponse struct { @@ -6287,36 +7313,90 @@ func (r *StopInstanceResponse) FromJsonString(s string) error { return json.Unmarshal([]byte(s), &r) } +// Predefined struct for user +type StopProjectRequestParams struct { + // 项目 id + ProjectId *int64 `json:"ProjectId,omitnil" name:"ProjectId"` +} + +type StopProjectRequest struct { + *tchttp.BaseRequest + + // 项目 id + ProjectId *int64 `json:"ProjectId,omitnil" name:"ProjectId"` +} + +func (r *StopProjectRequest) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *StopProjectRequest) FromJsonString(s string) error { + f := make(map[string]interface{}) + if err := json.Unmarshal([]byte(s), &f); err != nil { + return err + } + delete(f, "ProjectId") + if len(f) > 0 { + return tcerr.NewTencentCloudSDKError("ClientError.BuildRequestError", "StopProjectRequest has unknown keys!", "") + } + return json.Unmarshal([]byte(s), &r) +} + +// Predefined struct for user +type StopProjectResponseParams struct { + // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 + RequestId *string `json:"RequestId,omitnil" name:"RequestId"` +} + +type StopProjectResponse struct { + *tchttp.BaseResponse + Response *StopProjectResponseParams `json:"Response"` +} + +func (r *StopProjectResponse) ToJsonString() string { + b, _ := json.Marshal(r) + return string(b) +} + +// FromJsonString It is highly **NOT** recommended to use this function +// because it has no param check, nor strict type check +func (r *StopProjectResponse) FromJsonString(s string) error { + return json.Unmarshal([]byte(s), &r) +} + type Tag struct { // 标签key - Key *string `json:"Key,omitempty" name:"Key"` + Key *string `json:"Key,omitnil" name:"Key"` // 标签value - Value *string `json:"Value,omitempty" name:"Value"` + Value *string `json:"Value,omitnil" name:"Value"` } type Whitelist struct { // 备注 - Remark *string `json:"Remark,omitempty" name:"Remark"` + Remark *string `json:"Remark,omitnil" name:"Remark"` // 实例ID - InstanceID *string `json:"InstanceID,omitempty" name:"InstanceID"` + InstanceID *string `json:"InstanceID,omitnil" name:"InstanceID"` // 截止时间 - Ttl *string `json:"Ttl,omitempty" name:"Ttl"` + Ttl *string `json:"Ttl,omitnil" name:"Ttl"` // 白名单自增ID - ID *string `json:"ID,omitempty" name:"ID"` + ID *string `json:"ID,omitnil" name:"ID"` // 业务唯一标识 - WhitelistUin *string `json:"WhitelistUin,omitempty" name:"WhitelistUin"` + WhitelistUin *string `json:"WhitelistUin,omitnil" name:"WhitelistUin"` // 创建者ID - CreateUser *string `json:"CreateUser,omitempty" name:"CreateUser"` + CreateUser *string `json:"CreateUser,omitnil" name:"CreateUser"` // aid标识 - Aid *string `json:"Aid,omitempty" name:"Aid"` + Aid *string `json:"Aid,omitnil" name:"Aid"` // 创建时间 - CreateTime *string `json:"CreateTime,omitempty" name:"CreateTime"` + CreateTime *string `json:"CreateTime,omitnil" name:"CreateTime"` } \ No newline at end of file diff --git a/vendor/modules.txt b/vendor/modules.txt index 13a71c53b2..a4feb125c9 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -1221,7 +1221,7 @@ github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/pts/v20210728 # github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/redis v1.0.657 ## explicit; go 1.14 github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/redis/v20180412 -# github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum v1.0.542 +# github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum v1.0.744 ## explicit; go 1.14 github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/rum/v20210622 # github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/scf v1.0.729 diff --git a/website/docs/d/rum_custom_url.html.markdown b/website/docs/d/rum_custom_url.html.markdown new file mode 100644 index 0000000000..9cfcd07304 --- /dev/null +++ b/website/docs/d/rum_custom_url.html.markdown @@ -0,0 +1,79 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_custom_url" +sidebar_current: "docs-tencentcloud-datasource-rum_custom_url" +description: |- + Use this data source to query detailed information of rum custom_url +--- + +# tencentcloud_rum_custom_url + +Use this data source to query detailed information of rum custom_url + +## Example Usage + +```hcl +data "tencentcloud_rum_custom_url" "custom_url" { + start_time = 1625444040 + type = "top" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Data Type. `top`: CostType Sorting order by top, `nettype`: CostType Sorting order by nettype, `allcount`: CostType allcount, `day`: CostType group by day, `condition`: CostType Sorting in condition, `pagepv`: CostType Sorting order by pagepv, `area`: CostType query in area, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `cost_type` - (Optional, String) The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile, `90`: 90th percentile, `95`: 95th percentile, `99`: 99th percentile, `99.5`: 99.5th percentile, `avg`: Mean. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `url` - (Optional, String) The URL Key where the data reporting takes place. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_event_url.html.markdown b/website/docs/d/rum_event_url.html.markdown new file mode 100644 index 0000000000..fdf16ffda4 --- /dev/null +++ b/website/docs/d/rum_event_url.html.markdown @@ -0,0 +1,77 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_event_url" +sidebar_current: "docs-tencentcloud-datasource-rum_event_url" +description: |- + Use this data source to query detailed information of rum event_url +--- + +# tencentcloud_rum_event_url + +Use this data source to query detailed information of rum event_url + +## Example Usage + +```hcl +data "tencentcloud_rum_event_url" "event_url" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + name = "test" + env = "production" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Data Type. `allcount`:CostType allcount, `day`:CostType group by day, `condition`:CostType group by condition, `ckuv`:CostType group by uv, `ckpv`:CostType group by pv, `nettype`: CostType sort by nettype, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `name` - (Optional, String) Event name for data reporting. +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_fetch_url.html.markdown b/website/docs/d/rum_fetch_url.html.markdown new file mode 100644 index 0000000000..26335c20be --- /dev/null +++ b/website/docs/d/rum_fetch_url.html.markdown @@ -0,0 +1,85 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_fetch_url" +sidebar_current: "docs-tencentcloud-datasource-rum_fetch_url" +description: |- + Use this data source to query detailed information of rum fetch_url +--- + +# tencentcloud_rum_fetch_url + +Use this data source to query detailed information of rum fetch_url + +## Example Usage + +```hcl +data "tencentcloud_rum_fetch_url" "fetch_url" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" + status = "200" + ret = "0" + net_status = "0" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Data Type. `allcount`:CostType allcount, `day`:CostType group by day, `count40x`: CostType Sorting order by statusCode(40x) count, `count50x`: CostType Sorting order by statusCode(50x) count, `count5xand4x`: CostType Sorting order by statusCode(40x) count and statusCode(50x) count, `top`:CostType Sorting order by top, `nettype`: CostType sort by nettype, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `cost_type` - (Optional, String) The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_status` - (Optional, String) The network status where the data reporting takes place.`0`: noraml, `1`: week, `2`: disconnection, `3`: unknown. +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `ret` - (Optional, String) Remote request response body code. +* `status` - (Optional, String) HTTP protocol response code. +* `url` - (Optional, String) The URL Key where the data reporting takes place. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_fetch_url_info.html.markdown b/website/docs/d/rum_fetch_url_info.html.markdown new file mode 100644 index 0000000000..9f7cbb790d --- /dev/null +++ b/website/docs/d/rum_fetch_url_info.html.markdown @@ -0,0 +1,79 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_fetch_url_info" +sidebar_current: "docs-tencentcloud-datasource-rum_fetch_url_info" +description: |- + Use this data source to query detailed information of rum fetch_url_info +--- + +# tencentcloud_rum_fetch_url_info + +Use this data source to query detailed information of rum fetch_url_info + +## Example Usage + +```hcl +data "tencentcloud_rum_fetch_url_info" "fetch_url_info" { + start_time = 1625444040 + type = "top" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Data type. `top`: CostType Sorting order by top. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `cost_type` - (Optional, String) The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `url` - (Optional, String) The URL Key where the data reporting takes place. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_group_log.html.markdown b/website/docs/d/rum_group_log.html.markdown new file mode 100644 index 0000000000..d8aa6cc296 --- /dev/null +++ b/website/docs/d/rum_group_log.html.markdown @@ -0,0 +1,45 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_group_log" +sidebar_current: "docs-tencentcloud-datasource-rum_group_log" +description: |- + Use this data source to query detailed information of rum group_log +--- + +# tencentcloud_rum_group_log + +Use this data source to query detailed information of rum group_log + +## Example Usage + +```hcl +data "tencentcloud_rum_group_log" "group_log" { + order_by = "desc" + start_time = 1625444040000 + query = "id:123 AND type:"log"" + end_time = 1625454840000 + project_id = 1 + group_field = "level" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, String) End time but is represented using a timestamp in milliseconds. +* `group_field` - (Required, String) The field used for group. +* `order_by` - (Required, String) Sorting method. `desc`:Descending order; `asc`: Ascending order. +* `project_id` - (Required, Int) Project ID. +* `query` - (Required, String) Log Query syntax statement. +* `start_time` - (Required, String) Start time but is represented using a timestamp in milliseconds. +* `result_output_file` - (Optional, String) Used to save results. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_log_list.html.markdown b/website/docs/d/rum_log_list.html.markdown new file mode 100644 index 0000000000..7a925e7afe --- /dev/null +++ b/website/docs/d/rum_log_list.html.markdown @@ -0,0 +1,43 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_log_list" +sidebar_current: "docs-tencentcloud-datasource-rum_log_list" +description: |- + Use this data source to query detailed information of rum log_list +--- + +# tencentcloud_rum_log_list + +Use this data source to query detailed information of rum log_list + +## Example Usage + +```hcl +data "tencentcloud_rum_log_list" "log_list" { + order_by = "desc" + start_time = 1625444040000 + query = "id:123 AND type:"log"" + end_time = 1625454840000 + project_id = 1 +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, String) End time but is represented using a timestamp in milliseconds. +* `order_by` - (Required, String) Sorting method. `desc`:Descending order; `asc`: Ascending order. +* `project_id` - (Required, Int) Project ID. +* `query` - (Required, String) Log Query syntax statement. +* `start_time` - (Required, String) Start time but is represented using a timestamp in milliseconds. +* `result_output_file` - (Optional, String) Used to save results. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_log_url_statistics.html.markdown b/website/docs/d/rum_log_url_statistics.html.markdown new file mode 100644 index 0000000000..3e627a3c66 --- /dev/null +++ b/website/docs/d/rum_log_url_statistics.html.markdown @@ -0,0 +1,75 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_log_url_statistics" +sidebar_current: "docs-tencentcloud-datasource-rum_log_url_statistics" +description: |- + Use this data source to query detailed information of rum log_url_statistics +--- + +# tencentcloud_rum_log_url_statistics + +Use this data source to query detailed information of rum log_url_statistics + +## Example Usage + +```hcl +data "tencentcloud_rum_log_url_statistics" "log_url_statistics" { + start_time = 1625444040 + type = "analysis" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + env = "production" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Data Type. `analysis`:query analysis data, `compare`:query compare data, `allcount`:query allcount, `condition`:query in condition, `nettype`: CostType sort by nettype, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_performance_page.html.markdown b/website/docs/d/rum_performance_page.html.markdown new file mode 100644 index 0000000000..393da2024c --- /dev/null +++ b/website/docs/d/rum_performance_page.html.markdown @@ -0,0 +1,79 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_performance_page" +sidebar_current: "docs-tencentcloud-datasource-rum_performance_page" +description: |- + Use this data source to query detailed information of rum performance_page +--- + +# tencentcloud_rum_performance_page + +Use this data source to query detailed information of rum performance_page + +## Example Usage + +```hcl +data "tencentcloud_rum_performance_page" "performance_page" { + project_id = 1 + start_time = 1625444040 + end_time = 1625454840 + type = "pagepv" + level = "1" + isp = "中国电信" + area = "广州市" + net_type = "2" + platform = "2" + device = "Apple - iPhone" + version_num = "1.0" + ext_first = "ext1" + ext_second = "ext2" + ext_third = "ext3" + is_abroad = "0" + browser = "Chrome(79.0)" + os = "Windows - 10" + engine = "Blink(79.0)" + brand = "Apple" + from = "https://user.qzone.qq.com/" + cost_type = "50" + env = "production" + net_status = "0" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Data Type. `pagepv`: CostType query by pagepv, `allcount`: CostType query allcount, `falls`: CostType query by falls, `samp`: CostType query by samp, `day`: CostType query by day, `nettype`: CostType query by nettype, `performance`: CostType query by performance `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `cost_type` - (Optional, String) The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_status` - (Optional, String) The network status where the data reporting takes place.`0`: noraml, `1`: week, `2`: disconnection, `3`: unknown. +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_pv_url_info.html.markdown b/website/docs/d/rum_pv_url_info.html.markdown new file mode 100644 index 0000000000..53d35d6b74 --- /dev/null +++ b/website/docs/d/rum_pv_url_info.html.markdown @@ -0,0 +1,75 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_pv_url_info" +sidebar_current: "docs-tencentcloud-datasource-rum_pv_url_info" +description: |- + Use this data source to query detailed information of rum pv_url_info +--- + +# tencentcloud_rum_pv_url_info + +Use this data source to query detailed information of rum pv_url_info + +## Example Usage + +```hcl +data "tencentcloud_rum_pv_url_info" "pv_url_info" { + start_time = 1625444040 + type = "pagepv" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + env = "production" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Type value is fixed, please always pass `pagepv`. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_pv_url_statistics.html.markdown b/website/docs/d/rum_pv_url_statistics.html.markdown new file mode 100644 index 0000000000..0052d1b401 --- /dev/null +++ b/website/docs/d/rum_pv_url_statistics.html.markdown @@ -0,0 +1,77 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_pv_url_statistics" +sidebar_current: "docs-tencentcloud-datasource-rum_pv_url_statistics" +description: |- + Use this data source to query detailed information of rum pv_url_statistics +--- + +# tencentcloud_rum_pv_url_statistics + +Use this data source to query detailed information of rum pv_url_statistics + +## Example Usage + +```hcl +data "tencentcloud_rum_pv_url_statistics" "pv_url_statistics" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + env = "production" + group_by_type = 1 +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Date Type. `allcount`:CostType allcount, `day`:CostType group by day, `vp`: CostType group by vp, `ckuv`:CostType group by uv, `ckpv`:CostType group by pv, `ckwau`:CostType group by ckwau, `ckmau`:CostType group by ckmau, `condition`:CostType group by condition, `nettype`: CostType sort by nettype, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `group_by_type` - (Optional, Int) Query groupby type `1`: 1m, `2`: 5m, `3`: 30m, `4`: 1h, `5`: 1d. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_report_count.html.markdown b/website/docs/d/rum_report_count.html.markdown new file mode 100644 index 0000000000..d6372e50b1 --- /dev/null +++ b/website/docs/d/rum_report_count.html.markdown @@ -0,0 +1,43 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_report_count" +sidebar_current: "docs-tencentcloud-datasource-rum_report_count" +description: |- + Use this data source to query detailed information of rum report_count +--- + +# tencentcloud_rum_report_count + +Use this data source to query detailed information of rum report_count + +## Example Usage + +```hcl +data "tencentcloud_rum_report_count" "report_count" { + start_time = 1625444040 + end_time = 1625454840 + project_id = 1 + report_type = "log" + instance_id = "rum-xxx" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `instance_id` - (Optional, String) Instance ID. +* `report_type` - (Optional, String) Report type, empty is meaning all type count. `log`:log report count, `pv`:pv report count, `event`:event report count, `speed`:speed report count, `performance`:performance report count, `custom`:custom report count, `webvitals`:webvitals report count, `miniProgramData`:miniProgramData report count. +* `result_output_file` - (Optional, String) Used to save results. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_rum_log_stats_log_list.html.markdown b/website/docs/d/rum_rum_log_stats_log_list.html.markdown new file mode 100644 index 0000000000..f9d2ae5476 --- /dev/null +++ b/website/docs/d/rum_rum_log_stats_log_list.html.markdown @@ -0,0 +1,41 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_rum_log_stats_log_list" +sidebar_current: "docs-tencentcloud-datasource-rum_rum_log_stats_log_list" +description: |- + Use this data source to query detailed information of rum rum_log_stats_log_list +--- + +# tencentcloud_rum_rum_log_stats_log_list + +Use this data source to query detailed information of rum rum_log_stats_log_list + +## Example Usage + +```hcl +data "tencentcloud_rum_rum_log_stats_log_list" "rum_log_stats_log_list" { + start_time = 1625444040 + query = "id:123 AND type:"log"" + end_time = 1625454840 + project_id = 1 +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, String) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `query` - (Required, String) Log Query syntax statement. +* `start_time` - (Required, String) Start time but is represented using a timestamp in seconds. +* `result_output_file` - (Optional, String) Used to save results. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_scores.html.markdown b/website/docs/d/rum_scores.html.markdown new file mode 100644 index 0000000000..fcf766807f --- /dev/null +++ b/website/docs/d/rum_scores.html.markdown @@ -0,0 +1,55 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_scores" +sidebar_current: "docs-tencentcloud-datasource-rum_scores" +description: |- + Use this data source to query detailed information of rum scores +--- + +# tencentcloud_rum_scores + +Use this data source to query detailed information of rum scores + +## Example Usage + +```hcl +data "tencentcloud_rum_scores" "scores" { + end_time = "2023082215" + start_time = "2023082214" + project_id = 1 + is_demo = 1 +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, String) End time. +* `start_time` - (Required, String) Start time. +* `is_demo` - (Optional, Int) Get data from demo. This parameter is deprecated. +* `project_id` - (Optional, Int) Project ID. +* `result_output_file` - (Optional, String) Used to save results. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `score_set` - Score list. + * `api_duration` - The mean duration of api request. + * `api_fail` - The number of failed api. + * `api_num` - The number of all request api. + * `create_time` - Project record created time. + * `page_duration` - The duration of page load. + * `page_error` - The number of exception which happend on page. + * `page_pv` - Pv. + * `page_uv` - User view. + * `project_id` - Project ID. + * `record_num` - The number of record. + * `score` - The score of project. + * `static_duration` - Duration. + * `static_fail` - The number of failed request static resource. + * `static_num` - The number of static resource on page. + + diff --git a/website/docs/d/rum_set_url_statistics.html.markdown b/website/docs/d/rum_set_url_statistics.html.markdown new file mode 100644 index 0000000000..0a5de632cc --- /dev/null +++ b/website/docs/d/rum_set_url_statistics.html.markdown @@ -0,0 +1,79 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_set_url_statistics" +sidebar_current: "docs-tencentcloud-datasource-rum_set_url_statistics" +description: |- + Use this data source to query detailed information of rum set_url_statistics +--- + +# tencentcloud_rum_set_url_statistics + +Use this data source to query detailed information of rum set_url_statistics + +## Example Usage + +```hcl +data "tencentcloud_rum_set_url_statistics" "set_url_statistics" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + env = "production" + package_type = "loadPackage" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Data Type. `allcount`:CostType allcount, `data`: CostType group by data, `component`:miniProgram component, `day`:query data in day, `nettype`:query data group by nettype, `performance`:query data group by performance, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `cost_type` - (Optional, String) The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `package_type` - (Optional, String) Package Type. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_sign.html.markdown b/website/docs/d/rum_sign.html.markdown new file mode 100644 index 0000000000..237ce3d396 --- /dev/null +++ b/website/docs/d/rum_sign.html.markdown @@ -0,0 +1,41 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_sign" +sidebar_current: "docs-tencentcloud-datasource-rum_sign" +description: |- + Use this data source to query detailed information of rum sign +--- + +# tencentcloud_rum_sign + +Use this data source to query detailed information of rum sign + +## Example Usage + +```hcl +data "tencentcloud_rum_sign" "sign" { + timeout = 1800 + file_type = web +} +``` + +## Argument Reference + +The following arguments are supported: + +* `file_type` - (Optional, Int) Bucket type. `web`:web project; `app`:app project. +* `result_output_file` - (Optional, String) Used to save results. +* `timeout` - (Optional, Int) Timeout duration. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `expired_time` - Expiration timestamp. +* `secret_id` - Temporary access key ID. +* `secret_key` - Temporary access key. +* `session_token` - Temporary access key token. +* `start_time` - Start timestamp. + + diff --git a/website/docs/d/rum_static_project.html.markdown b/website/docs/d/rum_static_project.html.markdown new file mode 100644 index 0000000000..78ed20823a --- /dev/null +++ b/website/docs/d/rum_static_project.html.markdown @@ -0,0 +1,79 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_static_project" +sidebar_current: "docs-tencentcloud-datasource-rum_static_project" +description: |- + Use this data source to query detailed information of rum static_project +--- + +# tencentcloud_rum_static_project + +Use this data source to query detailed information of rum static_project + +## Example Usage + +```hcl +data "tencentcloud_rum_static_project" "static_project" { + start_time = 1625444040 + type = "allcount" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Data Type. `allcount`: CostType allcount, `day`: CostType group by day, `condition`: CostType Sorting in condition, `area`: CostType query in area, `nettype`: CostType sort by nettype, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: CostType sort by region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `cost_type` - (Optional, String) The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `url` - (Optional, String) The URL Key where the data reporting takes place. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_static_resource.html.markdown b/website/docs/d/rum_static_resource.html.markdown new file mode 100644 index 0000000000..0ddcda81f3 --- /dev/null +++ b/website/docs/d/rum_static_resource.html.markdown @@ -0,0 +1,79 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_static_resource" +sidebar_current: "docs-tencentcloud-datasource-rum_static_resource" +description: |- + Use this data source to query detailed information of rum static_resource +--- + +# tencentcloud_rum_static_resource + +Use this data source to query detailed information of rum static_resource + +## Example Usage + +```hcl +data "tencentcloud_rum_static_resource" "static_resource" { + start_time = 1625444040 + type = "top" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Data Type. `top`: CostType Sorting order by top, `count40x`: CostType Sorting order by statusCode(40x) count, `nettype`: CostType Sorting order by nettype, `allcount`: CostType allcount, `day`: CostType group by day, `condition`: CostType Sorting in condition, `pagepv`: CostType Sorting order by pagepv, `area`: CostType query in area, `version`: CostType sort by version, `platform`: CostType sort by platform, `isp`: CostType sort by isp, `region`: region, `device`: CostType sort by device, `browser`: CostType sort by browser, `ext1`: CostType sort by ext1, `ext2`: CostType sort by ext2, `ext3`: CostType sort by ext3, `ret`: CostType sort by ret, `status`: CostType sort by status, `from`: CostType sort by from, `url`: CostType sort by url, `env`: CostType sort by env. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `cost_type` - (Optional, String) The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `url` - (Optional, String) The URL Key where the data reporting takes place. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_static_url.html.markdown b/website/docs/d/rum_static_url.html.markdown new file mode 100644 index 0000000000..2731a7a071 --- /dev/null +++ b/website/docs/d/rum_static_url.html.markdown @@ -0,0 +1,79 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_static_url" +sidebar_current: "docs-tencentcloud-datasource-rum_static_url" +description: |- + Use this data source to query detailed information of rum static_url +--- + +# tencentcloud_rum_static_url + +Use this data source to query detailed information of rum static_url + +## Example Usage + +```hcl +data "tencentcloud_rum_static_url" "static_url" { + start_time = 1625444040 + type = "pagepv" + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + url = "http://qq.com/" + env = "production" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `type` - (Required, String) Query Data Type. `pagepv`: CostType query by pagepv, `nettype`: CostType group by nettype, `version`: CostType group by version, `platform`: CostType group by platform, `isp`: CostType group by isp, `region`: CostType group by region, `device`: CostType group by device, `browser`: CostType group by browser, `ext1`: CostType group by ext1, `ext2`: CostType group by ext2, `ext3`: CostType group by ext3, `ret`: CostType group by ret, `status`: CostType group by status, `from`: CostType group by from, `url`: CostType group by url, `env`: CostType group by env. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `cost_type` - (Optional, String) The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `url` - (Optional, String) The URL Key where the data reporting takes place. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/docs/d/rum_taw_area.html.markdown b/website/docs/d/rum_taw_area.html.markdown new file mode 100644 index 0000000000..e33ba18e77 --- /dev/null +++ b/website/docs/d/rum_taw_area.html.markdown @@ -0,0 +1,46 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_taw_area" +sidebar_current: "docs-tencentcloud-datasource-rum_taw_area" +description: |- + Use this data source to query detailed information of rum taw_area +--- + +# tencentcloud_rum_taw_area + +Use this data source to query detailed information of rum taw_area + +## Example Usage + +```hcl +data "tencentcloud_rum_taw_area" "taw_area" { + area_ids = + area_keys = + area_statuses = +} +``` + +## Argument Reference + +The following arguments are supported: + +* `area_ids` - (Optional, Set: [`Int`]) Area id. +* `area_keys` - (Optional, Set: [`String`]) Area key. +* `area_statuses` - (Optional, Set: [`Int`]) Area status `1`:valid; `2`:invalid. +* `result_output_file` - (Optional, String) Used to save results. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `area_set` - Area list. + * `area_abbr` - Region abbreviation. + * `area_id` - Area id. + * `area_key` - Area key. + * `area_name` - Area name. + * `area_region_code` - Area code. + * `area_region_id` - Area code id. + * `area_status` - Area status `1`:&#39;valid&#39;; `2`:&#39;invalid&#39;. + + diff --git a/website/docs/d/rum_web_vitals_page.html.markdown b/website/docs/d/rum_web_vitals_page.html.markdown new file mode 100644 index 0000000000..4c12d1b327 --- /dev/null +++ b/website/docs/d/rum_web_vitals_page.html.markdown @@ -0,0 +1,77 @@ +--- +subcategory: "Real User Monitoring(RUM)" +layout: "tencentcloud" +page_title: "TencentCloud: tencentcloud_rum_web_vitals_page" +sidebar_current: "docs-tencentcloud-datasource-rum_web_vitals_page" +description: |- + Use this data source to query detailed information of rum web_vitals_page +--- + +# tencentcloud_rum_web_vitals_page + +Use this data source to query detailed information of rum web_vitals_page + +## Example Usage + +```hcl +data "tencentcloud_rum_web_vitals_page" "web_vitals_page" { + start_time = 1625444040 + end_time = 1625454840 + project_id = 1 + ext_second = "ext2" + engine = "Blink(79.0)" + isp = "中国电信" + from = "https://user.qzone.qq.com/" + level = "1" + type = "from" + brand = "Apple" + area = "广州市" + version_num = "1.0" + platform = "2" + ext_third = "ext3" + ext_first = "ext1" + net_type = "2" + device = "Apple - iPhone" + is_abroad = "0" + os = "Windows - 10" + browser = "Chrome(79.0)" + cost_type = "50" + env = "production" +} +``` + +## Argument Reference + +The following arguments are supported: + +* `end_time` - (Required, Int) End time but is represented using a timestamp in seconds. +* `project_id` - (Required, Int) Project ID. +* `start_time` - (Required, Int) Start time but is represented using a timestamp in seconds. +* `area` - (Optional, String) The region where the data reporting takes place. +* `brand` - (Optional, String) The mobile phone brand used for data reporting. +* `browser` - (Optional, String) The browser type used for data reporting. +* `cost_type` - (Optional, String) The method used for calculating the elapsed time `50`: 50th percentile, `75`: 75th percentile., `90`: 90th percentile., `95`: 95th percentile., `99`: 99th percentile., `99.5`: 99.5th percentile., `avg`: Mean. +* `device` - (Optional, String) The device used for data reporting. +* `engine` - (Optional, String) The browser engine used for data reporting. +* `env` - (Optional, String) The code environment where the data reporting takes place.(`production`: production env, `development`: development env, `gray`: gray env, `pre`: pre env, `daily`: daily env, `local`: local env, `others`: others env). +* `ext_first` - (Optional, String) First Expansion parameter. +* `ext_second` - (Optional, String) Second Expansion parameter. +* `ext_third` - (Optional, String) Third Expansion parameter. +* `from` - (Optional, String) The source page of the data reporting. +* `is_abroad` - (Optional, String) Whether it is non-China region.`1`: yes; `0`: no. +* `isp` - (Optional, String) The internet service provider used for data reporting. +* `level` - (Optional, String) Log level for data reporting(`1`: whitelist, `2`: normal, `4`: error, `8`: promise error, `16`: ajax request error, `32`: js resource load error, `64`: image resource load error, `128`: css resource load error, `256`: console.error, `512`: video resource load error, `1024`: request retcode error, `2048`: sdk self monitor error, `4096`: pv log, `8192`: event log). +* `net_type` - (Optional, String) The network type used for data reporting.(`1`: Wifi, `2`: 2G, `3`: 3G, `4`: 4G, `5`: 5G, `6`: 6G, `100`: Unknown). +* `os` - (Optional, String) The operating system used for data reporting. +* `platform` - (Optional, String) The platform where the data reporting takes place.(`1`: Android, `2`: IOS, `3`: Windows, `4`: Mac, `5`: Linux, `100`: Other). +* `result_output_file` - (Optional, String) Used to save results. +* `type` - (Optional, String) Query Data Type(from or empty). `from`: CostType query by from. +* `version_num` - (Optional, String) The SDK version used for data reporting. + +## Attributes Reference + +In addition to all arguments above, the following attributes are exported: + +* `result` - Return value. + + diff --git a/website/tencentcloud.erb b/website/tencentcloud.erb index b87c6184e1..5fc9729e99 100644 --- a/website/tencentcloud.erb +++ b/website/tencentcloud.erb @@ -2332,15 +2332,75 @@
  • Data Sources