Get story details

GET /v2/stories/{storyId}

Retrieves detailed information about a specific story including its settings and dynamic variables

Path parameters

  • storyId string Required

    The ID of the story to retrieve

Responses

  • 200 application/json

    Story details retrieved successfully

    Hide response attributes Show response attributes object
    • id string Required

      Unique identifier for the story

    • status string Required

      Current status of the story

      Values are Draft, Live, or Archived.

    • previewUrl string(uri) | null

      Preview URL for the story (null if not published)

    • createdAt string(date-time)

      Timestamp when the story was created

    • title string Required

      Title of the story

    • dynamicVariables object

      Dynamic variables configuration for the story

      Hide dynamicVariables attribute Show dynamicVariables attribute object
      • * object Additional properties
        Hide * attributes Show * attributes object
        • type string

          Type of the variable

        • name string

          Variable name

        • title string

          Display title for the variable

        • default string

          Default value

        • tip string

          Tooltip or help text

        • validation object
          Hide validation attributes Show validation attributes object
          • required boolean
          • errorMessage string
        • mapping string

          Field mapping

  • 400 application/json

    Missing or invalid storyId parameter

    Hide response attribute Show response attribute object
    • error string
  • 403 application/json

    Authentication failed or missing token

    Hide response attribute Show response attribute object
    • error string
  • 404 application/json

    Story not found

    Hide response attribute Show response attribute object
    • error string
  • 429 application/json

    Rate limit exceeded

    Hide headers attributes Show headers attributes
    • x-rate-limit-counter integer

      Current request count

    • x-rate-limit-maximum integer

      Maximum allowed requests

    Hide response attribute Show response attribute object
    • error string
  • 500 application/json

    Internal server error

    Hide response attributes Show response attributes object
    • error string
    • errorId string
GET /v2/stories/{storyId}
curl \
 --request GET 'https://api.storydoc.com/v2/stories/61b1e50223b713000a41ca74' \
 --header "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "id": "61b1e50223b713000a41ca74",
  "title": "Sales Presentation Template",
  "status": "Live",
  "createdAt": "2024-01-15T10:30:00.000Z",
  "previewUrl": "https://view.storydoc.com/preview/abc123",
  "dynamicVariables": {
    "company": {
      "tip": "Enter the company name",
      "name": "company",
      "type": "input",
      "title": "Company name",
      "default": "",
      "mapping": "CompanyName",
      "validation": {
        "required": false
      }
    },
    "first_name": {
      "tip": "Prospect's first name",
      "name": "first_name",
      "type": "input",
      "title": "Prospect's first name",
      "default": "",
      "mapping": "FirstName",
      "validation": {
        "required": true,
        "errorMessage": "Required"
      }
    }
  }
}
Response examples (400)
{
  "error": "Missing storyId"
}
Response examples (403)
{
  "error": "Access denied"
}
Response examples (404)
{
  "error": "Story not found"
}
Response examples (429)
# Headers
x-rate-limit-counter: 42
x-rate-limit-maximum: 42

# Payload
{
  "error": "Too many requests"
}
Response examples (500)
{
  "error": "Error occured",
  "errorId": "550e8400-e29b-41d4-a716-446655440000"
}