A few weeks ago, our company sold a portion of our services.
As part of the pass over, JIRA data has to be transferred to their instance.
What would be the best way to go about it?
Our JIRA instance contains 3 other projects that can't be shared with them.
I've read that you can only export the full instance.
Is it possible to sanitize the exported data before sending it over?
It is still the case, there's not a lot built into Jira to help you with it.
However, there are now a lot more apps that can help you move projects between systems. There's a been a handful (Project configurator, Configuration Manager, etc) for years, but over the last couple of years more have become available, including Atlassian's own JCMA - that was built for people to do Server to Cloud migrations, but can be used to move projects Cloud to Cloud as well now. There's a Cloud backup system by Revya that I've not yet tried out, but sounds like it can do single project stuff too.
The "clone then delete what you don't need" method is still the most simple conceptually, but it's well worth a look at all the apps that can help.