Skip to content

Commit

Permalink
Add ageVerificationSlotsAvailable, Improve ageVerificationStatus (#420)
Browse files Browse the repository at this point in the history
* Add ageVerificationSlotsAvailable, Improve ageVerificationStatus

* deduplicate schema

* Add Group Permissions Enum

* add ageVerificationBetaCode, add ageVerificationBetaSlots

* Update openapi/components/schemas/AgeVerificationStatus.yaml

Co-authored-by: Lars Olzem <hackebein@gmail.com>

---------

Co-authored-by: Aries <me@ariesclark.com>
  • Loading branch information
Hackebein and ariesclark authored Dec 17, 2024
1 parent 1b35761 commit 457ca88
Show file tree
Hide file tree
Showing 9 changed files with 51 additions and 15 deletions.
4 changes: 1 addition & 3 deletions openapi/components/requests/CreateGroupRoleRequest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ properties:
type: boolean
default: false
permissions:
type: array
items:
type: string
$ref: ../schemas/GroupPermissions.yaml


4 changes: 1 addition & 3 deletions openapi/components/requests/UpdateGroupRoleRequest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ properties:
type: boolean
default: false
permissions:
type: array
items:
type: string
$ref: ../schemas/GroupPermissions.yaml
order:
type: integer
10 changes: 10 additions & 0 deletions openapi/components/schemas/AgeVerificationStatus.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
title: AgeVerificationStatus
type: string
enum:
- hidden
- verified
- 18+
x-enum-varnames:
- hidden
- verified
- plus18
2 changes: 1 addition & 1 deletion openapi/components/schemas/CurrentUser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ properties:
items:
$ref: ./UserID.yaml
ageVerificationStatus:
type: string
$ref: ./AgeVerificationStatus.yaml
ageVerified:
type: boolean
allowAvatarCopying:
Expand Down
8 changes: 8 additions & 0 deletions openapi/components/schemas/Group.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
title: Group
type: object
properties:
ageVerificationSlotsAvailable:
type: boolean
ageVerificationBetaCode:
type: string
example: abc1234
ageVerificationBetaSlots:
type: number
example: 500
badges:
type: array
items:
Expand Down
5 changes: 1 addition & 4 deletions openapi/components/schemas/GroupMyMember.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,4 @@ properties:
items:
type: string
permissions:
type: array
items:
type: string
example: group-instance-join
$ref: ./GroupPermissions.yaml
27 changes: 27 additions & 0 deletions openapi/components/schemas/GroupPermissions.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
type: array
items:
type: string
enum:
- group-announcement-manage
- group-audit-view
- group-bans-manage
- group-data-manage
- group-default-role-manage
- group-galleries-manage
- group-instance-age-gated-create
- group-instance-join
- group-instance-manage
- group-instance-moderate
- group-instance-open-create
- group-instance-plus-create
- group-instance-plus-portal
- group-instance-plus-portal-unlocked
- group-instance-public-create
- group-instance-queue-priority
- group-instance-restricted-create
- group-invites-manage
- group-members-manage
- group-members-remove
- group-members-viewall
- group-roles-assign
- group-roles-manage
4 changes: 1 addition & 3 deletions openapi/components/schemas/GroupRole.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,7 @@ properties:
type: boolean
default: false
permissions:
type: array
items:
type: string
$ref: ./GroupPermissions.yaml
isManagementRole:
type: boolean
default: false
Expand Down
2 changes: 1 addition & 1 deletion openapi/components/schemas/User.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ title: User
type: object
properties:
ageVerificationStatus:
type: string
$ref: ./AgeVerificationStatus.yaml
allowAvatarCopying:
type: boolean
default: true
Expand Down

0 comments on commit 457ca88

Please sign in to comment.