Save webhook
PUT
/api/v1/instance/audit/webhook
const url = 'https://example.com/api/v1/instance/audit/webhook';const options = { method: 'PUT', headers: { cookie: 'ttx_access_token=<ttx_access_token>', 'X-CSRF-Token': '<X-CSRF-Token>', 'Content-Type': 'application/json' }, body: '{"authorization":"example","enabled":true,"url":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://example.com/api/v1/instance/audit/webhook \ --header 'Content-Type: application/json' \ --header 'X-CSRF-Token: <X-CSRF-Token>' \ --cookie ttx_access_token=<ttx_access_token> \ --data '{ "authorization": "example", "enabled": true, "url": "example" }'Where the log goes: every event from now on is forwarded (the ones before can be exported). Recorded, with step-up – it sends account emails out of the deployment.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Responses
Section titled “Responses”Successful Response
Media typeapplication/json
AuditWebhookRead
object
allow_http
required
Allow Http
boolean
configured
required
Configured
boolean
enabled
Enabled
boolean
has_authorization
Has Authorization
boolean
pending
Pending
integer
Example
{ "enabled": false, "has_authorization": false, "pending": 0}Validation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
ctx
Context
object
input
Input
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
Example generated
{ "detail": [ { "ctx": {}, "input": "example", "loc": [ "example" ], "msg": "example", "type": "example" } ]}