APG PayAPG Paydocs

Merchants

Create travel dbi corrections

POST/travel-dbi-corrections

Correct the references of one or more entries and apply them. Answers with what was staged, refused and skipped, and what applying did.

Permissions

Required permission
merchantTravelData:update

Requires the `update` action on `merchantTravelData` for the supplied runtime context

Request body

This body is a tagged shape: type is always "TvldbicCmdSubmit". Send it; more variants can be added, and a caller that switches on it keeps working when they are.

Discriminated by type
type = "TvldbicCmdSubmit"
merchantIdMchtId

Whose entries to correct. Omit it when the Merchant-Id header names the merchant.

Example mcht_9f2Kd8QpLzXw

curl -X POST https://api.tst.au.apgpay.dev/travel-dbi-corrections \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "type": "TvldbicCmdSubmit",
  "merchantId": "mcht_9f2Kd8QpLzXw",
  "corrections": [
    {
      "type": "TvldbicItemAttributes",
      "travelEntryId": "tvlent_9f2Kd8QpLzXw",
      "references": {
        "type": "TvldbicReferencesAttributes",
        "pk": "string",
        "ds": "string",
        "ks": "string",
        "ae": "string",
        "ik": "string",
        "bd": "2026-08-19",
        "pr": "string",
        "au": "string",
        "ak": "string",
        "rz": "string"
      }
    }
  ]
}'

Responses

The response is a tagged shape: type is always "TvldbicResultAttributes". Switch on it; subtypes can be added, and a client that already reads it will not break.

Discriminated by type
type = "TvldbicResultAttributes"
stagedarray of TvlentId

The corrections staged.

Example tvlent_9f2Kd8QpLzXw

skippedarray of TvlentId

Corrections that name no entry of the merchant whose check failed, which are passed over.

Example tvlent_9f2Kd8QpLzXw

Present when at least one correction was staged: what applying everything staged for the merchant did, any an earlier call left included.

Example
{
  "type": "TvldbicResultAttributes",
  "staged": [
    "tvlent_9f2Kd8QpLzXw"
  ],
  "refused": [
    {
      "type": "TvldbicRefusalAttributes",
      "travelEntryId": "tvlent_9f2Kd8QpLzXw",
      "reasons": [
        "Requested by the customer."
      ]
    }
  ],
  "skipped": [
    "tvlent_9f2Kd8QpLzXw"
  ],
  "applied": {
    "type": "TvldbicAppliedAttributes",
    "applied": 1250,
    "failed": 1250
  }
}

Error responses