# Pain.011

The pain.011 message defined by [ISO 20022](https://www.iso20022.org/iso-20022-message-definitions) is used to submit mandate cancellation requests to Italian banks using the [SEDA](/docs/payment-processors/seda-for-sepa) scheme. The pain.011 file is generated by mandate schedules.

FinDock follows the Associazione Bancaria Italiana message specifications which are based on pain.011.001.02.

## Pain.011 file structure

The pain.011 file in a simple XML with two sections:

* Group header node
* Cancellation details node


## Pain.011 field mapping

The following table outlines how Salesforce data is mapped to pain.011 elements of the parent Mandate Cancellation Request (MndtCxlReq) message.

### Group Header node

The Group Header (GrpHdr) node includes details covering the entire scope of the file.

| Object | Field | Pain.011 element | Further info |
|  --- | --- | --- | --- |
| Mandate | Mandate Id | MsgId | - |
| N/A | N/A | CreDtTm | Time file was generated, Y-m-d\TH:i:s |


### Underlying Cancellation Details node

The Underlying Cancellation Details (UndrlygCxlDtls) node includes details about the mandate that needs to be cancelled and the creditor initiating the request.

| Object | Field | Pain.011 element | Further info |
|  --- | --- | --- | --- |
| N/A | N/A | CxlRsn / Rsn / Cd | N/A, always `MD17` |
| Mandate | Mandate Id | OrgnlMndt / OrgnlMndt / MndtId | - |
| Mandate | Mandate Id | OrgnlMndt / OrgnlMndt / MndtReqId | - |
| Mandate | Mandate Id | OrgnlMndt / OrgnlMndt / MndtId | - |
| N/A | N/A | OrgnlMndt / OrgnlMndt / Tp / SvcLvl / Prtry | N/A, always `CMF` |
| N/A | N/A | OrgnlMndt / OrgnlMndt / Tp / LclInstrum / Prtry | N/A, always `CORSEDPM` |
| N/A | Creditor Id | OrgnlMndt / OrgnlMndt / CdtrSchmeId / Id / OrgId / Othr / Id | From target on mandate schedule |
| N/A | Company Name | OrgnlMndt / OrgnlMndt / Cdtr / Nm | From target on mandate schedule |
| N/A | Bank Account Addition | OrgnlMndt / OrgnlMndt / CdtrAgt / FinInstnId / BICFI | From target on mandate schedule |
| Mandate | Account Holder Name | OrgnlMndt / OrgnlMndt / Dbtr / Nm | - |
| Mandate | IBAN | OrgnlMndt / OrgnlMndt / DbtrAcct / Id / IBAN | - |