DutyClaims Docs
Migration Guide

Move new work to canonical `/v1/*` routes and treat compatibility paths as explicit debt.

DutyClaims still carries legacy diligence and broker-compatibility surfaces so current traffic does not break during cutovers. New work should target the canonical partner API, and existing work should migrate with visible alias headers, route maps, and rollback discipline.

Migration rules that prevent drift

  • Point new tooling, generated clients, and partner examples at canonical `/v1/*` routes first.
  • Keep compatibility aliases explicit in code, logs, partner communication, and sunset planning.
  • Do not present migration-only routes as permanent product surface area.
  • Keep the cutover packet on the same OpenAPI hash as the deployment you are validating.

Legacy diligence to canonical v1

Legacy pathCanonical routeAuth and header ruleBehavior note
/api/diligence/submitPOST /v1/diligence/submitPrefer managed bearer credentials; the published compatibility surface still allows `X-API-Key`.Keep the multipart body shape, record the returned job ID immediately, and treat `202 Accepted` as queue handoff rather than completion.
/api/diligence/status/{jobId}GET /v1/diligence/status/{jobId}Use the same managed credential posture as submit and keep the current compatibility header path only where the live integration still depends on it.Poll the durable job record rather than inferring progress from queue timing or upload completion.
/api/diligence/report/{jobId}GET /v1/diligence/report/{jobId}Keep auth semantics aligned with the canonical diligence family so report consumers do not drift from submit/status readers.Treat the report payload, including `rf8Review`, as the public source of truth for diligence outcomes.
/api/diligence/dataset/{jobId}GET /v1/diligence/dataset/{jobId}Use the same credential path as the report route to avoid split behavior during migration.Keep dataset consumers pinned to the same contract version as the report readers.
/api/diligence/jobs/{jobId}/resumePOST /v1/diligence/jobs/{jobId}/resumeDo not treat resume as a blind retry. It is an explicit operational action with the same diligence auth posture.Resume only when the job is partial or failed and the current operator workflow actually calls for it.

Canonical diligence examples

Use the generated examples below as your migration rehearsal path, then move your app logic onto the downloaded starter files or your own typed client wrapper.

#!/usr/bin/env bash
set -euo pipefail

API_BASE_URL="${API_BASE_URL:-https://api.dutyclaims.com}"
TOKEN="${TOKEN:-dcp_live_replace_me}"
CSV_PATH="${CSV_PATH:-./sample-entries.csv}"

curl -X POST "${API_BASE_URL}/v1/diligence/submit" \
  -H "Authorization: Bearer ${TOKEN}" \
  -F "seller_name=Acme Imports" \
  -F "requires_protest_documentation=false" \
  -F "file=@${CSV_PATH};type=text/csv"
#!/usr/bin/env bash
set -euo pipefail

API_BASE_URL="${API_BASE_URL:-https://api.dutyclaims.com}"
TOKEN="${TOKEN:-dcp_live_replace_me}"
JOB_ID="${JOB_ID:-00000000-0000-4000-8000-000000000000}"

curl "${API_BASE_URL}/v1/diligence/status/${JOB_ID}" \
  -H "Authorization: Bearer ${TOKEN}" \
  -H "Accept: application/json"
#!/usr/bin/env bash
set -euo pipefail

API_BASE_URL="${API_BASE_URL:-https://api.dutyclaims.com}"
TOKEN="${TOKEN:-dcp_live_replace_me}"
JOB_ID="${JOB_ID:-00000000-0000-4000-8000-000000000000}"

curl -X POST "${API_BASE_URL}/v1/diligence/jobs/${JOB_ID}/resume" \
  -H "Authorization: Bearer ${TOKEN}" \
  -H "Accept: application/json"

Diligence cutover checks

  • Compare auth success and failure behavior on the legacy and canonical surfaces before switching traffic.
  • Keep report and dataset consumers pinned to the same job ID and contract version.
  • Do not remove the legacy compatibility path until your comparison suite passes against live-like traffic.
  • Keep RF8 interpretation on the public report contract only; source-lookup details remain internal.

Broker alias map from the generated compatibility artifact

AliasCanonical pathFamilyLifecycleNotes
/broker/onboard/v1/partner-organizations/{partnerOrgId}onboardingmigration_onlyLegacy broker onboarding shortcut retained for migration cutovers.
/broker/v1/onboard/v1/partner-organizations/{partnerOrgId}onboardinglong_termBootstraps broker-facing partner org and capability context.
/broker/v1/webhooks/register/v1/webhooks/endpointswebhookslong_termRegisters broker webhook endpoints against the canonical webhook registry.
/broker/v1/clients/v1/clientsclientslong_termCreates and lists broker-linked client accounts through the canonical client model.
/broker/v1/portfolio/scan/v1/portfolio-scansportfolio_scanslong_termRuns canonical portfolio scans without forcing an immediate path rewrite.
/broker/v1/portfolio/delta-scan/v1/portfolio-scansportfolio_scansmigration_onlyTransforms legacy delta-scan payloads into canonical portfolio scan requests.
/broker/v1/portfolio/scan/{scanId}/v1/portfolio-scans/{scanId}portfolio_scanslong_termReads canonical scan detail from the broker-prefixed route family.
/broker/v1/portfolio/summary/v1/portfolio-scans/{scanId}/summaryportfolio_scansmigration_onlyPreserves the summary endpoint shape while routing into canonical scan summaries.
/broker/v1/notifications/v1/notificationsnotificationslong_termCreates canonical partner notification requests from broker-facing URLs.
/broker/v1/revenue/ledger/v1/revenue/ledgerrevenuelong_termReads the canonical revenue ledger through the broker-prefixed namespace.
/broker/v1/revenue/dashboard/v1/revenue/dashboardrevenuelong_termReads the canonical revenue dashboard through the broker-prefixed namespace.
/broker/v1/claims/v1/claimsclaimslong_termCreates and lists canonical claims from broker integrations.
/broker/v1/offers/v1/offersofferslong_termCreates and lists canonical financing offers from broker integrations.
/broker/v1/litigation/enroll/v1/litigation/enrolllitigationlong_termEnrolls claims into canonical litigation workflows from broker-prefixed routes.

Headers to log during alias traffic

HeaderWhy it matters
X-DutyClaims-Broker-AliasThe exact alias path the request used.
X-DutyClaims-Canonical-PathThe canonical `/v1/*` path the alias forwarded into.
X-DutyClaims-Compatibility-LifecycleWhether the alias is long-term or migration-only.

When to stop using alias routes

  • Stop once the canonical route delivers the same business outcome and your partner no longer depends on the alias namespace.
  • Keep long-term aliases explicit in docs and code; they are compatibility aids, not proof that canonical migration is optional.
  • Set an explicit sunset date for every migration-only alias that remains live.
  • Use the production launch checklist before moving live traffic.

Long-term aliases

  • /broker/v1/onboard -> /v1/partner-organizations/{partnerOrgId}
  • /broker/v1/webhooks/register -> /v1/webhooks/endpoints
  • /broker/v1/clients -> /v1/clients
  • /broker/v1/portfolio/scan -> /v1/portfolio-scans
  • /broker/v1/portfolio/scan/{scanId} -> /v1/portfolio-scans/{scanId}
  • /broker/v1/notifications -> /v1/notifications
  • /broker/v1/revenue/ledger -> /v1/revenue/ledger
  • /broker/v1/revenue/dashboard -> /v1/revenue/dashboard
  • /broker/v1/claims -> /v1/claims
  • /broker/v1/offers -> /v1/offers
  • /broker/v1/litigation/enroll -> /v1/litigation/enroll

Migration-only aliases

  • /broker/onboard -> /v1/partner-organizations/{partnerOrgId}
  • /broker/v1/portfolio/delta-scan -> /v1/portfolio-scans
  • /broker/v1/portfolio/summary -> /v1/portfolio-scans/{scanId}/summary