Manage Xero accounting - invoices, contacts, bank transactions, and reports via Xero API.
Cloud accounting platform.
```bash
export XERO_ACCESS_TOKEN="xxxxxxxxxx"
export XERO_TENANT_ID="xxxxxxxxxx"
```
```bash
curl "https://api.xero.com/api.xro/2.0/Contacts" \
-H "Authorization: Bearer $XERO_ACCESS_TOKEN" \
-H "Xero-Tenant-Id: $XERO_TENANT_ID" \
-H "Accept: application/json"
```
```bash
curl -X POST "https://api.xero.com/api.xro/2.0/Invoices" \
-H "Authorization: Bearer $XERO_ACCESS_TOKEN" \
-H "Xero-Tenant-Id: $XERO_TENANT_ID" \
-H "Content-Type: application/json" \
-d '{
"Invoices": [{
"Type": "ACCREC",
"Contact": {"ContactID": "xxxxx"},
"LineItems": [{"Description": "Consulting", "Quantity": 1, "UnitAmount": 500}],
"Date": "2024-01-30",
"DueDate": "2024-02-28"
}]
}'
```
```bash
curl "https://api.xero.com/api.xro/2.0/Invoices" \
-H "Authorization: Bearer $XERO_ACCESS_TOKEN" \
-H "Xero-Tenant-Id: $XERO_TENANT_ID" \
-H "Accept: application/json"
```
```bash
curl "https://api.xero.com/api.xro/2.0/BankTransactions" \
-H "Authorization: Bearer $XERO_ACCESS_TOKEN" \
-H "Xero-Tenant-Id: $XERO_TENANT_ID"
```
```bash
curl "https://api.xero.com/api.xro/2.0/Reports/ProfitAndLoss?fromDate=2024-01-01&toDate=2024-12-31" \
-H "Authorization: Bearer $XERO_ACCESS_TOKEN" \
-H "Xero-Tenant-Id: $XERO_TENANT_ID"
```
Leave a review
No reviews yet. Be the first to review this skill!