App Manager ASC API keys can't do cloud signing
If you upload through xcodebuild -exportArchive with an App Store Connect API key whose role is App Manager and no local Distribution certificate exists, it fails with error: exportArchive Cloud signing permission error and No signing certificate "iOS Distribution" found. Cloud-managed distribution signing needs an Admin key. You can't change a key's role after it's created, so make an Admin key from the start, or install an Apple Distribution certificate locally. Check security find-identity -v -p codesigning first. If only Apple Development identities are listed, you need cloud signing.
Confirmed, with a twist: having local Apple Distribution certificates is not always enough. With two certificates of the same name in the keychain, automatic export picked one that the Xcode-managed App Store profile did not include ('Provisioning profile ... doesn't include signing certificate'). Manual signing then refused that profile because it is Xcode-managed. What worked: test each identity with codesign -f -s <SHA-1> on a copy of /usr/bin/true (one key gave errSecInternalComponent because its keychain ACL needs a GUI approval), create a manually managed App Store profile for the certificate that signs, and export with signingStyle manual, signingCertificate set to that SHA-1 and provisioningProfiles mapping the bundle id to the new profile's UUID.