> For the complete documentation index, see [llms.txt](https://developers.hyp.co.il/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developers.hyp.co.il/enterprise/additional-payment-scenarios/installments-direct-charge.md).

# Installments in Direct Charge and Two-Phase Commit

When you want to use installments in a direct charge (without showing the [payment page](https://developers.hyp.co.il/enterprise/payment-page-integration/installments.md)) or in a capture request as part of a [two-phase commit](https://developers.hyp.co.il/enterprise/two-phase-commits/overview.md), your request must explicitly contain additional elements. The set and meaning of these elements depend on whether you're using regular or credit installments. In any case, as a merchant, you need to calculate and send an exact breakdown of the installment payments.

## Regular installments

With regular installments (`creditType` is set to `Payments`), your `doDeal` request must include:

* `creditType` set to `Payments` to enable regular installments.
* `firstPayment`: the amount of the first payment in the installment series, specified in currency subunits such as cents or agorot.
* `periodicalPayment`: the amount of each subsequent payment in the installment series, specified in currency subunits such as cents or agorot.
* `numberOfPayments`: the number of periodical payments requested, not including the first payment. For example, to split the transaction into a total of six regular installments (1 first payment and five periodical payments), set `numberOfPayments` to 5.

Hyp will validate your request against the following formula and return error 037 if the validation fails:

```
total = firstPayment + (numberOfPayments x periodicalPayment)
```

In the following request example, the total amount is ₪100, the first payment is ₪10, the periodical payment is ₪30, and the number of periodical payments is 3. Because ₪10+(₪30\*3) equals ₪100, the validation succeeds.

```xml
<ashrait>
      <request>
          <version>2000</version>
          <language>ENG</language>
          <command>doDeal</command>
          <doDeal>
              <terminalNumber>0882818012</terminalNumber>
              <cardId>1024038988865846</cardId>
              <cardExpiration>0427</cardExpiration>
              <total>10000</total>
              <transactionType>Debit</transactionType>
              <creditType>Payments</creditType>
              <currency>ILS</currency>
              <transactionCode>Internet</transactionCode>
              <validation>AutoComm</validation>
              <firstPayment>1000</firstPayment>
              <periodicalPayment>3000</periodicalPayment>
              <numberOfPayments>3</numberOfPayments>
          </doDeal>
      </request>
  </ashrait>
```

A response to this request will look like this:

<details>

<summary>Show response</summary>

```xml
<?xml version='1.0'?>
<ashrait>
    <response>
        <command>doDeal</command>
        <dateTime>2026-07-03 17:11</dateTime>
        <requestId/>
        <tranId>128039564</tranId>
        <result>000</result>
        <message>Permitted transaction</message>
        <userMessage>Permitted transaction</userMessage>
        <additionalInfo>Host Result Remote 00-SUCCESS</additionalInfo>
        <version>2000</version>
        <language>Eng</language>
        <doDeal>
            <status>000</status>
            <statusText>Permitted transaction</statusText>
            <extendedStatus/>
            <extendedStatusText/>
            <extendedUserMessage/>
            <terminalNumber>0882818012</terminalNumber>
            <cardId>1024038988865846</cardId>
            <cardBin>532610</cardBin>
            <cardMask>532610******5846</cardMask>
            <cardLength>16</cardLength>
            <cardNo>xxxxxxxxxxxx5846</cardNo>
            <cardName/>
            <cardExpiration>0427</cardExpiration>
            <cardType code="00">Local</cardType>
            <extendedCardType code="0">Credit</extendedCardType>
            <blockedCard/>
            <lifeStyle/>
            <customCardType/>
            <creditCompany code="1">Isracard</creditCompany>
            <cardBrand code="1">Mastercard</cardBrand>
            <cardAcquirer code="1">Isracard</cardAcquirer>
            <serviceCode/>
            <transactionType code="01">RegularDebit</transactionType>
            <creditType code="8">Payments</creditType>
            <currency code="1">ILS</currency>
            <baseCurrency/>
            <baseAmount/>
            <transactionCode code="52">Internet</transactionCode>
            <total>10000</total>
            <firstPayment>1000</firstPayment>
            <periodicalPayment>3000</periodicalPayment>
            <numberOfPayments>3</numberOfPayments>
            <clubId/>
            <validation code="4">AutoComm</validation>
            <idStatus code="0">Absent</idStatus>
            <cvvStatus code="3">NotValidated</cvvStatus>
            <authSource code="2">CreditCompany</authSource>
            <authNumber>5574022</authNumber>
            <fileNumber>64</fileNumber>
            <slaveTerminalNumber>003</slaveTerminalNumber>
            <slaveTerminalSequence>139</slaveTerminalSequence>
            <eci>7</eci>
            <clientIp/>
            <email/>
            <cavv code=""/>
            <user/>
            <addonData/>
            <supplierNumber>71506</supplierNumber>
            <id/>
            <shiftId1/>
            <shiftId2/>
            <shiftId3/>
            <shiftTxnDate/>
            <cgUid>128039564</cgUid>
            <cardHash/>
            <acquirerData>
                <gateway>AshraitEmv</gateway>
                <acquirerTranType>01</acquirerTranType>
                <mcc>4121</mcc>
                <acquirerTranCode>52</acquirerTranCode>
                <avsResponse code="0">Absent</avsResponse>
                <acquirerResponseId>129337390209</acquirerResponseId>
            </acquirerData>
            <ashraitEmvData>
                <uid>26070317114708828185649</uid>
                <authCodeCreditCompany code="1">CreditCompanyAuthorized</authCodeCreditCompany>
                <ashReasonText>KOD_BIZUA_DCODE, SUG_ISKA</ashReasonText>
                <ashTermType>0</ashTermType>
                <ashVersion>x</ashVersion>
                <authCodeAcquirer code="0">NoAuthNumber</authCodeAcquirer>
                <catLevel>0</catLevel>
                <deviceStatus>1111000000</deviceStatus>
                <emvResponseCode>00</emvResponseCode>
                <cvvFlag>0</cvvFlag>
                <idFlag>0</idFlag>
                <isDoReverseDeal>0</isDoReverseDeal>
                <manufId>CGD</manufId>
                <manufUse>001101</manufUse>
                <mti>100</mti>
            </ashraitEmvData>
            <extendedTranCode/>
            <sendNotification/>
        </doDeal>
    </response>
</ashrait>
```

</details>

## Credit installments

With credit installments (`creditType` is set to `SpecialCredit`), your `doDeal` request must include:

* `creditType` set to `SpecialCredit` to enable credit installments.
* `periodicalPayment`: the amount of each payment in the credit installment series, specified in currency subunits such as cents or agorot. Credit installments do not have a first payment, so this is the only payment amount.
* `numberOfPayments`: the total number of payments requested (3 or more).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://developers.hyp.co.il/enterprise/additional-payment-scenarios/installments-direct-charge.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
