The DraCor API currently silently assumes that there is only one teiCorpus document per corpus, and this document is the corpus.xml. The incident caused in conjunction with bug #306 made clear that this is currently not guaranteed and uploading a teiCorpus document as a regular play can break the API.
We need to make sure that the PUT /corpora/{corpusname}/plays/{playname}/tei and POST /corpora/{corpusname} endpoints only accept with a TEI root element.
The DraCor API currently silently assumes that there is only one
teiCorpusdocument per corpus, and this document is the corpus.xml. The incident caused in conjunction with bug #306 made clear that this is currently not guaranteed and uploading ateiCorpusdocument as a regular play can break the API.We need to make sure that the
PUT /corpora/{corpusname}/plays/{playname}/teiandPOST /corpora/{corpusname}endpoints only accept with aTEIroot element.