Get the Sales File

Through this API it is possible to download the sales file.

The sales file is generated with the events of the previous day that generated launches in your Wirecard account.

To obtain the file, you will first need to make a request in the reconciliation API and download the file through the link returned in the response.

Response Attributes

Name

Description

Details

id

File id.

string(16)

type

File type. Possible value: SALES.

string(16)

date

The reference date of the file (the same date informed in the request URL).

date(YYYYMMDD)

_links

File link.

structured

├─file

Link to download the file.

link

File Attributes

Name

Description

Details

createdAt

File generation date.

date

authorizedPayments

Structure with payment authorizations.

structured

├─summary

Summary.

structured

├─├─count

Total authorize events.

integer

├─├─amount

Total value of authorized events..

integer

└─└─resources

List with events of type
PAYMENT.AUTHORIZED.

list Resources

refundedPayments

Structure with payment refunds.

structured

├─summary

Summary.

structured

├─├─count

Total refund events.

integer

├─├─amount

Total value of refund events.

integer

└─└─resources

List with events of type PAYMENT.REFUNDED.

list Resources

reversedPayments

Structure with chargebacks.

structured

├─summary

Summary.

structured

├─├─count

Total reversed events.

integer

├─├─amount

Total value of refund events.

integer

└─└─resources

Lista com os eventos do tipo PAYMENT.REVERSED.

list Resources

📘

TIP

The attributes contained within the resources array follow the response pattern of the GETs of the Payments resource.

Sales File Example

{  
   "id":"REC-6THY3VYLJUKI",
   "createdAt":"2018-12-15T01:21:17.604-02",
   "type":"SALES",
   "authorizedPayments":{  
      "summary":{  
         "count":7202, 
         "amount":82612486 
      },
      "resources":[  
         {  
            "id":"PAY-Z86PHFZHFYHT",
            "status":"AUTHORIZED", 
            "delayCapture":false, 
            "amount":{  
               "total":15091,
               "gross":15091,
               "fees":1507,
               "refunds":0,
               "liquid":13584,
               "currency":"BRL"
            },
            "installmentCount":2, 
            "statementDescriptor":"Minha Loja",
            "fundingInstrument":{  
               "creditCard":{  
                  "id":"CRC-4UYHH8MLCDB54",
                  "brand":"MASTERCARD",
                  "first6":"548376",
                  "last4":"1784",
                  "store":true,
                  "holder":{  
                     "birthdate":"1991-06-26",
                     "birthDate":"1991-06-26",
                     "taxDocument":{  
                        "type":"CPF",
                        "number":"14887765500"
                     },
                     "billingAddress":{ 
                        "street":"Rua Maestro Villa Lobos",
                        "streetNumber":"100",
                        "complement":"",
                        "district":"Centro",
                        "city":"São Paulo",
                        "state":"RJ",
                        "country":"BR",
                        "zipCode":"020050100"
                     },
                     "fullname":"Marcus Santos"
                  }
               },
               "method":"CREDIT_CARD" 
            },
            "acquirerDetails":{
               "authorizationNumber":"004438",
               "taxDocument":{  
                  "type":"CNPJ",
                  "number":"01011119000292"
               }
            },
            "fees":[ 
               {  
                  "type":"TRANSACTION",
                  "amount":753
               },
               {  
                  "type":"PRE_PAYMENT",
                  "amount":754
               }
            ],
            "events":[  
               {  
                  "type":"PAYMENT.AUTHORIZED",
                  "createdAt":"2018-12-14T00:00:23.000-02"
               }
            ],
            "receivers":[ 
               {  
                  "moipAccount":{  
                     "id":"MPA-645E822U822B",
                     "login":"[email protected]",
                     "fullname":"Maria Silva"
                  },
                  "type":"PRIMARY",
                  "amount":{  
                     "total":13992,
                     "currency":"BRL",
                     "fees":1507,
                     "refunds":0
                  },
                  "feePayor":true 
               },
               {  
                  "moipAccount":{  
                     "id":"MPA-7000YT6K9876",
                     "login":"vendassa",
                     "fullname":"Vendas SA"
                  },
                  "type":"SECONDARY",
                  "amount":{  
                     "total":1099,
                     "currency":"BRL",
                     "fees":0,
                     "refunds":0
                  },
                  "feePayor":false
               }
            ],
            "_links":{  
               "self":{  
                  "href":"https://api.moip.com.br/v2/payments/PAY-Z86PHFZHFYHT"
               },
               "order":{  
                  "href":"https://api.moip.com.br/v2/orders/ORD-JUHJEFTFEE0U",
                  "title":"ORD-JUHJEFTFEE0U"
               }
            },
            "createdAt":"2018-12-14T00:00:13.000-02",
            "updatedAt":"2018-12-14T00:00:23.000-02"
         }
      ]
   }
}
Language