dambel

دمبل

shevron
ورود | ثبت نام

API Docs / posts / post resource



Post Resource

Represents a post entity, including its profile association, content, and draft status.


Schema

FieldTypeDescription
idintUnique identifier for the post
profile_typestringType of the profile (e.g., App\\Models\\User)
profile_idintID of the profile the post belongs to
titlestringTitle of the post
contentstringContent of the post
is_draftboolWhether the post is a draft
mediaMedia Resource[]List of media items (see here)

Example

{
  "id": 123,
  "profile_type": "App\\Models\\User",
  "profile_id": 42,
  "title": "My Workout",
  "content": "Did squats and deadlifts.",
  "is_draft": false,
  "media": [
    {
      "id": 10,
      "attachable_type": "App\\Models\\Posts\\Post",
      "attachable_id": 123,
      "link": "https://example.com/media/10.jpg"
    }
  ],
}

Related Resources

footer wave
logo

دمبل، دنیای هوشمند ورزش و تغذیه

LinkedinInstagramXYoutube