cancel
Showing results for 
Search instead for 
Did you mean: 

NOT ABLE TO VALIDATE TICKET RECEIVED IN POSTMAN THROUGH ALFRESCO REST API

Suprabhat
Champ in-the-making
Champ in-the-making

Hi I am using alfresco community edition 6.0, I tried to use alfresco rest api.

using POST: http://127.0.0.1:8080/alfresco/api/-default-/public/authentication/versions/1/tickets in post I generated a ticket.

But when I went to validate the ticke by using GET: http://127.0.0.1:8080/alfresco/api/-default-/public/authentication/versions/1/tickets/-me- in postman, I am receiving some error.

Error:

{
    "error": {
        "errorKey": "framework.exception.ApiDefault",
        "statusCode": 401,
        "briefSummary": "05270018 Authentication failed for Web Script org/alfresco/api/ResourceWebScript.get",
        "stackTrace": "For security reasons the stack trace is no longer displayed, but the property is kept for previous versions",
        "descriptionURL": "https://api-explorer.alfresco.com"
    }
}
2 REPLIES 2

kintu_barot
Star Collaborator
Star Collaborator

Hello,

Can you provide the payload or the request body for the ticket validation?

Regards,
Kintu

fedorow
Elite Collaborator
Elite Collaborator

To validate ticket it must be encoded like this.

btoa("my_ticket_value");

The API explorer gives the javascript example:

request.setRequestHeader ("Authorization", "Basic " + btoa(ticket));

So, in the postman it will be like this:

image