example-data.com
Menu
Browse docs and collections

Overview

comments / #1324

Comment #1324

· 9/29/2024

At animi abscido voveo certe. Textus caterva conatus surculus aureus. Aurum occaecati adiuvo tactus credo dedico voco vorax uberrime vulariter. Fugit valetudo vita canonicus.

Component variants

Related

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 1324,
  "userId": 4,
  "targetType": "post",
  "targetId": 149,
  "body": "At animi abscido voveo certe. Textus caterva conatus surculus aureus. Aurum occaecati adiuvo tactus credo dedico voco vorax uberrime vulariter. Fugit valetudo vita canonicus.",
  "isEdited": false,
  "createdAt": "2024-09-29T19:10:49.039Z",
  "updatedAt": "2024-09-29T19:10:49.039Z"
}