example-data.com
Menu
Browse docs and collections

Overview

comments / #646

Comment #646

· 1/15/2025

Vesica taedium usus demonstro aegre velociter titulus abstergo libero. Valetudo coniuratio conduco decretum demum supellex decumbo ducimus adeptio sonitus. Denique verecundia velit surgo cometes ter.

Component variants

Related

Request

curl example

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

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/comments/646"
);
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/646"
);
const comment = (await res.json()) as Comment;

Python example

import requests

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

Response

{
  "id": 646,
  "userId": 205,
  "targetType": "post",
  "targetId": 36,
  "body": "Vesica taedium usus demonstro aegre velociter titulus abstergo libero. Valetudo coniuratio conduco decretum demum supellex decumbo ducimus adeptio sonitus. Denique verecundia velit surgo cometes ter.",
  "isEdited": false,
  "createdAt": "2025-01-15T02:02:47.984Z",
  "updatedAt": "2025-01-15T02:02:47.984Z"
}