/
CLclinicos
DocsSign in
  • Docs
  • History
  • Schema
  • Generate
ApiKeys7
AppointmentConfirmation2
Appointments25
AppointmentTypes10
AutomatedEmailTemplates4
BillableItems5
Breeds5
BulkClientExport2
BulkPatientExport2
CareQueue2
CaseMilestones6
Cases5
ChatExport1
ClientAccount1
ClientCredit2
ClientExport3
Clients6
ClientStatement1
ClinicalAddenda2
ClinicConfig41
ClinicSettings2
Clocking6
Compliance1
ConsentDocuments2
DeaBooks10
DeaExport2
DentalCharts9
DeviceFormHandoffs4
DevicePush3
Devices5
DeviceSelf1
DiagnosisTerms1
DischargeSignOff2
Disclaimers7
DiscountCodes7
Drafts7
EdgePrinters3
EdgePrintJobs2
EmailVerification2
EmergencyIntake2
Erx6
Estimates30
  • get/Estimates
  • post/Estimates
  • get/Estimates/{id}
  • delete/Estimates/{id}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/Estimates/by-appointment/{appointmentId}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. Display-only callers (visit history, summaries, banners) pass `create=false` and get 404 when there is none: auto-creating from a read left a blank draft on every viewed visit — imported history included — which clinics saw as empty bills.
  • get/Estimates/linkableList 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.
  • get/Estimates/line-item-notes/suggestionsAutocomplete suggestions for the line-item note field (ITE-573 + ITE-574): saved note templates merged with distinct notes previously used on estimate lines for the same catalog item. Saved entries carry `source: "saved"` + their `templateId`; history entries carry `source: "history"` + null. Serves the FE combobox (ITE-575). Saved-template candidacy: templates with an attachment to the line's item id, tag attachments whose Smart Tag is assigned to the line's item (service/inventory lines only — retail and billable items are not taggable), plus any-item templates (AppliesToAnyItem, offered on any keyed line); Clinic scope for everyone, Personal scope only for the owner. A history entry whose trimmed case-insensitive text equals a saved template's collapses INTO the saved entry (saved wins). Orphaned templates (item-specific, all items deleted) are never offered. The caller sends exactly one item-id param — whichever FK the line being authored keys on. `PrescriptionItemId` is deliberately NOT a keying param: Rx-created lines always carry `InventoryItemId` too, and a prescription item is a per-prescription governance record, not a reusable catalog identity. Ranking: q match quality (prefix beats substring) → recency → frequency. De-duped case-insensitively on trimmed text; blank or <3-char notes excluded. Always 200 with `[]` on no key / no match.
  • post/Estimates/{id}/link-appointment 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. Its consent trail moves to the survivor first and an ConsentEventType.EstimateMerged event records the merge (ITE-1450). A removed estimate's consent events are always re-parented, never cascade-deleted. Returns the resulting estimate the Services tab should render.
  • post/Estimates/{id}/convert-to-invoiceConvert a treatment plan to an estimate using the selected tier's quantities.
  • post/invoices/{invoiceId}/revert-to-estimate 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/Estimates/{id}/presentRecord 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/Estimates/{id}/acceptRecord 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/Estimates/{id}/declineClient declined the plan. Sets status to Declined and logs an event.
  • get/Estimates/{id}/consent-events
  • get/Estimates/{id}/convert-readinessRead-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). Hospital sheets retain these execution gates even without an appointment billing association; standalone quotes are exempt — the quote itself becomes the bill.
  • post/Estimates/{id}/itemsAdd a single line (procedure / inventory / retail) to an estimate.
  • post/Estimates/{id}/kitsAdd a kit (GroupCode): every item it contains becomes a Pending line, priced as if added alone and then by the kit's per-item price override, all tagged with one kit-instance id.
  • post/Estimates/{id}/items/populate-defaultsSeed 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/Estimates/{id}/items/{lineId}Update a single estimate line (quantity / price / billing flag / order / tier qtys).
  • delete/Estimates/{id}/items/{lineId}Delete a single estimate line. Blocks when the line is performed-and-dispensed (use void).
  • put/Estimates/{id}/layoutSave how the estimate's lines are grouped and ordered (EstimateLineGroups) — the whole layout in one write, so a drag can never leave half an order behind. Creates, renames, reorders and deletes groups, and re-sequences every line's `DisplayOrder` to match EstimateLineLayout. Presentational only: no price, quantity or execution state changes, so it records no consent event and never trips the consent gate. Lines the request doesn't mention (e.g. added by someone else meanwhile) keep their relative order at the end of the ungrouped lines.
  • get/Estimates/{id}/items/{lineId}/availabilityStock-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/Estimates/{id}/items/{lineId}/take-home-componentsList 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/Estimates/{id}/items/{lineId}/performMark 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/Estimates/{id}/items/{lineId}/declineMark an estimate line declined by the client. Drops it from billing and reassigns any dispense fee.
  • post/Estimates/{id}/items/{lineId}/voidVoid 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`.
  • post/Estimates/{id}/discountsGenerate a PDF for a saved treatment plan.
  • delete/Estimates/{id}/discounts/{appliedDiscountId}Remove a discount code from an estimate (order-level or line).
  • get/Estimates/{id}/pdf
  • post/Estimates/{id}/email-to-clientEmail 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.
ExamTemplates6
Expenses6
Featurebase2
FeatureFlags1
Flowboard10
FormHandoffs6
GroupCodes7
GroupVisits6
Health1
HomeAgain4
HospitalStays18
IntegrationCredentials18
InternalPrescribing1
InternalWidget1
Inventory25
InventoryApprovals5
InventoryLocations7
Invoices29
JourneyMilestones6
Kiosk4
LabPanels5
Labs21
LineItemNotes5
LocationClosures4
Locations11
Logos7
MedicationRequests7
MentorMetrics5
MessageAttachments4
Metrics31
NpsAnalytics3
NvsIntegration11
OnlineBookingReadiness1
Partners6
PatientGroups9
PatientMasses6
PatientProblems4
PatientRecordExport3
Patients21
Payments22
PaymentTokens5
Pep5
Pharmacies5
Phones2
PriceRules6
Printers7
PrintJobs4
PtoRequests6
PublicDevicePairing1
PublicEmailUnsubscribe2
PublicFileLinks2
PublicFormHandoffs1
PublicNps2
PublicPriceList5
PublicQuestionnaires4
PublicSmsConsent2
PurchaseOrders11
QiEvents9
QuestionnaireResponses7
Questionnaires18
RabiesTags10
RdvmPortal22
Recordings9
RecurringExpenses5
ReferralMessages2
Referrals20
Reminders14
Reports2
RetailItems11
Roles6
RoomDayAssignments3
RxGovernance26
SavedReports5
ScheduleItems10
ServiceCatalog5
Shifts5
ShiftSwaps8
SlotConfigurations6
SmsConsent9
Species5
StaffAvailability1
Subscriptions10
SurgicalRecords11
TagAssignments4
Tags5
TelnyxCallControl1
Templates16
TenantKnowledge5
TimeEntries5
Transparency3
Users14
Vaccinations12
VaccineAdministration3
VaccineCertificateRecords6
VaccineCertificates2
VaccineTypes5
Vendors6
Vitals2
VitalTypes6
Widget18
WidgetChatbot4
WorkItemRules5
WorkTasks13
    Estimates

    GET /Estimates/{id}/pdf

    Request

    • Base URL
      https://api.clinicos.vet/backend/business
    • Auth
      HTTP bearer

    Path parameters

    idstring required

    Response

    OK

    Changes

    No recorded changes to this operation across all 14 revisions of this API.

    Previousdelete/Estimates/{id}/discounts/{appliedDiscountId}Remove a discount code from an estimate (order-level or line).Nextpost/Estimates/{id}/email-to-clientEmail 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.
    Skmtc

    Docs, change tracking and code generation pipelines for OpenAPI

    Status

    Catalog

    Search APIsBrowse by categoryAPI change logGeneratorsCheck your API list

    Developers

    DocsDocs from a schemaSkillsGitHub

    Change feeds

    AtomJSON FeedMarkdown

    Agents

    MCP serverMCP setup guidellms.txtexplore.md

    © 2026 Skmtc

    Status
    Privacy policy