Invoices

Invoices#index

Retrieves all firm invoices

GET /invoices

Response

Returns a 200 OK with an array of invoices:

[
    {
        "id": 1,
        "firm_id": 1,
        "user_id": 1,
        "contact_id": 1,
        "due_date": "2021-09-29",
        "close_date": null,
        "discount_percent_description": null,
        "discount_percent": 0,
        "discount_amount_description": null,
        "discount_amount": 0,
        "trust_request_amount": null,
        "trust_level": null,
        "last_reminder": null,
        "created_at": "2021-09-22T17:47:49.041Z",
        "updated_at": "2021-09-22T17:47:49.041Z",
        "issue_date": "2021-09-22",
        "invoice_number": "1",
        "footer": null,
        "has_discount_percent": false,
        "has_discount_amount": false,
        "color_scheme": "",
        "include_footer": false,
        "invoice_type": "bill",
        "status": "paid",
        "reminder_frequency": 7,
        "send_reminders": false,
        "public_code": "1234example",
        "discarded_at": null,
        "created_by_id": 1,
        "stored_total": "0.0",
        "stored_balance": "0.0",
        "payment_plan_id": null,
        "description": "Trust Request",
        "channel": "email",
        "viewed_by_contact": false,
        "include_logo": true,
        "quickbooks_uid": null
    }
]
    

Invoices#show

Returns a single invoice

Response

Returns a 200 OK with a single invoice:

Invoices#create

Creates a new invoice. Keep in mind to send invoice data inside an invoice root key.

You should pass a JSON with the following parameters:

  • user_id integer

  • contact_id integerrequired

  • status 'unpaid' or 'paid'

  • due_date date

  • close_date date

  • discount_percent_description string

  • discount_percent integer

  • discount_amount_description string

  • discount_amount integer

  • trust_request_amount decimal

  • invoice_type 'bill', 'trust_request' or 'disbursement'

  • trust_level 'client_level' or 'matter_level'

  • last_reminder datetime

  • issue_date date

  • footer string

  • has_discount_percent boolean

  • has_discount_amount boolean

  • include_footer boolean

  • send_reminders boolean

  • reminder_frequency integer, default(7)

  • description string

  • include_logo boolean

  • invoice_matters_attributes array

    • matter_id integer

Response

Returns a 201 created.

Invoices#update

Updates an existing invoice.

You should pass a JSON with the following parameters:

  • user_id integer

  • contact_id integerrequired

  • status 'unpaid' or 'paid'

  • due_date date

  • close_date date

  • discount_percent_description string

  • discount_percent integer

  • discount_amount_description string

  • discount_amount integer

  • trust_request_amount decimal

  • invoice_type 'bill', 'trust_request' or 'disbursement'

  • trust_level 'client_level' or 'matter_level'

  • last_reminder datetime

  • issue_date date

  • footer string

  • has_discount_percent boolean

  • has_discount_amount boolean

  • include_footer boolean

  • send_reminders boolean

  • reminder_frequency integer, default(7)

  • description string

  • include_logo boolean

  • invoice_matters_attributes array

    • matter_id integer

Response:

Returns 200 OK

Last updated

Was this helpful?