-
-
Notifications
You must be signed in to change notification settings - Fork 64
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #273 from mnfst/hooks
✨ Webhooks
- Loading branch information
Showing
43 changed files
with
964 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'manifest': minor | ||
--- | ||
|
||
Added webhooks |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,14 @@ | ||
{ | ||
"semi": false, | ||
"singleQuote": true, | ||
"trailingComma": "none" | ||
"trailingComma": "none", | ||
|
||
"overrides": [ | ||
{ | ||
"files": "*.yml", | ||
"options": { | ||
"singleQuote": false | ||
} | ||
} | ||
] | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
packages/core/json-schema/src/schema/definitions/hooks/hook-schema.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"$id": "https://schema.manifest.build/definitions/hooks/hook-schema.json", | ||
"title": "Hook Schema", | ||
"description": "A hook related to an event the entity records. Doc: https://manifest.build/docs/hooks", | ||
"type": "object", | ||
|
||
"properties": { | ||
"url": { | ||
"description": "The URL to send the request to.", | ||
"type": "string" | ||
}, | ||
"method": { | ||
"type": "string", | ||
"description": "The HTTP method to use, defaults to POST.", | ||
"enum": ["GET", "POST", "PUT", "PATCH", "DELETE"] | ||
}, | ||
"headers": { | ||
"type": "object", | ||
"description": "The headers to send with the request", | ||
"additionalProperties": { | ||
"type": "string" | ||
} | ||
} | ||
}, | ||
"required": ["url"], | ||
"additionalProperties": false | ||
} |
52 changes: 52 additions & 0 deletions
52
packages/core/json-schema/src/schema/definitions/hooks/hooks-schema.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"$id": "https://schema.manifest.build/definitions/hooks/hooks-schema.json", | ||
"title": "Hooks Schema", | ||
"description": "The hooks related to events the entity records. Doc: https://manifest.build/docs/hooks", | ||
"type": "object", | ||
"properties": { | ||
"beforeCreate": { | ||
"type": "array", | ||
"description": "Hooks to run before creating a record. Doc: https://manifest.build/docs/hooks#events", | ||
"items": { | ||
"$ref": "hook-schema.json" | ||
} | ||
}, | ||
"afterCreate": { | ||
"type": "array", | ||
"description": "Hooks to run after creating a record. Doc: https://manifest.build/docs/hooks#events", | ||
"items": { | ||
"$ref": "hook-schema.json" | ||
} | ||
}, | ||
"beforeUpdate": { | ||
"type": "array", | ||
"description": "Hooks to run before updating a record. Doc: https://manifest.build/docs/hooks#events", | ||
"items": { | ||
"$ref": "hook-schema.json" | ||
} | ||
}, | ||
"afterUpdate": { | ||
"type": "array", | ||
"description": "Hooks to run after updating a record. Doc: https://manifest.build/docs/hooks#events", | ||
"items": { | ||
"$ref": "hook-schema.json" | ||
} | ||
}, | ||
"beforeDelete": { | ||
"type": "array", | ||
"description": "Hooks to run before deleting a record. Doc: https://manifest.build/docs/hooks#events", | ||
"items": { | ||
"$ref": "hook-schema.json" | ||
} | ||
}, | ||
"afterDelete": { | ||
"type": "array", | ||
"description": "Hooks to run after deleting a record. Doc: https://manifest.build/docs/hooks#events", | ||
"items": { | ||
"$ref": "hook-schema.json" | ||
} | ||
} | ||
}, | ||
"additionalProperties": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.