Skip to content

Commit d8dfe8e

Browse files
author
nashqueue
committed
ignite cli scaffold map wordle
1 parent f7c121b commit d8dfe8e

File tree

27 files changed

+3116
-57
lines changed

27 files changed

+3116
-57
lines changed

docs/static/openapi.yml

Lines changed: 229 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30469,6 +30469,175 @@ paths:
3046930469
additionalProperties: {}
3047030470
tags:
3047130471
- Query
30472+
/YazzyYaz/wordle/wordle/wordle:
30473+
get:
30474+
summary: Queries a list of Wordle items.
30475+
operationId: YazzyyazWordleWordleWordleAll
30476+
responses:
30477+
'200':
30478+
description: A successful response.
30479+
schema:
30480+
type: object
30481+
properties:
30482+
wordle:
30483+
type: array
30484+
items:
30485+
type: object
30486+
properties:
30487+
index:
30488+
type: string
30489+
word:
30490+
type: string
30491+
submitter:
30492+
type: string
30493+
pagination:
30494+
type: object
30495+
properties:
30496+
next_key:
30497+
type: string
30498+
format: byte
30499+
title: |-
30500+
next_key is the key to be passed to PageRequest.key to
30501+
query the next page most efficiently
30502+
total:
30503+
type: string
30504+
format: uint64
30505+
title: >-
30506+
total is total number of results available if
30507+
PageRequest.count_total
30508+
30509+
was set, its value is undefined otherwise
30510+
description: >-
30511+
PageResponse is to be embedded in gRPC response messages where
30512+
the
30513+
30514+
corresponding request message has used PageRequest.
30515+
30516+
message SomeResponse {
30517+
repeated Bar results = 1;
30518+
PageResponse page = 2;
30519+
}
30520+
default:
30521+
description: An unexpected error response.
30522+
schema:
30523+
type: object
30524+
properties:
30525+
code:
30526+
type: integer
30527+
format: int32
30528+
message:
30529+
type: string
30530+
details:
30531+
type: array
30532+
items:
30533+
type: object
30534+
properties:
30535+
'@type':
30536+
type: string
30537+
additionalProperties: {}
30538+
parameters:
30539+
- name: pagination.key
30540+
description: |-
30541+
key is a value returned in PageResponse.next_key to begin
30542+
querying the next page most efficiently. Only one of offset or key
30543+
should be set.
30544+
in: query
30545+
required: false
30546+
type: string
30547+
format: byte
30548+
- name: pagination.offset
30549+
description: >-
30550+
offset is a numeric offset that can be used when key is unavailable.
30551+
30552+
It is less efficient than using key. Only one of offset or key
30553+
should
30554+
30555+
be set.
30556+
in: query
30557+
required: false
30558+
type: string
30559+
format: uint64
30560+
- name: pagination.limit
30561+
description: >-
30562+
limit is the total number of results to be returned in the result
30563+
page.
30564+
30565+
If left empty it will default to a value to be set by each app.
30566+
in: query
30567+
required: false
30568+
type: string
30569+
format: uint64
30570+
- name: pagination.count_total
30571+
description: >-
30572+
count_total is set to true to indicate that the result set should
30573+
include
30574+
30575+
a count of the total number of items available for pagination in
30576+
UIs.
30577+
30578+
count_total is only respected when offset is used. It is ignored
30579+
when key
30580+
30581+
is set.
30582+
in: query
30583+
required: false
30584+
type: boolean
30585+
- name: pagination.reverse
30586+
description: >-
30587+
reverse is set to true if results are to be returned in the
30588+
descending order.
30589+
30590+
30591+
Since: cosmos-sdk 0.43
30592+
in: query
30593+
required: false
30594+
type: boolean
30595+
tags:
30596+
- Query
30597+
'/YazzyYaz/wordle/wordle/wordle/{index}':
30598+
get:
30599+
summary: Queries a Wordle by index.
30600+
operationId: YazzyyazWordleWordleWordle
30601+
responses:
30602+
'200':
30603+
description: A successful response.
30604+
schema:
30605+
type: object
30606+
properties:
30607+
wordle:
30608+
type: object
30609+
properties:
30610+
index:
30611+
type: string
30612+
word:
30613+
type: string
30614+
submitter:
30615+
type: string
30616+
default:
30617+
description: An unexpected error response.
30618+
schema:
30619+
type: object
30620+
properties:
30621+
code:
30622+
type: integer
30623+
format: int32
30624+
message:
30625+
type: string
30626+
details:
30627+
type: array
30628+
items:
30629+
type: object
30630+
properties:
30631+
'@type':
30632+
type: string
30633+
additionalProperties: {}
30634+
parameters:
30635+
- name: index
30636+
in: path
30637+
required: true
30638+
type: string
30639+
tags:
30640+
- Query
3047230641
definitions:
3047330642
cosmos.auth.v1beta1.Params:
3047430643
type: object
@@ -51934,10 +52103,70 @@ definitions:
5193452103
yazzyyaz.wordle.wordle.Params:
5193552104
type: object
5193652105
description: Params defines the parameters for the module.
52106+
yazzyyaz.wordle.wordle.QueryAllWordleResponse:
52107+
type: object
52108+
properties:
52109+
wordle:
52110+
type: array
52111+
items:
52112+
type: object
52113+
properties:
52114+
index:
52115+
type: string
52116+
word:
52117+
type: string
52118+
submitter:
52119+
type: string
52120+
pagination:
52121+
type: object
52122+
properties:
52123+
next_key:
52124+
type: string
52125+
format: byte
52126+
title: |-
52127+
next_key is the key to be passed to PageRequest.key to
52128+
query the next page most efficiently
52129+
total:
52130+
type: string
52131+
format: uint64
52132+
title: >-
52133+
total is total number of results available if
52134+
PageRequest.count_total
52135+
52136+
was set, its value is undefined otherwise
52137+
description: |-
52138+
PageResponse is to be embedded in gRPC response messages where the
52139+
corresponding request message has used PageRequest.
52140+
52141+
message SomeResponse {
52142+
repeated Bar results = 1;
52143+
PageResponse page = 2;
52144+
}
52145+
yazzyyaz.wordle.wordle.QueryGetWordleResponse:
52146+
type: object
52147+
properties:
52148+
wordle:
52149+
type: object
52150+
properties:
52151+
index:
52152+
type: string
52153+
word:
52154+
type: string
52155+
submitter:
52156+
type: string
5193752157
yazzyyaz.wordle.wordle.QueryParamsResponse:
5193852158
type: object
5193952159
properties:
5194052160
params:
5194152161
description: params holds all the parameters of this module.
5194252162
type: object
5194352163
description: QueryParamsResponse is response type for the Query/Params RPC method.
52164+
yazzyyaz.wordle.wordle.Wordle:
52165+
type: object
52166+
properties:
52167+
index:
52168+
type: string
52169+
word:
52170+
type: string
52171+
submitter:
52172+
type: string

proto/wordle/genesis.proto

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,14 @@ package yazzyyaz.wordle.wordle;
33

44
import "gogoproto/gogo.proto";
55
import "wordle/params.proto";
6+
import "wordle/wordle.proto";
67
// this line is used by starport scaffolding # genesis/proto/import
78

89
option go_package = "github.com/YazzyYaz/wordle/x/wordle/types";
910

1011
// GenesisState defines the wordle module's genesis state.
1112
message GenesisState {
1213
Params params = 1 [(gogoproto.nullable) = false];
14+
repeated Wordle wordleList = 2 [(gogoproto.nullable) = false];
1315
// this line is used by starport scaffolding # genesis/proto/state
1416
}

proto/wordle/query.proto

Lines changed: 30 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import "gogoproto/gogo.proto";
55
import "google/api/annotations.proto";
66
import "cosmos/base/query/v1beta1/pagination.proto";
77
import "wordle/params.proto";
8+
import "wordle/wordle.proto";
89
// this line is used by starport scaffolding # 1
910

1011
option go_package = "github.com/YazzyYaz/wordle/x/wordle/types";
@@ -15,7 +16,17 @@ service Query {
1516
rpc Params(QueryParamsRequest) returns (QueryParamsResponse) {
1617
option (google.api.http).get = "/YazzyYaz/wordle/wordle/params";
1718
}
18-
// this line is used by starport scaffolding # 2
19+
// Queries a Wordle by index.
20+
rpc Wordle(QueryGetWordleRequest) returns (QueryGetWordleResponse) {
21+
option (google.api.http).get = "/YazzyYaz/wordle/wordle/wordle/{index}";
22+
}
23+
24+
// Queries a list of Wordle items.
25+
rpc WordleAll(QueryAllWordleRequest) returns (QueryAllWordleResponse) {
26+
option (google.api.http).get = "/YazzyYaz/wordle/wordle/wordle";
27+
}
28+
29+
// this line is used by starport scaffolding # 2
1930
}
2031

2132
// QueryParamsRequest is request type for the Query/Params RPC method.
@@ -27,4 +38,22 @@ message QueryParamsResponse {
2738
Params params = 1 [(gogoproto.nullable) = false];
2839
}
2940

41+
message QueryGetWordleRequest {
42+
string index = 1;
43+
44+
}
45+
46+
message QueryGetWordleResponse {
47+
Wordle wordle = 1 [(gogoproto.nullable) = false];
48+
}
49+
50+
message QueryAllWordleRequest {
51+
cosmos.base.query.v1beta1.PageRequest pagination = 1;
52+
}
53+
54+
message QueryAllWordleResponse {
55+
repeated Wordle wordle = 1 [(gogoproto.nullable) = false];
56+
cosmos.base.query.v1beta1.PageResponse pagination = 2;
57+
}
58+
3059
// this line is used by starport scaffolding # 3

proto/wordle/wordle.proto

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
syntax = "proto3";
2+
package yazzyyaz.wordle.wordle;
3+
4+
option go_package = "github.com/YazzyYaz/wordle/x/wordle/types";
5+
6+
message Wordle {
7+
string index = 1;
8+
string word = 2;
9+
string submitter = 3;
10+
11+
}
12+

0 commit comments

Comments
 (0)