看起来最好的选择(到目前为止只有我能找到)是创建修改原件,然后添加第二个。最后,添加一个新action-endpoint
的endpoints
.
ReadBook删除了可选行
action (ReadBook) {
description ("Read a page from a book (first if page isn't provided)."")
type (Calculation)
collect {
input (book) {
type (Book)
min (Required) max (One)
}
input (page) {
type (PageNum)
min (Optional) max (One)
}
}
output (Passage)
}
ReadBookLine需要所有输入
action (ReadBookLine) {
description (Read a line from a book.)
type (Calculation)
collect {
input (book) {
type (Book)
min (Required) max (One)
}
input (page) {
type (PageNum)
min (Required) max (One)
}
input (line) {
type (LineNum)
min (Required) max (One)
}
}
output (Passage)
}
端点
endpoints {
action-endpoint (ReadBook) {
accepted-inputs (book, page)
remote-endpoint ("https://.../read_book) {
method (POST)
}
}
action-endpoint (ReadBookLine) {
accepted-inputs (book, page, line)
remote-endpoint ("https://.../read_book") {
method (POST)
}
}
}
}