{"openapi":"3.1.0","info":{"title":"GET /api/v1/payment-advisory/recommendations","version":"1.0.0","description":"Get payment recommendations"},"servers":[{"url":"https://api.ondayzero.com","description":"Production"}],"paths":{"/api/v1/payment-advisory/recommendations":{"get":{"tags":["payment-advisory"],"summary":"Get payment recommendations","description":"Get prioritized payment recommendations for outstanding bills.","operationId":"get_payment_recommendations_api_v1_payment_advisory_recommendations_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-business-id","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Business-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuccessEnvelope_GetPaymentRecommendationsResponse_"}}}},"401":{"description":"Unauthorized - Authentication required","content":{"application/json":{"example":{"detail":"Not authenticated"}}}},"403":{"description":"Forbidden - Insufficient permissions","content":{"application/json":{"example":{"detail":"Not enough permissions"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"GetPaymentRecommendationsResponse":{"properties":{"summary":{"$ref":"#/components/schemas/PaymentRecommendationsSummary"},"recommendations":{"$ref":"#/components/schemas/PaymentRecommendationsGrouped"}},"additionalProperties":true,"type":"object","required":["summary","recommendations"],"title":"GetPaymentRecommendationsResponse","description":"Response for ``get_payment_recommendations``."},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"PaymentRecommendationItem":{"properties":{"bill_id":{"type":"string","title":"Bill Id"},"vendor_name":{"type":"string","title":"Vendor Name"},"amount_cents":{"type":"integer","title":"Amount Cents"},"balance_cents":{"type":"integer","title":"Balance Cents"},"due_on":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Due On"},"priority":{"type":"string","enum":["overdue","due_this_week","due_this_month","can_defer"],"title":"Priority"},"action":{"type":"string","title":"Action"},"reasoning":{"type":"string","title":"Reasoning"},"contract_match":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Match"}},"additionalProperties":true,"type":"object","required":["bill_id","vendor_name","amount_cents","balance_cents","priority","action","reasoning"],"title":"PaymentRecommendationItem","description":"Single bill payment recommendation."},"PaymentRecommendationsGrouped":{"properties":{"overdue":{"items":{"$ref":"#/components/schemas/PaymentRecommendationItem"},"type":"array","title":"Overdue"},"due_this_week":{"items":{"$ref":"#/components/schemas/PaymentRecommendationItem"},"type":"array","title":"Due This Week"},"due_this_month":{"items":{"$ref":"#/components/schemas/PaymentRecommendationItem"},"type":"array","title":"Due This Month"},"can_defer":{"items":{"$ref":"#/components/schemas/PaymentRecommendationItem"},"type":"array","title":"Can Defer"}},"additionalProperties":true,"type":"object","title":"PaymentRecommendationsGrouped","description":"Recommendations grouped by priority bucket."},"PaymentRecommendationsSummary":{"properties":{"total_outstanding_cents":{"type":"integer","title":"Total Outstanding Cents"},"total_overdue_cents":{"type":"integer","title":"Total Overdue Cents"},"total_due_this_week_cents":{"type":"integer","title":"Total Due This Week Cents"},"bills_count":{"type":"integer","title":"Bills Count"}},"additionalProperties":true,"type":"object","required":["total_outstanding_cents","total_overdue_cents","total_due_this_week_cents","bills_count"],"title":"PaymentRecommendationsSummary","description":"Aggregate metrics for payment recommendations."},"SuccessEnvelope_GetPaymentRecommendationsResponse_":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"},"code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"},"data":{"anyOf":[{"$ref":"#/components/schemas/GetPaymentRecommendationsResponse"},{"type":"null"}]}},"additionalProperties":true,"type":"object","title":"SuccessEnvelope[GetPaymentRecommendationsResponse]"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}},"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"API Token","description":"API token authentication. Format: `Bearer dz_...`"}}},"security":[{"BearerAuth":[]}]}