Skip to main content
Question

API FRESHSERVICE - DELETE AN ASSET

  • January 13, 2023
  • 10 replies
  • 112 views

Forum|alt.badge.img+1

Hello

I try to delete an asset

But I have this message :

{
    "description""Validation failed",
    "errors": [
        {
            "field""deleted",
            "message""awrns_service_delete_not_allowed",
            "code""invalid_value"
        }
    ]
}

 

An idea ?

 

10 replies

afautley
Top Contributor ⭐
Forum|alt.badge.img+11
  • Top Contributor ⭐
  • January 13, 2023

How was you trying to delete it, via an API?

 


Forum|alt.badge.img+1
  • Author
  • Contributor
  • January 14, 2023

I try by CURL, by POSTMAN, by ASP, by VB.net

same error !!


Forum|alt.badge.img+1
  • Author
  • Contributor
  • January 14, 2023

curl -v -u my_address_mail:password -X DELETE "https://parthena.freshservice.com/api/v2/assets/5268"


Forum|alt.badge.img+1
  • Author
  • Contributor
  • January 15, 2023

yes via an API
I tried in CURL, with POSTMAN, in VB.Net or in ASP Classic, I have the same error


afautley
Top Contributor ⭐
Forum|alt.badge.img+11
  • Top Contributor ⭐
  • January 16, 2023

Have you checked your permissions on the account you are using? 

Also have you tried to delete this asset manually just to confirm that you can delete it? 


Forum|alt.badge.img+1
  • Author
  • Contributor
  • January 16, 2023

from the Freshservice web interface and with the same account used in the APIs, I can delete an asset


afautley
Top Contributor ⭐
Forum|alt.badge.img+11
  • Top Contributor ⭐
  • January 16, 2023

have you tried via the workflow Automator? Get web request? 

To me, that message is saying it cannot validate it due to the code having an invalid value so the code could be wrong, 

I use the workflow Automator for most of my work not using Curl/postman, maybe if you can get is to work from the web request then it will confirm the code you are using needs tweaking. if you cannot get to work with workflow Automator then it indicates that the asset itself needs amending?


Forum|alt.badge.img+1
  • Author
  • Contributor
  • January 16, 2023

I can't use WORKFLOW AUTOMATOR because I have set up an EDI (computer data exchange) between our CRM and Freshservice. Deleting a contact or a company works perfectly

another point, restoring an asset works very well


afautley
Top Contributor ⭐
Forum|alt.badge.img+11
  • Top Contributor ⭐
  • January 16, 2023

I would say contact FreshService direct then? sorry...


Forum|alt.badge.img+1
  • Author
  • Contributor
  • January 16, 2023

I’m in contact with Freshservice but it has been over a week and I still have no solution. So I try other channels