> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mangopay.com/llms.txt
> Use this file to discover all available pages before exploring further.

# The Preauthorized PayIn object

### Description

The Preauthorized PayIn object represents a request to capture funds previously authorized with a Preauthorization object. 

The preauthorized pay-in must be:

* Of an amount equal to or less than the preauthorized amount
* Done within 6.5 days of a successful authorization

<Warning>
  **Caution – Idempotency key required for multi-capture**

  You must use an idempotency key if making multiple captures (available with Visa, Mastercard, CB,AMEX).

  Unless accompanied by an idempotency key, two pay-ins are considered as duplicate if they are made:

  * within 24 hours for the same amount and currency
  * with the same `CardId`
</Warning>

### Attributes

<ParamField body="Id" type="string">
  The unique identifier of the object.
</ParamField>

<ParamField body="Tag" type="string">
  Max. length: 255 characters

  Custom data that you can add to this object.\
  For transactions (pay-in, transfer, payout), you can use this parameter to identify corresponding information regarding the user, transaction, or payment methods on your platform.
</ParamField>

<ParamField body="CreationDate" type="Unix timestamp">
  The date and time at which the object was created.
</ParamField>

<ParamField body="ResultCode" type="string">
  The code indicating the result of the operation. This information is mostly used to <a href="/errors/codes">handle errors</a> or for filtering purposes.
</ParamField>

<ParamField body="ResultMessage" type="string">
  The explanation of the result code.
</ParamField>

<ParamField body="AuthorId" type="string">
  The unique identifier of the user at the source of the transaction.
</ParamField>

<ParamField body="CreditedUserId" type="string">
  **Default value:** The unique identifier of the owner of the credited wallet.

  The unique identifier of the user whose wallet is credited.
</ParamField>

<ParamField body="DebitedFunds" type="object">
  Information about the debited funds.

  <Expandable title="properties">
    <ParamField body="Currency" type="string">
      **Returned values:** The three-letter <a href="/api-reference/overview/data-formats" target="_blank">ISO 4217 code</a> (EUR, GBP, etc.) of a <a href="/guides/currencies" target="_blank">supported currency</a> (depends on feature, contract, and activation settings).

      The currency of the debited funds.
    </ParamField>

    <ParamField body="Amount" type="integer">
      An amount of money in the smallest sub-division of the currency (e.g., EUR 12.60 would be represented as `1260` whereas JPY 12 would be represented as just `12`).
    </ParamField>
  </Expandable>
</ParamField>

<ParamField body="CreditedFunds" type="object">
  Information about the credited funds (`CreditedFunds` = `DebitedFunds` - `Fees`).

  <Expandable title="properties">
    <ParamField body="Currency" type="string">
      **Returned values:** The three-letter <a href="/api-reference/overview/data-formats" target="_blank">ISO 4217 code</a> (EUR, GBP, etc.) of a <a href="/guides/currencies" target="_blank">supported currency</a> (depends on feature, contract, and activation settings).

      The currency of the credited funds.
    </ParamField>

    <ParamField body="Amount" type="integer">
      An amount of money in the smallest sub-division of the currency (e.g., EUR 12.60 would be represented as `1260` whereas JPY 12 would be represented as just `12`).
    </ParamField>
  </Expandable>
</ParamField>

<ParamField body="Fees" type="object">
  Information about the fees taken by the platform for this transaction (and hence transferred to the Fees Wallet).

  <Expandable title="properties">
    <ParamField body="Currency" type="string">
      **Returned values:** The three-letter <a href="/api-reference/overview/data-formats" target="_blank">ISO 4217 code</a> (EUR, GBP, etc.) of a <a href="/guides/currencies" target="_blank">supported currency</a> (depends on feature, contract, and activation settings).

      The currency of the fees.
    </ParamField>

    <ParamField body="Amount" type="integer">
      An amount of money in the smallest sub-division of the currency (e.g., EUR 12.60 would be represented as `1260` whereas JPY 12 would be represented as just `12`).
    </ParamField>
  </Expandable>
</ParamField>

<ParamField body="Status" type="string">
  **Returned values:** `CREATED`, `SUCCEEDED`, `FAILED`

  The status of the transaction.
</ParamField>

<ParamField body="ExecutionDate" type="Unix timestamp">
  The date and time at which the status changed to `SUCCEEDED`, indicating that the transaction occurred. The statuses `CREATED` and `FAILED` return an `ExecutionDate` of `null`.
</ParamField>

<ParamField body="Type" type="string">
  **Returned values:** `PAYIN`, `TRANSFER`, `CONVERSION`, `PAYOUT`

  The type of the transaction.
</ParamField>

<ParamField body="Nature" type="string">
  **Returned values:** `REGULAR`, `REPUDIATION`, `REFUND`, `SETTLEMENT`

  The nature of the transaction, providing more information about the context in which the transaction occurred:

  * `REGULAR` – Relative to most of the transactions (pay-ins, payouts, and transfers) in a usual workflow.
  * `REPUDIATION` – Automatic withdrawal of funds from the platform’s repudiation wallet as part of the dispute process (when the user has requested a chargeback).
  * `REFUND` – Reimbursement of a transaction to the user (pay-in refund), to a wallet (transfer refund), or of a payout (payout refund, only initiated by Mangopay).
  * `SETTLEMENT` – Transfer made to the repudiation wallet by the platform to settle a lost dispute.
</ParamField>

<ParamField body="CreditedWalletId" type="string">
  The unique identifier of the credited wallet.
</ParamField>

<ParamField body="DebitedWalletId" type="string">
  The unique identifier of the debited wallet.

  In the case of a pay-in, this value is always `null` since there is no debited wallet.
</ParamField>

<ParamField body="PaymentType" type="string">
  **Returned values:** `CARD`, `DIRECT_DEBIT`, `PREAUTHORIZED`, `BANK_WIRE`

  The type of pay-in.
</ParamField>

<ParamField body="ExecutionType" type="string">
  **Returned values:** `WEB`, `DIRECT`, `EXTERNAL_INSTRUCTION`

  The type of execution for the pay-in.
</ParamField>

<ParamField body="PreauthorizationId" type="string">
  The unique identifier of the preauthorization.
</ParamField>

<ResponseField name="AuthenticationResult" type="object | null" defaultOpen>
  Information about the authentication result, based on the request made by Mangopay and the decision of the issuer regarding the type of authentication to be enforced (if applicable).

  <Expandable title="properties">
    <ResponseField name="AuthenticationType" type="string | null">
      Response values: `CHALLENGE`, `FRICTIONLESS`, `DIRECT_AUTHORIZATION`

      The type of authentication:

      * `CHALLENGE` – The issuer requested SCA to be enforced (for example, using 3DS).
      * `FRICTIONLESS` – The transaction was exempted from SCA because an exemption was granted by the issuer.
      * `DIRECT_AUTHORIZATION` – The transaction was sent to the issuer for authorization without any frictionless or challenge (for example, if SCA doesn't apply).

      A `null` value typically indicates that authentication was not requested (for example, because the request failed before being sent) or a decision was not received.
    </ResponseField>
  </Expandable>
</ResponseField>

### Related resources

<CardGroup cols={2}>
  <Card title="How to" href="/guides/payment-methods/card/preauthorization/how-to">How to process a 7-day card preauthorization</Card>
</CardGroup>
