def createResourceFolder(self, pid, pathname):
url = "<STR_LIT>".format(url_base=self.url_base, pid=pid, path=pathname)<EOL>r = self._request('<STR_LIT>', url)<EOL>if r.status_code != <NUM_LIT>:<EOL><INDENT>if r.status_code == <NUM_LIT>:<EOL><INDENT>raise HydroShareNotAuthorized(('<STR_LIT>', url))<EOL><DEDENT>elif r.status_code == <NUM_LIT>:<EOL><INDENT>raise HydroShareNotFound((pid,))<EOL><DEDENT>else:<EOL><INDENT>raise HydroShareHTTPException((url, '<STR_LIT>', r.status_code))<EOL><DEDENT><DEDENT>return r.json()<EOL>
Create folder as specified by *pathname* for a given resource

        :param pid: The HydroShare ID of the resource for which folder to be created
        :param pathname: Folder path/name for the folder to be created
        :return: A JSON object representing the resource id and path of the folder that was created

        :raises: HydroShareNotAuthorized if user is not authorized to perform action.
        :raises: HydroShareNotFound if the resource or resource file was not found.
        :raises: HydroShareHTTPException if an unexpected HTTP response code is encountered.

        Example of JSON data returned:
        {
            "resource_id": "32a08bc23a86e471282a832143491b49",
            "path": "model/initial"
        }