Yes, there are two ways to do this before you upload to Splunk Cloud.
1. AppInspect CLI (runs fully on your machine)
pip install splunk-appinspect
splunk-appinspect inspect myapp.tgz --mode precert --included-tags cloudFor private apps on Splunk Cloud, use the tag that matches your stack's architecture instead of cloud: --included-tags private_victoria or --included-tags private_classic. These architecture-based tags are groups of checks taken from the original private-app tag, and they apply the self-service install checks for your specific Cloud stack. You can add --output-file report.json or --generate-feedback to get a report you can act on.
2. AppInspect API (the same service Cloud uses)
Send the package to https://appinspect.splunk.com/v1/app/validate with a Bearer token from your splunk.com account and the same tags. This is closer to what Cloud will report. The API has more checks than the CLI, including some runtime checks that install the app into a running Splunk instance. It may also use a newer version of the AppInspect library.
What I'd recommend: run the CLI on every build, since it's fast and works offline. Then run the API with your stack's tag as the last step before you upload. Splunk's docs say the CLI might not include the latest checks and does not use dynamic analysis, so a clean CLI run doesn't guarantee a clean result in Cloud. If you use GitHub Actions, Splunk publishes actions for both the CLI and the API, so you can run this on each PR. If you install private apps through ACS, upload the same package that passed the API run.
Docs: https://dev.splunk.com/enterprise/docs/developapps/testvalidate/appinspect
You can use Add-On builder. After installing AOB, you can choose your app from "Other apps and add-ons" and have it checked. If you only use "Best Practice", "Data Model Mapping" and "Field Extraction" checks, they are done locally. If you choose "App Precertification", the app will get uploaded on your behalf to the Cloud app checker (you have to provide your user/pass in settings).