HTTP account details
To establish a connection to an HTTP endpoint, you must add an account that defines the account details to connect with. You can define these details by creating a configuration object in the App Connect Dashboard, the Red Hat® OpenShift® web console or CLI, or the Kubernetes CLI.
Account parameters
If you've configured more than one set of user credentials or generated more than one API key for an HTTP endpoint (for example, to accommodate different rate limits or access levels), you can define multiple accounts for the endpoint.
For each account that you require, you can specify a new set of account details in any of the following ways:
- If you are using the App Connect Dashboard, either complete the
Account details fields in the
Create configuration
panel, or specify the account parameters in an accounts.yaml file before importing it into theCreate configuration
panel. For more information, see Accounts type. - If you are using the Red Hat OpenShift web console or CLI, or the Kubernetes CLI, specify the account parameters in an accounts.yaml file, and then use this configuration file to create a configuration object. For more information, see Creating the file for a configuration object of type Accounts.
The set of required and optional Account fields or parameters are listed in the following table.
The values required to connect to your HTTP server are dependent on the type of security scheme that is configured for the endpoint.
- Connecting to an un-authenticated public endpoint
-
If the endpoint is publicly available and requires no authentication, you don't need to specify any connection details, but must specify an account name by using the name parameter.
- Connecting with basic authentication
-
If the HTTP endpoint is secured using basic authentication, you must specify a username and password by using the username and password parameters.
- Connecting to an endpoint that requires an API key
-
If the HTTP endpoint requires an API key whenever a request is made (for example, to authenticate API calls, monitor usage, or apply permissions), you must specify an API key, API key location, and API key name by using the apiKeyValue, apiKeyLocation, and apiKeyName parameters.
| Field | Parameter | Values | Condition | Description |
|---|---|---|---|---|
|
Account name |
name |
User defined |
Required |
The name of an HTTP account that is used in the exported flow. |
|
User name |
username |
User defined |
Optional Use in conjunction with the password parameter. |
The name of a user that is authorized to perform HTTP operations on an endpoint that is secured using basic authentication. |
|
Password |
password |
User defined |
Optional Use in conjunction with the username parameter. |
The password for the user connecting with basic authentication. If the authentication requires a user name with an API key as the password, set the password parameter to the API key value. |
|
API key |
apiKeyValue |
User defined |
Optional Use in conjunction with the apiKeyLocation and apiKeyName parameters. |
An API key that the endpoint requires to validate each HTTP request. |
|
API key location |
apiKeyLocation |
header body URL encoded |
Optional Use in conjunction with the apiKeyValue and apiKeyName parameters. |
The location where the API key should be stored in the HTTP request.
|
|
API key name |
apiKeyName |
User defined |
Optional Use in conjunction with the apiKeyValue and apiKeyLocation parameters. |
The header or body parameter that will be used to store the API key. If necessary, check your API documentation for this parameter name. In your HTTP node, if you add a Request headers field with a name that’s identical to the apiKeyName value that was configured to be passed in a request header, the header in these connection credentials takes priority. |
|
Allow self-signed certificates |
acceptSelfSignedCerts |
true false |
Optional |
If you want to be able to accept self-signed certificates that are trusted and used only in a non-production environment, set this value to true. The default is false. |
|
Override the HTTP endpoint host name and port of the URL used in the flow |
endpointUrl |
User defined |
Optional |
A URL that lets you override the protocol, host, and port in the endpoint URL being called by the HTTP node. This setting enables you to use the same flow to call different endpoints by setting up multiple accounts with different override URLs. Specify this value in the format
|
Examples
accounts: http:
- name: Account 1
credentials: {}
endpoint: {} http:
- name: Account 1
credentials:
username: joebloggs
password: topsecret1234
endpoint: {} http:
- name: Account 1
credentials:
username: joebloggs
password: topsecret1234
apiKeyValue: ABcde-12345
apiKeyLocation: header
apiKeyName: Apikey
endpoint: {} http:
- name: Account 1
credentials:
username: joebloggs
password: topsecret1234
endpoint:
endpointUrl: 'https://mystagingAPIhost.acme.com:3002'