Skip to content

Commit 0808d91

Browse files
authored
chore: switch to field access rules for makeAllPublic (#56)
* chore: switch to field access rules for makeAllPublic * chore: cleanup
1 parent 8908a18 commit 0808d91

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

protection/makeAllPublic/config.yaml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
1-
# This is a blanket way to make all endpoints public, i.e. not requiring an API Key or JWT.
1+
# This is a blanket way to make all Query fields public, i.e. not requiring an API Key or JWT.
22
# For example, you would typically do this for your product catalog queries.
3-
# Remember to test this not through the localhost proxy
4-
# that automatically sets the Apikey to be the admin key and bypasses these permissions,
5-
# but use separate a GraphQL or API client to check these.
6-
ruleset:
7-
- query: "[ALL]"
8-
rules:
9-
- predicate: true
10-
action: allow
3+
# Remember to test this through a GraphQL client that does not automatically set an api or admin key.
4+
access:
5+
policies:
6+
- type: Query
7+
policyDefault:
8+
condition: true # allow all fields in Query with no authorization

0 commit comments

Comments
 (0)