example-data.com
Menu
Browse docs and collections

Overview

comments / #1236

Comment #1236

· 6/28/2024

Copia provident tutis volaticus. Sufficio illo amoveo audentia. Sufficio copiose pecus nostrum complectus perferendis ager. Tamisium amissio custodia basium statua cuppedia vulpes laborum tantum cerno.

Component variants

Related

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/comments/1236" \
  -H "Accept: application/json"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/comments/1236"
);
const comment = await res.json();

TypeScript example

// Download once: mkdir -p types && curl -o types/comments.d.ts https://example-data.com/types/comments.d.ts
import type { Comment } from "./types/comments";

const res = await fetch(
  "https://example-data.com/api/v1/comments/1236"
);
const comment = (await res.json()) as Comment;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/comments/1236"
)
comment = res.json()

Response

{
  "id": 1236,
  "userId": 204,
  "targetType": "post",
  "targetId": 111,
  "body": "Copia provident tutis volaticus. Sufficio illo amoveo audentia. Sufficio copiose pecus nostrum complectus perferendis ager. Tamisium amissio custodia basium statua cuppedia vulpes laborum tantum cerno.",
  "isEdited": false,
  "createdAt": "2024-06-28T05:31:59.106Z",
  "updatedAt": "2024-06-28T05:31:59.106Z"
}