フィードバックのペイロードスキーマ
curl --request POST \
--url https://api.example.com/feedback/payload_schema \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"project_id": "<string>",
"start": "2023-11-07T05:31:56Z",
"end": "2023-11-07T05:31:56Z",
"feedback_type": "<string>",
"sample_limit": 2000,
"trigger_ref": "<string>"
}
'import requests
url = "https://api.example.com/feedback/payload_schema"
payload = {
"project_id": "<string>",
"start": "2023-11-07T05:31:56Z",
"end": "2023-11-07T05:31:56Z",
"feedback_type": "<string>",
"sample_limit": 2000,
"trigger_ref": "<string>"
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Basic <encoded-value>', 'Content-Type': 'application/json'},
body: JSON.stringify({
project_id: '<string>',
start: '2023-11-07T05:31:56Z',
end: '2023-11-07T05:31:56Z',
feedback_type: '<string>',
sample_limit: 2000,
trigger_ref: '<string>'
})
};
fetch('https://api.example.com/feedback/payload_schema', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/feedback/payload_schema",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'project_id' => '<string>',
'start' => '2023-11-07T05:31:56Z',
'end' => '2023-11-07T05:31:56Z',
'feedback_type' => '<string>',
'sample_limit' => 2000,
'trigger_ref' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/feedback/payload_schema"
payload := strings.NewReader("{\n \"project_id\": \"<string>\",\n \"start\": \"2023-11-07T05:31:56Z\",\n \"end\": \"2023-11-07T05:31:56Z\",\n \"feedback_type\": \"<string>\",\n \"sample_limit\": 2000,\n \"trigger_ref\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/feedback/payload_schema")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/json")
.body("{\n \"project_id\": \"<string>\",\n \"start\": \"2023-11-07T05:31:56Z\",\n \"end\": \"2023-11-07T05:31:56Z\",\n \"feedback_type\": \"<string>\",\n \"sample_limit\": 2000,\n \"trigger_ref\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/feedback/payload_schema")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"project_id\": \"<string>\",\n \"start\": \"2023-11-07T05:31:56Z\",\n \"end\": \"2023-11-07T05:31:56Z\",\n \"feedback_type\": \"<string>\",\n \"sample_limit\": 2000,\n \"trigger_ref\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"paths": [
{
"json_path": "<string>",
"value_type": "numeric"
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}サンプル行からフィードバックペイロードのスキーマ(パスとタイプ)を特定します。
POST
/
feedback
/
payload_schema
フィードバックのペイロードスキーマ
curl --request POST \
--url https://api.example.com/feedback/payload_schema \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"project_id": "<string>",
"start": "2023-11-07T05:31:56Z",
"end": "2023-11-07T05:31:56Z",
"feedback_type": "<string>",
"sample_limit": 2000,
"trigger_ref": "<string>"
}
'import requests
url = "https://api.example.com/feedback/payload_schema"
payload = {
"project_id": "<string>",
"start": "2023-11-07T05:31:56Z",
"end": "2023-11-07T05:31:56Z",
"feedback_type": "<string>",
"sample_limit": 2000,
"trigger_ref": "<string>"
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Basic <encoded-value>', 'Content-Type': 'application/json'},
body: JSON.stringify({
project_id: '<string>',
start: '2023-11-07T05:31:56Z',
end: '2023-11-07T05:31:56Z',
feedback_type: '<string>',
sample_limit: 2000,
trigger_ref: '<string>'
})
};
fetch('https://api.example.com/feedback/payload_schema', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/feedback/payload_schema",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'project_id' => '<string>',
'start' => '2023-11-07T05:31:56Z',
'end' => '2023-11-07T05:31:56Z',
'feedback_type' => '<string>',
'sample_limit' => 2000,
'trigger_ref' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/feedback/payload_schema"
payload := strings.NewReader("{\n \"project_id\": \"<string>\",\n \"start\": \"2023-11-07T05:31:56Z\",\n \"end\": \"2023-11-07T05:31:56Z\",\n \"feedback_type\": \"<string>\",\n \"sample_limit\": 2000,\n \"trigger_ref\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/feedback/payload_schema")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/json")
.body("{\n \"project_id\": \"<string>\",\n \"start\": \"2023-11-07T05:31:56Z\",\n \"end\": \"2023-11-07T05:31:56Z\",\n \"feedback_type\": \"<string>\",\n \"sample_limit\": 2000,\n \"trigger_ref\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/feedback/payload_schema")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"project_id\": \"<string>\",\n \"start\": \"2023-11-07T05:31:56Z\",\n \"end\": \"2023-11-07T05:31:56Z\",\n \"feedback_type\": \"<string>\",\n \"sample_limit\": 2000,\n \"trigger_ref\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"paths": [
{
"json_path": "<string>",
"value_type": "numeric"
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}承認
HTTPBasicHTTPBearer
Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.
ボディ
application/json
フィードバックのペイロード スキーマを検出するためのリクエスト。
開始時刻(UTC、ISO 8601、含む)。
終了時刻(UTC、ISO 8601、含まない)。省略した場合は現在時刻がデフォルトです。
feedback_type でフィルターします。
ペイロード スキーマの検出時にサンプリングする、重複のない trigger_ref の最大数です。通常、各 trigger_ref(monitor/source)ではペイロード構造は固定されているため、ref ごとに 1 つのペイロードをサンプリングすれば、完全なスキーマを確認するには十分です。2,000 で実運用のほぼすべてのプロジェクトをカバーしつつ、クエリを高速に保てます。5,000 のハード上限により、過剰なスキャンを防止します。
必須範囲:
1 <= x <= 5000trigger_ref でフィルターします(all-versions では完全一致またはプレフィックス一致)。
レスポンス
正常なレスポンス
検出されたフィードバック ペイロードのパスとタイプを含むResponse。
推定された値のタイプを持つ、検出済みのリーフ パス。
Show child attributes
Show child attributes
⌘I