def delete_map(self, map_id): """ Delete a map. """ self.requires_auth() resource = '/maps/%s.json' % (map_id) request = Request(user=self.user, password=self.password, token=self.get_token(), cache=self.cache, url=self.url) request.delete(resource) return True
def delete_database(self, db_name): """ Delete a database. """ self.requires_auth() resource = '/databases/%s.json' % (db_name) request = Request(user=self.user, password=self.password, token=self.get_token(), cache=self.cache, url=self.url) content = request.delete(resource) return json.loads(content)