Skip to main content
Solved

How to add a Project Attribute to a web service endpoint for quotes?

  • Jul 11, 2025 12:53 AM UTC
  • 16 replies
  • 369 views
  • Translate All

I have made a project attribute: DOCLINKS which I use to store a string (url) for documents to attach to Project Quotes.

I want to update this field via the api.

As far as I know, Acumatica does not have a DEFAULT end point for Project Quotes so I cannot extend the default end point.

I tried to create a new web service endpoint to pull at least the quote number from the Quote Summary but am struggling to add the project attribute field to the response.

 

I can pull the data via querying a custom GI but I need to also update and edit that field which you cannot do via the api.

I tried following this 

But to no avail.

Best answer by varthinibhaskaran18

Unfortunately, there is no workaround as of now and the team is working on it.

I will keep the post updated with any new findings, so the OP can get an update asap.

​@Tony Lanzer Please create a case using the Acumatica portal to get regular updates on this issue.

Have a nice day!

View original

16 replies

Tony Lanzer
Captain II
Forum|alt.badge.img+3
  • Captain II
  • Jul 14, 2025 3:00 PM UTC

​@mattyo Did you follow the instructions in the post you reference? If you perform a GET on the appropriate endpoint, is your attribute not returned in the response?

Translate

  • Author
  • Freshman I
  • Jul 14, 2025 11:34 PM UTC

​@Tony Lanzer 

Thank you for the response.

 

Yes, I tried to use the custom field but I could not find anywhere what the label of the custom field would be.

 

In the Quote, I have the following attribute (amongst others): panda doc link (ID: PANDADOCLK)

 

When I add the custom field like this as a parameter

I get the following error in Postman

So I’m assuming the name of the attribute is different, but I have no idea where to find the correct name.

I’ve also tried expanding the attributes but since the Attribute value is not mapped to anything when I create it from an existing entity, it always returns empty.

 

 

Translate

  • Author
  • Freshman I
  • Jul 15, 2025 2:41 AM UTC

​@Tony Lanzer 

I did a bit more playing around and using the $adHocSchema at the end of the endpoint, I was able to check which custom fields are available for this endpoint.

 

Unfortunately there are no project attributes listed here:

 

"custom": {
        "Quote": {
            "OpportunityID": {
                "type": "CustomStringField",
                "value": null
            },
            "IsPrimary": {
                "type": "CustomBooleanField",
                "value": null
            },
            "DocumentDate": {
                "type": "CustomDateTimeField",
                "value": null
            },
            "ExpirationDate": {
                "type": "CustomDateTimeField",
                "value": null
            },
            "ExternalRef": {
                "type": "CustomStringField",
                "value": null
            },
            "TemplateID": {
                "type": "CustomStringField",
                "value": null
            },
            "ProjectManager": {
                "type": "CustomStringField",
                "value": null
            },
            "BAccountID": {
                "type": "CustomStringField",
                "value": null
            },
            "ContactID": {
                "type": "CustomIntField",
                "value": null
            },
            "ContactID_description": {
                "type": "CustomStringField",
                "value": null
            },
            "OwnerID": {
                "type": "CustomIntField",
                "value": null
            },
            "OwnerID_description": {
                "type": "CustomStringField",
                "value": null
            },
            "CuryID": {
                "type": "CustomStringField",
                "value": null
            },
            "CuryViewState": {
                "type": "CustomBooleanField",
                "value": null
            },
            "QuoteProjectID": {
                "type": "CustomStringField",
                "value": null
            },
            "QuoteProjectCD": {
                "type": "CustomStringField",
                "value": null
            },
            "CuryAmount": {
                "type": "CustomDecimalField",
                "value": null
            },
            "CuryCostTotal": {
                "type": "CustomDecimalField",
                "value": null
            },
            "CuryGrossMarginAmount": {
                "type": "CustomDecimalField",
                "value": null
            },
            "GrossMarginPct": {
                "type": "CustomDecimalField",
                "value": null
            },
            "CuryTaxTotal": {
                "type": "CustomDecimalField",
                "value": null
            },
            "CuryQuoteTotal": {
                "type": "CustomDecimalField",
                "value": null
            },
            "NoteText": {
                "type": "CustomStringField",
                "value": null
            },
            "NoteID": {
                "type": "CustomGuidField",
                "value": null
            }
        }

Translate

Tony Lanzer
Captain II
Forum|alt.badge.img+3
  • Captain II
  • Jul 15, 2025 7:26 PM UTC

In a GET request, use 

$expand=Attributes

in your url to return your attributes in the response, as shown in this help topic: https://help.acumatica.com/(W(4))/Help?ScreenId=ShowWiki&pageid=56831ee7-14b0-45ef-8207-dace30beb2cb

In a PUT request body include:

"Attributes": 
[
{
"Attribute": {"value": "Is Inspection Complete?"},
"Value": {"value": true}
}
]

If these don’t work, please supply your request URLs.

Translate

  • Author
  • Freshman I
  • Jul 15, 2025 10:30 PM UTC

Thanks ​@Tony Lanzer 

The request URL I’m using is a custom web end point since there is no default end point for quotes:

https:// client-domain /entity/Custom/1/ProjectQuote?$expand=Attributes&$filter=QuoteNumber eq 'PQ000200'

The issue is that even when I expand the Attributes, it returns as an empty array.

 

Since it is a custom web end point, I had to add the Attributes via Creating an Entity attached to that end point using an existing entity.

And by doing that, as shown in the first image, these values aren’t mapped to any object, hence why the returned array is always empty and I can’t update those attributes via a PUT request.

 

The PUT request returns a 200 OK response but nothing is updated.

 

Translate

Tony Lanzer
Captain II
Forum|alt.badge.img+3
  • Captain II
  • Jul 16, 2025 3:19 PM UTC

Can you map your custom ProjectQuote Attributes node like the Project Attributes node?
 

 

Translate

  • Author
  • Freshman I
  • Jul 16, 2025 10:05 PM UTC

​@Tony Lanzer 
Yeah I’ve tried that but keep getting this error:

 

 "message": "An error has occurred.",

    "exceptionMessage": "Cannot form sql query",

 "exceptionType":"PX.Api.ContractBased.OptimizedExport.CannotOptimizeException",

    "stackTrace": "   at PX.Api.ContractBased.OptimizedExport.NotWorkingOptimizedExportProvider.get_CanOptimize() in C:\\build\\code_repo\\NetTools\\PX.Api.ContractBased\\OptimizedExport\\NotWorkingOptimizedExportProvider.cs:line 93\r\n   at PX.Api.ContractBased.EntityService.<GetListAsyncFromEnumerable>d__8.MoveNext() in C:\\build\\code_repo\\NetTools\\PX.Api.ContractBased\\EntityService.cs:line 249\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at PX.Api.ContractBased.SystemContracts.V2.SoapFacade.<PX-Api-ContractBased-IRestGate-GetListAsync>d__4.MoveNext() in C:\\build\\code_repo\\NetTools\\PX.Api.ContractBased\\SystemContracts\\V2\\SoapFacade.cs:line 44\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Threading.Tasks.TaskHelpersExtensions.<CastToObject>d__1`1.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Controllers.ApiControllerActionInvoker.<InvokeActionAsyncCore>d__1.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Filters.ActionFilterAttribute.<ExecuteActionFilterAsyncCore>d__5.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Controllers.ActionFilterResult.<ExecuteAsync>d__5.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Filters.AuthorizationFilterAttribute.<ExecuteAuthorizationFilterAsyncCore>d__3.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Controllers.ExceptionFilterResult.<ExecuteAsync>d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Web.Http.Controllers.ExceptionFilterResult.<ExecuteAsync>d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Dispatcher.HttpControllerDispatcher.<SendAsync>d__15.MoveNext()"

Translate

Forum|alt.badge.img+1

Unfortunately, there is no work around for this error.

This is a known issue and Acumatica engineering team is work on it. The fix should be available soon.

Translate

Tony Lanzer
Captain II
Forum|alt.badge.img+3
  • Captain II
  • Jul 24, 2025 12:04 PM UTC

​@varthinibhaskaran18 , Can you please offer more details so that the OP and the Community know what exactly causes the error and how to get around it?  If a new endpoint is created for Project Quotes and fields are mapped just like an existing endpoint, why doesn’t it work? If a different endpoint version were extended would it work?

Translate

Forum|alt.badge.img+1

Unfortunately, there is no workaround as of now and the team is working on it.

I will keep the post updated with any new findings, so the OP can get an update asap.

​@Tony Lanzer Please create a case using the Acumatica portal to get regular updates on this issue.

Have a nice day!

Translate

Tony Lanzer
Captain II
Forum|alt.badge.img+3
  • Captain II
  • Jul 24, 2025 4:34 PM UTC

​@varthinibhaskaran18 ,Please clarify. Are you saying Project Quotes can’t be added as an endpoint, are you saying that the way he’s mapping it doesn’t work, are you saying extending an endpoint doesn’t work, or ?? Please supply details of exactly what it is that is broken, otherwise no one knows what not to do.

Translate

  • Author
  • Freshman I
  • Jul 25, 2025 6:54 AM UTC

​@varthinibhaskaran18 ,Please clarify. Are you saying Project Quotes can’t be added as an endpoint, are you saying that the way he’s mapping it doesn’t work, are you saying extending an endpoint doesn’t work, or ?? Please supply details of exactly what it is that is broken, otherwise no one knows what not to do.

From my experience with the api so for, Project Quotes can be extended as an endpoint, but only for reading data and creating new quotes.

I’ve tried in a separate custom end point to update the description of a quote but consistently get the same error: 

 "message": "An error has occurred.",
"exceptionMessage": "The system failed to commit the Quote row.",

 

Translate

Forum|alt.badge.img+1

​@Tony Lanzer The issue is only with Attributes parts of Project Quote entity.

There is no issue in extending endpoint or adding project quote entity to it or retrieving Project quote details other than the attributes.

Hope this helps!

Translate

  • Author
  • Freshman I
  • Jul 29, 2025 10:22 PM UTC

​@varthinibhaskaran18 

 

I’ve successfully retrieved Project quote details via extending the endpoint and can also retrieve the attributes via a custom GI.

I’ve also successfully created a new Project quote using a Put request on that extended endpoint.

 

The issue is that Project Quotes cannot be updated or modified. Even fields such as the description result in the following error:

"exceptionMessage": "The system failed to commit the Quote row.",

 

If/When a fix for this is released, how will we be notified?

Translate

Forum|alt.badge.img+1

I will try to keep the post notified with any updates on this issue.

Meanwhile, if you wish to get regular updates, please do create a support request through the portal.

 

Hope this helps!

Translate

  • Author
  • Freshman I
  • Aug 6, 2025 3:26 AM UTC

Thanks ​@varthinibhaskaran18 .

For anyone else struggling with this issue, a temporary work around is that you can update the notes in a quote, so at least that is better than nothing.

Translate