Skip to content

Commit

Permalink
feat: add name as a filter for ListStores (#211)
Browse files Browse the repository at this point in the history
* Add name as a filter for ListStores

* Add validation and openapi annotations

* Skip validation on empty name

* Add description
  • Loading branch information
kalleep authored Dec 17, 2024
1 parent a03cf03 commit 6e048d8
Show file tree
Hide file tree
Showing 4 changed files with 1,916 additions and 1,851 deletions.
7 changes: 7 additions & 0 deletions docs/openapiv2/apidocs.swagger.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 14 additions & 0 deletions openfga/v1/openfga_service.proto
Original file line number Diff line number Diff line change
Expand Up @@ -1796,6 +1796,20 @@ message ListStoresRequest {
(validate.rules).string.max_bytes = 5120,
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {example: "\"eyJwayI6IkxBVEVTVF9OU0NPTkZJR19hdXRoMHN0b3JlIiwic2siOiIxem1qbXF3MWZLZExTcUoyN01MdTdqTjh0cWgifQ==\""}
];

string name = 3 [
(google.api.field_behavior) = OPTIONAL,
(validate.rules).string = {
pattern: "^[a-zA-Z0-9\\s\\.\\-\\/^_&@]{3,64}$"
ignore_empty: true
},
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
example: "\"my-store-name\""
description:
"The name parameter instructs the API to only include results that match that name."
"Multiple results may be returned. Only exact matches will be returned; substring matches and regexes will not be evaluated"
}
];
}

message ListStoresResponse {
Expand Down
Loading

0 comments on commit 6e048d8

Please sign in to comment.