Web Client access error when SAM is hosted on a different server - HxGN SDx - Update 64 - Administration & Configuration

Administration and Configuration of HxGN SDx

Language
English
Product
HxGN SDx
Search by Category
Administration & Configuration
SmartPlant Foundation / SDx Version
10

Problem

When using Smart API Manager version 5 or later, you cannot access the Web Client which is configured on a different server and see the following error:

SAM WC access issue

Solution

You must update the CORS section of the appsettings.json file of the Smart API Manager server to allow you to log in to the Web Client using your access credentials.

Set the AllowCredentials property to True in the appsettings.json file.

For example:

"Security": {

"Cors": {

"AllowedOrigins": [

"https://<machinename>.ingrnet.com",

"http://<machinename>.ingrnet.com",

],

"AllowedMethods": [

"GET"

"POST"

"PUT"

"DELETE"

],

"ExposedHeaders": [

"Location",

"Preference-Applied",

"Retry-After"

],

"AllowCredentials": True,

"PreflightMaxAge": 600

},