cancel
Showing results for 
Search instead for 
Did you mean: 
twcwebs
Level 1

When creating an invoice through API call, I get a Invalid Reference Id error mentioning "Invalid Reference Id : Line.SalesItemLineDetail.ItemRef" with the error code "2500". Can anybody help me on this isse?

API call that being requested:

 

POST /v3/company/[realmId]/invoice?minorversion=51

 

Request Body that being sent: 

 

{
        Line: [
            {
                DetailType"SalesItemLineDetail",
                Amount100.0,
                SalesItemLineDetail: {
                    ItemRef: {
                        name"Moisturizer",
                        value"12"
                    }
                }
            }
        ],
        CustomerRef: {
            "value""1"
        }
};
 
The error:

{
     Message: 'Invalid Reference Id',
     Detail: 'Invalid Reference Id : Line.SalesItemLineDetail.ItemRef',
     code: '2500',
     element: 'Line.SalesItemLineDetail.ItemRef'
}
 
I'm 100% sure what I'm sending in the Request Body. I'm sending what I'm receiving from quickbooks. I get the data from quickbooks for customer and for each items in SalesItemLine. Data in the Request Body is being validated with quickbooks data. If something is not correct I'll be getting before I do the API call. Without figuring out why I get this error and solving it I can't go forward with create invoice feature. Please can someone help me from Intuit or anybody in the community!!!!!
2 Comments 2
FritzF
Moderator

When creating an invoice through API call, I get a Invalid Reference Id error mentioning "Invalid Reference Id : Line.SalesItemLineDetail.ItemRef" with the error code "2500". Can anybody help me on this isse?

Welcome to the Community, @twcwebs.

 

We have a separate forum specially created for API questions and developers like you. Please visit this link so our developer support and other API users can help with your question about adding company timezone using your app: https://help.developer.intuit.com/s/.

 

You can go directly to the Questions tab, then click Ask A Question.

 

I want to make sure everything is taken care of for you, so let me know if you have any other questions or concerns in the comment section below. I'm always here to help. Have a good one!

twcwebs
Level 1

When creating an invoice through API call, I get a Invalid Reference Id error mentioning "Invalid Reference Id : Line.SalesItemLineDetail.ItemRef" with the error code "2500". Can anybody help me on this isse?

Okay I will....

 

As instructed this is my asked question,

https://help.developer.intuit.com/s/question/0D54R0000784gJcSAI/when-creating-an-invoice-through-api... 

 

If you can redirect this issue to a developer that would be great! Thanks!

Need to get in touch?

Contact us