{
  "lexicon": 1,
  "id": "app.xptracker.job.listing",
  "defs": {
    "main": {
      "type": "record",
      "description": "A job listing published on the AT Protocol.",
      "key": "tid",
      "record": {
        "type": "object",
        "required": [
          "title",
          "company",
          "sourceUri",
          "createdAt"
        ],
        "properties": {
          "title": {
            "type": "string",
            "maxLength": 256,
            "description": "Job title or role name."
          },
          "company": {
            "type": "string",
            "maxLength": 256,
            "description": "Name of the hiring organization."
          },
          "jobType": {
            "type": "ref",
            "ref": "app.xptracker.job.defs#jobType"
          },
          "employmentType": {
            "type": "ref",
            "ref": "app.xptracker.job.defs#employmentType"
          },
          "description": {
            "type": "string",
            "maxLength": 100000,
            "description": "Full job description or body text. Plain text preferred."
          },
          "sourceUri": {
            "type": "string",
            "format": "uri",
            "description": "Canonical URL of the original job listing."
          },
          "skills": {
            "type": "array",
            "items": {
              "type": "string",
              "maxLength": 128
            },
            "maxLength": 100,
            "description": "Free-form skill labels for this listing."
          },
          "location": {
            "type": "string",
            "maxLength": 256,
            "description": "Human-readable location string."
          },
          "createdAt": {
            "type": "string",
            "format": "datetime",
            "description": "When this record was created on the PDS."
          },
          "postedAt": {
            "type": "string",
            "format": "datetime",
            "description": "When the job was posted on the source platform."
          },
          "expiresAt": {
            "type": "string",
            "format": "datetime",
            "description": "When the listing is expected to expire."
          },
          "publisherDid": {
            "type": "string",
            "format": "did",
            "description": "DID of the publishing entity, if different from repo owner."
          },
          "provenance": {
            "type": "ref",
            "ref": "app.xptracker.job.defs#provenanceMethod",
            "description": "How this record was created."
          },
          "sourceId": {
            "type": "string",
            "maxLength": 256,
            "description": "Identifier from the source system for deduplication."
          }
        }
      }
    }
  }
}
