{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "additionalProperties": false,
  "description": "A news item as JSON object -- copyright 2021 IPTC - International Press Telecommunications Council - www.iptc.org - This document is published under the Creative Commons Attribution 4.0 license, see  http://creativecommons.org/licenses/by/4.0/",
  "id": "http://www.iptc.org/std/ninjs/ninjs-schema_2.0.json#",
  "name": "ninjs",
  "properties": {
    "uri": {
      "title": "Uniform Resource Identifier",
      "description": "The global unique identifier for this news object. This is the only required property and should identify the ninjs object, not be used for links to external resources etc.  nar:newsItem@guid",
      "type": "string",
      "format": "uri"
    },
    "type": {
      "title": "Type",
      "description": "The generic news type of this news object. (Value 'component' added in version 1.2 as issue #21.). See: http://cv.iptc.org/newscodes/ninature/ nar:itemClass",
      "type": "string",
      "enum": [
        "text",
        "audio",
        "video",
        "picture",
        "graphic",
        "composite",
        "component"
      ]
    },
    "representationtype": {
      "title": "Representation type",
      "description": "Indicates how complete this representation of a news item is. No mapping to nar. Specific for ninjs.",
      "type": "string",
      "enum": ["full", "partial"]
    },
    "profile": {
      "title": "Profile",
      "description": "An identifier for the structure of the news object. This can be any string but we suggest something identifying the structure of the content such as 'text-only' or 'text-photo'. Profiles are typically provider-specific. nar:profile",
      "type": "string"
    },
    "version": {
      "title": "Version",
      "description": "The version of the news object which is identified by the uri property. nar:newsItem@version",
      "type": "string"
    },
    "firstcreated": {
      "title": "First created",
      "description": "Indicates when the first version of this ninjs object was created. (Added in version 1.2 from issue #5). nar:firstCreated",
      "type": "string",
      "format": "date-time"
    },
    "versioncreated": {
      "title": "Version created",
      "description": "The date and time when this version of this ninjs object was created. nar:versionCreated",
      "type": "string",
      "format": "date-time"
    },
    "contentcreated": {
      "title": "Content created",
      "description": "The date and time when the content of this ninjs object was originally created. For example and old photo that is now handled as a ninjs object. nar:contentCreated",
      "type": "string",
      "format": "date-time"
    },
    "embargoed": {
      "title": "Embargoed",
      "description": "The date and time before which all versions of the news object are embargoed. If absent, this object is not embargoed. nar:embargoed",
      "type": "string",
      "format": "date-time"
    },
    "pubstatus": {
      "title": "Publication status",
      "description": "The publishing status of the news object, its value is *usable* by default. nar:pubStatus",
      "type": "string",
      "enum": ["usable", "withheld", "canceled"]
    },
    "urgency": {
      "title": "Urgency",
      "description": "The editorial urgency of the content. Values from 1 to 9. 1 represents the highest urgency, 9 the lowest. nar:urgency",
      "type": "number"
    },
    "copyrightholder": {
      "title": "Copyright holder",
      "description": "The person or organisation claiming the intellectual property for the content. nar:copyrightHolder",
      "type": "string"
    },
    "copyrightnotice": {
      "title": "Copyright notice",
      "description": "Any necessary copyright notice for claiming the intellectual property for the content. nar:copyrightNotice",
      "type": "string"
    },
    "usageterms": {
      "title": "Usage terms",
      "description": "A natural-language statement about the usage terms pertaining to the content. nar:usageTerms",
      "type": "string"
    },
    "ednote": {
      "title": "Editorial note",
      "description": "A note that is intended to be read by internal staff at the receiving organisation, but not intended to be published. (Added in version 1.2 from issue #6.). (Consider using this before using the descriptions array.) ednote: nar:edNote",
      "type": "string"
    },
    "language": {
      "title": "Language",
      "description": "The human language used by the content. The value should follow IETF BCP47. nar:language",
      "type": "string"
    },
    "descriptions": {
      "title": "Descriptions",
      "description": "An array of one or more descriptions of the ninjs object. See also ednote for information from provider to receiver. Descriptions are seen as metadata. For a simple description use an array with one object only containing the value property. Role and contenttype are then undefined and it is up to the provider.",
      "type": "array",
      "items": {
        "type": "object",
        "required": ["value"],
        "additionalProperties": false,
        "properties": {
          "role": {
            "title": "Role",
            "description": "The role of this description",
            "type": "string"
          },
          "contenttype": {
            "title": "Content Type",
            "description": "The IANA (Internet Assigned Numbers Authority) MIME type of the content of this description.",
            "type": "string"
          },
          "value": {
            "title": "Value",
            "description": "The descriptive text identified with the above role (and contenttype).",
            "type": "string"
          }
        }
      }
    },
    "bodies": {
      "title": "Bodies",
      "description": "An array of body objects with the content as text or with markup. For a simple body use an array with one object only containing the value property. Role and contenttype are then undefined and it is up to the provider.",
      "type": "array",
      "items": {
        "type": "object",
        "required": ["value"],
        "additionalProperties": false,
        "properties": {
          "role": {
            "title": "Role",
            "description": "The role of this body",
            "type": "string"
          },
          "contenttype": {
            "title": "Content Type",
            "description": "The IANA (Internet Assigned Numbers Authority) MIME type of the content of this body.",
            "type": "string"
          },
          "charcount": {
            "title": "Character count",
            "description": "The total character count in this body excluding figure captions. (Added in version 1.2 according to issue #27.). nar:charcount",
            "type": "number"
          },
          "wordcount": {
            "title": "Word count",
            "description": "The total number of words in this body excluding figure captions. (Added in version 1.2 according to issue #27.). nar:wordcount",
            "type": "number"
          },
          "value": {
            "title": "Value",
            "description": "The body text identified with the above role and contenttype.",
            "type": "string"
          }
        }
      }
    },
    "headlines": {
      "title": "Headlines",
      "description": "An array of objects containing various types of headlines. For a simple headline use an array with one object only containing the value property. Role and contenttype are then undefined and it is up to the provider.",
      "type": "array",
      "items": {
        "type": "object",
        "required": ["value"],
        "additionalProperties": false,
        "properties": {
          "role": {
            "title": "Role",
            "description": "The role of this headline",
            "type": "string"
          },
          "contenttype": {
            "title": "Content Type",
            "description": "The IANA (Internet Assigned Numbers Authority) MIME type of the content of this headline.",
            "type": "string"
          },
          "value": {
            "title": "Value",
            "description": "The headline identified with the above role and contenttype.",
            "type": "string"
          }
        }
      }
    },
    "people": {
      "title": "People",
      "description": "An array of objects describing individual human beings. nar:subject",
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "name": {
            "title": "Name",
            "description": "The name of a person",
            "type": "string"
          },
          "rel": {
            "title": "Relationship",
            "description": "The relationship of the content of the news object to the person",
            "type": "string"
          },
          "uri": {
            "title": "URI",
            "description": "The identifier for the person as a complete uri with the code.",
            "type": "string",
            "format": "uri"
          },
          "literal": {
            "title": "Literal",
            "description": "The code for the person as a literal value.",
            "type": "string"
          }
        }
      }
    },
    "organisations": {
      "title": "Organisations",
      "description": "An array of objects describing administrative and functional structures which may, for example, act as as a business, as a political party or not-for-profit party. nar:subject",
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "name": {
            "title": "Name",
            "description": "The name of the organisation",
            "type": "string"
          },
          "rel": {
            "title": "Relationship",
            "description": "The relationship of the content of the news object to the organisation",
            "type": "string"
          },
          "uri": {
            "title": "URI",
            "description": "The identifier of the organisation as a complete uri",
            "type": "string",
            "format": "uri"
          },
          "literal": {
            "title": "Literal",
            "description": "The code for the organisation as a literal",
            "type": "string"
          },
          "symbols": {
            "title": "Symbols",
            "description": "Symbols used for a financial instrument linked to the organisation at a specific market place",
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "ticker": {
                  "title": "Ticker",
                  "description": "Ticker symbol used for the financial instrument",
                  "type": "string"
                },
                "exchange": {
                  "title": "Exchange",
                  "description": "Identifier for the marketplace which uses the ticker symbols of the ticker property",
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "places": {
      "title": "Places",
      "description": "An array of named locations. nar:subject",
      "additionalProperties": false,
      "type": "array",
      "items": {
        "type": "object",
        "anyOf": [
          {
            "properties": {
              "name": {
                "title": "Name",
                "description": "The name of the place",
                "type": "string"
              },
              "rel": {
                "title": "Relationship",
                "description": "The relationship of the content of the news object to the place",
                "type": "string"
              },
              "uri": {
                "title": "URI",
                "description": "The identifier for the place as a complete uri",
                "type": "string",
                "format": "uri"
              },
              "literal": {
                "title": "Literal",
                "description": "The code for the place as a literal",
                "type": "string"
              }
            }
          },
          {
            "$ref": "https://json.schemastore.org/geojson"
          }
        ]
      }
    },
    "subjects": {
      "title": "Subjects",
      "description": "An array of objects holding concepts with a relationship to the content. nar:subject",
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "name": {
            "title": "Name",
            "description": "The name of the subject",
            "type": "string"
          },
          "rel": {
            "title": "Relationship",
            "description": "The relationship of the content of the news object to the subject",
            "type": "string"
          },
          "uri": {
            "title": "URI",
            "description": "The identifier of the subject as a complete uri",
            "type": "string",
            "format": "uri"
          },
          "literal": {
            "title": "Literal",
            "description": "The code for the subject as a string literal",
            "type": "string"
          }
        }
      }
    },
    "events": {
      "title": "Events",
      "description": "An array of objects describing something which happens in a planned or unplanned manner. nar:?",
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "name": {
            "title": "Name",
            "description": "The name of the event",
            "type": "string"
          },
          "rel": {
            "title": "Relationship",
            "description": "The relationship of the content of the news object to the event",
            "type": "string"
          },
          "uri": {
            "title": "URI",
            "description": "The identifier for the event as a complete uri",
            "type": "string",
            "format": "uri"
          },
          "literal": {
            "title": "Literal",
            "description": "The code for the event as a string literal",
            "type": "string"
          }
        }
      }
    },
    "objects": {
      "title": "Objects",
      "description": "An array of objects describing something material, excluding persons. nar:subject",
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "name": {
            "title": "Name",
            "description": "The name of the object",
            "type": "string"
          },
          "rel": {
            "title": "Relationship",
            "description": "The relationship of the content of the news object to the object",
            "type": "string"
          },
          "uri": {
            "title": "URI",
            "description": "The identifier for the object as a complete uri",
            "type": "string",
            "format": "uri"
          },
          "literal": {
            "title": "Literal",
            "description": "The code for the object as a string literal",
            "type": "string"
          }
        }
      }
    },
    "infosources": {
      "title": "Info sources",
      "description": "An array of parties (person or organisation) which originated, modified, enhanced, distributed, aggregated or supplied the content or provided some information used to create or enhance the content. (Added in version 1.2 according to issue #15.) .  infosource:  nar:infoSource",
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "name": {
            "title": "Name",
            "description": "The name of the infosource",
            "type": "string"
          },
          "role": {
            "title": "Role",
            "description": "The role the infosource in relationship to the content as a uri.",
            "type": "string",
            "format": "uri"
          },
          "uri": {
            "title": "URI",
            "description": "The identifier of the infosource as a complete uri",
            "type": "string",
            "format": "uri"
          },
          "literal": {
            "title": "Literal",
            "description": "The code for the infosource as a string literal",
            "type": "string"
          }
        }
      }
    },
    "title": {
      "title": "Title",
      "description": "A short natural-language name for the item. Title is metadata, use headlines for publishable headlines. (Added in version 1.2 according to issue #9). nar:itemMeta/title",
      "type": "string"
    },
    "by": {
      "title": "By",
      "description": "A natural-language statement about the creator (author, photographer etc.) of the content. nar:by",
      "type": "string"
    },
    "slugline": {
      "title": "Slugline",
      "description": "A human-readable identifier for the item. (Added in version 1.2 from issue #4.). nar:slugline",
      "type": "string"
    },
    "located": {
      "title": "Located",
      "description": "The name of the location from which the content originates. nar:located",
      "type": "string"
    },
    "renditions": {
      "title": "Renditions",
      "description": "An array of objects with different renditions of the news object. nar:remoteContent",
      "type": "array",
      "additionalProperties": false,
      "items": {
        "description": "A specific rendition of the content of the news object. (Description changed in version 1.2 according to issue #17.)",
        "type": "object",
        "additionalProperties": false,
        "required": ["name"],
        "properties": {
          "name": {
            "title": "Name",
            "description": "The name of this object in the array of renditions. For example 'thumbnail'",
            "type": "string"
          },
          "href": {
            "title": "href",
            "description": "The URL for accessing the rendition as a resource. nar:remoteContent@ref",
            "type": "string",
            "format": "uri"
          },
          "contenttype": {
            "title": "Content Type",
            "description": "A MIME type which applies to this rendition. nar:remoteContent@contenttype",
            "type": "string"
          },
          "title": {
            "title": "Title",
            "description": "A title for the link to the rendition resource",
            "type": "string"
          },
          "height": {
            "title": "Height",
            "description": "For still and moving images: the height of the display area measured in pixels. nar:remoteContent@height",
            "type": "number"
          },
          "width": {
            "title": "Width",
            "description": "For still and moving images: the width of the display area measured in pixels. nar:remoteContent@width",
            "type": "number"
          },
          "sizeinbytes": {
            "title": "Size in bytes",
            "description": "The size of the rendition resource in bytes",
            "type": "number"
          },
          "duration": {
            "title": "Duration",
            "description": "The total time duration of the content in seconds. (Added in version 1.2. Issue #18). nar:remoteContent@duration",
            "type": "number"
          },
          "format": {
            "title": "Format",
            "description": "Binary format name. (Added in version 1.2. Issue #18). nar:remoteContent@format",
            "type": "string"
          }
        }
      }
    },
    "associations": {
      "title": "Associations",
      "description": "An array of objects with content of news objects which are associated with this news object.",
      "type": "array",
      "additionalProperties": false,
      "items": {
        "description": "One associated object where each object can use all properties in ninjs.",
        "type": "object",
        "anyOf": [
          {
            "properties": {
              "name": {
                "type": "string",
                "description": "The name of this object in the array of associations. For example 'logo'"
              }
            },
            "required": ["name"]
          },
          {
            "$ref": "#"
          }
        ]
      }
    },
    "altids": {
      "title": "Alternative ids",
      "description": "Alternative identifiers assigned to the content. Each alternative id can have a role and a value. nar:altId issue #3.",
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "role": {
            "title": "Role",
            "description": "The role of the alternative id",
            "type": "string"
          },
          "value": {
            "title": "Value",
            "description": "The alternative id value",
            "type": "string"
          }
        }
      }
    },
    "trustindicators": {
      "title": "Trust indicators",
      "description": "An array of objects to allow links to documents about trust indicators. issue #44. (Added in version 1.3)",
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "role": {
            "title": "Role",
            "description": "The role of the trust indicator as a complete uri",
            "type": "string",
            "format": "uri"
          },
          "title": {
            "title": "Title",
            "description": "The title of the resource being referenced.",
            "type": "string"
          },
          "href": {
            "title": "href",
            "description": "The URL for accessing the trust indicator resource.",
            "type": "string",
            "format": "uri"
          }
        }
      }
    },
    "standard": {
      "title": "Standard",
      "type": "object",
      "description": "An object with information about standard, version and schema this instance is valid against. nar:standard, nar:standardversion and xml:schema issue #43. (Added in version 1.3)",
      "additionalProperties": false,
      "properties": {
        "name": {
          "title": "Name of standard.",
          "description": "For example ninjs. nar:standard",
          "type": "string"
        },
        "version": {
          "title": "Version of standard.",
          "description": "For example 1.3. nar:standardversion",
          "type": "string"
        },
        "schema": {
          "title": "Schema",
          "description": "The uri of the json schema to use for validation.",
          "type": "string",
          "format": "uri"
        }
      }
    },
    "genres": {
      "title": "Genres",
      "description": "A nature, intellectual or journalistic form of the content. nar:genre. (Added in version 1.3)",
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "name": {
            "title": "Name",
            "description": "The name of the genre",
            "type": "string"
          },
          "uri": {
            "title": "URI",
            "description": "The identifier of  the genre as a complete uri",
            "type": "string",
            "format": "uri"
          },
          "literal": {
            "title": "Literal",
            "description": "The code for the genre as a string literal",
            "type": "string"
          }
        }
      }
    },
    "rightsinfo": {
      "title": "Rights information",
      "type": "object",
      "description": "Expression of rights to be applied to content. nar:rightsInfo",
      "properties": {
        "langid": {
          "type": "string",
          "title": "Language id",
          "description": "Identifier for the Rights Expression language used. nar:@langid",
          "format": "uri"
        },
        "linkedrights": {
          "title": "Linked rights",
          "description": "A link from the current Item to Web resource with rights related information. nar:link",
          "type": "string",
          "format": "uri"
        },
        "encodedrights": {
          "title": "Encoded Rights",
          "additionalProperties": false,
          "type": "string",
          "description": "Contains a rights expression as defined by a Rights Expression Language. nar:rightsExpressionXML or nar:rightsExpressionData"
        }
      },
      "oneOf": [
        {
          "required": ["linkedrights"]
        },
        {
          "required": ["encodedrights"]
        }
      ]
    }
  },
  "required": ["uri"],
  "title": "IPTC ninjs - News in JSON - version 2.0 (approved at IPTC Standards Committee October 2021)",
  "type": "object"
}
