{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/freeport-gg/json-schema/freeport-gg-withdrawal-schema.json",
  "title": "Withdrawal",
  "x-generated": "2026-11-23",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/_original/freeport-gg-api-openapi.json#/components/schemas/Withdrawal",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "A prefixed ULID"
    },
    "state": {
      "type": "string",
      "enum": [
        "requested",
        "approved",
        "sent",
        "paid",
        "returned",
        "rejected",
        "failed"
      ],
      "description": "`requested`: waiting for a person to review it. `approved`: checked and cleared, being sent. `sent`: on its way, `provider_ref` holds the reference; final for a withdrawal paid by hand. `paid`: in your bank account. `returned`: your bank sent it back, and the money is back in your balance. `rejected`: declined, and the money is back in your balance. `failed`: it could not be sent, and the money is back in your balance."
    },
    "speed": {
      "type": "string",
      "enum": [
        "batch",
        "express"
      ],
      "description": "`batch` is a standard withdrawal, approved and sent every business day once its money is past the payout hold. `express` is sent sooner, and only sellers may ask for one."
    },
    "amount": {
      "type": "string",
      "pattern": "^\\d+(\\.\\d+)?$",
      "description": "What was asked for, and what left your available balance when the request was made. A withdrawal to your bank account is paid in full and costs nothing; one paid by hand has its fee taken out of it. `net` is what you receive."
    },
    "fee": {
      "type": "string",
      "pattern": "^\\d+(\\.\\d+)?$",
      "description": "What the withdrawal cost: nothing for one to your bank account, which the payout fee on your sales pays for; for one paid by hand, what the published fee schedule priced its speed at when it was asked for (the fees page lists the prices). 0.00 on a batch withdrawal asked for before 15 October 2026, when the batch was free."
    },
    "net": {
      "type": "string",
      "pattern": "^\\d+(\\.\\d+)?$",
      "description": "What is paid to you: all of `amount` for a withdrawal to your bank account, `amount` less `fee` for one paid by hand."
    },
    "currency": {
      "type": "string",
      "minLength": 3,
      "maxLength": 3
    },
    "destination_hint": {
      "type": "string",
      "description": "Where it was sent, masked as the Payouts page masks it. The full address is never returned by the API."
    },
    "rail": {
      "type": "string",
      "enum": [
        "bank",
        "skrill"
      ],
      "description": "How it is paid: `bank`, to your bank account; `skrill`, by hand."
    },
    "requested_at": {
      "type": "string",
      "format": "date-time"
    },
    "state_updated_at": {
      "type": "string",
      "format": "date-time",
      "description": "When `state` last changed."
    },
    "provider_ref": {
      "type": [
        "string",
        "null"
      ],
      "description": "The payment provider’s reference, once it is sent. Null until then."
    },
    "reason": {
      "type": [
        "string",
        "null"
      ],
      "description": "The sentence shown beside the withdrawal on the Payouts page when it was rejected or failed. Null otherwise."
    },
    "filed_for": {
      "type": [
        "string",
        "null"
      ],
      "enum": [
        "unwithdrawn",
        "closing"
      ],
      "description": "Null where you asked for it. `unwithdrawn`: Freeport filed it for sales you had not withdrawn 75 days after they were paid. `closing`: Freeport filed it before your account was closed."
    }
  },
  "required": [
    "id",
    "state",
    "speed",
    "amount",
    "fee",
    "net",
    "currency",
    "destination_hint",
    "rail",
    "requested_at",
    "state_updated_at",
    "provider_ref",
    "reason",
    "filed_for"
  ],
  "additionalProperties": false
}