Actions execution with Alfresco API Explorer

cancel
Showing results for 
Search instead for 
Did you mean: 
Fjordo
Active Member

Actions execution with Alfresco API Explorer

Hello to Everyone

I work on Alfresco 5.2 community edition,

I would like to use this api service https://api-explorer.alfresco.com/api-explorer/#!/actions/actionExec, but i can't reach it from my local environment.  If I call it from Postman I get 404 error, and I can't find it in my deployed Alfresco Api Explorer.war

In the link before it has been written "Note: this endpoint is available in Alfresco 5.2 and newer versions." and I'm using Alfresco 5.2, what am I missing?

Any suggests?

thanks

1 Reply
abhinavmishra14
Moderator
Moderator

Re: Actions execution with Alfresco API Explorer

Its expected, you have to deploy api-explorer.war to your alfresco instance that can connect to repository. 

Take a look at this documentation for more info: https://docs.alfresco.com/5.2/concepts/dev-api-by-language-alf-rest-install-api-explorer.html

https://docs.alfresco.com/5.2/concepts/dev-api-by-language-alf-rest.html

The request you would be making from client would be like (e.g.):

POST http://<host>:<port>/alfresco/api/-default-/public/alfresco/versions/1/action-executions

Request Body:
{
  "actionDefinitionId": "copy",
  "targetId": "4c4b3c43-f18b-43ff-af84-751f16f1ddfd",
  "params": {"destination-folder": "34219f79-66fa-4ebf-b371-118598af898c"}
}
curl -X POST --header 'Content-Type: application/json' --header 'Accept: application/json' --header 'Authorization: Basic YWRtaW46YWRtaW4=' -d '{
  "actionDefinitionId": "copy",
  "targetId": "4c4b3c43-f18b-43ff-af84-751f16f1ddfd",
  "params": {"destination-folder": "34219f79-66fa-4ebf-b371-118598af898c"}
}' 'http://<HOST>:<PORT>/alfresco/api/-default-/public/alfresco/versions/1/action-executions'

These apis should be working from client even without installing the api explorer as it is just an interface to play with available ReST APIs. 

 

~Abhinav
(ACSCE, AWS SAA-C02, GAIQ)