> For the complete documentation index, see [llms.txt](https://docs.pagopa.it/centrostella-1/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.pagopa.it/centrostella-1/rtd-documentation/input-file-specifications.md).

# Input file specifications

This chapter describes the structure of the Standard PagoPA file, i.e. the transaction file to be used as an input for the batch service elaboration, the output file produced by the batch service will have the same format.

The naming convention of the file is as follows:

* \[service].\[ABI].\[filetype].\[date].\[time].\[nnn].csv

in particular:

| **field**                               | **Type**                                                                                                                                                                                                                                                       | **Mandatory** | **Notes**                                                                                                                                                                                                                                                                                                                                                                                  |
| --------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| **sender\_code**                        | Alphanumeric - max 5 char                                                                                                                                                                                                                                      | YES           | ABI code of the sender. If not available, a 5 char code assigned by PagoPA                                                                                                                                                                                                                                                                                                                 |
| **operation\_type**                     | Numeric - regexp \[0-9]{2}                                                                                                                                                                                                                                     | YES           | <p>Operation type:</p><p>00 - payment</p><p>01 - reversal of payment</p><p>​</p><p>xx - future uses</p><p>​</p>                                                                                                                                                                                                                                                                            |
| **circuit\_type**                       | Alphanumeric - regexp \[0-9]{2}                                                                                                                                                                                                                                | YES           | <p>Payment circuit:</p><p>00 – Pagobancomat</p><p>01- Visa</p><p>02- Mastercard</p><p>03- Amex</p><p>04- JCB</p><p>05- UnionPay</p><p>06- Diners</p><p>07- PostePay Code</p><p>08- BancomatPay</p><p>09- SatisPay</p><p>10- private circuit (onus, onwe)</p><p>12 - AliPay</p><p>13 - WeChat</p><p>14 - TPay</p><p>99 - other (to use in case previous codes do not apply)</p>             |
| **pan/hpan**                            | Alphanumeric max 64 char                                                                                                                                                                                                                                       | YES           | PAN of the payment instrument used. In the case of a non-card based circuit, will be the unique identifier of the payment instrument, the same the user can register using the IO App or a touch point from the Issuer bank. In the input file the information must be provided unencrypted, in the output file the information will be hashed                                             |
| **date\_time**                          | <p>ISO8601 date.</p><p>It must be compliant with the following <a href="https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html#patterns">DateTimeFormatter pattern</a>:</p><p><code>yyyy-MM-dd'T'HH:mm:ss.SSS\[XX]\[XXX]</code></p> | YES           | <p>Timestamp of the payment transaction carried out with the Merchant.</p><p>Please note that the second details are not always available for all transactions. In this case, the field will be padded with all '0's</p>                                                                                                                                                                   |
| **id\_trx\_acquirer**                   | Alphanumeric -max 255 char                                                                                                                                                                                                                                     | YES           | <p>Unique identifier of the transaction at the Acquirer level.</p><p>- can be populated with the <em>ARN</em>, or if this data is not present, with a <em>unique id</em> that allows to uniquely identify the transaction on the Acquirer side.</p>                                                                                                                                        |
| **id\_trx\_issuer**                     | Alphanumeric -max 255 char                                                                                                                                                                                                                                     | YES           | Authorization code issued by the Issuer (ex: AuthCode). If the record not have the the AuthCode (es:. reversal operation - operatio\_type = 01) insert fixed value *MISSING*                                                                                                                                                                                                               |
| **correlation\_id**                     | Alphanumeric -max 255 char                                                                                                                                                                                                                                     | NO            | <p>Correlation identifier between payment transaction and possible reversal.</p><p>The field is <strong>mandatory</strong> if the record refers to a reversal operation (operation\_type = 01)</p>                                                                                                                                                                                         |
| **total\_amount**                       | Numeric                                                                                                                                                                                                                                                        | YES           | Valued in euro cents (ex: 10€ = 1000) and expressed in absolute value: the sign is assumed from the type of operation *“00-payment, 01-reversal*"                                                                                                                                                                                                                                          |
| **currency**                            | Alphanumeric - max 3 char                                                                                                                                                                                                                                      | YES           | Fixed value 978 = EUR. International ISO coding is used.                                                                                                                                                                                                                                                                                                                                   |
| **acquirer\_id**                        | Alphanumeric -max 255 char                                                                                                                                                                                                                                     | YES           | <p>Unique Acquirer ID. In the case of card transactions, it represents the homonymous value conveyed on the international circuits.</p><p>- In the Pagobancomat circuit it corresponds to the field <em>codice\_sia\_abi</em></p><p>- Visa/Mastercard Circuit: <em>acquirer\_id</em></p><p>In other cases the field will be valued with fixed data depending on the reference Acquirer</p> |
| **merchant\_id**                        | Alphanumeric -max 255 char                                                                                                                                                                                                                                     | YES           | <p>Unique identifier of the physical store of the Acquirer (also known to the Merchant and used by the same to register on the Automatic Billing platform).</p><p>- In the Pagobancomat circuit it can correspond to the field: merchant</p>                                                                                                                                               |
| **terminal\_id**                        | Alphanumeric -max 255 char                                                                                                                                                                                                                                     | YES           | <p>Identification of the Merchant's terminal/POS (Point of Sale).</p><p>- In the Pagobancomat circuit it corresponds to the field: <em>cashier premises</em></p><p>- Visa/Mastercard circuit: <em>terminal\_id</em></p>                                                                                                                                                                    |
| **bank\_identificatio n\_number (BIN)** | Alphanumeric or - regexp \[0- 9]{6}\|\[0-9]{8}                                                                                                                                                                                                                 | YES           | <p>Code containing the first 8 digits of the payment instrument.</p><p>- In the Pagobancomat circuit it corresponds to the field: <em>codice\_abi</em></p>                                                                                                                                                                                                                                 |
| **MCC**                                 | Alphanumeric -max 5 char                                                                                                                                                                                                                                       | YES           | Merchant Category Code.                                                                                                                                                                                                                                                                                                                                                                    |
| **fiscal\_code**                        | Alphanumeric - max 50 char                                                                                                                                                                                                                                     | YES           | Fiscal code for legal person and for natural person (self-employed workers).                                                                                                                                                                                                                                                                                                               |
| **VAT**                                 | Alphanumeric - max 50 chars                                                                                                                                                                                                                                    | NO            | VAT Code, Tax Code legal person. The fied is **mandatory** if fiscal\_code record refers to a legal person                                                                                                                                                                                                                                                                                 |
| **pos\_type**                           | Alphanumeric regexp \[0-9]{2}                                                                                                                                                                                                                                  | YES           | <p>​</p><p>POS Type:</p><ul><li>00 - physical POS</li><li>01 - e-commerce</li></ul>                                                                                                                                                                                                                                                                                                        |
| **PAR**                                 | Alphanumeric                                                                                                                                                                                                                                                   | NO            | <p>Payment Account reference</p><p>The field must contain the information of the PAR, which can be defined as a collector capable to associate each TokenPAN with the PAN of the physical card, thanks to the unique and immutable association between PAN and PAR and Token and PAR</p>                                                                                                   |
