Inttegro PHP SDK

PaymentMethods
in package

Payment methods resource for saving and verifying customer payment instruments.

Payment methods store customer payment details for future use. Tokenize mobile money wallets, verify ownership, and charge saved methods without re-collecting details. Essential for subscription billing and returning customer checkout flows.

Tags
see
https://studio.inttegro.com/payment-methods

for detailed guides

Table of Contents

Methods

__construct()  : mixed
activate()  : PaymentMethod
archive()  : PaymentMethod
confirmVerification()  : PaymentMethod
Complete payment method verification using customer-provided OTP.
deactivate()  : PaymentMethod
delete()  : PaymentMethodDeletion
Remove a saved payment method, preventing future charges.
disactivate()  : PaymentMethod
lookup()  : PaymentMethod
Retrieve details of a saved payment method.
page()  : PaymentMethodPage
Retrieve a paginated list of payment methods.
settings()  : PaymentMethodSettings
Retrieve payment method configuration and capabilities.
tokenize()  : PaymentMethod
Save a payment method for future use without charging it.
unarchive()  : PaymentMethod
update()  : PaymentMethod
Update mutable payment method metadata and state.
verify()  : PaymentMethodVerificationSession
Initiate verification of a saved payment method.

Methods

confirmVerification()

Complete payment method verification using customer-provided OTP.

public confirmVerification(array<string|int, mixed> $payload) : PaymentMethod

Submits the verification code to confirm payment method ownership. Once verified, the payment method can be charged without customer confirmation (frictionless charging).

Parameters
$payload : array<string|int, mixed>

Verification parameters

  • payment_method_id: string - Payment method being verified (required)
  • token: string - OTP code provided by customer (required, typically 6 digits)
Tags
example

Confirm verification with OTP

$paymentMethod = $client->paymentMethods->confirmVerification([
    'payment_method_id' => 'pm_xyz789abc',
    'token' => '123456'
]);

if ($paymentMethod->verification?->status === 'verified') {
    echo "Payment method verified! Can now charge without OTP.\n";
}
see
https://studio.inttegro.com/charge-repeat-customers

for verification guide

Return values
PaymentMethod

Verified payment method

delete()

Remove a saved payment method, preventing future charges.

public delete(string $paymentMethodId[, array<string|int, mixed> $requestMeta = [] ]) : PaymentMethodDeletion

Deletes the payment method from customer's saved instruments. Use this when customers remove payment methods from their account or when payment details become invalid. Deletion is permanent and cannot be undone.

Parameters
$paymentMethodId : string

Unique identifier of the payment method to delete (required)

$requestMeta : array<string|int, mixed> = []

Request controls such as idempotency_key (optional)

Tags
example

Delete a payment method

$result = $client->paymentMethods->delete(
    'pm_xyz789abc'
);

echo "Payment method removed\n";
see
https://studio.inttegro.com/payment-methods

for payment method management

Return values
PaymentMethodDeletion

Confirmation of deletion

lookup()

Retrieve details of a saved payment method.

public lookup(string $paymentMethodId) : PaymentMethod

Returns full payment method information including type, masked details (e.g., last 4 digits), verification status, and associated customer. Use this to display saved payment methods to customers or check verification state before charging.

Parameters
$paymentMethodId : string

Unique identifier of the payment method to retrieve (required)

Tags
example

Lookup a payment method

$paymentMethod = $client->paymentMethods->lookup(
    'pm_xyz789abc'
);

echo "Type: {$paymentMethod->type}\n";
echo "Customer: {$paymentMethod->customerId}\n";
echo "Verified: " . ($paymentMethod->verification?->status === 'verified' ? 'yes' : 'no') . "\n";
see
https://studio.inttegro.com/payment-methods

for payment method overview

Return values
PaymentMethod

Complete payment method object

settings()

Retrieve payment method configuration and capabilities.

public settings() : PaymentMethodSettings

Returns the current payment method settings for your application, including supported payment types, verification requirements, and other configuration details.

Tags
example

Get payment method settings

$settings = $client->paymentMethods->settings();
// View supported payment types and configuration
see
https://studio.inttegro.com/payment-methods

for payment method overview

Return values
PaymentMethodSettings

Payment method settings

tokenize()

Save a payment method for future use without charging it.

public tokenize(array<string|int, mixed> $payload) : PaymentMethod

Tokenizes payment details and associates them with a customer. The payment method can be charged later without re-collecting details. Currently supports mobile money wallets. Optionally trigger verification immediately after tokenization.

Parameters
$payload : array<string|int, mixed>

Tokenization parameters

  • customer_id: string - Customer who will own this payment method (required)
  • payment_method_data: array - Payment details to tokenize (required)
  • verify_immediately: bool - Send verification OTP right after tokenization (default: false)
Tags
example

Tokenize mobile money wallet

$paymentMethod = $client->paymentMethods->tokenize([
    'customer_id' => 'cu_abc123',
    'payment_method_data' => [
        'type' => 'mobile_money',
        'mobile_money' => [
            'network' => 'mtn',
            'account_number' => '0541234567'
        ]
    ],
    'verify_immediately' => true
]);

echo "Payment method saved: {$paymentMethod->id}\n";
echo "Verification status: {$paymentMethod->verification?->status}\n";
see
https://studio.inttegro.com/charge-repeat-customers

for saved payment method guide

Return values
PaymentMethod

Tokenized payment method

update()

Update mutable payment method metadata and state.

public update(array<string|int, mixed> $payload) : PaymentMethod
Parameters
$payload : array<string|int, mixed>
Return values
PaymentMethod

verify()

Initiate verification of a saved payment method.

public verify(string $paymentMethodId[, array<string|int, mixed> $requestMeta = [] ]) : PaymentMethodVerificationSession

Sends an OTP to the payment method (e.g., SMS to mobile money number) to verify customer ownership. After verification, the payment method can be charged without requiring customer confirmation on each transaction.

Parameters
$paymentMethodId : string

Unique identifier of the payment method to verify (required)

$requestMeta : array<string|int, mixed> = []

Request controls such as idempotency_key (optional)

Tags
example

Start payment method verification

$verification = $client->paymentMethods->verify(
    'pm_xyz789abc'
);

if ($verification->status === 'pending') {
    echo "OTP sent. Collect code from customer.\n";
}
see
https://studio.inttegro.com/charge-repeat-customers

for verification flow

Return values
PaymentMethodVerificationSession

Payment method with verification status

On this page

Search results