Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OerebLex Release 2024/09: api version 1.2.5 #330

Open
michmuel opened this issue Aug 23, 2024 · 2 comments
Open

OerebLex Release 2024/09: api version 1.2.5 #330

michmuel opened this issue Aug 23, 2024 · 2 comments

Comments

@michmuel
Copy link
Contributor

Release notes

[extract from the release notes published by SITROX; subjects not relevant for the api left out]

Note:

Das produktive Release findet am 25.09.2024 statt und es ist mit einem längeren Ausfall zwischen 20:00 und 23:00 Uhr zu rechnen.

Mit diesem Release gibt es eine neue Version (1.2.5) des GEO-Links. Bitte lassen Sie es uns wissen, falls wir bei Ihrer produktiven Instanz direkt die Version 1.2.5 als Default hinterlegen sollen.

OEREBlex:

  1. Anpassung des GEO-Link HTML bezüglich der "Beschreibung für Dokumente"
  • Bei Entscheiden steht neu das Eingabefeld "Dokument-Beschreibung" zur Verfügung.
  • Dieses wird im GEO-Link HTML anstelle des Dateinamen angezeigt und im GEO-Link xml unter "description" ausgeliefert. (Ab Version 1.2.5)
  • Der PDF-Link wurde aus den Titeln entfernt und die PDFs sind nun unter Dokumente aufgeführt.
  1. Einführen eines mehrsprachigen GEO-Link XML (Ab Version 1.2.5)
  • Für Entscheide steht ein mehrsprachiges GEO-Link XML zur Verfügung unter /api/geolinks/.xml?multilang=true
  • Es wird ein <multilang_geolinks> Tag übergeordnet geliefert und dann pro verfügbare Sprache ein Tag mit der Antwort auf eine einzelnen Abfragen an 1 Sprache.
  • Falls Dokument(e) nicht verfügbar sind in der gewünschten Sprache, wird das entsprechende Dokument der ersten Sprache geliefert wo es verfügbar ist.
  1. Anpassung des GEO-Link XML (Ab Version 1.2.5)
  • Auf den XML Elementen wird neu das Attribut "language" ausgewiesen.

[...]

  1. API-Dokumentation und Handbuch zu OEREBlex
  • #128659.1 Handbuch
  • #128658.1 Dokumentation der Schnittstellen und Exporte

[...]

  1. Der öffentliche Export aller Entscheide unter /api/public_decrees.{xml|xlsx} steht neu
    auch ohne das Zusatzmodul Frontend zur Verfügung.

[...]

Zusatzmodul Vorwirkungen:

  1. Einführen eines mehrsprachigen Prepub-Link XML (Ab Version 1.2.5)
  • Analog zu den GEO-Links unter Punkt 2.
  1. Anpassung des Prepub-LinkXML (Ab Version 1.2.5)
  • Auf den XML Elementen wird neu das Attribut "language" ausgewiesen.

[...]

  1. Öffentlicher Vorwirkungsstatus
  • [...]
  • Prepub-Links sind nur für öffentliche Vorwirkungen verfügbar.
  • Die Abfrage eines Prepub-Links ohne Status liefert die aktuelle öffentliche Version der Vorwirkung
  • Auch wenn ein Prepub-Link einen öffentlichen Status hat, ist er erst nach seinem "Statusbeginn" öffentlich verfügbar.
  • Der öffentliche Export aller Vorwirkungen unter /api/public_prepublications.{xml|xlsx} enthält nur die öffentlichen Vorwirkungen.
  • Der Export "Vorwirkungen" im Register "Exporte" enthält alle Vorwirkungsversionen und eine neue Spalte "Status öffentlich".
  • Zu Entscheid konvertierte Vorwirkungen werden nicht in den Exporten angezeigt.

[...]

Zusatzmodul Vorwirkungen und Frontend:

[...]

API

  • Geolink / Prepub-Link
    • XSD Version 1.2.5: Anhang geolinks_1.2.5.xsd
    • Abfrage spezifischer Version über api// statt api
    • Verfügbare Versionen: 1.1.1, 1.2.0, 1.2.1, 1.2.2, 1.2.3, 1.2.4, 1.2.5
  • Geolinks
    • Schnittstelle /api/geolinks/.{xml|html}
    • Parameter (optional): locale= / multilang=true (für xml)
  • Prepub-Links (Zusatzmodul Vorwirkungen)
    • Schnittstelle /api/prepubs/.{xml|html}
    • Parameter (optional): locale= / multilang=true (für xml) / status_id=<S_ID>
  • Edicts
    • Schnittstelle: /api/main/v1/edicts
    • Dokumentation: /api-doc/main
  • Exporte
    • Liste von Entscheiden /api/public_decrees.{xml|xlsx}
    • Liste von öffentlichen Vorwirkungen (Zusatmodul Vorwirkungen) public_prepublications.{xml | xlsx}

XML-Schema geolinks_1.2.5.xsd

[schema published by SITROX]

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">

  <xs:element name="multilang_geolinks">
    <xs:complexType>
      <xs:choice minOccurs="1" maxOccurs="unbounded">
        <xs:element name="geolinks" type="base_links" />
      </xs:choice>
    </xs:complexType>
  </xs:element>

  <xs:element name="geolinks" type="base_links" />

  <xs:element name="multilang_prepublinks">
    <xs:complexType>
      <xs:choice minOccurs="1" maxOccurs="unbounded">
        <xs:element name="prepublinks" type="base_links" />
      </xs:choice>
    </xs:complexType>
  </xs:element>

  <xs:element name="prepublinks" type="base_links" />

  <xs:complexType name="base_links">
    <xs:sequence>
      <xs:element name="document" type="full_document" minOccurs="1" maxOccurs="unbounded" />
    </xs:sequence>
    <xs:attribute name="language" type="language" />
  </xs:complexType>

  <xs:complexType name="full_document">
    <xs:complexContent>
      <xs:extension base="base_document">
        <xs:attributeGroup ref="geolink_document" />
        <xs:attributeGroup ref="prepublink_document" />
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>

  <xs:attributeGroup name="geolink_document">
    <xs:attribute name="abrogation_date" type="xs:date" />
    <xs:attribute name="approval_date" type="xs:date" />
    <xs:attribute name="decree_date" type="xs:date" />
    <xs:attribute name="enactment_date" type="xs:date" />
    <xs:attribute name="publication_date" type="xs:date" />
  </xs:attributeGroup>

  <xs:attributeGroup name="prepublink_document">
    <xs:attribute name="status" type="xs:string" />
    <xs:attribute name="status_end_date" type="xs:date" />
    <xs:attribute name="status_start_date" type="xs:date" />
  </xs:attributeGroup>

  <xs:complexType name="base_document">
    <xs:sequence>
      <xs:element name="file" minOccurs="0" maxOccurs="unbounded">
        <xs:complexType>
          <xs:attribute name="category">
            <xs:simpleType>
              <xs:restriction base="xs:string">
                <xs:enumeration value="main" />
                <xs:enumeration value="additional" />
              </xs:restriction>
            </xs:simpleType>
          </xs:attribute>
          <xs:attribute name="href" type="xs:string" />
          <xs:attribute name="title" type="xs:string" />
          <xs:attribute name="description" type="xs:string" />
        </xs:complexType>
      </xs:element>
    </xs:sequence>
    <xs:attribute name="abbreviation" type="xs:string" />
    <xs:attribute name="authority" type="xs:string" />
    <xs:attribute name="authority_url" type="xs:string" />
    <xs:attribute name="category">
      <xs:simpleType>
        <xs:restriction base="xs:string">
          <xs:enumeration value="main" />
          <xs:enumeration value="related" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="cycle" type="xs:string" />
    <xs:attribute name="doctype">
      <xs:simpleType>
        <xs:restriction base="xs:string">
          <xs:enumeration value="edict" />
          <xs:enumeration value="decree" />
          <xs:enumeration value="notice" />
          <xs:enumeration value="prepublication" />
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="federal_level" type="xs:string" />
    <xs:attribute name="id" type="xs:string" />
    <xs:attribute name="index" type="xs:integer" />
    <xs:attribute name="instance" type="xs:string" />
    <xs:attribute name="language" type="language" />
    <xs:attribute name="municipality" type="xs:string" />
    <xs:attribute name="number" type="xs:string" />
    <xs:attribute name="subtype" type="xs:string" />
    <xs:attribute name="title" type="xs:string" />
    <xs:attribute name="type" type="xs:string" />
  </xs:complexType>

  <xs:simpleType name="language">
    <xs:restriction base="xs:string">
      <xs:enumeration value="de" />
      <xs:enumeration value="fr" />
      <xs:enumeration value="it" />
      <xs:enumeration value="rm" />
    </xs:restriction>
  </xs:simpleType>
</xs:schema>
@michmuel
Copy link
Contributor Author

@jwkaltz, @vvmruder

I guess you use this package as well. An implementation by myself would be around end of September (+/-). This issue might also require some work in the pyramid oereb project.

@jwkaltz
Copy link
Member

jwkaltz commented Sep 6, 2024

Sorry @michmuel I forgot to reply. Indeed pyramid_oereb always includes this package, and in fact almost all cantons using pyramid_oereb actually use oereblex.
We can work on the update via support packages if desired, but so far no canton has asked about the new release of Oereblex, so I assume there is no urgent functionality included.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants