• Resolved dfreeman33

    (@dfreeman33)


    When using the API to create a new invoice, is there a way to retrieve the invoice number that was created?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Contributor MariaKravchenko

    (@mariakravchenko)

    Hello

    In the answer to your request for creating the invoice, you could get full information about the invoice, including ID. Some example here – https://wp-invoice.github.io/docs/api/

    Variable $new_invoice includes everything that you need.

    Regards.

    Thread Starter dfreeman33

    (@dfreeman33)

    When I try to access $new_invoice, it has a NULL value. When I look at the contents of $client, there is an error that is returned:
    Error: IXR_Error Object
    Code: -32700
    Message: parse error. not well formed

    I can see that the invoice was created, but I just can’t access $new_invoice

    Plugin Contributor MariaKravchenko

    (@mariakravchenko)

    Something wrong with your request. For technical support please use the Feedback/Support tab in WP-Invoice Settings.

    Regards.

    Thread Starter dfreeman33

    (@dfreeman33)

    I’ve tried with both an invoice I created as well as a copy/paste from the API example. In the example, the only lines I changed were the credentials, the client endpoint URL and the user_data array to point to an existing user. In both cases, the invoice is created, but the response includes the parse error.

    Is anyone else using version 4.2.1 and able to generate invoices and access the responses?

    Plugin Contributor MariaKravchenko

    (@mariakravchenko)

    We will be able to check that at the end of the month. Unfortunately, we have limited resources and can’t check that right now.

    Thread Starter dfreeman33

    (@dfreeman33)

    You can cancel this request. I found the problem was an issue with a child theme incompatibility that was affecting all XML-RPC request. This was causing the parse error.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘API New Invoice Number’ is closed to new replies.