Skip to content

Reports for a shop

To get either a list or a number of all transactions processed for your shop by PayCross for a certain period of time, send report requests as described below.

The requests must:

Info

If you suppose that the requested report might contain more than 1000 transactions, it is strongly recommended using the [pagination reports API](/en/payment_management/reports/paginated_report/).

Get a list of transactions

Request

Send a POST request to https://admin.pay-cross.com/api/reports with the additional X-Api-Version: 2 header and the following parameters:

Parameter Type Description
report_params * required
object A section of report parameters.
date_type * required
string A date type.

Possible values:
created_at,
paid_at,
settled_at.
date * required
string A date in the YYYY-MM-DD format, for example 2020-01-01.
status * required
string A transaction status.

Possible values:
all,
successful,
failed,
pending,
incomplete.
payment_method_type * required
string A payment method.

Possible values:
credit_card,
alternative.
time_zone * required
string A timezone name as defined here, for example Europe/London.
Example of the request
{
"report_params": {
    "date_type":"created_at",
    "date":"2022-01-27",
    "status":"failed",
    "payment_method_type":"credit_card",
    "time_zone":"Etc/UTC"
}
}
Response
Parameter Type Description
transactions * required
array An array of transactions of the requested report. Each element represents a transaction property with its own set of fields depending on the payment type and payment method used in this transaction.
count * required
integer A total number of transactions in the requested report.
Example of the successful response
{
    "transactions": [
        {
            "billing_address": {
                "first_name": null,
                "last_name": null,
                "address": null,
                "country": null,
                "city": null,
                "zip": null,
                "state": null,
                "phone": null,
                "birth_date": null
            },
            "customer": {
                "ip": "127.0.0.1",
                "email": null
            },
            "authorization": {
                "gateway_id": 2,
                "ref_id": null,
                "message": "Card check error",
                "status": "failed",
                "auth_code": null,
                "bank_code": null,
                "rrn": null,
                "billing_descriptor": null
            },
            "credit_card": {
                "holder": "JJJ",
                "token": "f1ed1ac4-875a-48bf-ae15-e2b2092969c1",
                "brand": "visa",
                "last_4": "0000",
                "first_1": "4",
                "bin": "420000",
                "issuer_country": "IT",
                "issuer_name": "INVESTBANK",
                "exp_month": 10,
                "exp_year": 2026,
                "product": "VISA"
            },
            "shop": {
                "id": 1
            },
            "uid": "20527-b7ea8c95f4",
            "id": 28859,
            "payment_method_type": "credit_card",
            "status": "failed",
            "message": null,
            "amount": 1000,
            "discount_rate": 0.0,
            "transaction_rate": 0.0,
            "pay_to_merchant": 0.0,
            "transaction_fee": 0.0,
            "test": false,
            "currency": "USD",
            "description": "Test description",
            "tracking_id": null,
            "type": "authorization",
            "order_id": 27723,
            "created_at": "2022-01-27T13:48:51Z",
            "paid_at": null,
            "settled_at": null,
            "manually_corrected_at": null,
            "additional_data": {
                "customer": {
                    "id": "b17727a9-0632-4454-b639-b941826be36f"
                },
                "request_id": "2a906819-5fbc-4dcb-8aaf-fe7ac17da248",
                "browser": {
                    "screen_width": 1440,
                    "screen_height": 900,
                    "screen_color_depth": 24,
                    "language": "it",
                    "java_enabled": false,
                    "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.110 Safari/537.36",
                    "time_zone": -180,
                    "time_zone_name": "Europe/London",
                    "window_height": 744,
                    "window_width": 600,
                    "accept_header": "application/json"
                },
                "vendor": {
                    "name": "CTP",
                    "token": "cb15c0e3d6419c24bda4823b5b32559a2f30c16cdbb30539ade2c449c7cd453c"
                },
                "tdsecure": {
                    "status": "failed",
                    "message": "Card check error",
                    "ve_status": "E",
                    "acs_url": null,
                    "pa_req": null,
                    "md": null,
                    "pa_res_url": "https://gateway.pay-cross.com/process/20527-b7ea8c95f4",
                    "eci": "07",
                    "pa_status": null,
                    "xid": null,
                    "cavv": null,
                    "cavv_algorithm": null,
                    "fail_reason": null,
                    "method_process_url": null
                },
                "avs_cvc": {
                    "avs_verification": {
                        "result_code": null
                    },
                    "cvc_verification": {
                        "result_code": null
                    }
                }
            },
            "three_d_secure_verification": {
                "eci": "07",
                "pa_status": null,
                "xid": null,
                "cavv": null,
                "cavv_algorithm": null,
                "ve_status": "E",
                "message": "Card check error",
                "status": "failed"
            }
        },
        {
            "billing_address": {
                "first_name": "Jane",
                "last_name": "Smith",
                "address": "Gilbert 104",
                "country": "IT",
                "city": "Milan",
                "zip": null,
                "state": null,
                "phone": null,
                "birth_date": null
            },
            "customer": {
                "ip": "127.0.0.1",
                "email": "[email protected]"
            },
            "p2p": {
                "gateway_id": 2,
                "ref_id": null,
                "message": "Can't make",
                "status": "failed",
                "auth_code": null,
                "bank_code": null,
                "rrn": null,
                "billing_descriptor": null
            },
            "credit_card": {
                "holder": "Dof Hag",
                "token": "a1e442d1-0633-4f48-b6ab-4dc36d71356d",
                "brand": "master",
                "last_4": "0707",
                "first_1": "5",
                "bin": "515464",
                "issuer_country": null,
                "issuer_name": null,
                "exp_month": 6,
                "exp_year": 2026,
                "product": null
            },
            "shop": {
                "id": 1
            },
            "uid": "20532-cb06cfeeed",
            "id": 28864,
            "payment_method_type": "credit_card",
            "status": "failed",
            "message": null,
            "amount": 100,
            "discount_rate": 0.0,
            "transaction_rate": 0.0,
            "pay_to_merchant": 0.0,
            "transaction_fee": 0.0,
            "test": false,
            "currency": "USD",
            "description": "Test transaction",
            "tracking_id": "tracking_id_000",
            "type": "p2p",
            "order_id": 27728,
            "created_at": "2022-01-27T15:03:01Z",
            "paid_at": null,
            "settled_at": null,
            "manually_corrected_at": null,
            "additional_data": {
                "tdsecure": {
                    "status": "successful",
                    "message": "Authentication Successful",
                    "ve_status": "Y",
                    "acs_url": null,
                    "pa_req": null,
                    "md": null,
                    "pa_res_url": "https://gateway.pay-cross.com/process/20532-cb06cfeeed",
                    "eci": "02",
                    "pa_status": "Y",
                    "xid": "8GamGXlGw6o2QTwXDd2cjz70qr0=",
                    "cavv": "ADlWFgxrq8BtAU6/rKnuAoABFA==",
                    "cavv_algorithm": null,
                    "fail_reason": null,
                    "method_process_url": null
                },
                "verify_p2p": {
                    "status": "failed",
                    "message": "Can't make",
                    "amount": 100,
                    "currency": "USD",
                    "bank_fee": 0.0,
                    "required_fields": {
                        "p_id": null
                    }
                }
            },
            "three_d_secure_verification": {
                "eci": "02",
                "pa_status": "Y",
                "xid": "8GamGXlGw6o2QTwXDd2cjz70qr0=",
                "cavv": "ADlWFgxrq8BtAU6/rKnuAoABFA==",
                "cavv_algorithm": null,
                "ve_status": "Y",
                "message": "Authentication Successful",
                "status": "successful"
            },
            "recipient_card": {
                "holder": "Qwert Qwerty",
                "token": "516638c8-a113-4061-97a1-a58874cd9cd2",
                "brand": "visa",
                "last_4": "3101",
                "first_1": "4",
                "bin": "401200",
                "issuer_country": null,
                "issuer_name": null
            }
        }
    ],
    "count": 2
}

Count the number of transactions for a shop

Request

Send a POST request to https://admin.pay-cross.com/api/reports/count with the additional X-Api-Version: 3 header and the following parameters:

Parameter Type Description
report_params * required
object A section of the report parameters.
date_type * required
string A date type.

Possible values: created_at, paid_at, settled_at.
from * required
string A start date of the reporting period in the YYYY-MM-DD hh:mm:ssformat, for example 2020-01-01 12:00:00.
to * required
string An end date of the reporting period in the YYYY-MM-DD hh:mm:ss format, for example 2020-01-01 15:00:00.
status * required
string A transaction status.

Possible values:
all,
successful,
failed,
pending,
incomplete.
payment_method_type * required
string A payment method.

Possible values:
credit_card,
alternative.
time_zone * required
string A timezone name as defined here, for example Europe/London.
Example of the request
{
"report_params": {
    "date_type":"created_at",
    "from":"2022-01-25 00:00:00",
    "to":"2022-01-27 23:59:59",
    "status":"incomplete",
    "payment_method_type":"credit_card",
    "time_zone":"Etc/UTC"
}
}
Response
Parameter Type Description
transactions object
count * required
integer A total number of transactions in the requested report.
Example of the response
{
    "transactions": {
        "count": 2
    }
}