Skip to content

Commit

Permalink
scaffold event message
Browse files Browse the repository at this point in the history
  • Loading branch information
Max-Levitskiy committed Apr 30, 2022
1 parent 686436f commit 9a956bb
Show file tree
Hide file tree
Showing 41 changed files with 7,433 additions and 64 deletions.
305 changes: 305 additions & 0 deletions docs/static/openapi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28270,6 +28270,202 @@ paths:
additionalProperties: {}
tags:
- Query
/web-tree/story/story/event:
get:
summary: Queries a list of Event items.
operationId: WebtreeStoryStoryEventAll
responses:
'200':
description: A successful response.
schema:
type: object
properties:
Event:
type: array
items:
type: object
properties:
id:
type: string
format: uint64
giverId:
type: string
takerId:
type: string
giverSign:
type: string
takerSign:
type: string
unionId:
type: string
typeId:
type: string
body:
type: string
creator:
type: string
pagination:
type: object
properties:
next_key:
type: string
format: byte
title: |-
next_key is the key to be passed to PageRequest.key to
query the next page most efficiently
total:
type: string
format: uint64
title: >-
total is total number of results available if
PageRequest.count_total

was set, its value is undefined otherwise
description: >-
PageResponse is to be embedded in gRPC response messages where
the

corresponding request message has used PageRequest.

message SomeResponse {
repeated Bar results = 1;
PageResponse page = 2;
}
default:
description: An unexpected error response.
schema:
type: object
properties:
code:
type: integer
format: int32
message:
type: string
details:
type: array
items:
type: object
properties:
'@type':
type: string
additionalProperties: {}
parameters:
- name: pagination.key
description: |-
key is a value returned in PageResponse.next_key to begin
querying the next page most efficiently. Only one of offset or key
should be set.
in: query
required: false
type: string
format: byte
- name: pagination.offset
description: >-
offset is a numeric offset that can be used when key is unavailable.

It is less efficient than using key. Only one of offset or key
should

be set.
in: query
required: false
type: string
format: uint64
- name: pagination.limit
description: >-
limit is the total number of results to be returned in the result
page.

If left empty it will default to a value to be set by each app.
in: query
required: false
type: string
format: uint64
- name: pagination.count_total
description: >-
count_total is set to true to indicate that the result set should
include

a count of the total number of items available for pagination in
UIs.

count_total is only respected when offset is used. It is ignored
when key

is set.
in: query
required: false
type: boolean
- name: pagination.reverse
description: >-
reverse is set to true if results are to be returned in the
descending order.


Since: cosmos-sdk 0.43
in: query
required: false
type: boolean
tags:
- Query
'/web-tree/story/story/event/{id}':
get:
summary: Queries a Event by id.
operationId: WebtreeStoryStoryEvent
responses:
'200':
description: A successful response.
schema:
type: object
properties:
Event:
type: object
properties:
id:
type: string
format: uint64
giverId:
type: string
takerId:
type: string
giverSign:
type: string
takerSign:
type: string
unionId:
type: string
typeId:
type: string
body:
type: string
creator:
type: string
default:
description: An unexpected error response.
schema:
type: object
properties:
code:
type: integer
format: int32
message:
type: string
details:
type: array
items:
type: object
properties:
'@type':
type: string
additionalProperties: {}
parameters:
- name: id
in: path
required: true
type: string
format: uint64
tags:
- Query
/webtree/story/story/params:
get:
summary: Parameters queries the parameters of the module.
Expand Down Expand Up @@ -48502,9 +48698,118 @@ definitions:
title: >-
SignatureCounts contains information about signature reporting for a
number of blocks
webtree.story.story.Event:
type: object
properties:
id:
type: string
format: uint64
giverId:
type: string
takerId:
type: string
giverSign:
type: string
takerSign:
type: string
unionId:
type: string
typeId:
type: string
body:
type: string
creator:
type: string
webtree.story.story.MsgCreateEventResponse:
type: object
properties:
id:
type: string
format: uint64
webtree.story.story.MsgDeleteEventResponse:
type: object
webtree.story.story.MsgUpdateEventResponse:
type: object
webtree.story.story.Params:
type: object
description: Params defines the parameters for the module.
webtree.story.story.QueryAllEventResponse:
type: object
properties:
Event:
type: array
items:
type: object
properties:
id:
type: string
format: uint64
giverId:
type: string
takerId:
type: string
giverSign:
type: string
takerSign:
type: string
unionId:
type: string
typeId:
type: string
body:
type: string
creator:
type: string
pagination:
type: object
properties:
next_key:
type: string
format: byte
title: |-
next_key is the key to be passed to PageRequest.key to
query the next page most efficiently
total:
type: string
format: uint64
title: >-
total is total number of results available if
PageRequest.count_total

was set, its value is undefined otherwise
description: |-
PageResponse is to be embedded in gRPC response messages where the
corresponding request message has used PageRequest.

message SomeResponse {
repeated Bar results = 1;
PageResponse page = 2;
}
webtree.story.story.QueryGetEventResponse:
type: object
properties:
Event:
type: object
properties:
id:
type: string
format: uint64
giverId:
type: string
takerId:
type: string
giverSign:
type: string
takerSign:
type: string
unionId:
type: string
typeId:
type: string
body:
type: string
creator:
type: string
webtree.story.story.QueryParamsResponse:
type: object
properties:
Expand Down
16 changes: 16 additions & 0 deletions proto/story/event.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
syntax = "proto3";
package webtree.story.story;

option go_package = "github.com/web-tree/story/x/story/types";

message Event {
uint64 id = 1;
string giverId = 2;
string takerId = 3;
string giverSign = 4;
string takerSign = 5;
string unionId = 6;
string typeId = 7;
string body = 8;
string creator = 9;
}
3 changes: 3 additions & 0 deletions proto/story/genesis.proto
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package webtree.story.story;

import "gogoproto/gogo.proto";
import "story/params.proto";
import "story/event.proto";
// this line is used by starport scaffolding # genesis/proto/import

option go_package = "github.com/web-tree/story/x/story/types";
Expand All @@ -11,5 +12,7 @@ option go_package = "github.com/web-tree/story/x/story/types";
message GenesisState {
Params params = 1 [(gogoproto.nullable) = false];
string port_id = 2;
repeated Event eventList = 3 [(gogoproto.nullable) = false];
uint64 eventCount = 4;
// this line is used by starport scaffolding # genesis/proto/state
}
Loading

0 comments on commit 9a956bb

Please sign in to comment.