← Library
◆ ProductProduct ManagementOctober 25, 2026 · 4 min read

An API contract must explain the customer outcome

A successful response can describe work that is still unfinished. Give the consuming product a contract for the outcome it may honestly show.

Article
Reading time
4 min read
Sections
4
Published
October 25, 2026
LinkedInEmail
In this essay4 sections

A customer requests a document export. The API returns HTTP 202, and the interface displays “Your file is ready.” The customer clicks Download and receives nothing because conversion is still running.

The endpoint behaved as designed. The consumer's interpretation did not. API contract design has to explain the business result a client may show, as well as the shape of a successful HTTP response.

Two colleagues test a document scanner with blank paper in an office.

Define the promise at each state

RFC 9110, section 15.3.3, defines 202 as acceptance for processing without completed processing. The response should describe the current status and point to, or include, a status monitor. Acceptance therefore cannot carry the same product promise as an available export.

For this fictional document service, the contract could expose an operation reference and a status resource. The following states are a proposed application design, not a required HTTP vocabulary.

Application state Evidence available Appropriate customer experience
Accepted The service has accepted this export request Show that preparation has been requested and preserve its reference
Processing The export is still being produced Show progress only if the service can substantiate it
Completed The result exists and the authorized caller can retrieve it Offer the supported download route
Failed The operation ended without a usable result Explain the permitted recovery using an appropriate error type
Expired A previously available result is no longer retrievable under the retention policy Explain expiry and whether a new export is permitted

An HTTP 200 response from the status endpoint means the status query succeeded. It does not transform an application state of processing into completed.

Give the consumer enough evidence to behave correctly

The consumer needs to know which operation the response describes, which state values it must handle and which actions are allowed. The result link needs its own access and expiry rules. A link existing in a payload does not prove that every caller may retrieve the file.

The contract should also define what happens when the client cannot determine the current state. Preserve the operation reference and show that the result is being checked. Do not invent completion or immediately create another job because the last status request failed. The design of uncertain interface states is covered in the UI state inventory.

Show the export outcome supported by the operation state
1. Accept the export request

Preserve the operation reference and expose the supported status route. Acceptance is not a ready file.

Read the current application state
2. Is the result ready for this authorized caller?

A successful status query may still describe accepted or processing work.

Processing or state unknown

Keep the same operation and check its supported status route. Do not display completion.

Recheck result readiness
Failed or expired

Explain the specific supported recovery. Do not offer a nonexistent file.

Only completed, retrievable work proceeds to download
3. Offer the supported result

Apply access and expiry rules to the actual file. Keep the operation reference available.

These export states are an application design example. HTTP acceptance alone does not establish file readiness; failed, expired and unknown results require their own supported response.

Make errors useful without making prose an API

RFC 9457 provides a structure for problem details. Its type identifies the kind of problem; detail explains the particular occurrence to a person. Clients should not parse that explanatory prose to make decisions. The specification also cautions against exposing sensitive implementation details.

For the export, a stable problem type might distinguish unsupported input from an unavailable result. The exact identifiers and remediation rules belong in the service's contract. Keep internal storage paths or stack traces out of the customer-facing response.

A translated explanation can change wording while preserving the machine-facing meaning. Conversely, keeping the same wording while changing whether an operation can continue is a contract change that needs review.

Test the consuming product, not just the response schema

Ask the client team to demonstrate accepted, delayed, completed, failed and expired operations with controlled fixtures. Include an unfamiliar optional response field and an unknown state value. Define the supported compatibility policy in advance: a client that cannot interpret a state should retain uncertainty and use an approved escalation path, rather than display success.

Check the response and the actual interface together. Does the Download action appear only when the result is usable? Does the customer keep the same operation reference through a lost status response? Can support find that operation without asking the customer to repeat the request?

Record these examples in the development handoff. A schema that validates all five payloads is useful evidence, but the customer promise is only tested when the consumer uses each one correctly.

Tags
interface contractproduct managementasynchronous operations

Closing thought and further reading

A successful response can describe work that is still unfinished. Give the consuming product a contract for the outcome it may honestly show.

Share article
LinkedInEmail
Keep reading
View all essays
Product Management

Design the state that appears when the normal journey stops

An empty form after a lost response cannot tell the user whether a booking exists. Map evidence, interface wording and the next permitted action together.

5 min read
Product Management

A product handoff is ready when the receiving team can use it

A folder of designs is not enough when the receiving team cannot find the current rule. Walk through one case and expose the decisions that still affect it.

5 min read
Product Management

Accessibility belongs in the acceptance conversation

A dialog can look clear while leaving a keyboard user behind it. Follow the complete change task and record what the tested environment actually supports.

4 min read
Operating proof
Continue the conversation

Need help applying this to your business?

Explore practical support for payment operations, product decisions, program delivery and AI automation, grounded in the challenges behind this essay.

Explore relevant supportEmail Rizwan
Payments Infrastructure Notes

Interested in future field notes?

Request email updates on payments, product decisions, program delivery and practical AI. Your request goes to my inbox for follow-up.

A request for occasional updates, with no weekly schedule promised.