-
Notifications
You must be signed in to change notification settings - Fork 9.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Callback feature #763
Callback feature #763
Conversation
@OAI/tdc for discussion today ^^ |
@@ -1050,6 +1051,36 @@ Response with no return value: | |||
description: object created | |||
``` | |||
|
|||
#### <a name="callbackObject"></a>Callback Object | |||
|
|||
A container for possible out-of band callbacks from an operation. A callback may be returned from an operation, calling back to the path specified in the operation object. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
»A callback may be returned from an operation« sounds wrong. Maybe better »A callback may be caused/triggered by an operation«?
This |
@@ -1050,6 +1051,36 @@ Response with no return value: | |||
description: object created | |||
``` | |||
|
|||
#### <a name="callbackObject"></a>Callback Object |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is called here »Callback Object«, but »Callback Responses Object« in the Operation object.
in the example, I think |
The proposal should address security considerations -- can a man in the middle or other attack alter the callback URL in the request in order to redirect sensitive data? |
@DavidBiesack I'm not sure how you think this proposal introduces any security issues? Please explain. |
@OAI/tdc please review and add your feedback. Would be great to get any other examples or feedback on this structure. |
I'm all 👍 on this. |
A few comments;
... which could allow WebHooks to be specified standalone by allowing
|
Hi @DavidBiesack github does in fact use |
One more thought; could we add an element something like; subscriptionList: '$request.body.config.events' Which uses your syntax to make it clear which element of the webhooks subscription interaction specifies the list of events required. |
This implementation doesn't seem anything like what I'm see elsewhere. I think calling things what they are in the spec, Here is an example of GitHub's Webhook documentation: https://developer.github.com/webhooks/ I realize this feedback might be a little late. |
Here is a portion of our Event Hub definition updated with this callback proposal:
|
Callback feature
Addresses #716, #735, #736, #737.
To support webhooks, a proposed
callback
mechanism is added. Essentially, callbacks are out-of-bandoperations
against some remote server. The callback subscription mechanism is not prescribed, as it is actually implementation dependent. The mechanism for responses, however, is created by added acallbacks
section to any operation.The
callbacks
section has named callbacks, which are essentially operations. The operations can be applied to a URL as extracted from therequest
options using a syntax similar to with thelinks
technique.An example below describes the GitHub webhook mechanism, with comments, for discussion.