-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
17 changed files
with
312 additions
and
103 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
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
File renamed without changes.
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
40 changes: 40 additions & 0 deletions
40
src/compiler/cli/src/commonTest/resources/wirespec/todo.ws
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,40 @@ | ||
endpoint GetTodos GET /todos ? {done: Boolean?} -> { | ||
200 -> Todo[] | ||
404 -> Error | ||
} | ||
|
||
endpoint CreateTodo POST TodoInput /todos -> { | ||
200 -> Todo | ||
404 -> Error | ||
} | ||
|
||
endpoint GetTodoById GET /todos/{id: String} -> { | ||
200 -> Todo | ||
404 -> Error | ||
} | ||
|
||
endpoint UpdateTodo PUT TodoInput /todos/{id: String} -> { | ||
200 -> Todo | ||
404 -> Error | ||
} | ||
|
||
endpoint DeleteTodo DELETE /todos/{id: String} -> { | ||
200 -> Todo | ||
404 -> Error | ||
} | ||
|
||
type Todo { | ||
id: String, | ||
name: String, | ||
done: Boolean | ||
} | ||
|
||
type TodoInput { | ||
name: String, | ||
done: Boolean | ||
} | ||
|
||
type Error { | ||
code: String, | ||
description: String? | ||
} |
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.