1. Get sweeps

Send an HTTP GET request to the relevant endpoint + /api/reconciliation/v1/merchant/sweeps and include any required query parameters in the request. You can use the same reconciliation token generated previously.

Sweep queries can contain the following terms:

  • createdAt
  • settlementAccountIdentifier

Request

curl --request GET \
     --url 'https://app.payvyne.com/api/v1/reconciliation/merchant/sweeps?size=2&query=%28createdAt%20%3E%3D%20%272023-01-01%27%20AND%20createdAt%20%3C%3D%20%272023-03-20%27%29%20AND%20settlementAccountIdentifier%20%3D%20%27GBP3%27' \
     --header 'Accept: application/json'
ParameterValue
size2
query(createdAt >= '2023-01-01' AND createdAt <= '2023-03-20') AND settlementAccountIdentifier = 'GBP3'
cursorNull

🚧

Be aware

The queries specified in your GET request requires URL encoding.

Response

{
    "elements": [{
        "id": "728f19403d1104a1",
        "settlementAccount": {
            "identifier": "GBP1"
        },
        "openingBalance": {
            "amount": 100.00,
            "currency": "GBP"
        },
        "closingBalance": {
            "amount": 100.00,
            "currency": "GBP"
        },
        "reservedBalance": {
            "amount": 100.00,
            "currency": "GBP"
        },
        "transferredAmount": {
            "amount": 780.80,
            "currency": "GBP"
        },
        "summary": {
            "payments": {
                "value": {
                    "amount": 800.00,
                    "currency": "GBP"
                },
                "count": 20
            },
            "refunds": {
                "value": {
                    "amount": 10.00,
                    "currency": "GBP"
                },
                "count": 2
            },
            "payouts": {
                "value": {
                    "amount": 0.00,
                    "currency": "GBP"
                },
                "count": 0
            },
            "fees": {
                "value": {
                    "amount": 10.00,
                    "currency": "GBP"
                },
                "count": 22
            },
            "topUps": {
                "value": {
                    "amount": 0.00,
                    "currency": "GBP"
                },
                "count": 0
            },
            "miscellaneous": {
                "value": {
                    "amount": 0.00,
                    "currency": "GBP"
                },
                "count": 0
            }
        },
        "createdAt": "2023-01-01T23:59:00Z",
        "updatedAt": "2023-01-01T23:59:00Z"
    }, {
        "id": "f821233fc716ffe4",
        "settlementAccount": {
            "identifier": "GBP1"
        },
        "openingBalance": {
            "amount": 100.00,
            "currency": "GBP"
        },
        "closingBalance": {
            "amount": 100.00,
            "currency": "GBP"
        },
        "reservedBalance": {
            "amount": 100.00,
            "currency": "GBP"
        },
        "transferredAmount": {
            "amount": 150.00,
            "currency": "GBP"
        },
        "summary": {
            "payments": {
                "value": {
                    "amount": 200.00,
                    "currency": "GBP"
                },
                "count": 20
            },
            "refunds": {
                "value": {
                    "amount": 50.00,
                    "currency": "GBP"
                },
                "count": 1
            },
            "payouts": {
                "value": {
                    "amount": 150.00,
                    "currency": "GBP"
                },
                "count": 3
            },
            "fees": {
                "value": {
                    "amount": 10.00,
                    "currency": "GBP"
                },
                "count": 5
            },
            "topUps": {
                "value": {
                    "amount": 160.00,
                    "currency": "GBP"
                },
                "count": 2
            },
            "miscellaneous": {
                "value": {
                    "amount": 0.00,
                    "currency": "GBP"
                },
                "count": 0
            }
        },
        "createdAt": "2023-01-02T23:59:00Z",
        "updatedAt": "2023-01-02T23:59:00Z"
    }],
    "previousPage": null,
    "nextPage": "eyJ0eXBlIjoiUEZDIiwiY3Vyc29yRGlyIjoiTkVYVCIsImNyZWF0ZWRBdCI6IjIwMjAtMDYtMTVUMTk6MjI6MTYuMjgzWiIsInBheW1lbnRJZCI6IjcyOGYxOTQwM2QxMTA0YTEifQ==",
    "size": 2
}

📘

Helpful to know

For the next set of results, set the cursor query parameter to the value of nextPage from the response.