URL system¶
The URL system represents a HTTP server (i.e. a web server)
serving HTTP requests from a base url.
It supports the HTTP
and HTTPS
protocols. It provides session handling, connection pooling and authentication
services to sources and sinks which need to communicate with a HTTP server.
Prototype¶
{
"_id": "id-of-system",
"name": "Name of system",
"type": "system:url",
"url_pattern": "http://host:port/path/%s",
"verify_ssl": false,
"custom_ca_pem_chain": "-----BEGIN CERTIFICATE-----\nMIIGYTCCB[...]\n-----END CERTIFICATE-----\n",
"username": null,
"password": null,
"jwt_token": null,
"headers": {
"MY_HEADER": "some-value",
"MY_OTHER_HEADER": "$ENV(key-for-other-value)",
"MY_SECRET_HEADER": "$SECRET(secret-key)"
},
"oauth2": {
"client_id": "my-client-id",
"client_secret": "$SECRET(client-secret)",
"token_url": "https://oath2-enabled-server:port/path/to/service/for/access/token",
"access_token": "$SECRET(access-token)",
"refresh_token": "$SECRET(refresh-token)",
"refresh_window": 30,
"scope": ["scope1", "scope2"],
"extra": {
"some": "extra-params",
"to": "include-in-token-request"
}
},
"tripletex": {
"consumer_token": "$SECRET(consumer-token)",
"employee_token": "$SECRET(employee-token)",
"token_url": "https://tripletex-api:port/path/to/service/for/token-refresh",
"ttl": 48
},
"proxies": {
"http": "socks5://mysocksproxy:1234",
"https": "socks5://user:password@mysslsocksproxy:1234",
},
"authentication": "basic",
"connect_timeout": 60,
"read_timeout": 1800
}
Properties¶
Property |
Type |
Description |
Default |
Req |
---|---|---|---|---|
|
String |
Similar to |
Yes |
|
|
String |
Deprecated. Use the |
||
|
Boolean |
Indicate to the client if it should attempt to verify the SSL certificate when communicating with the HTTP server over SSL/TLS. A global default value for all URL systems can be set in the service metadata. |
|
|
|
String |
If |
||
|
String |
The username to use when authenticating with the HTTP server. Note that you also have to specify
authentication protocol in |
||
|
String |
The password to use if |
Yes* |
|
|
String |
If |
||
|
Dict<String,String> |
A optional set of header values to set as defaults in the requests made using the URL system. Both keys and values must
evaluate to strings. Note that any “Authorization” header provided in this object is automatically overwritten
when using the |
||
|
Enum<String> |
What kind of authentication protocol to use. Note that authentication is opt-in only and the default is no
authentication. Allowed values is either |
||
|
Dict<String,String> |
A optional set of properties that specifies support for automatic fetching of JWT access tokens from a oauth2
enabled provider. The grant types supported are “client credentials” and “refresh token”. For the “client credentials”
grant type you need to supply a |
||
|
Dict<String,String> |
A optional set of properties that specifies support for automatic generation and refreshing of Tripletex access
tokens. See the Tripletex API documentation for details.
You need to supply a |
||
|
Dict<String,String> |
A optional set of properties that specifies a set of SOCKS5 proxies for the URL system. The keys represents url-
prefixes (for example ‘http’ and ‘https’) and the values of the HTTP(S) or SOCKS5 servers that the requests matching the
prefixes should be passed through. The values should be on the form |
||
|
Integer |
Number of seconds to wait for connecting to the HTTP server before timing out. |
|
|
|
Integer |
Number of seconds to wait for the HTTP server to respond to a request before timing out. |
|
|
|
Boolean |
Normally, the URL system will throw an error if the |
|
[1] Exactly one of base_url
and url_pattern
must be specified.
Example configuration¶
{
"_id": "our-http-server",
"name": "Our HTTP Server",
"type": "system:url",
"base_url": "http://our.domain.com/files"
}
Example with ntlm configuration:
{
"_id": "our-http-server",
"name": "Our HTTP Server",
"type": "system:url",
"authentication": "ntlm",
"username": "$ENV(username-variable)",
"password": "$SECRET(password-variable)",
"base_url": "http://our.domain.com/files"
}