<!--
		SIF Infrastructure Specification 3.7

		(January 21, 2025)
		
		Infrastructure Version: 3.7
		
		license: 
		    name: Apache  2.0
        identifier: Apache-2.0
        url: 'https://home.a4l.org/legal/'
	-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://www.sifassociation.org/infrastructure/3.7" targetNamespace="http://www.sifassociation.org/infrastructure/3.7" elementFormDefault="qualified" version="3.7">
  <xs:complexType name="podType">
    <xs:annotation>
      <xs:appinfo>
        <sifChar />
        <privacyRating>Low</privacyRating>
      </xs:appinfo>
      <xs:documentation>This object contains information about privacy obligations.</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="podStatus">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The status value for this POD.</xs:documentation>
        </xs:annotation>
        <xs:simpleType>
          <xs:restriction base="xs:token">
            <xs:enumeration value="Live" />
            <xs:enumeration value="Draft" />
            <xs:enumeration value="Pending" />
            <xs:enumeration value="Expired" />
          </xs:restriction>
        </xs:simpleType>
      </xs:element>
      <xs:element name="podToken" type="gCoreLocalIdType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The token reference for the POD, also conveyed as the dataPrivacyMarker header.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="podVersion" type="xs:normalizedString">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The POD version number. PODs are expected to change over time.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="partyId" type="xs:normalizedString">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The name of the party (typically the data processor) which will receive the data from the school, district or state and has entered into an agreement to process the data and respect the privacy obligations of the data.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="privacyList" type="privacyListType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The set of privacy controls, laws and obligations which apply in this POD. There may be multiple sets which apply.</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
    <xs:attribute name="id" use="required" type="uuidType">
      <xs:annotation>
        <xs:appinfo>
          <sifChar>M</sifChar>
          <privacyRating>Low</privacyRating>
        </xs:appinfo>
        <xs:documentation>The ID (GUID) that uniquely identifies this object.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
  </xs:complexType>

  <xs:element name="pod" type="podType">
    <xs:key name="podKey1">
      <xs:selector xpath="." />
      <xs:field xpath="@id" />
    </xs:key>
  </xs:element>

  <xs:complexType name="podCollectionType">
    <xs:sequence>
      <xs:element name="pod" type="podType" minOccurs="0" maxOccurs="unbounded" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="pods" type="podCollectionType" />

</xs:schema>