{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/ploid/json-schema/ploid-linked-in-posts-response-schema.json",
  "title": "LinkedInPostsResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/ploid-linked-in-api-openapi.yml#/components/schemas/LinkedInPostsResponse",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "data",
    "meta"
  ],
  "properties": {
    "data": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "items",
        "cursor"
      ],
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/LinkedInPost"
          }
        },
        "cursor": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "meta": {
      "$ref": "#/$defs/PublicCreditsResponseMeta"
    }
  },
  "$defs": {
    "LinkedInPost": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "socialId",
        "postUrl",
        "text",
        "publishedAt",
        "reactionCount",
        "commentCount",
        "shareCount",
        "kind",
        "author",
        "mediaUrl"
      ],
      "properties": {
        "socialId": {
          "type": "string"
        },
        "postUrl": {
          "type": [
            "string",
            "null"
          ]
        },
        "text": {
          "type": [
            "string",
            "null"
          ]
        },
        "publishedAt": {
          "type": [
            "string",
            "null"
          ]
        },
        "reactionCount": {
          "type": "number",
          "minimum": 0
        },
        "commentCount": {
          "type": "number",
          "minimum": 0
        },
        "shareCount": {
          "type": "number",
          "minimum": 0
        },
        "kind": {
          "type": "string",
          "enum": [
            "post",
            "share",
            "article",
            "unknown"
          ]
        },
        "author": {
          "$ref": "#/$defs/LinkedInPostAuthor"
        },
        "mediaUrl": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "LinkedInPostAuthor": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "socialId",
        "name",
        "headline",
        "profileUrl",
        "profilePictureUrl"
      ],
      "properties": {
        "socialId": {
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "type": [
            "string",
            "null"
          ]
        },
        "headline": {
          "type": [
            "string",
            "null"
          ]
        },
        "profileUrl": {
          "type": [
            "string",
            "null"
          ]
        },
        "profilePictureUrl": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "PublicCreditsResponseMeta": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "request_id",
        "credits_charged"
      ],
      "properties": {
        "request_id": {
          "type": "string"
        },
        "credits_charged": {
          "type": "number",
          "minimum": 0
        },
        "remaining_credits": {
          "type": "number",
          "minimum": 0
        },
        "cursor": {
          "type": [
            "string",
            "null"
          ]
        },
        "message": {
          "type": "string"
        }
      }
    }
  }
}