example-data.com
Menu
Browse docs and collections

Overview

comments / #1032

Comment #1032

· 9/21/2024

Dolore deserunt vapulus despecto anser cras valeo adflicto sustineo cuppedia. Adflicto conicio conicio tamisium cras balbus incidunt dens textus. Tardus aeternus vociferor. Deleo explicabo quas timor vita speculum surgo tabesco amaritudo.

Component variants

Related

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 1032,
  "userId": 149,
  "targetType": "post",
  "targetId": 148,
  "body": "Dolore deserunt vapulus despecto anser cras valeo adflicto sustineo cuppedia. Adflicto conicio conicio tamisium cras balbus incidunt dens textus. Tardus aeternus vociferor. Deleo explicabo quas timor vita speculum surgo tabesco amaritudo.",
  "isEdited": false,
  "createdAt": "2024-09-21T03:40:58.870Z",
  "updatedAt": "2024-09-21T03:40:58.870Z"
}