캐시플로우 인사이트 — AI-Enhanced Backend with Xano
Source: Dev.to
내가 만든 것
연체된 결제와 예측할 수 없는 현금 유입은 중소기업에게 가장 큰 운영 위험 중 하나입니다. 대부분의 회계 도구는 청구서와 결제를 기록하지만, 현금이 실제로 언제 들어올지, 어떤 고객이 가장 높은 위험을 가지고 있는지, 비즈니스가 다음에 어떤 조치를 취해야 하는지에 대한 실행 가능한 통찰을 제공하는 경우는 드뭅니다. 그 결과, 재무 팀은 종종 스프레드시트, 정적 보고서 또는 직관에 의존하게 되며, 이는 회수 지연과 유동성 압박을 초래합니다.
이 프로젝트는 Xano 위에 구축된 프로덕션 준비된 현금 흐름 인텔리전스 API를 제공함으로써 그 격차를 메웁니다. API는 원시 청구서 데이터를 기반으로 명확한 재무 신호로 변환합니다. 매출채권을 집계하고, 결제 행동을 분석하며, 고위험 고객을 식별하고, 무엇이 일어나고 있는지뿐 아니라 왜 그런지 설명하는 평이한 언어의 통찰을 생성합니다.
해결된 핵심 문제
- 가시성 부족 – 기업은 매출채권 중 실제로 회수 가능한 금액과 연체·위험이 높은 금액을 파악하기 어렵습니다.
- 위험 감지 지연 – 고위험 고객이 청구서가 심각하게 연체된 후에야 식별되는 경우가 많습니다.
- 지침 없는 데이터 – 숫자 보고서만으로는 팀이 어떤 조치를 우선시해야 하는지 알 수 없습니다.
API 기능
- 매출채권 연령 및 연체 노출을 계산합니다.
- 실제 미결제 잔액을 기반으로 단기 현금 유입을 예측합니다.
- 행동 신호를 사용해 고객을 결제 위험 순으로 평가합니다.
- 재무 데이터를 운영 지침으로 변환하는 AI‑생성 설명 및 권장 사항을 제공합니다.
전적으로 Xano에서 구축된 이 백엔드는 정확성, 명확성 및 실제 사용성을 강조합니다. 누락된 데이터와 같은 엣지 케이스를 처리하고, 오해의 소지가 있는 파라미터를 피하며, 대시보드, 재무 도구 또는 통합에 적합한 깔끔한 API 계약을 노출합니다. 그 결과, 파편화된 청구서 데이터를 실행 가능한 현금 흐름 인텔리전스로 전환하는 백엔드 서비스가 제공되어 기업이 가장 중요한 부분에 노력을 집중할 수 있게 합니다.
API 문서
Base URL
https://xbty-lwqs-omi0.m2.xano.io/api:HiJHfYhN
인증
모든 엔드포인트는 API 키가 필요합니다. /signup 엔드포인트를 통해 계정을 생성하고 키를 발급받으세요.
{
"business_name": "example name"
}
예시 API 키: ec49f7f0-089b-47f8-9f74-b81e6e474fba
엔드포인트
POST /insert_invoice_data
새 청구서 레코드를 삽입합니다.
Request
curl -X POST 'https://xbty-lwqs-omi0.m2.xano.io/api:HiJHfYhN/insert_invoice_data' \
-H 'Content-Type: application/json' \
-H 'x-api-key: 10ebbb4b-a128-479b-b7b9-550d79bcf7cd' \
--data '{
"invoice_amount": 250,
"due_date": "2025-12-23",
"invoice_date": "2025-12-13",
"status": "unpaid",
"paid_date": null,
"customer_name": "Example_name",
"Currency": "dollars",
"invoice_number": "1"
}'
Response
{
"message": "Invoice created successfully",
"invoice": {
"id": 411,
"created_at": 1765656533022,
"invoice_date": "2025-12-13",
"customer_name": "Example_name",
"business_id": 6,
"due_date": "2025-12-23",
"amount": 250,
"status": "unpaid",
"paid_date": null,
"currency": "dollars",
"invoice_number": 1
}
}
GET /receivables_analytics
비즈니스의 매출채권을 분석하여 DSO, 연령대별 금액 및 연체 비율을 반환합니다.
Request
curl -X GET 'https://xbty-lwqs-omi0.m2.xano.io/api:HiJHfYhN/receivables_analytics' \
-H 'Content-Type: application/json' \
-H 'x-api-key: ec49f7f0-089b-47f8-9f74-b81e6e474fba'
Response
{
"response": {
"days_sales_outstanding": 167.75147928994087,
"ageing": {
"0_30": 78.2,
"31_60": 183.25,
"61_90": 0,
"90_plus": 0
},
"overdue": 70.08988334289538
}
}
POST /cashflow_forecast
현재 청구서 데이터를 기반으로 현금 유입을 예측합니다.
Request
curl -X POST 'https://xbty-lwqs-omi0.m2.xano.io/api:HiJHfYhN/cashflow_forecast' \
-H 'Content-Type: application/json' \
-H 'x-api-key: 89d9f509-573e-4ff8-94c7-2457832483ca'
Response
{
"forecast": {
"expected_inflows": {
"0_30_days": 234.37,
"31_60_days": 0,
"61_90_days": 0
},
"assumptions": {
"average_delay_days": 26
}
}
}
POST /calculate_risk_score
특정 고객에 대한 위험 분석을 수행합니다. ai_notes를 1로 설정하면 AI가 생성한 평이한 언어의 메모를 받을 수 있습니다(구글 Gemini 기반).
Request
curl -X POST 'https://xbty-lwqs-omi0.m2.xano.io/api:HiJHfYhN/calculate_risk_score' \
-H 'Content-Type: application/json' \
-H 'x-api-key: 89d9f509-573e-4ff8-94c7-2457832483ca' \
--data '{
"ai_notes": 1,
"customer_name": "Judith Morales"
}'
Response
{
"risk_data": {
"customer_name": "Judith Morales",
"score": 31,
"risk_level": "High",
"late_payment_probability": 1
},
"ai_note": "Despite a low percentage of late invoices and no significant long‑term overdues, the \"High\" risk level is primarily driven by the substantial average payment delay of 49 days. This indicates consistent cash‑flow inefficiencies or slow internal payment processes for the customer, impacting your working capital. We recommend shortening payment terms or requiring partial upfront payments to mitigate exposure and improve cash conversion."
}
POST /business_dashboard
모든 분석(매출채권, 예측, 위험)을 결합하고 상위 5명의 고위험 고객과 비즈니스 현금 흐름 건강에 대한 AI 요약을 반환합니다.
Request
curl -X POST 'https://xbty-lwqs-omi0.m2.xano.io/api:HiJHfYhN/business_dashboard' \
-H 'Content-Type: application/json' \
-H 'x-api-key: ec49f7f0-089b-47f8-9f74-b81e6e474fba'
Response
{
"stats": {
"dso": 167.75147928994087,
"overdue_percent": 70.08988334289538,
"total_ar_0_30": 78.2,
"total_ar_31_60": 183.25,
"total_ar_61_90": 0,
"total_ar_90_plus": 0,
"forecast_0_30": 261.45,
"forecast_31_60": 0,
"forecast_61_90": 0
},
"risky_customers": {
"itemsReceived": 5,
"items": [
{
"customer_name": "Sue Grant",
"score": 20,
"risk_level": "High",
"late_payment_probability": 1
},
{
"customer_name": "Philip Herrera",
"score": 23,
"risk_level": "High",
"late_payment_probability": 1
},
{
"customer_name": "Elsie Dunn",
"score": 56,
"risk_level": "Medium",
"late_payment_probability": 1
},
{
"customer_name": "Katie Weaver",
"score": 100,
"risk_level": "Low",
"late_payment_probability": 0
},
{
"customer_name": "Terry Ortiz",
"score": 100,
"risk_level": "Low",
"late_payment_probability": 0
}
]
},
"summary": "Your accounts receivable health is concerning. Your Days Sales Outstanding (DSO) is very high at 168 days, indicating very slow collections. An alarming 70% of your current receivables are overdue, with a significant amount ($183.25) already 31‑60 days past due. While you forecast $261.45 in cash inflows for the next 30 days, there are no significant inflows projected beyond that for the 31‑90 day period. This gap is critical, especially considering the large existing overdue balance from 31‑60 days. High‑risk customers like Sue Grant, Philip Herrera, and Elsie Dunn are very likely to cause payment delays, directly impacting cash conversion."
}