I'm able to perform other CRUD operations on the term store, but I'm unable to delete a term from it.
An app has been created in AAD, and read/write/all permssions have been assigned for both SharePoint and Graph. I'm able to get a bearer token in my workflow, so I'm guessing this has been set up correctly? The account being used for the workflow actions has been explicitly given read/write permissions to the term store. As I said, I'm able to perform the other CRUD actions, so I'm also guessing the permissions are set up correctly.
I've tried the below parameters in varying combinations in both the SharePoint and generic HTTP request actions. I'm getting a range of errors, and I've added those to the URI's returning them.
URI's for bearer token:
1. https://login.microsoftonline.com/[SITE ID]/oauth2/token (no error)
2. https://login.microsoftonline.com/[SITE ID]/oauth2/v2.0/token (error: Invalid version: sites)
URI's for delete action:
1. https://graph.microsoft.com/beta/termStore/sets/[TERM SET ID]/terms/[TERM ID] (error: Either scp or roles claim need to be present in the token. * Since this was beta, I didn't investigate this and tried the other Graph URI)
2. https://graph.microsoft.com/sites/[SITE ID]/termStore/sets/[TERM SET ID]/terms/[TERM ID] (error: Access token validation failure. Invalid audience.)
3. /_api/v2.1/termStore/groups/[GROUP ID]/sets/[TERM SET ID]/terms/[TERM ID] (error: InternalServerError)
Method: DELETE
Headers:
1. Content-Type = application/json
2. Authorization = Bearer [BEARER TOKEN]
I appeciate any help you can provide.