For Developers
Pay Invoice
POST https://ed.link/api/v2/teams/:team_id/invoices/:invoice_id/pay
Initiates charge processing via Stripe for an open invoice.
Permissions
Requires either the invoices.create or invoices.update system permission.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
:team_id | UUID | Yes | The ID of the team. |
:invoice_id | UUID | Yes | The ID of the invoice to pay. |
Sample Request
const response = await axios.post(
`https://ed.link/api/v2/teams/${team_id}/invoices/${invoice_id}/pay`,
{},
{
headers: {
authorization: `Bearer ${user_session_token}`
}
}
);
Sample Response
{
"$data": {
"invoice": {
"id": "2a90184b-4819-4712-9912-391820491820",
"status": "paid",
"amount_due": 0
},
"payments": [
{
"id": "90184b23-9041-4712-8819-102938475819",
"amount": 45000,
"status": "succeeded"
}
]
}
}
