Update Payout Method
PUT/affiliate-manager/:locationId/affiliate/:affiliateId/payout-method/:payoutMethodId
Replace the stored details of a payout method. The payout method type cannot be changed, and the method must belong to the affiliate named in the path.
Request
Version stringrequired
API Version
Available options
2021-07-28locationId stringrequired
Location Id
affiliateId stringrequired
Affiliate Id
payoutMethodId stringrequired
Payout Method Id
- application/json
- Body
- Example (auto)
Bodyrequired
paypalEmailstring
PayPal Email (required if method is PAYPAL)
payoutMethodstringrequired
Payout method to store the details under
Available options
PAYPALBANKbankDetailsobject
Bank Details (required if method is BANK)
{
"payoutMethod": "PAYPAL",
"bankDetails": {
"bankCountry": "United States",
"accountHolderName": "John Doe",
"recipientAddress": {
"country": "United States",
"state": "California",
"city": "San Francisco",
"postalCode": "94105"
},
"fields": [
{
"key": "accountNumber",
"value": "12345678"
}
]
}
}
Successful response
- application/json
- Schema
- Example (auto)
Schema
_idstringrequired
Payout method id
locationIdstringrequired
Location the payout method belongs to
affiliateIdstringrequired
Affiliate the payout method belongs to
methodstringrequired
Payout method type
Available options
PAYPALBANKpaypalEmailstring
PayPal email, when the method is PAYPAL
bankDetailsobject
Bank details, when the method is BANK
isPrimarybooleanrequired
Whether payouts default to this method
createdAtstringrequired
Created at timestamp
updatedAtstringrequired
Updated at timestamp
{
"_id": "63e35ac8b4dac93dfc2757c7",
"locationId": "ve9EPM428h8vShlRW1KT",
"affiliateId": "6385d230f6d19db03eef6fb2",
"method": "PAYPAL",
"bankDetails": {
"bankCountry": "United States",
"accountHolderName": "John Doe",
"recipientAddress": {
"country": "United States",
"state": "California",
"city": "San Francisco",
"postalCode": "94105"
},
"fields": [
{
"key": "accountNumber",
"value": "********5678"
}
]
},
"isPrimary": true,
"createdAt": "2024-06-16T00:00:00.000Z",
"updatedAt": "2024-06-16T00:00:00.000Z"
}