The eWAY Rapid API PHP Library does not define the 'CardType' property in the CardDetails so this data is being discarded when the PHP lib parses the eWAY Transaction Query response.
To access card type data, a property needs to be added to the CardDetails class defined in the CardDetails.php file, as shown below:
class CardDetails extends AbstractModel
{
protected $fillable = [
'Name',
'Number',
'ExpiryMonth',
'ExpiryYear',
'StartMonth',
'StartYear',
'IssueNumber',
'CVN',
'CardType', / add this line here /
];
}
The eWAY Rapid API returns a value for the transaction card type under Customer > CardDetails > CardType (see https://eway.io/api-v3/?shell#transaction-query).
The eWAY Rapid API PHP Library does not define the 'CardType' property in the CardDetails so this data is being discarded when the PHP lib parses the eWAY Transaction Query response.
To access card type data, a property needs to be added to the CardDetails class defined in the CardDetails.php file, as shown below:
class CardDetails extends AbstractModel { protected $fillable = [ 'Name', 'Number', 'ExpiryMonth', 'ExpiryYear', 'StartMonth', 'StartYear', 'IssueNumber', 'CVN', 'CardType', / add this line here / ]; }