mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Closes #5610: Add REST API endpoint for webhooks
This commit is contained in:
@@ -21,6 +21,19 @@ from utilities.querysets import RestrictedQuerySet
|
||||
from utilities.utils import deepmerge, render_jinja2
|
||||
|
||||
|
||||
__all__ = (
|
||||
'ConfigContext',
|
||||
'ConfigContextModel',
|
||||
'CustomLink',
|
||||
'ExportTemplate',
|
||||
'ImageAttachment',
|
||||
'JobResult',
|
||||
'Report',
|
||||
'Script',
|
||||
'Webhook',
|
||||
)
|
||||
|
||||
|
||||
#
|
||||
# Webhooks
|
||||
#
|
||||
@@ -109,6 +122,8 @@ class Webhook(BigIDModel):
|
||||
'Leave blank to use the system defaults.'
|
||||
)
|
||||
|
||||
objects = RestrictedQuerySet.as_manager()
|
||||
|
||||
class Meta:
|
||||
ordering = ('name',)
|
||||
unique_together = ('payload_url', 'type_create', 'type_update', 'type_delete',)
|
||||
|
Reference in New Issue
Block a user