Skip to main content
POST
/
agent
/
stripe
/
payment-methods
Add payment method
curl --request POST \
  --url http://localhost/mogl/mogl-backend/api/agent/stripe/payment-methods \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "payment_type": "C",
  "card_number": "4242424242424242",
  "exp_month": "12",
  "exp_year": "2028",
  "cvc": "123",
  "card_name": "Jane Doe",
  "account_holder_name": "Jane Doe",
  "account_holder_type": "individual",
  "routing_number": "110000000",
  "account_number": "000123456789"
}
'

Documentation Index

Fetch the complete documentation index at: https://developer.mogl.online/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

JWT Bearer token authentication. Use the /api/login endpoint to obtain a token.

Body

application/json
payment_type
string

'C' for card (default), any other value for bank account

Example:

"C"

card_number
string | null

Card number (required for card)

Example:

"4242424242424242"

exp_month
string | null

Card expiry month (required for card)

Example:

"12"

exp_year
string | null

Card expiry year (required for card)

Example:

"2028"

cvc
string | null

Card CVC (required for card)

Example:

"123"

card_name
string | null

Name on card (required for card)

Example:

"Jane Doe"

account_holder_name
string | null

Bank account holder name (required for bank)

Example:

"Jane Doe"

account_holder_type
enum<string> | null

Bank account type (required for bank)

Available options:
individual,
company
Example:

"individual"

routing_number
string | null

Bank routing number (required for bank)

Example:

"110000000"

account_number
string | null

Bank account number (required for bank)

Example:

"000123456789"

Response

200

Payment method added