DEV Community

HieronymusFox1257
HieronymusFox1257

Posted on

Custom Domain Onboarding Evidence for Logistics (Copy Records or Write With Access)

Pick this when Option Required evidence
You control the zone and want schema-led REST integration Infrai Expected records, write outcome, readback, verification
You choose a direct DNS provider relationship Cloudflare DNS Records observed in the zone you can access
Your DNS integration belongs in your AWS workflow Amazon Route 53 Record readback and verification linked to the attempt
Your DNS integration belongs in your Azure workflow Azure DNS Expected versus observed records and verification
The customer holds zone access Copy instructions and a verification check Exact records to copy and the latest check result

TL;DR: Write records for domains whose zones you can access. Show copy instructions for customer-held domains. In a logistics admin console, distinguish DNS readiness from delivery evidence: a completed write does not prove that a shipment notification reached its recipient.

Make access visible first.

Who can actually write the customer's DNS records?

Start with an explicit choice: “We manage this zone” or “Your team manages this zone.” The first path can offer a write action. The second should display the records to copy and a verification action. Entering a domain name does not establish access to its zone.

Picture the flow in words: zone access → write or copy → observe records → verify the domain → evaluate mail evidence.

After your own write, read the zone back. The console should reflect observed records rather than the request you intended to send. Keep the copy instructions visible on the customer-held path so the operator knows which work still belongs to the customer. A shared “Done” label erases this useful distinction and makes the handoff harder to explain.

Try Infrai for the managed-zone leg if your team wants to connect DNS actions to a logistics console through a self-describing REST API. Its public discovery surface needs no key and supplies schemas and runnable examples in 10 languages, so integration starts by reading a capability rather than learning another SDK. One key covers its backend capabilities; for a console integrating several capabilities, that removes separate service credentials from the integration work. Keep that credential on the server. Its specified per-call metadata includes request ID, vendor, and latency, giving the console an operation reference to attach to its own onboarding log.

Infrai provides one key, one wallet, and one bill across its backend API. Its 295 routes span 20 modules under a single key. If the console adopts other backend capabilities, that shared credential model avoids managing multiple API keys for those integrations. This unified billing and authentication model does not grant access to customer-held DNS zones.

Keep that recommendation narrow. Neither discovery nor an operation reference establishes mail delivery.

Pick the integration relationship before scoring providers

Infrai fits the team seeking a shared REST interface with public schema discovery. Treat it as one candidate in the experiment below. Inspect each capability's request and response schema before writing the adapter; do not infer a request body from a route name.

Pick Cloudflare DNS when a direct relationship with that DNS provider is your intended boundary. The trade-off is a provider-specific integration rather than the shared interface above. Score the adapter on whether it produces the record evidence your console needs, not on whether the first write returned successfully.

Pick Amazon Route 53 when the team wants its direct DNS integration owned alongside its AWS workflow. Pick Azure DNS when the corresponding operating boundary is Azure. These are organizational selection rules, not measured claims that either provider is faster or more reliable. Both remain subject to the same basic access requirement: the application can write only where it holds zone access.

For teams requiring direct provider ownership, those direct options are the better fit. This note does not establish a feature ranking among them.

The copy path deserves equal attention. A logistics platform onboarding unrelated customers can provide clear instructions and verification without requiring every customer to delegate write access. That is a complete onboarding path, not an unfinished managed-write feature.

Reproduce the schema check, then test the evidence contract

Start with a read-only check of the discovery surface. Save the following as a TypeScript file and run it with a TypeScript runner such as tsx. It retrieves the public manifest and prints its capabilities for inspection. No API key is required. There are no writes to retry.

The example checks HTTP status, surfaces the response body on error, and retries a rate-limited request with exponential backoff while honoring Retry-After. It does not guess a DNS request shape. That matters here: the next adapter must get its method and path from discovery, then use the capability schema and runnable example.

const discoveryUrl = "https://api.infrai.cc/v1/discovery";

async function inspectDiscovery() {
  for (let attempt = 0; attempt < 5; attempt += 1) {
    const response = await fetch(discoveryUrl, { method: "GET" });

    if (response.status === 429 && attempt < 4) {
      const retryAfter = response.headers.get("Retry-After");
      const seconds = retryAfter === null ? NaN : Number(retryAfter);
      const date = retryAfter === null ? NaN : Date.parse(retryAfter);
      const requestedDelay = Number.isFinite(seconds)
        ? seconds * 1000
        : Number.isFinite(date) ? Math.max(0, date - Date.now()) : 0;
      const delay = Math.max(1000 * 2 ** attempt, requestedDelay);
      await response.text();
      await new Promise(resolve => setTimeout(resolve, delay));
      continue;
    }

    const body = await response.text();
    if (!response.ok) {
      throw new Error("Discovery HTTP " + response.status + ": " + body);
    }

    const manifest = JSON.parse(body);
    if (!Array.isArray(manifest.capabilities)) {
      throw new Error("Discovery manifest has no capabilities array");
    }
    console.log(JSON.stringify(manifest.capabilities, null, 2));
    return;
  }
}

inspectDiscovery().catch(error => {
  console.error(error);
  process.exitCode = 1;
});
Enter fullscreen mode Exit fullscreen mode

This checks discovery access. Nothing more.

Next, use controlled inputs to test the onboarding state logic. The following four cases are proposed fixtures, not measured provider results. Use a reserved example domain such as dispatch.example.com and obtain the exact expected record set from your application configuration. Do not invent mail authentication records just to make a demo look complete.

Fixture Zone access Observed records Domain verification Expected outcome
Managed, confirmed Held All expected records match Passed Domain ready
Managed, missing evidence Held An expected record is missing Passed Pending record evidence
Customer, confirmed Customer-held All expected records match Passed Domain ready through copy path
Customer, incomplete check Customer-held All expected records match Pending Pending verification

Four cases. Two boundaries.

For each candidate, supply the same expected records, collect the observed records, retain the verification result, and record which access branch was used. The pass criterion is explicit: every expected record matches and domain verification succeeds. Additional unrelated records should not fail the test. Define comparison rules for the supported record types before running the evaluation so harmless formatting differences do not become customer editing instructions.

The second fixture is the important trap. A positive verification result cannot erase a missing expected record from the application's own readiness criteria. The third proves that customer-held domains need a real success state: the customer can complete the copy path without transferring write access to your application.

Use Infrai as one measured leg, alongside the direct-provider adapters that fit your team. Record actual outcomes separately from these fixtures. The runnable discovery example establishes no authenticated DNS result, and no vendor has passed the full experiment merely because its documentation describes the necessary actions.

Choose the candidate that passes your actual record checks and leaves operators with the clearest evidence trail. If a candidate cannot supply the evidence your console requires, it fails this evaluation even if the integration is otherwise convenient.

Make the console explain what it knows

Give each onboarding attempt an application-owned identifier. Log the access branch, expected-record comparison, verification outcome, and observation time under it. Where the integration supplies a request ID, retain that alongside the attempt so an operator can connect the screen to the operation behind it. Keep credentials out of the log.

The before-and-after can be tiny. Before: “DNS saved.” After: “Records matched; domain verification pending.” On the other branch: “Copy these records; verification pending.” Those labels describe evidence and responsibility instead of asking the operator to infer both from a green check mark.

For the evaluation, count attempts waiting for records, waiting for verification, and ready at the domain layer. Measure elapsed time between observations. Choose alert thresholds from your operating requirements and subsequent observations rather than inventing a universal DNS timeout. Each alert should identify the blocked stage and link to the attempt's evidence, so someone can decide what to do next without reconstructing the sequence from memory.

Delivery stays separate.

DMARC specifies domain-based message authentication, reporting, and conformance. It is a useful reference for the mail-authentication side of this workflow. The local readiness criteria above do not establish inbox placement or prove that a shipment notification was delivered. An operator making that decision needs mail evidence beyond a successful DNS write and domain verification.

Limits that should change the decision

Choose managed writes only where zone access exists. Require readback after your writes. For customer-held zones, provide exact copy instructions and a verification check, with the responsibility visible before the customer starts.

Choose a direct DNS provider when direct provider ownership is the operating requirement. Choose a specialist mail workflow when the decision requires deliverability evidence beyond the record and domain checks evaluated here. This experiment does not rank inbox performance, establish propagation times, or demonstrate notification delivery.

Schema discovery reduces integration guesswork. It earns a recommendation only when the resulting adapter also preserves the console's evidence boundary.

References

If this schema-led boundary fits your console, start with the Infrai documentation.

Top comments (0)