API ReferenceapiaffiliatesPOST /v1/admin/payouts/{id}/mark-paid

POST /v1/admin/payouts/\{id\}/mark-paid

Service: affiliates · operationId: (none)

Mark a payout as paid by recording the external reference (PayPal txn id, Stripe transfer id, etc).

Required scopes

(no scope declared — review service config)

Path parameters

  • id (string) required

Request body

{
  "type": "object",
  "properties": {
    "external_ref": {
      "type": "string",
      "minLength": 1
    }
  },
  "required": [
    "external_ref"
  ]
}

Responses

200 Payout marked paid

{
  "type": "object",
  "properties": {
    "id": {
      "type": "string"
    },
    "affiliate_id": {
      "type": "string"
    },
    "currency": {
      "type": "string"
    },
    "gross_amount_cents": {
      "type": "string"
    },
    "reversal_amount_cents": {
      "type": "string"
    },
    "amount_cents": {
      "type": "string"
    },
    "recovery_owed_cents": {
      "type": "string"
    },
    "commission_ids": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "commission_count": {
      "type": "integer"
    },
    "period_start": {
      "type": "string"
    },
    "period_end": {
      "type": "string"
    },
    "status": {
      "type": "string"
    },
    "approved_at": {
      "type": [
        "string",
        "null"
      ]
    },
    "approved_by": {
      "type": [
        "string",
        "null"
      ]
    },
    "paid_at": {
      "type": [
        "string",
        "null"
      ]
    },
    "external_ref": {
      "type": [
        "string",
        "null"
      ]
    },
    "created_at": {
      "type": "string"
    }
  },
  "required": [
    "id",
    "affiliate_id",
    "currency",
    "gross_amount_cents",
    "reversal_amount_cents",
    "amount_cents",
    "recovery_owed_cents",
    "commission_ids",
    "commission_count",
    "period_start",
    "period_end",
    "status",
    "approved_at",
    "approved_by",
    "paid_at",
    "external_ref",
    "created_at"
  ]
}

404 Payout not found

{
  "type": "object",
  "properties": {
    "error": {
      "type": "string"
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "error",
    "message"
  ]
}

Example

curl -X POST https://affiliates.platform.loop.health/v1/admin/payouts/{id}/mark-paid \
  -H "Authorization: Bearer $ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'