Add a new comment to a case.
The comment must have the following fields set: body.
EXAMPLES:
cURL:
<code><code>shell
case="projects/some-project/cases/43591344"
curl \
--request POST \
--header "Authorization: Bearer $(gcloud auth print-access-token)" \
--header 'Content-Type: application/json' \
--data '{
"body": "This is a test comment."
}' \
"https://cloudsupport.googleapis.com/v2/$case/comments"
</code></code><code>
Python:
</code><code><code>python
import googleapiclient.discovery
api_version = "v2"
supportApiService = googleapiclient.discovery.build(
serviceName="cloudsupport",
version=api_version,
discoveryServiceUrl=f"https://cloudsupport.googleapis.com/$discovery/rest?version={api_version}",
)
request = (
supportApiService.cases()
.comments()
.create(
parent="projects/some-project/cases/43595344",
body={"body": "This is a test comment."},
)
)
print(request.execute())
</code></code>
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-06-05 UTC."],[],[]]