Skip to main content
Solved

attach files to Bills and Adjustments via REST API

  • April 10, 2024
  • 4 replies
  • 274 views

Hi,

I have a customer trying to implement integration and we’re trying to attach files to bills but are unable to do so. it’s showing as success, but there’s no attachment.

here’s the sample URL request:

https://dev-acumatica.customername.com/customeracct/entity/default/22.200.001/Bill/INV/026331/files/file.pdf

I’m trying to find any related API documentation for this specific endpoint but failed to do so.

 

Best answer by Vignesh Ponnusamy

Hey @daryldiaday,

If you are using or extending the Default endpoint 22.200.001 and above, I would suggest you use the _links approach. As far as, I remember, these are functionalities introduced in Default endpoint 22.200.001. 

If you are using the 20.200.001 and below version, you can use the approach suggested by @RohitRattan88. Hope that clarifies.!

View original
Did this topic help you find an answer to your question?

4 replies

Vignesh Ponnusamy
Acumatica Moderator
Forum|alt.badge.img+5

Hi @daryldiaday,

Refer to the example available in the following help article, https://help-2023r1.acumatica.com/Help?ScreenId=ShowWiki&pageid=591def3d-5fe5-42c1-bb35-cfe5b4c77f6f

The step in short,

  1. Do a GET request for the Bill to which you need to attach the file
  2. From the response in the step 2, use the URL from the files field available under the _links entity to attach the file

Feel free to post if you have any questions. Good Luck,


RohitRattan88
Acumatica Moderator
Forum|alt.badge.img+4
  • Acumatica Moderator
  • 253 replies
  • April 10, 2024

  • Author
  • Freshman I
  • 2 replies
  • April 12, 2024

Hi Rohit/Vignesh,

Thank you for the responses.

I have questions regarding the links you’ve provided as there are 2 different ways to attach files to the record:

https://help-2023r1.acumatica.com/Help?ScreenId=ShowWiki&pageid=591def3d-5fe5-42c1-bb35-cfe5b4c77f6f

for this specific article, it’s using the files:put “URL” for the next request to attach the file.

 

While this article, https://asiablog.acumatica.com/2018/01/attach-files-with-rest-api.html

using a different PUT URL request:
 

 

Are these 2 requests valid and just the same?


Vignesh Ponnusamy
Acumatica Moderator
Forum|alt.badge.img+5

Hey @daryldiaday,

If you are using or extending the Default endpoint 22.200.001 and above, I would suggest you use the _links approach. As far as, I remember, these are functionalities introduced in Default endpoint 22.200.001. 

If you are using the 20.200.001 and below version, you can use the approach suggested by @RohitRattan88. Hope that clarifies.!


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings