Record owner debit payment
curl --request POST \
--url https://app.yampi.ai/api/v1/accounts/{account_id}/treasury/owners/{id}/debit_payments \
--header 'Content-Type: application/json' \
--header 'api_access_token: <api-key>' \
--data '{
"amount": 123
}'const options = {
method: 'POST',
headers: {api_access_token: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({amount: 123})
};
fetch('https://app.yampi.ai/api/v1/accounts/{account_id}/treasury/owners/{id}/debit_payments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.yampi.ai/api/v1/accounts/{account_id}/treasury/owners/{id}/debit_payments"
payload = { "amount": 123 }
headers = {
"api_access_token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"payload": {
"id": 123,
"amount": 123,
"paid_on": "2023-12-25",
"reference": "<string>",
"applied": true
}
}{
"description": "<string>",
"errors": [
{
"field": "<string>",
"message": "<string>",
"code": "<string>"
}
]
}{}{}Treasury Owners
Record owner debit payment
Record money the owner sent to pay their debits back.
POST
/
api
/
v1
/
accounts
/
{account_id}
/
treasury
/
owners
/
{id}
/
debit_payments
Record owner debit payment
curl --request POST \
--url https://app.yampi.ai/api/v1/accounts/{account_id}/treasury/owners/{id}/debit_payments \
--header 'Content-Type: application/json' \
--header 'api_access_token: <api-key>' \
--data '{
"amount": 123
}'const options = {
method: 'POST',
headers: {api_access_token: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({amount: 123})
};
fetch('https://app.yampi.ai/api/v1/accounts/{account_id}/treasury/owners/{id}/debit_payments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.yampi.ai/api/v1/accounts/{account_id}/treasury/owners/{id}/debit_payments"
payload = { "amount": 123 }
headers = {
"api_access_token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"payload": {
"id": 123,
"amount": 123,
"paid_on": "2023-12-25",
"reference": "<string>",
"applied": true
}
}{
"description": "<string>",
"errors": [
{
"field": "<string>",
"message": "<string>",
"code": "<string>"
}
]
}{}{}Was this page helpful?