{
“error”: {
“code”: 400,
“message”: “Invalid JSON payload received. Unknown name "": Root element must be a message.”,
“errors”: [
{
“message”: “Invalid JSON payload received. Unknown name "": Root element must be a message.”,
“reason”: “invalid”
}
],
“status”: “INVALID_ARGUMENT”,
“details”: [
{
“@type”: “type.googleapis.com/google.rpc.BadRequest”,
“fieldViolations”: [
{
“description”: “Invalid JSON payload received. Unknown name "": Root element must be a message.”
}
]
}
]
}
}
Please how do I fix this error.
here’s my scenario
output:
[
{
“statusCode”: 400,
“headers”: [
{
“name”: “vary”,
“value”: “X-Origin, Referer, Origin,Accept-Encoding”
},
{
“name”: “content-type”,
“value”: “application/json; charset=UTF-8”
},
{
“name”: “date”,
“value”: “Tue, 07 May 2024 20:22:36 GMT”
},
{
“name”: “server”,
“value”: “scaffolding on HTTPServer2”
},
{
“name”: “cache-control”,
“value”: “private”
},
{
“name”: “x-xss-protection”,
“value”: “0”
},
{
“name”: “x-frame-options”,
“value”: “SAMEORIGIN”
},
{
“name”: “x-content-type-options”,
“value”: “nosniff”
},
{
“name”: “accept-ranges”,
“value”: “none”
},
{
“name”: “transfer-encoding”,
“value”: “chunked”
},
{
“name”: “alt-svc”,
“value”: “h3=":443"; ma=2592000,h3-29=":443"; ma=2592000”
},
{
“name”: “connection”,
“value”: “close”
}
],
“cookieHeaders”: ,
“data”: “{\n "error": {\n "code": 400,\n "message": "Invalid JSON payload received. Unknown name \"\": Root element must be a message.",\n "errors": [\n {\n "message": "Invalid JSON payload received. Unknown name \"\": Root element must be a message.",\n "reason": "invalid"\n }\n ],\n "status": "INVALID_ARGUMENT",\n "details": [\n {\n "@type": "type.googleapis.com/google.rpc.BadRequest",\n "fieldViolations": [\n {\n "description": "Invalid JSON payload received. Unknown name \"\": Root element must be a message."\n }\n ]\n }\n ]\n }\n}\n”,
“fileSize”: 618
}
]
input:
[
{
“ca”: null,
“qs”: [
{
“name”: “part”,
“value”: “snippet”
}
],
“url”: “https://www.googleapis.com/youtube/v3/videos?”,
“data”: “"{\n \"id\": bmQls6zbKiQ\",\n \"snippet\": {\n \"title\"my video test\",\n \"description\": \"Embrace the rhythm of life with every step copy copy copy copy copy copy copy copy copy\",\n \"categoryId\": \"24\",\n \"tags\": [\"travel\", \"vlog\", \"beach\"]\n }\n}"”,
“gzip”: true,
“method”: “put”,
“headers”: [
{
“name”: “Authorization”,
“value”: “Bearer ya29.a0AXooCgu8ata-Hkn4gZ1oH4mrIVo9_mm-cy0qEVRMRzEdpakkfDyTx6Dv2BGcB0dcUlJ9t_k4dGkNfUgNc8YhowzmA4s_pYqCy017LBksl8ZMdob5ZSsP8t1Aj8ed0pxMOEMS76EYqHle4zOQ3D_RtRCey-WX4JB5GWBybgaCgYKAeoSARMSFQHGX2MioBsn_n_tEZt15ebidpVHIA0173”
}
],
“timeout”: null,
“useMtls”: false,
“authPass”: null,
“authUser”: null,
“bodyType”: “raw”,
“contentType”: “application/json”,
“serializeUrl”: false,
“shareCookies”: false,
“parseResponse”: false,
“followRedirect”: true,
“useQuerystring”: false,
“followAllRedirects”: false,
“rejectUnauthorized”: true
}
]