Search Storyblok's Documentation
  1. The Story Object

The Story Object

The following object represents a story (a content entry). The schema of a story is defined in the Blok Library within Storyblok. The story type (content type) determines the content structure of a story via the definition of fields. This structure is represented in the content property of the story object, whereas the other properties are generic and included in all Story Objects.

Properties

  • name

    string

    The complete name provided for the story

  • created_at

    string

    Creation date (Format: yyyy-MM-dd'T'HH:mm:ssZ)

  • published_at

    string

    Latest publishing date (Format: yyyy-MM-dd'T'HH:mm:ssZ)

  • id

    number

    The numeric ID

  • uuid

    string

    Generated UUID string

  • content

    object

    An object containing the field data associated with the specific story type's specific content structure. Also includes a component property with the story type's technical name.

  • slug

    string

    The slug specific for the story

  • full_slug

    string

    The full slug of the story, combining the parent folder(s) and the designated story slug

  • sort_by_date

    string

    Date defined in the story's entry configuration (Format: YYYY-mm-dd)

  • position

    number

    Numeric representation of the story's position in the folder

  • tag_list

    string[]

    Array of tag names

  • is_startpage

    boolean

    true if the story is defined as root for the folder

  • parent_id

    number

    ID of the parent folder

  • meta_data

    object

    Object to store non-editable data that is exclusively maintained with the Management API

  • group_id

    string

    Group ID (UUID string), shared between stories defined as alternates

  • first_published_at

    string

    First publishing date (Format: yyyy-MM-dd'T'HH:mm:ssZ)

  • release_id

    number

    ID of the current release (can be requested with the from_release API parameter)

  • lang

    string

    Language code of the current language (can be requested with the language API parameter)

  • path

    string

    Value of the real path defined in the story's entry configuration (usually, this value is only required for Storyblok's Visual Editor)

  • alternates

    object[]

    An array containing objects that provide basic data of the stories defined as alternates of the current story

    • id

      number

      The numeric ID

    • name

      string

      The complete name provided for the story

    • slug

      string

      The slug specific for the story

    • published

      boolean

      true if a story has been published at least once (even if it is currently in draft)

    • full_slug

      string

      The full slug of the story, combining the parent folder(s) and the designated story slug

    • is_folder

      boolean

      true if the instance constitutes a folder

  • default_full_slug

    string

    Contains the complete slug of the default language (if the app Translatable Slugs is installed)

  • translated_slugs

    object[]

    Array of translated slug objects (if the app Translatable Slugs is installed)

    • path

      string

      Value of the translated slug

    • name

      string

      The complete name provided for the story

    • lang

      string

      Language code of the current language (can be requested with the language API parameter)

    • published

      boolean

      true if a story has been published at least once (even if it is currently in draft)

Example Object
{
  "story": {
    "name": "My third post",
    "created_at": "2024-02-08T16:26:24.425Z",
    "published_at": "2024-02-08T16:27:05.705Z",
    "id": 440448565,
    "uuid": "e656e146-f4ed-44a2-8017-013e5a9d9395",
    "content": {
      "_uid": "cfe0ff0b-3211-4bb7-8128-66e6ad262a56",
      "component": "page"
    },
    "slug": "my-third-post",
    "full_slug": "posts/my-third-post",
    "sort_by_date": null,
    "position": 0,
    "tag_list": [],
    "is_startpage": false,
    "parent_id": 440448337,
    "meta_data": null,
    "group_id": "b913a671-f1e9-436a-bc5d-2795d2740198",
    "first_published_at": "2024-02-08T16:27:05.705Z",
    "release_id": null,
    "lang": "default",
    "path": null,
    "alternates": [
      {
        "id": 440452827,
        "name": "Mein dritter Beitrag",
        "slug": "mein-dritter-beitrag",
        "published": true,
        "full_slug": "beitraege/mein-dritter-beitrag",
        "is_folder": false,
        "parent_id": 440452826
      }
    ],
    "default_full_slug": "posts/my-third-post",
    "translated_slugs": [
      {
        "path": "posts/my-third-post",
        "name": null,
        "lang": "fr",
        "published": null
      },
      {
        "path": "posts/mein-dritter-beitrag",
        "name": "Mein dritter Beitrag",
        "lang": "de",
        "published": true
      }
    ]
  }
}