<configure
    xmlns="http://namespaces.zope.org/zope"
    xmlns:five="http://namespaces.zope.org/five"
    xmlns:genericsetup="http://namespaces.zope.org/genericsetup"
    xmlns:browser="http://namespaces.zope.org/browser"
    xmlns:i18n="http://namespaces.zope.org/i18n"
    xmlns:pp="http://namespaces.zopyx.com/pp"
    xmlns:plone="http://namespaces.plone.org/plone"
    >

    <include package="plone.rest" file="configure.zcml" />

    <!-- TESTED -->

    <plone:service
      method="PUT"
        for="*"
        permission="cmf.ModifyPortalContent"
        factory=".restapi.api_create"
        name="xmldirector-create"
    />

    <plone:service
      method="GET"
        permission="zope2.View"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_get_metadata"
        name="xmldirector-get-metadata"
    />

    <plone:service
      method="POST"
        permission="cmf.ModifyPortalContent"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_set_metadata"
        name="xmldirector-set-metadata"
    />

    <plone:service
      method="GET"
        permission="zope2.View"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_get"
        name="xmldirector-get"
    />

    <plone:service
      method="GET"
        permission="zope2.View"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_get_zip"
        name="xmldirector-get-zip"
    />

    <plone:service
      method="POST"
        permission="cmf.ModifyPortalContent"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_store_zip"
        name="xmldirector-store-zip"
    />

    <plone:service
      method="POST"
        permission="cmf.ModifyPortalContent"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_store"
        name="xmldirector-store"
    />

    <plone:service
      method="GET"
        permission="zope2.View"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_list"
        name="xmldirector-list"
    />

    <plone:service
      method="GET"
        permission="zope2.View"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_list_full"
        name="xmldirector-list-full"
    />

    <plone:service
      method="DELETE"
        for="xmldirector.plonecore.connector.IConnector"
        permission="cmf.ModifyPortalContent"
        factory=".restapi.api_delete"
        name="xmldirector-delete"
    />

    <plone:service
      method="GET"
        for="*"
        permission="zope2.View"
        factory=".restapi.api_search"
        name="xmldirector-search"
    />

    <plone:service
      method="GET"
        permission="zope2.View"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_hashes"
        name="xmldirector-hashes"
    />

    <plone:service
      method="POST"
        permission="cmf.ModifyPortalContent"
        for="xmldirector.plonecore.connector.IConnector"
        factory=".restapi.api_delete_content"
        name="xmldirector-delete-content"
    />

</configure>
