Create invoice for account | Moov Documentation
Create invoice for account
Create an invoice for a Moov account.
To access this endpoint using an access token
you'll need to specify the /accounts/{accountID}/invoices.write scope.
POST
/accounts/{accountID}/invoices
Ask
curl -X POST "https://api.moov.io/accounts/{accountID}/invoices" \
-H "Authorization: Bearer {token}" \
-H "X-Moov-Version: v2026.04.00" \
-d '{
"customerAccountID": "string",
"lineItems": {
"items": [\
{\
"name": "string",\
"basePrice": {\
"currency": "USD",\
"valueDecimal": "12.987654321"\
},\
"quantity": 1\
}\
]
}
}'
Ask
mc, _ := moov.NewClient()
accountID := "241bf524-e777-4941-a5e4-d7f3f34d7a00"
customerAccountID := "3dfff852-927d-47e8-822c-2fffc57ff6b9"
invoice := moov.CreateInvoice{
CustomerAccountID: customerAccountID,
Description: "Professional services for Q1 2026",
LineItems: moov.CreateInvoiceLineItems{
Items: []moov.CreateInvoiceLineItem{
{
Name: "Professional Services",
BasePrice: moov.AmountDecimal{
Currency: "USD",
ValueDecimal: "100.00",
},
Quantity: 1,
Options: []moov.CreateInvoiceLineItemOption{
{
Name: "Additional services",
Quantity: 1,
PriceModifier: &moov.AmountDecimal{
Currency: "USD",
ValueDecimal: "80.00",
},
},
},
},
},
},
}
mc.CreateInvoice(ctx, accountID, invoice)
Ask
import { Moov } from "@moovio/sdk";
const moov = new Moov({
security: {
username: "",
password: "",
},
});
async function run() {
const result = await moov.invoices.createInvoice({
accountID: "241bf524-e777-4941-a5e4-d7f3f34d7a00",
createInvoice: {
customerAccountID: "3dfff852-927d-47e8-822c-2fffc57ff6b9",
description: "Professional services for Q1 2026",
lineItems: {
items: [\
{\
name: "Professional Services",\
basePrice: {\
currency: "USD",\
valueDecimal: "1000.00",\
},\
quantity: 1,\
},\
],
},
invoiceDate: new Date("2026-01-15T00:00:00Z"),
dueDate: new Date("2026-02-15T00:00:00Z"),
taxAmount: {
currency: "USD",
valueDecimal: "80.00",
},
},
});
console.log(result);
}
run();
Ask
declare(strict_types=1);
require 'vendor/autoload.php';
use Moov\