Skip to Content
Paycose Docs
Accounts

Accounts

The connect_split_preview object

How a payment of amount would split with an account under the terms you pass, before anything is saved. Amounts are in the currency's smallest unit (for example 49900 = 499.00 THB).

Attributes

  • objectstringRequired

    String naming the object's type: always connect_split_preview.

  • accountstringRequired

    The account ID from the path, as you passed it.

  • account_namestringRequired

    The connected account's display name; empty when connected is false.

  • connectedbooleanRequired

    true when the account is one of your connected accounts. false for your own account or one you cannot see; nothing splits then and you keep the whole amount.

  • modestringRequired

    How the split is set.

    • application_fee

      You keep the application fee and the rest reaches the account. Also the mode when connected is false.

    • transfer_amount

      transfer_amount reaches the account and you keep the rest. Used when you pass transfer_amount.

  • amountintegerRequired

    The amount you passed; a missing or negative one reads as 0.

  • application_feeintegerRequired

    The application fee you keep: application_fee_percent of amount (the percent kept to two decimals, the result rounded half up) when you pass it, else application_fee_amount. 0 in transfer_amount mode and when connected is false.

  • to_accountintegerRequired

    What reaches the account: amount − application_fee, or transfer_amount in transfer_amount mode. Negative when the application fee is more than amount; 0 when connected is false.

  • you_keepintegerRequired

    What you keep: application_fee, or amount − transfer_amount in transfer_amount mode; the whole amount when connected is false.

  • exceedsbooleanRequired

    true when the application fee or the transfer amount is more than amount.

  • no_feebooleanRequired

    true when you keep nothing from the payment.