Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Scroll ignore
scroll-pdftrue
scroll-officetrue
scroll-chmtrue
scroll-docbooktrue
scroll-eclipsehelptrue
scroll-epubtrue
scroll-htmltrue


#F0F0F0#F0F0F0

3



Scroll export button
scopecurrent
template-id4fda9400-a7df-4ede-a95f-e4ae5fcf4796
captionDownload this Page
add-onScroll PDF Exporter

Generate authentication token using GenerateToken API. Use the generated token to fetch details of an API based on JWT token based authentication for standard and dynamic API.

Prerequisites:

For JWT token based authentication, following keys must be enabled in the web.config file:

  • <add key=”JWT:EnableToken” value=”true” />
  • <add key=”JWT:SecretKey” value=”C1CF4B7DC4C1475B6618DE4F55CA4ASD24” />
  • <add key=”JWT:ExpireMins” value=”4” />

Generate Token 

Generate authentication tokens using GenerateTokenAPI. These authentication tokens are used to provide a secure path to access restricted applications.

The HTTP type for GenerateTokenAPI is GET type.

Generate the token by passing either of the following fields in the Headers section of Postman application:

  1. UserName and Password, or;
  2. API Key

If API Key is enabled, then generate the token based on the API Key. If the API Key is disabled, then generate the token using Username and Password.

Perform the following steps to generate token using GenerateTokenAPI.

  1. Open the Postman application.
  2. Select HTTP Method as GET.
  3. Click Headers tab.
  4. Enter the username and password or the API key.
  5. Click Send.

Get details of an API through JWT token based authentication in Standard and Dynamic API 

After generating the token using GenerateTokenAPI, use any one of the below methods to get the details of standard API using the generated token through JWT token based authentication.

Method 1: 

  1. Open the Postman application.
  2. Select HTTP Method as POST.
  3. Navigate to Auth.
  4. Select Type as Bearer Token.
  5. Paste the token generated in the Token field.
  6. Click Send.

Method 2: 

  1. Open the Postman application.
  2. Select HTTP Method as POST.
  3. Navigate to Headers.
  4. Paste the Token in the Authorization field.
  5. Click Send.

Details of the API are displayed. If the Token is wrong or if the validity time of the token has expired, then the result will show an error stating ‘Invalid or Expired Token’.

Note
titleNote

If using JWT token based authentication is enabled, then no other authentication mechanism will work.

To find token based authentication instructions and collections.

Token URL - <URL>/REST/Summit_RESTWCF.svc/RESTService/GenerateToken


Figure: Using API Key to Generate Bearer Token


Figure: Bearer Token

Sample Request

Code Block
titleSample Request - ("_ProxyDetails" section has been removed)
linenumberstrue
{

"ServiceName": "IM_LogOrUpdateIncident",

"objCommonParameters": {

"incidentParamsJSON": {

"IncidentContainerJsonObj": {

"Updater": "Executive",

"CI_Key": "hostname",

"Ticket": {

"IsFromWebService": true,

"Priority_Name": "P4",

"Classification_Name": "test 4",

"Sup_Function": "Info",

"Caller_EmailID": "xyz@abc.com",

"Status": "New",

"Urgency_Name": "test",

"Assigned_WorkGroup_Name": "IM WG",

"Medium": "Application",

"Impact_Name": "Medium",

"Description": "High",

"PageName": "TicketDetail"

},

"TicketInformation": {

"Information": "Test Symptop!!!Test Symptop!!!Test Symptop!!!Test Symptop!!!",

"UserLog": "UserLog"

}

}

},

"RequestType": "RemoteCall"

}

}


Code Block
titleSample Response
linenumberstrue
{

"Errors": "",

"Input": null,

"Message": "New ticket has been logged successfully",

"OrgID": 0,

"Output": null,

"OutputID": 0,

"OutputObject": null,

"TokenID": null,

"Token_Expire_InSecs": 0,

"Priority": null,

"ResolutionDeadLine": null,

"Resolution_DeadLine": "1/1/0001 12:00:00 AM",

"SLA": null,

"TicketID_Encrypted": "ea4PdE3gQgXXXXXhYSCdrg%3d%3d",

"TicketID_Internal": 32535,

"TicketNo": 51733

}


Scroll ignore
scroll-pdftrue
scroll-officetrue
scroll-chmtrue
scroll-docbooktrue
scroll-eclipsehelptrue
scroll-epubtrue
scroll-htmltrue


1

| |