Generate a new passcode for one of your Dynatrace dashboard shares with the Public Access API, for example to rotate access to a passcode-protected link.
| POST | SaaS | https://{your-environment-id}.apps.dynatrace.com/v1/shares/{shareId}/passcode |
You use the shareId path parameter to choose one of your passcode-protected dashboard shares and generate a new passcode for it, for example to rotate access after the old passcode was shared too widely. Viewers then need the new passcode to open the public link. A 201 response confirms that the passcode was generated.
To execute this request, you need a platform token or OAuth access token with public-access:shares:write scope. To learn how to obtain and use it, see Tokens and authentication.
| Parameter | Type | Description | In | Required |
|---|---|---|---|---|
| shareId | string | The UUID of the share config | path | Required |
| Code | Type | Description |
|---|---|---|
| 201 | Passcode | Passcode generated |
| 404 | - | - |
| 4XX | - | - |
| 5XX | - | - |
PasscodeResponse object| Element | Type | Description |
|---|---|---|
| passcode | string | The passcode for the share config |
{"passcode": "string"}