GET
/
v2.01
/
{ClientId}
/
cards
/
{CardId}
<?php 

require_once 'vendor/autoload.php';

use MangoPay\MangoPayApi;
use MangoPay\Libraries\ResponseException as MGPResponseException;
use MangoPay\Libraries\Exception as MGPException;

$api = new MangoPayApi();

$api->Config->ClientId = 'your-client-id';
$api->Config->ClientPassword = 'your-api-key';
$api->Config->TemporaryFolder = 'tmp/';

try {
    $cardId = '193935874';

    $response = $api->Cards->Get($cardId);

    print_r($response);
} catch(MGPResponseException $e) {
    print_r($e);
} catch(MGPException $e) {
    print_r($e);
}  
{
    "ExpirationDate": "1229",
    "Alias": "497010XXXXXX8183",
    "CardType": "CB_VISA_MASTERCARD",
    "CardProvider": "VISA",
    "Country": "FRA",
    "Product": "I",
    "BankCode": "unknown",
    "Active": true,
    "Currency": "EUR",
    "Validity": "UNKNOWN",
    "UserId": "user_m_01HWWPNMR93ASQYJEH6XVDW44T",
    "Id": "card_m_01HXVD91R8QEDY7MYC8TX9R9M8",
    "Tag": null,
    "CreationDate": 1715685590,
    "Fingerprint": "48d63bbcfc2c47fcbc19df35e47b2f8d",
    "CardHolderName": "Alex Smith"
}

Path parameters

CardId
string
required

The unique identifier of the Card object, which is returned after updating the Card Registration object with the RegistrationData.

Responses

{
    "ExpirationDate": "1229",
    "Alias": "497010XXXXXX8183",
    "CardType": "CB_VISA_MASTERCARD",
    "CardProvider": "VISA",
    "Country": "FRA",
    "Product": "I",
    "BankCode": "unknown",
    "Active": true,
    "Currency": "EUR",
    "Validity": "UNKNOWN",
    "UserId": "user_m_01HWWPNMR93ASQYJEH6XVDW44T",
    "Id": "card_m_01HXVD91R8QEDY7MYC8TX9R9M8",
    "Tag": null,
    "CreationDate": 1715685590,
    "Fingerprint": "48d63bbcfc2c47fcbc19df35e47b2f8d",
    "CardHolderName": "Alex Smith"
}
<?php 

require_once 'vendor/autoload.php';

use MangoPay\MangoPayApi;
use MangoPay\Libraries\ResponseException as MGPResponseException;
use MangoPay\Libraries\Exception as MGPException;

$api = new MangoPayApi();

$api->Config->ClientId = 'your-client-id';
$api->Config->ClientPassword = 'your-api-key';
$api->Config->TemporaryFolder = 'tmp/';

try {
    $cardId = '193935874';

    $response = $api->Cards->Get($cardId);

    print_r($response);
} catch(MGPResponseException $e) {
    print_r($e);
} catch(MGPException $e) {
    print_r($e);
}