DEV Community

Cover image for Day 96: How to stop Apple from rejecting your serverless app
Eric Rodríguez
Eric Rodríguez

Posted on

Day 96: How to stop Apple from rejecting your serverless app

Today I submitted my Serverless AI Financial Agent to the iOS App Store.

If you build apps that rely on external APIs (like Stripe, Plaid, or heavy GenAI models), you are at risk of failing the App Store Review. If a reviewer logs in and your 3rd-party Sandbox API times out, they will reject your app instantly.

The Solution: AWS Lambda Test Routing
I didn't just give Apple a test account; I built a trapdoor for them in my Python backend.

When the HTTP request hits API Gateway, my Lambda function decodes the JWT. If it detects the Apple Reviewer's email, it completely skips the external API calls.

Inside lambda_function.py

if user_email_jwt == 'apple.review@duromoney.com':
# Bypass DynamoDB and Plaid
return serve_deterministic_mock_state()

This ensures the reviewer gets a lightning-fast, perfectly populated UI every single time, without exposing any real PII or relying on flaky sandbox environments.

App Store Connect "Notes":
Always be transparent. I explicitly wrote in the Review Notes: "This test account loads deterministic mock data to prevent 3rd-party API timeouts during your review. The AI engine remains live."

Control the review environment, and you control the approval.

Top comments (1)

Collapse
 
harjjotsinghh profile image
Harjot Singh

App Store rejection is the most demoralizing boring-but-required gate there is, because it's not about whether your app works - it's about satisfying an opaque, inconsistently-applied reviewer checklist that has nothing to do with your actual product. And the serverless angle adds its own traps: reviewers wanting a working demo account, guideline 4.2 "minimum functionality," anything that looks like it phones home to a backend they can't inspect, account-deletion requirements. Writing down the concrete fixes is genuinely useful because everyone hits these and the docs don't tell you in advance - you find out by getting rejected. Day 96 of building in public and still shipping through this is real persistence.

This is squarely the "boring 20% that's invisible until it blocks you" problem I care about - the gap between "my code works" and "it's actually allowed to ship" is where so much time dies. It's the whole reason Moonshift exists, the thing I work on - a multi-agent pipeline that takes a prompt to a deployed web SaaS, getting the deploy/compliance friction handled so the last mile isn't where you stall (different surface than App Store review, same philosophy: don't let the boring gate kill the project). Multi-model routing keeps a build ~$3 flat, first run free no card. Solid, hard-won writeup. Which rejection reason was the sneakiest - the demo-account/minimum-functionality one, or something privacy-related? Those two eat the most resubmits.