Get Payment Methods
get
/paymentMethod
Gets the payment methods that match the query criteria.
Request
Query Parameters
-
bankAccount.BIC: string
The Business Identifier Code of a bank (for retrieving bankAccountDebit payment methods).Examples
-
bankAccount.accountNumber: string
The account number (for retrieving bankAccountDebit payment methods).Examples
-
bankAccount.bank: string
The name of a bank (for retrieving bankAccountDebit payment methods).Examples
-
bankCard.cardNumber: string
The card number (for retrieving bankCard payment methods).Examples
-
bankCard.nameOnCard: string
The name on the card (for retrieving bankCard payment methods). You can use bankCard.nameOnCard.like= to get partial matches.Examples
-
bankCard.type: string
The type of bank card (for retrieving bankCard payment methods). The only valid value for BRM is CREDIT.Examples
-
fields: string
The list of comma-separated fields to return in the response.Examples
-
invoice.name: string
The name on the invoice (for retrieving invoice payment methods). You can use invoice.name.like= to get partial matches.Examples
-
limit: integer
The maximum number of results to return.Examples
-
name: string
The name of the payment method instance.Examples
-
offset: integer
The number of results to offset the response by.Examples
-
relatedParty.id: string
The ID of a related party to get payment methods for.Examples
-
relatedParty.type: string
The type of related party to get payment methods for.
-
type: string
The type of payment method to get: tokenizedCard, invoice, bankAccountDebit, or bankCard.ExamplesAllowed Values:
[ "tokenizedCard", "bankAccountDebit", "bankCard", "invoice" ]
There's no request body for this operation.
Back to TopResponse
Supported Media Types
- application/json
200 Response
The payment methods were returned successfully.
Headers
-
X-Total-Count:
The total number of results.
Nested Schema : PaymentMethodType
Type:
objectA payment method.
Show Source
-
@type(required): string
Allowed Values:
[ "tokenizedCard", "bankAccountDebit", "bankCard", "invoice" ]The payment method's type: tokenizedCard, bankAccountDebit, bankCard, or invoice. The value of this property determines the content of the details property. -
account: array
account
An account that owns or can use the payment method.
-
authorizationCode: string
An authorization code provided by a financial institution. Typically, for recurring payments using the payment method.
-
description: string
The payment method's description.
-
details(required): object
details
The payment method's details, which differ based on the @type property.
-
href(required): string
The payment method's href.
-
id(required): string
The payment method's ID.
-
name: string
The payment method's name.
-
preferred: boolean
Whether this is the preferred payment method for the account, bill unit, or billing cycle specification (true) or not (false).
- relatedParty: array relatedParty
-
status: string
The payment method's status.
-
statusDate: string
(date-time)
The date the payment method's status was recorded.
-
validFor:
TimePeriodType
A period of time.
Nested Schema : account
Type:
arrayAn account that owns or can use the payment method.
Show Source
-
Array of:
object AccountRefType
An account reference.
Nested Schema : details
Type:
objectThe payment method's details, which differ based on the @type property.
Nested Schema : TimePeriodType
Type:
objectA period of time.
Show Source
-
endDateTime: string
(date-time)
The end of the time period.
-
startDateTime(required): string
(date-time)
The start of the time period.
Nested Schema : AccountRefType
Type:
objectAn account reference.
Show Source
-
@referredType: string
The referred account's type. For example: customer account or financial account.
-
description: string
The referred account's description.
-
href(required): string
The referred account's href.
-
id(required): string
The referred account's ID.
-
name: string
The referred account's name.
Nested Schema : RelatedPartyRefType
Type:
objectA related party.
Show Source
-
@referredType: string
The type of related party. For example: account, customer, or user.
-
href(required): string
The related party's href.
-
id(required): string
The related party's ID.
-
name: string
The related party's name.
-
role: string
The related party's role.
400 Response
The request isn't valid.
401 Response
The client doesn't have the correct privileges.
403 Response
The request wasn't authorized.
405 Response
This method is not allowed.
500 Response
The system encountered an internal error.
Examples
The following example shows how to get a list of no more than two bankAccountDebit payment methods at the My Bank bank by submitting a GET request on the REST resource using cURL. For more information about cURL, see Use cURL.
curl -X GET 'http://host:port/brm/paymentMethods/version/paymentMethod?type=bankAccountDebit&limit=2'
Example of the Response Body
The following example shows the contents of the response body in JSON format. Because of the query criteria, only two debit accounts are shown.
[
{
"id": "0.0.0.1+-payinfo-dd+240947",
"href": "http://host:port/brm/paymentMethods/version/paymentMethod/0.0.0.1+-payinfo-dd+240947",
"name": "Mary Robbin's Direct Debit Account",
"description": null,
"validFor": null,
"account": [
{
"id": "0.0.0.1+-account+244543",
"href": null,
"description": "Mary's Primary Account",
"name": "Mary Robbins",
"@baseType": null,
"@schemaLocation": null,
"@type": null,
"@referredType": null
}
],
"preferred": true,
"relatedParty": null,
"@type": "bankAccountDebit",
"authorizationCode": null,
"status": null,
"statusDate": null,
"details": {
"accountNumber": "12341234123412341",
"accountNumberType": "Savings",
"BIC": "111122334",
"owner": "Mary Robbins",
"bank": "My Bank"
}
},
{
"id": "0.0.0.1+-payinfo-dd+249648",
"href": "http://host:port/brm/paymentMethods/version/paymentMethod/0.0.0.1+-payinfo-dd+249648",
"name": "Adam Baker's Direct Debit Account",
"description": null,
"validFor": null,
"account": [
{
"id": "0.0.0.1+-account+104221",
"href": null,
"description": "Grace's Primary Account",
"name": "Adam Baker",
"@baseType": null,
"@schemaLocation": null,
"@type": null,
"@referredType": null
}
],
"preferred": true,
"relatedParty": null,
"@type": "bankAccountDebit",
"authorizationCode": null,
"status": null,
"statusDate": null,
"details": {
"accountNumber": "12345678901236491",
"accountNumberType": "Savings",
"BIC": "111122334",
"owner": "Adam Baker",
"bank": "My Bank"
}
}
]