Repository: mem0ai/mem0
File: mem0/client/main.py (Python)

Code before:

        Returns:
            Dict containing export request ID and status message
        """
        response = self.client.post("/v1/exports/", json={"schema": schema, **self._prepare_params(kwargs)})
        response.raise_for_status()
        capture_client_event("client.create_memory_export", self, {"schema": schema, "keys": list(kwargs.keys())})
        return response.json()

    @api_error_handler
    def get_memory_export(self, **kwargs) -> Dict[str, Any]:
        """Get a memory export.

        Args:
            **kwargs: Filters like user_id to get specific export

        Returns:
            Dict containing the exported data
        """
        response = self.client.get("/v1/exports/", params=self._prepare_params(kwargs))
        response.raise_for_status()
        capture_client_event("client.get_memory_export", self, {"keys": list(kwargs.keys())})
        return response.json()

    @api_error_handler
    def get_custom_instructions_and_categories(self, custom_instructions: Optional[bool]=False, custom_categories: Optional[bool]=False) -> Dict[str, Any]:
        """Get instructions or categories for the current project.

        Args:
            custom_instructions: Whether to retrieve custom instructions
            custom_categories: Whether to retrieve custom categories

        Returns:
            Dictionary containing the requested instructions or categories.

        Raises:
            APIError: If the API request fails.
            ValueError: If org_id or project_id are not set.
        """
        if not (self.org_id and self.project_id):
            raise ValueError("org_id and project_id must be set to access instructions or categories")
        
        if not custom_instructions and not custom_categories:
            return {}

        fields = []
        if custom_instructions:
            fields.append("custom_instructions")
        if custom_categories:
            fields.append("custom_categories")
        params = self._prepare_params({"fields": fields})

Review comment (refactor):
We can remove this function altogether. It should be returned as part of the `get project details` function i.e 
- https://docs.mem0.ai/api-reference/project/get-projects
- https://docs.mem0.ai/api-reference/project/get-project

Code after:
    @api_error_handler
    def create_memory_export(self, schema: str, **kwargs) -> Dict[str, Any]:
        """Create a memory export with the provided schema.

        Args:
            schema: JSON schema defining the export structure
            **kwargs: Optional filters like user_id, run_id, etc.

        Returns:
            Dict containing export request ID and status message
        """
        response = self.client.post("/v1/exports/", json={"schema": schema, **self._prepare_params(kwargs)})
        response.raise_for_status()
        capture_client_event("client.create_memory_export", self, {"schema": schema, "keys": list(kwargs.keys())})
        return response.json()

    @api_error_handler
    def get_memory_export(self, **kwargs) -> Dict[str, Any]:
        """Get a memory export.

        Args:
            **kwargs: Filters like user_id to get specific export

        Returns:
            Dict containing the exported data
        """
        response = self.client.get("/v1/exports/", params=self._prepare_params(kwargs))
        response.raise_for_status()
        capture_client_event("client.get_memory_export", self, {"keys": list(kwargs.keys())})
        return response.json()

    @api_error_handler
    def get_project(self, fields: Optional[List[str]]=None) -> Dict[str, Any]:
        """Get instructions or categories for the current project.

        Args:
            fields: List of fields to retrieve

        Returns:
            Dictionary containing the requested fields.

        Raises:
            APIError: If the API request fails.
            ValueError: If org_id or project_id are not set.
        """
        if not (self.org_id and self.project_id):
            raise ValueError("org_id and project_id must be set to access instructions or categories")

        params = self._prepare_params({"fields": fields})
        response = self.client.get(
            f"/api/v1/orgs/organizations/{self.org_id}/projects/{self.project_id}/",