Retrieve a payment method
Get the specified payment method associated with a Moov account. Read our payment methods guide to learn more.
To access this endpoint using an access token
you'll need to specify the /accounts/{accountID}/payment-methods.read scope.
curl -X GET "https://api.moov.io/accounts/{accountID}/payment-methods/{paymentMethodID}" \
-H "Authorization: Bearer {token}" \
-H "x-moov-version: v2024.01.00" \
mc, _ := moov.NewClient()
var accountID string
var paymentMethodID string
mc.GetPaymentMethod(ctx, accountID, paymentMethodID)
using Moov.Sdk;
var sdk = new MoovClient(xMoovVersion: "<value>");
var res = await sdk.PaymentMethods.GetAsync(
accountID: "56878537-30b0-48ee-9c54-07ab3a8b243d",
paymentMethodID: "aa740bf3-4c5f-459b-9370-4f7d4bea382b"
);
// handle responsepackage hello.world;
import io.moov.sdk.Moov;
import io.moov.sdk.models.components.Security;
import io.moov.sdk.models.operations.GetPaymentMethodResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws Exception {
Moov sdk = Moov.builder()
.xMoovVersion("v2024.01.00")
.security(Security.builder()
.username("")
.password("")
.build())
.build();
GetPaymentMethodResponse res = sdk.paymentMethods().get()
.accountID("56878537-30b0-48ee-9c54-07ab3a8b243d")
.paymentMethodID("aa740bf3-4c5f-459b-9370-4f7d4bea382b")
.call();
if (res.paymentMethod().isPresent()) {
// handle response
}
}
}require 'moov_ruby'
Models = ::Moov::Models
s = ::Moov::Client.new(
x_moov_version: 'v2024.01.00',
)
res = s.payment_methods.get(account_id: '56878537-30b0-48ee-9c54-07ab3a8b243d', payment_method_id: 'aa740bf3-4c5f-459b-9370-4f7d4bea382b')
unless res.payment_method.nil?
# handle response
endimport { Moov } from "@moovio/sdk";
const moov = new Moov({
xMoovVersion: "v2024.01.00",
security: {
username: "",
password: "",
},
});
async function run() {
const result = await moov.paymentMethods.get({
accountID: "56878537-30b0-48ee-9c54-07ab3a8b243d",
paymentMethodID: "aa740bf3-4c5f-459b-9370-4f7d4bea382b",
});
console.log(result);
}
run();declare(strict_types=1);
require 'vendor/autoload.php';
use Moov\MoovPhp;
use Moov\MoovPhp\Models\Components;
$sdk = MoovPhp\Moov::builder()
->setXMoovVersion('v2024.01.00')
->setSecurity(
new Components\Security(
username: '',
password: '',
)
)
->build();
$response = $sdk->paymentMethods->get(
accountID: '56878537-30b0-48ee-9c54-07ab3a8b243d',
paymentMethodID: 'aa740bf3-4c5f-459b-9370-4f7d4bea382b'
);
if ($response->paymentMethod !== null) {
// handle response
}from moovio_sdk import Moov
from moovio_sdk.models import components
with Moov(
x_moov_version="v2024.01.00",
security=components.Security(
username="",
password="",
),
) as moov:
res = moov.payment_methods.get(account_id="56878537-30b0-48ee-9c54-07ab3a8b243d", payment_method_id="aa740bf3-4c5f-459b-9370-4f7d4bea382b")
# Handle response
print(res){
"paymentMethodID": "string",
"paymentMethodType": "moov-wallet",
"wallet": {
"walletID": "string",
"partnerAccountID": "string",
"walletType": "default"
}
}Response headers
x-request-id
string
required
Response headers
x-request-id
string
required
Response headers
x-request-id
string
required
Response headers
x-request-id
string
required
Response headers
x-request-id
string
required
Response headers
x-request-id
string
required
Response headers
x-request-id
string
required
Headers
X-Moov-Version
string
Specify an API version.
API versioning follows the format vYYYY.QQ.BB, where
YYYYis the yearQQis the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10)BBis the build number, starting at.01, for subsequent builds in the same quarter.- For example,
v2024.01.00is the initial release of the first quarter of 2024.
- For example,
The latest version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
When no version is specified, the API defaults to v2024.01.00.
Path parameters
accountID
string
required
paymentMethodID
string
required
Response
paymentMethodID
string
paymentMethodType
string<enum>
moov-wallet
wallet
object
Show child attributes
partnerAccountID
string
required
walletID
string
required
walletType
string<enum>
required
Type of a wallet.
default: The system-generated wallet automatically created when an account is granted the wallet capability.general: An additional, user-defined wallet created via API or Dashboard.
default,
general
bankAccount
object
Show child attributes
bankAccountID
string
required
bankAccountType
string<enum>
required
checking,
savings,
general-ledger,
loan
bankName
string
required
fingerprint
string
<=100 characters
required
Once the bank account is linked, we don't reveal the full bank account number.
The fingerprint acts as a way to identify whether two linked bank accounts are the same.
holderName
string
required
holderType
string<enum>
required
individual,
business,
guest
lastFourAccountNumber
string
required
routingNumber
string
required
status
string<enum>
required
new,
verified,
verificationFailed,
pending,
errored
updatedOn
string<date-time>
required
paymentMethodID
string
paymentMethodType
string<enum>
ach-debit-fund
bankAccount
object
Show child attributes
paymentMethodID
string
paymentMethodType
string<enum>
ach-debit-collect
bankAccount
object
Show child attributes
paymentMethodID
string
paymentMethodType
string<enum>
ach-credit-standard
bankAccount
object
Show child attributes
paymentMethodID
string
paymentMethodType
string<enum>
ach-credit-same-day
bankAccount
object
Show child attributes
paymentMethodID
string
paymentMethodType
string<enum>
rtp-credit
card
object
Show child attributes
billingAddress
object
required
Show child attributes
postalCode
string
<=10 characters
required
addressLine1
string
<=60 characters
addressLine2
string
<=32 characters
city
string
<=32 characters
country
string
<=2 characters
stateOrProvince
string
<=2 characters
bin
string
[6 to 8] characters
required
brand
string<enum>
required
American Express,
Discover,
Mastercard,
Visa,
Unknown
cardID
string
required
cardType
string<enum>
required
debit,
credit,
prepaid,
unknown
cardVerification
object
required
Show child attributes
addressLine1
string<enum>
required
cvv
string<enum>
required
noMatch,
match,
notChecked,
unavailable,
partialMatch
postalCode
string<enum>
required
accountName
object
Show child attributes
firstName
string<enum>
fullName
string<enum>
lastName
string<enum>
middleName
string<enum>
expiration
object
required
Show child attributes
month
string
2 characters
required
year
string
2 characters
required
fingerprint
string
<=100 characters
required
lastFourCardNumber
string
4 characters
required
cardAccountUpdater
object
Show child attributes
updateType
string<enum>
unspecified,
account-closed,
contact-cardholder,
expiration-update,
no-change,
no-match,
number-update
updatedOn
string<date-time>
cardOnFile
boolean
domesticPullFromCard
string<enum>
not-supported,
supported,
unknown
domesticPushToCard
string<enum>
not-supported,
standard,
fast-funds,
unknown
holderName
string
issuer
string
issuerCountry
string
merchantAccountID
string
paymentMethodID
string
paymentMethodType
string<enum>
card-payment
card
object
Show child attributes
paymentMethodID
string
paymentMethodType
string<enum>
push-to-card
card
object
Show child attributes
paymentMethodID
string
paymentMethodType
string<enum>
pull-from-card
applePay
object
Show child attributes
brand
string<enum>
required
American Express,
Discover,
Mastercard,
Visa,
Unknown
cardDisplayName
string
required
User-friendly name of the tokenized card returned by Apple.
It usually contains the brand and the last four digits of the underlying card. There is no standard format.
cardType
string<enum>
required
debit,
credit,
prepaid,
unknown
dynamicLastFour
string
required
expiration
object
required
Show child attributes
month
string
2 characters
required
year
string
2 characters
required
fingerprint
string
<=100 characters
required
issuerCountry
string
paymentMethodID
string
paymentMethodType
string<enum>
apple-pay
paymentMethodID
string
paymentMethodType
string<enum>
card-present-payment
terminalCard
object
Show child attributes
applicationID
string
applicationName
string
bin
string
[6 to 8] characters
brand
string<enum>
American Express,
Discover,
Mastercard,
Visa,
Unknown
cardType
string<enum>
debit,
credit,
prepaid,
unknown
entryMode
string<enum>
contactless
expiration
object
Show child attributes
month
string
2 characters
required
year
string
2 characters
required
fingerprint
string
<=100 characters
holderName
string
issuer
string
issuerCountry
string
lastFourCardNumber
string
4 characters
bankAccount
object
Show child attributes
paymentMethodID
string
paymentMethodType
string<enum>
instant-bank-credit