From c7b0d702b564a4590fba0cd00ccba581f05fed4d Mon Sep 17 00:00:00 2001 From: nickrobertson Date: Wed, 15 Oct 2025 16:35:13 -0600 Subject: [PATCH 1/2] [CORE-1855] Add created_by to the invite --- models/CreatedByUser.v1.yaml | 39 ++++++++++++++++++++++++++++++++++++ models/Invite.v1.yaml | 11 ++++++++++ models/InviteDetail.v1.yaml | 10 +++++++++ 3 files changed, 60 insertions(+) create mode 100644 models/CreatedByUser.v1.yaml diff --git a/models/CreatedByUser.v1.yaml b/models/CreatedByUser.v1.yaml new file mode 100644 index 0000000..87b3165 --- /dev/null +++ b/models/CreatedByUser.v1.yaml @@ -0,0 +1,39 @@ +title: CreatedByUser +type: object +x-examples: + default: + id: 42 + first_name: Jane + last_name: Doe + email: jane.doe@example.com + permission_bundles: + - ADMIN + - INVITES +description: User who created the invite with their permission bundles +properties: + id: + type: integer + format: int32 + description: User ID + first_name: + type: string + description: User's first name + last_name: + type: string + description: User's last name + email: + type: string + format: email + description: User's email address + permission_bundles: + type: array + description: List of permission bundle names assigned to the user + items: + type: string + example: ADMIN +required: + - id + - first_name + - last_name + - email + - permission_bundles \ No newline at end of file diff --git a/models/Invite.v1.yaml b/models/Invite.v1.yaml index 4e03777..22d1a1b 100644 --- a/models/Invite.v1.yaml +++ b/models/Invite.v1.yaml @@ -77,6 +77,14 @@ x-examples: created_at: '2018-02-10T09:30Z' updated_at: '2018-02-10T09:30Z' mobile_number: some text + created_by: + id: 42 + first_name: Jane + last_name: Doe + email: jane.doe@example.com + permission_bundles: + - ADMIN + - INVITES description: "The root of the Invite type's schema." properties: id: @@ -130,6 +138,9 @@ properties: assigned_stall: $ref: ./AssignedStall.v1.yaml nullable: true + created_by: + $ref: ./CreatedByUser.v1.yaml + nullable: true required: - id - email diff --git a/models/InviteDetail.v1.yaml b/models/InviteDetail.v1.yaml index 3d6ad0e..ede6644 100644 --- a/models/InviteDetail.v1.yaml +++ b/models/InviteDetail.v1.yaml @@ -118,6 +118,14 @@ x-examples: parking_lot_name: some text parking_lot_id: 321 parking_stall_id: 332 + created_by: + id: 42 + first_name: Jane + last_name: Doe + email: jane.doe@example.com + permission_bundles: + - ADMIN + - INVITES description: "The root of the InviteDetail type's schema." properties: id: @@ -179,6 +187,8 @@ properties: type: string assigned_stall: $ref: ./AssignedStall.v1.yaml + created_by: + $ref: ./CreatedByUser.v1.yaml required: - id - last_name From 1adb12cb7c3d47c645bf14a9748d375e375e5684 Mon Sep 17 00:00:00 2001 From: nickrobertson Date: Wed, 15 Oct 2025 16:45:24 -0600 Subject: [PATCH 2/2] add more doc --- openapi.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/openapi.yml b/openapi.yml index aaf28f2..d41f9cf 100644 --- a/openapi.yml +++ b/openapi.yml @@ -1037,6 +1037,14 @@ paths: parking_lot_name: some text parking_lot_id: 321 parking_stall_id: 332 + created_by: + id: 42 + first_name: Jane + last_name: Doe + email: jane.doe@example.com + permission_bundles: + - ADMIN + - INVITES invite_watchlist: id: 3 external_colours: @@ -2611,6 +2619,14 @@ paths: parking_lot_name: some text parking_lot_id: 321 parking_stall_id: 332 + created_by: + id: 42 + first_name: Jane + last_name: Doe + email: jane.doe@example.com + permission_bundles: + - ADMIN + - INVITES description: Successful response - returns a single `Invite`. "400": content: