I wanted to know if you can publish on both platforms with the same build.
No, this is no possible, because each store defines a diferent format for its bundles, for a Play Store Build you’lll need an “aab” format while in the App Store you’ll need a “ipa” (or some other) format.