Create an EdgeConnect in Dynatrace with the EdgeConnect API, setting host patterns, mappings, and optional OAuth client details in one request.
| POST | SaaS | https://{your-environment-id}.apps.dynatrace.com/v1/edge-connects |
You can either specify a UUID in the request body or a random UUID will be assigned to the created EdgeConnect configuration.
The name must not be longer than 50 characters and must be 'RFC 1123' compliant. The OAuth client ID is optional.
If no OAuth client ID is provided an OAuth client must be generated for that EdgeConnect. This additionally requires the oauth2:clients:manage scope allowing generation of OAuth clients with the app-engine:edge-connects:connect scope, e.g. via the following policy statement: ALLOW oauth2:clients:manage where oauth2:scopes='app-engine:edge-connects:connect'
The oauth2:clients:manage scope is not required if you provide an OAuth client ID.
The OAuth client ID, secret and resource will be returned in the response. The OAuth client secret is not retrievable later on.
To execute this request, you need a platform token or OAuth access token with app-engine:edge-connects:write scope. To learn how to obtain and use it, see Tokens and authentication.
| Parameter | Type | Description | In | Required |
|---|---|---|---|---|
| body | Edge | Maps the specified host patterns to this EdgeConnect | body | Required |
EdgeConnect objectMaps the specified host patterns to this EdgeConnect
| Element | Type | Description | Required |
|---|---|---|---|
| id | string | - | Optional |
| name | Edge | - | Required |
| hostPatterns | Host | - | Required |
| hostMappings | Host | - | Optional |
| oauthClientId | string | Id of OAuth client used to connect by the EdgeConnect | Optional |
| oauthClientSecret | string | Secret of OAuth client used to connect by the EdgeConnect. Only provided when creating a new EdgeConnect. | Optional |
| oauthClientResource | string | Resource of OAuth client used to connect by the EdgeConnect. Only provided when creating a new EdgeConnect. | Optional |
| modificationInfo | Modification | - | Optional |
| metadata | Metadata | - | Optional |
| managedByDynatraceOperator | boolean | Flag to identify if an EdgeConnect is managed by the Dynatrace operator. False by default! | Optional |
EdgeConnectName objectHostPattern objectEither an IP, or a domain name which may contain a wildcard ('') as the leftmost label. If a '' is used, it must be followed by at least two labels.
HostMapping objectTodo
| Element | Type | Description | Required |
|---|---|---|---|
| from | string | - | Required |
| to | string | - | Required |
ModificationInfo object| Element | Type | Description | Required |
|---|---|---|---|
| lastModifiedBy | string | - | Required |
| lastModifiedTime | string | - | Required |
Metadata object| Element | Type | Description | Required |
|---|---|---|---|
| instances | Edge | - | Optional |
| oauthClientStatus | string | The status of the OAuth client The element can hold these values
| Optional |
EdgeConnectInstance object| Element | Type | Description | Required |
|---|---|---|---|
| version | string | - | Optional |
| instanceId | string | - | Optional |
This is a model of the request body, showing the possible elements. It has to be adjusted for usage in an actual request.
{"id": "11111111-2222-4444-3333-555555555555","name": "internal-services","hostPatterns": ["*.internal.org"],"hostMappings": [{"from": "test.local","to": "kubernetes.my.cluster.local"}],"oauthClientId": "dt0s02.AIOUP56P","oauthClientSecret": "dt0s02.AIOUP56P.5ODBJEQYBA4KLD2F6F6EHQZKYK5Q45RARKVCHICXKLMAXVVLIH2L6N5RLMDDY4QA","oauthClientResource": "urn:dtenvironment:wu31a2p3","modificationInfo": {"lastModifiedBy": "12345678-abcd-efgh-1234-123456789","lastModifiedTime": "2022-01-01T01:02:03.165Z"},"metadata": {"instances": [{"version": "1.46.2","instanceId": "string"}],"oauthClientStatus": "ACTIVE"},"managedByDynatraceOperator": false}
| Code | Type | Description |
|---|---|---|
| 201 | Edge | The EdgeConnect has been created successfully |
| 400 | Error | Bad Request |
| default | - | - |
EdgeConnect objectMaps the specified host patterns to this EdgeConnect
| Element | Type | Description |
|---|---|---|
| id | string | - |
| name | Edge | - |
| hostPatterns | Host | - |
| hostMappings | Host | - |
| oauthClientId | string | Id of OAuth client used to connect by the EdgeConnect |
| oauthClientSecret | string | Secret of OAuth client used to connect by the EdgeConnect. Only provided when creating a new EdgeConnect. |
| oauthClientResource | string | Resource of OAuth client used to connect by the EdgeConnect. Only provided when creating a new EdgeConnect. |
| modificationInfo | Modification | - |
| metadata | Metadata | - |
| managedByDynatraceOperator | boolean | Flag to identify if an EdgeConnect is managed by the Dynatrace operator. False by default! |
EdgeConnectName objectHostPattern objectEither an IP, or a domain name which may contain a wildcard ('') as the leftmost label. If a '' is used, it must be followed by at least two labels.
HostMapping objectTodo
| Element | Type | Description |
|---|---|---|
| from | string | - |
| to | string | - |
ModificationInfo object| Element | Type | Description |
|---|---|---|
| lastModifiedBy | string | - |
| lastModifiedTime | string | - |
Metadata object| Element | Type | Description |
|---|---|---|
| instances | Edge | - |
| oauthClientStatus | string | The status of the OAuth client The element can hold these values
|
EdgeConnectInstance object| Element | Type | Description |
|---|---|---|
| version | string | - |
| instanceId | string | - |
ErrorResponse object| Element | Type | Description |
|---|---|---|
| error | Error | - |
Error object| Element | Type | Description |
|---|---|---|
| code | integer | - |
| message | string | - |
| details | Error | - |
ErrorDetails object| Element | Type | Description |
|---|---|---|
| constraintViolations | Constraint | - |
| missingScopes | string[] | - |
| missingPermissions | string[] | - |
ConstraintViolation object| Element | Type | Description |
|---|---|---|
| message | string | - |
| path | string | - |
| parameterLocation | string | - |
{"id": "11111111-2222-4444-3333-555555555555","name": "internal-services","hostPatterns": ["*.internal.org"],"hostMappings": [{"from": "test.local","to": "kubernetes.my.cluster.local"}],"oauthClientId": "dt0s02.AIOUP56P","oauthClientSecret": "dt0s02.AIOUP56P.5ODBJEQYBA4KLD2F6F6EHQZKYK5Q45RARKVCHICXKLMAXVVLIH2L6N5RLMDDY4QA","oauthClientResource": "urn:dtenvironment:wu31a2p3","modificationInfo": {"lastModifiedBy": "12345678-abcd-efgh-1234-123456789","lastModifiedTime": "2022-01-01T01:02:03.165Z"},"metadata": {"instances": [{"version": "1.46.2","instanceId": "string"}],"oauthClientStatus": "ACTIVE"},"managedByDynatraceOperator": false}
{"error": {"code": 1,"message": "string","details": {"constraintViolations": [{"error": {"code": 400,"message": "Constraints violated. Properties already exist in another configuration.","details": {"constraintViolations": [{"path": "hostPatterns[0]","message": "Host pattern must be unique across configurations.\nHost pattern 'myjira.com' already exists in EdgeConnect configuration 'InternalServices'."}]}}}],"missingScopes": ["string"],"missingPermissions": ["string"]}}}