For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Open sourceSupportFAQsDocs Home
  • Introduction
    • Overview
    • Retired adapters
      • Overview
        • Overview
          • Basic auth to get a token
          • Handle cookie-based tokens
          • Different host
          • Dynamic token per domain
          • Dynamic user per request
          • Encoding request values
          • Changing data types
        • Advanced authentication
      • SSL/TLS
      • Throttling
      • Headers
      • Add dynamic headers
      • Add query parameters
      • Update adapter configuration
LogoLogo
Open sourceSupportFAQsDocs Home
On this page
  • Configuration
  • action.json
ConfigureAuthenticationPatterns

Authentication to a different host

Was this page helpful?
Previous

Dynamic token per domain

Next
Built with

This system uses two-step authentication, but the token request is sent to a different host than the system the adapter integrates with — for example, a standalone single sign-on (SSO) service that returns a token valid for multiple downstream systems.

Configuration

This scenario requires only a change to action.json in the endpoint configuration at /adapter-home-dir/entities/.system.

action.json

Add an sso object to the getToken action. The sso object overrides the host, protocol, and port for the token request only, replacing the values from the service instance configuration or callProperties. The protocol and port can be omitted if they are the same as the adapter’s configured values.

1{
2 "name": "getToken",
3 "protocol": "REST",
4 "method": "POST",
5 "entitypath": "{base_path}/{version}/authentication/login",
6 "requestSchema": "tokenReqSchema.json",
7 "responseSchema": "tokenRespSchema.json",
8 "timeout": 0,
9 "sendEmpty": false,
10 "requestDatatype": "JSON",
11 "responseDatatype": "PLAIN",
12 "headers": {},
13 "sso": {
14 "protocol": "https",
15 "host": "tokenhost",
16 "port": 443
17 },
18 "responseObjects": [
19 {
20 "type": "default",
21 "key": "",
22 "mockFile": "mockdatafiles/getToken-default.json"
23 }
24 ]
25}