/
CL
clinicos
/
PawthosX.Business.API | v1
Search skmtc…
⌘K
Docs
Sign in
Sign in
APIs
Generators
Stacks
Projects
Docs
History
Schema
Sources
Checked 13h ago · Updated 3d ago
View markdown
clinicos
PawthosX.Business.API | v1
get
/Estimates
v2
latest
OpenAPI 3.1.1
2026-08-07
854
993
2.4 MB
AdminS3
2
ApiKeys
7
Appointments
21
AppointmentTypes
10
BillableItems
5
Breeds
5
BulkClientExport
2
BulkPatientExport
2
CareQueue
2
CaseMilestones
6
Cases
5
ChatExport
1
ClientAppInvite
3
ClientExport
3
Clients
5
ClinicConfig
29
ClinicSettings
2
Clocking
6
Compliance
1
ConsentDocuments
2
DeaBooks
9
DeaExport
2
DiagnosisTerms
1
DiscountCodes
7
Drafts
7
EdgePrinters
3
EdgePrintJobs
2
EmailVerification
2
Estimates
25
get
/Estimates
post
/Estimates
get
/Estimates/{id}
delete
Hard-delete an estimate. Allowed only when the estimate is provably inert — a EstimateStatus.Draft that has never been converted and has no line that has performed/dispensed anything. Anything with committed side effects (dispensed stock, DEA entries, a cut Rx) is refused with 409: the raw cascade delete reverses none of that, so those lines must be voided first (which restores stock, files the DEA correction, cancels the Rx). Mirrors the per-line delete guard at Task<ActionResult> EstimatesController.DeleteItemAsync(string id, string lineId).
get
Fetch the appointment's estimate, auto-creating an empty draft on first access. The estimate is the single authoring + execution surface rendered in the chronicle Services tab; a draft must exist before lines can be added.
get
List a patient's open, standalone estimates that can be linked to an appointment — i.e. pre-existing quotes (created from the client/patient record) that are not yet converted (`InvoiceId == null`), not declined, and not already tied to an appointment (`AppointmentId == null`). Drives the "Link existing estimate" picker on the Services tab.
post
Link a pre-existing open estimate to an appointment. Honors the unique index on `treatment_plans.appointment_id` (one estimate per appointment): * No estimate on the appointment yet → set AppointmentId on the chosen one. * The appointment's auto-created estimate is empty → drop it and re-point the chosen estimate (preserves the chosen estimate's identity + consent history). * The appointment's estimate already has lines → merge the chosen estimate's lines into it and remove the chosen estimate. Returns the resulting estimate the Services tab should render.
post
Convert a treatment plan to an estimate using the selected tier's quantities.
post
Revert an UNPAID invoice back to an editable estimate. Archives the bill (marks it InvoiceStatus.Superseded, keeping its lines as a read-only record), unstamps the dispense-linked transactions (so the dispenses re-appear as unbilled on the estimate), releases its appointment, reopens the source estimate to Draft, and records an ConsentEventType.InvoiceReverted consent event. Blocked once the invoice has any payment (PartiallyPaid/Paid or any non-failed Payment) — those need refund/void first. Does NOT reverse dispenses: lines stay Performed with their InventoryTransactionId on the estimate; returning stock is the separate per-line void flow. Routed under /invoices (absolute route) to match the bill it acts on; Billing-permission gated at controller level.
post
Record that the plan was presented to the client (overlay opened). Logs a PlanPresented event and bumps status to Presented. Idempotent if status is already Presented — always logs the event.
post
Record the client's acceptance of a presented plan WITHOUT converting it to an invoice. The in-visit present flow uses this: the client approves the plan (consent + optional signature + chosen tier) up front; the bill is created later by convert-to-invoice once services are performed. Sets status Accepted + tier and logs a PlanAccepted consent event; leaves the estimate un-converted (no InvoiceId).
post
Client declined the plan. Sets status to Declined and logs an event.
get
/Estimates/{id}/consent-events
get
Read-only convert-to-invoice readiness for an appointment estimate. Converting is the last step before payment, so the gate blocks while any line is still Pending or a performed take-home label hasn't been filled. Drives the Convert button's disabled state + blockers popover (mirrors the BillableItem availability pre-check). Standalone (no-appointment) estimates are always ready — the quote itself becomes the bill.
post
Add a single line (procedure / inventory / retail) to an estimate.
post
Seed the estimate's lines from its appointment type's default services. Rebuilds the retired appointment-services "populate-defaults" onto the estimate line: each active default service becomes a Pending line. The dispense fee is charged once per unique inventory item across the whole estimate (existing lines count), matching the old behaviour. No-op (ItemsAdded = 0) when the estimate has no appointment, the appointment has no type, or the type has no active default services.
put
Update a single estimate line (quantity / price / billing flag / order / tier qtys).
delete
Delete a single estimate line. Blocks when the line is performed-and-dispensed (use void).
get
Stock-only availability pre-check for a charge line on the estimate (design §5 / §9.1): are the BillableItem's components on hand at the line's quantity? Read-only — no validate-pass, no stock movement. Mirrors the invoice-side check off the same `CheckAvailabilityAsync`, so the estimate UI can flag a short charge before the user opens the perform modal.
get
List a performed charge line's take-home component dispenses (per-component disposition). A charge fans out to N component transactions; the ones dispensed take-home (DispenseType=Prescription) may have a deferred SIG. This returns each with whether its SIG/label is filled, so the UI can walk the unfilled ones through the post-dispense prescription flow and clear the SIG_REQUIRED convert block. See docs/june-updates/charge-component-disposition.md.
post
Mark an estimate line performed. For an undispensed inventory line this runs the in-visit dispense (stamping `InventoryTransactionId` on the line; no Invoice involvement until convert). Gas items have no transaction.
post
Mark an estimate line declined by the client. Drops it from billing and reassigns any dispense fee.
post
Void a performed-and-dispensed estimate line: reverse the dispense (restore the lot, write a Returned transaction, file a DEA correction for controlled substances, cancel any tied Rx), then remove the line. Falls through to a plain delete when there is no dispense to undo. Anchors entirely on the line's `InventoryTransactionId`.
get
Generate a PDF for a saved treatment plan.
post
Email the estimate PDF to the client through the unified communications inbox. Composes an Email-channel message (visible in /chat) with the rendered PDF attached, then records the presentation: Draft plans bump to Presented and a PlanPresented consent event is logged either way.
ExamTemplates
5
Expenses
6
Featurebase
2
Flowboard
10
GroupCodes
5
GroupVisits
6
Health
1
HomeAgain
4
IntegrationCredentials
15
InternalPrescribing
1
InternalWidget
1
Inventory
23
InventoryApprovals
5
InventoryLocations
7
Invoices
24
JourneyMilestones
6
Kiosk
4
LabPanels
5
Labs
16
LocationClosures
4
Locations
11
Logos
7
MedicationRequests
7
MentorMetrics
5
Metrics
31
NpsAnalytics
3
Partners
6
PatientGroups
9
PatientMasses
6
PatientProblems
4
PatientRecordExport
3
Patients
20
Payments
19
PaymentTokens
5
Pharmacies
5
Phones
2
PriceRules
6
Printers
6
PrintJobs
4
PtoRequests
6
PublicNps
2
PublicPriceList
5
PublicQuestionnaires
2
PublicSmsConsent
2
PurchaseOrders
11
QiEvents
9
QuestionnaireResponses
6
Questionnaires
10
RabiesTags
10
RdvmPortal
22
Recordings
7
RecurringExpenses
5
ReferralMessages
2
Referrals
20
Reminders
14
Reports
2
RetailItems
11
Roles
6
RoomDayAssignments
3
RxGovernance
25
SavedReports
5
ScheduleItems
10
ServiceCatalog
5
Shifts
5
ShiftSwaps
8
SlotConfigurations
6
SmsConsent
9
Species
5
Subscriptions
8
SurgicalRecords
6
TagAssignments
4
Tags
5
TelnyxCallControl
1
Templates
10
TenantKnowledge
4
TimeEntries
5
Transparency
3
Users
11
Vaccinations
9
VaccineAdministration
3
VaccineCertificateRecords
6
VaccineCertificates
2
VaccineTypes
5
Vendors
6
Vitals
2
VitalTypes
6
Widget
17
WidgetChatbot
4
WorkItemRules
5
WorkTasks
13
Estimates
get
/Estimates
Query parameters
status
string
clientId
string
patientId
string
appointmentId
string
page
union
integer
OR
string
int32
pageSize
union
integer
OR
string
int32
Response
OK
EstimateListResponseDto
required
items
EstimateSummaryDto[]
total
union