Skip to content

Commit 2f38058

Browse files
authored
Add type as required property in source object of webhook (#103)
In the Messaging API webhook, we use `discriminator` to differentiate classes based on the value of `type`. During the development of bot SDK for Ruby v2, it seems that only `Source` does not have `type` marked as required. This is simply a mistake. The type should always be included to distinguish the kind of JSON, and there should not be any instances where it is absent.
1 parent 31fa3c7 commit 2f38058

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

webhook.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,8 @@ components:
136136
externalDocs:
137137
url: https://developers.line.biz/en/reference/messaging-api/#source-user
138138
description: "the source of the event."
139+
required:
140+
- type
139141
type: object
140142
properties:
141143
type:

0 commit comments

Comments
 (0)