What Are You Delegating?
Every abstraction is a trade: it removes work by making decisions for you. Those decisions are still being made — just not by you, and not visibly. For each abstraction: what it genuinely handles, what remains yours, and the escape hatch.
An ORMAn HTTP client or SDKA managed database or cloud platformAn identity providerAn LLM or coding agentA web frameworkA library functionA managed message queueA cacheA container runtime and orchestrator
What are you delegating to an http client or sdk?
API DesignYou write
1const charge = await stripe.charges.create({ amount: 4990, currency: 'eur' })The abstraction handles
- ✓Serialization, headers, authentication headers
- ✓Connection reuse and TLS
- ✓Typed request and response shapes
- ✓Default retries for the failures the vendor considers safe
- ✓Pagination helpers, rate-limit backoff
Still your responsibility
- →Timeouts — the default is often none, and "none" means your thread waits as long as their outage lasts
- →Idempotency — a retried
POSTis a second request; the key that makes it safe is yours to supply - →Failure semantics — an exception does not tell you whether the remote side performed the action
- →Blast radius — what the API key is scoped to, where it lives, how it rotates
- →Their availability is now yours — unless you designed a fallback, their incident is your incident
Know your escape hatch
When: The SDK's retry policy, timeout or error mapping does not fit your endpoint's semantics.
Drop to: The raw HTTP contract: method, status codes, error model, Retry-After, and your own client with explicit timeouts and idempotency keys.
You do not have to stop using the SDK — most expose the underlying request options. You have to know they exist.