From e902bd7a817dcab852f4fa25a0e035d7e7683ce8 Mon Sep 17 00:00:00 2001 From: Kirti Gautam <53394284+KirtiGautam@users.noreply.github.com> Date: Mon, 8 Dec 2025 15:10:54 +0530 Subject: [PATCH 001/107] feat: Docs for POST /admin/reminders/stats (#757) --- reference/admin.yaml | 80 ++++++++++++++++++++++ src/admin/openapi.yaml | 2 + src/admin/paths/admin@reminders@stats.yaml | 54 +++++++++++++++ src/components/schemas/fields.yaml | 4 ++ src/components/schemas/reminder.yaml | 26 ++++++- 5 files changed, 165 insertions(+), 1 deletion(-) create mode 100644 src/admin/paths/admin@reminders@stats.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 5f7924127..08e1bdebe 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -5243,6 +5243,61 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/reminders/stats: + post: + tags: + - Reminders + summary: Reminders Stats + description: | + Reminders Stats + operationId: reminders_stats + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/reminders_stats_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/reminders_stats_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/reports: get: tags: @@ -19746,6 +19801,10 @@ components: - CONNECT_MASTERCARD_RTF - PROCESS_REPORTS - VERIFY_REPORTS + - ADD_BANK_ACCOUNT_EMPLOYEES + - COMPLETE_EXPENSES + - RESUBMIT_REPORTS + - SMS_OPT_IN maxLength: 255 description: Represents the type of reminder. example: FYLE_EXPENSES @@ -19908,6 +19967,27 @@ components: description: | ID of the reminder that needs to be deleted. example: remindNZgN7V5pft + reminders_stats_in: + properties: + query_params: + type: string + description: | + Query param string similar to reminders GET call. + nullable: false + example: id=in.('remind123','remind1234') + reminders_stats_out: + type: array + items: + type: object + properties: + last_reminded_at: + type: string + format: date-time + nullable: true + description: Signifies the time when this reminder was sent. In case of scheduled reminders, signifies when the last reminder was sent. Date-time in [ISO8601 format](https://xml2rfc.tools.ietf.org/public/rfc/html/rfc3339.html#anchor14). + example: '2021-06-01T13:14:54.804+00:00' + type: + $ref: '#/components/schemas/reminder_type' employee_out_embed_for_report: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 1d4d40611..88844cb52 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -291,6 +291,8 @@ paths: $ref: paths/admin@reminders.yaml /admin/reminders/delete: $ref: paths/admin@reminders@delete.yaml + /admin/reminders/stats: + $ref: paths/admin@reminders@stats.yaml /admin/reports: $ref: paths/admin@reports.yaml /admin/reports/eject_expenses: diff --git a/src/admin/paths/admin@reminders@stats.yaml b/src/admin/paths/admin@reminders@stats.yaml new file mode 100644 index 000000000..3cca816f3 --- /dev/null +++ b/src/admin/paths/admin@reminders@stats.yaml @@ -0,0 +1,54 @@ +post: + tags: + - Reminders + summary: Reminders Stats + description: | + Reminders Stats + operationId: reminders_stats + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: '../../components/schemas/reminder.yaml#/reminders_stats_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + properties: + data: + $ref: '../../components/schemas/reminder.yaml#/reminders_stats_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: ../../components/schemas/401.yaml + '403': + description: Forbidden + content: + application/json: + schema: + $ref: ../../components/schemas/403.yaml + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' \ No newline at end of file diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index fa57f1f89..8387c7e4e 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1297,6 +1297,10 @@ reminder_type: - CONNECT_MASTERCARD_RTF - PROCESS_REPORTS - VERIFY_REPORTS + - ADD_BANK_ACCOUNT_EMPLOYEES + - COMPLETE_EXPENSES + - RESUBMIT_REPORTS + - SMS_OPT_IN maxLength: 255 description: Represents the type of reminder. example: FYLE_EXPENSES diff --git a/src/components/schemas/reminder.yaml b/src/components/schemas/reminder.yaml index 6255fcf2b..7d1d36f03 100644 --- a/src/components/schemas/reminder.yaml +++ b/src/components/schemas/reminder.yaml @@ -88,4 +88,28 @@ reminder_delete_in: maxLength: 20 description: | ID of the reminder that needs to be deleted. - example: 'remindNZgN7V5pft' \ No newline at end of file + example: 'remindNZgN7V5pft' + +reminders_stats_in: + properties: + query_params: + type: string + description: | + Query param string similar to reminders GET call. + nullable: false + example: id=in.('remind123','remind1234') + +reminders_stats_out: + type: array + items: + type: object + properties: + last_reminded_at: + type: string + format: date-time + nullable: True + description: + Signifies the time when this reminder was sent. In case of scheduled reminders, signifies when the last reminder was sent. Date-time in [ISO8601 format](https://xml2rfc.tools.ietf.org/public/rfc/html/rfc3339.html#anchor14). + example: '2021-06-01T13:14:54.804+00:00' + type: + $ref: './fields.yaml#/reminder_type' \ No newline at end of file From 38c1608b62462d045def6a718ab819cb41e6a0dc Mon Sep 17 00:00:00 2001 From: Kirti Gautam <53394284+KirtiGautam@users.noreply.github.com> Date: Wed, 10 Dec 2025 15:22:11 +0530 Subject: [PATCH 002/107] feat: Docs for POST admin/employees/stats (#759) --- reference/admin.yaml | 78 ++++++++++++++++++++++ src/admin/openapi.yaml | 2 + src/admin/paths/admin@employees@stats.yaml | 54 +++++++++++++++ src/components/schemas/employee.yaml | 27 +++++++- 4 files changed, 160 insertions(+), 1 deletion(-) create mode 100644 src/admin/paths/admin@employees@stats.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 08e1bdebe..9294968ce 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -1781,6 +1781,61 @@ paths: application/json: schema: $ref: '#/components/schemas/401' + /admin/employees/stats: + post: + tags: + - Employees + summary: Employees Stats + description: | + Employees Stats + operationId: employees_stats + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/employees_stats_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/employees_stats_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/employees/potential_duplicate_expenses: get: tags: @@ -15255,6 +15310,29 @@ components: $ref: '#/components/schemas/category_out_embed' description: | List of categories that this employee is allowed to access. + employees_stats_in: + type: object + required: + - query_params + properties: + query_params: + type: string + description: | + Query param string similar to employees GET call. + example: id=in.('emp123','emp1234') + employees_stats_out: + type: array + additionalProperties: false + items: + type: object + additionalProperties: false + properties: + role: + $ref: '#/components/schemas/role' + count: + type: integer + description: Count of employees with the given role + example: 10 expense_duplicate_sets_out: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 88844cb52..971284d39 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -191,6 +191,8 @@ paths: $ref: paths/admin@levels.yaml /admin/employees: $ref: paths/admin@employees.yaml + /admin/employees/stats: + $ref: paths/admin@employees@stats.yaml /admin/employees/potential_duplicate_expenses: $ref: paths/admin@employees@potential_duplicate_expenses.yaml /admin/employees/business_units: diff --git a/src/admin/paths/admin@employees@stats.yaml b/src/admin/paths/admin@employees@stats.yaml new file mode 100644 index 000000000..bebfd19ae --- /dev/null +++ b/src/admin/paths/admin@employees@stats.yaml @@ -0,0 +1,54 @@ +post: + tags: + - Employees + summary: Employees Stats + description: | + Employees Stats + operationId: employees_stats + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: '../../components/schemas/employee.yaml#/employees_stats_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + properties: + data: + $ref: '../../components/schemas/employee.yaml#/employees_stats_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: ../../components/schemas/401.yaml + '403': + description: Forbidden + content: + application/json: + schema: + $ref: ../../components/schemas/403.yaml + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' \ No newline at end of file diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index a2f62245b..a8f54b335 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -1314,4 +1314,29 @@ employee_change_primary_org_in: - $ref: './fields.yaml#/id_string' example: ouabcdefghij required: - - target_org_id \ No newline at end of file + - target_org_id + +employees_stats_in: + type: object + required: + - query_params + properties: + query_params: + type: string + description: | + Query param string similar to employees GET call. + example: id=in.('emp123','emp1234') + +employees_stats_out: + type: array + additionalProperties: false + items: + type: object + additionalProperties: false + properties: + role: + $ref: ./fields.yaml#/role + count: + type: integer + description: Count of employees with the given role + example: 10 From d007a47871d39172d6d010544e0a25cd5d1bf897 Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Thu, 11 Dec 2025 11:45:51 +0530 Subject: [PATCH 003/107] feat: add budget visibility and user_ids to schema (#758) * add budget visibility and user_ids to schema * Auto generate API docs --- reference/admin.yaml | 30 ++++++++++++++++++++++++++++++ src/components/schemas/budget.yaml | 6 ++++++ src/components/schemas/fields.yaml | 23 +++++++++++++++++++++++ 3 files changed, 59 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 9294968ce..fb26867da 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -25821,6 +25821,15 @@ components: description: | Type of budgets example: WEEKLY + budget_visibility: + type: string + enum: + - ONLY_ADMINS + - SPECIFIC_EMPLOYEES + - ALL_CONTRIBUTING_EMPLOYEES + description: | + Visibility of the budget + example: ONLY_ADMINS budget_out: type: object additionalProperties: false @@ -25935,6 +25944,23 @@ components: nullable: true example: 50 description: Utilisation percentage of the budget interval + visibility: + $ref: '#/components/schemas/budget_visibility' + budget_user_ids: + type: array + nullable: true + items: + type: string + nullable: true + maxLength: 15 + description: | + This id is provided by Sage Exp Mgmt to identify an object. + example: uswoirwlwwg + example: + - uswoirwlwwg + - uswlgwkgw42 + description: | + List of IDs of users who are associated with the budget. budget_in: type: object required: @@ -26016,6 +26042,10 @@ components: description: Month number of start of fisical year minimum: 1 maximum: 12 + visibility: + $ref: '#/components/schemas/budget_visibility' + user_ids: + $ref: '#/components/schemas/budget_user_ids' budget_out_embed: type: object additionalProperties: false diff --git a/src/components/schemas/budget.yaml b/src/components/schemas/budget.yaml index 8ee0c8456..e18db2ff9 100644 --- a/src/components/schemas/budget.yaml +++ b/src/components/schemas/budget.yaml @@ -71,6 +71,10 @@ budget_in: description: Month number of start of fisical year minimum: 1 maximum: 12 + visibility: + $ref: ./fields.yaml#/budget_visibility + user_ids: + $ref: ./fields.yaml#/budget_user_ids budget_out: @@ -179,6 +183,8 @@ budget_out: nullable: true example: 50 description: Utilisation percentage of the budget interval + visibility: + $ref: ./fields.yaml#/budget_visibility budget_out_embed: type: object diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index 8387c7e4e..aca92edd1 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1236,6 +1236,29 @@ budget_type: Type of budgets example: WEEKLY +budget_visibility: + type: string + enum: + - ONLY_ADMINS + - SPECIFIC_EMPLOYEES + - ALL_CONTRIBUTING_EMPLOYEES + description: | + Visibility of the budget + example: ONLY_ADMINS + +budget_user_ids: + type: array + nullable: True + items: + type: string + nullable: True + maxLength: 15 + description: | + This id is provided by Sage Exp Mgmt to identify an object. + example: 'uswoirwlwwg' + example: [ 'uswoirwlwwg', 'uswlgwkgw42' ] + description: | + List of IDs of users who are associated with the budget. restricted_spender_user_ids: type: array From 7045cbe9bd7d6033dc93b28260b67d39caab033d Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Thu, 18 Dec 2025 13:00:39 +0530 Subject: [PATCH 004/107] feat: spender budgets api (#761) * spender budgets api * Auto generate API docs --- reference/spender.yaml | 251 +++++++++++++++++++++---- src/spender/openapi.yaml | 5 + src/spender/paths/spender@budgets.yaml | 46 +++++ 3 files changed, 270 insertions(+), 32 deletions(-) create mode 100644 src/spender/paths/spender@budgets.yaml diff --git a/reference/spender.yaml b/reference/spender.yaml index 5cd647968..10cab1d5f 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -20,6 +20,9 @@ tags: - name: Advances description: | This API gives you access to view your Cash Advances data. + - name: Budgets + description: | + This API gives you access to view budgets that are visible to you based on budget visibility settings. - name: Automations description: | This API gives you access to organisation's automations data. @@ -91,6 +94,52 @@ tags: description: | These APIs gives you access to manage Dwolla customer data. paths: + /spender/budgets: + get: + tags: + - Budgets + summary: List budgets + operationId: budgets_list + description: | + This API returns budgets that are visible to the spender based on budget visibility settings. + Budgets are filtered based on the user's presence in the budget_user_visibility table. + + This API supports very rich filtering on all response fields and pagination via query parameters. + To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + $ref: '#/components/schemas/count' + offset: + $ref: '#/components/schemas/offset' + data: + type: array + items: + $ref: '#/components/schemas/budget_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /spender/projects: get: tags: @@ -7276,11 +7325,12 @@ components: The second request will have offset as 200 and limit as 200 to return next 200 objects.
type: integer example: 10 - id_integer: - type: integer + id_string: + type: string + maxLength: 15 description: | This id is provided by Sage Exp Mgmt to identify an object. - example: 1234 + example: sdfd2391 org_id: type: string description: | @@ -7299,6 +7349,172 @@ components: description: | Signifies when this object was updated in [ISO8601 format](https://xml2rfc.tools.ietf.org/public/rfc/html/rfc3339.html#anchor14). example: '2020-06-11T13:14:55.201598+00:00' + is_enabled: + type: boolean + description: | + This indicates if the resource is enabled for use within the organisation. + example: true + name: + type: string + maxLength: 255 + description: | + This represents the name of the resource. This should be unique in an organization + example: foo123 + budget_type: + nullable: false + type: string + enum: + - WEEKLY + - MONTHLY + - QUARTERLY + - HALF_YEARLY + - YEARLY + - ONE_TIME + description: | + Type of budgets + example: WEEKLY + amount: + type: number + description: | + amount of money + example: 47.99 + id_integer: + type: integer + description: | + This id is provided by Sage Exp Mgmt to identify an object. + example: 1234 + email: + type: string + maxLength: 127 + example: john.doe@example.com + description: | + An immutable field that represents the email address of the employee. + Must be compliant with RFC 822. + budget_visibility: + type: string + enum: + - ONLY_ADMINS + - SPECIFIC_EMPLOYEES + - ALL_CONTRIBUTING_EMPLOYEES + description: | + Visibility of the budget + example: ONLY_ADMINS + budget_out: + type: object + additionalProperties: false + properties: + id: + $ref: '#/components/schemas/id_string' + org_id: + $ref: '#/components/schemas/org_id' + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' + is_enabled: + $ref: '#/components/schemas/is_enabled' + name: + allOf: + - $ref: '#/components/schemas/name' + example: Sales + type: + $ref: '#/components/schemas/budget_type' + amount_limit: + $ref: '#/components/schemas/amount' + alert_threshold: + nullable: true + type: number + example: 5000 + department_ids: + type: array + items: + $ref: '#/components/schemas/id_string' + example: + - 2222 + - 1221 + description: | + List of department ids + project_ids: + type: array + items: + $ref: '#/components/schemas/id_integer' + example: + - 2222 + - 1221 + description: | + List of project ids + cost_center_ids: + type: array + items: + $ref: '#/components/schemas/id_integer' + example: + - 2222 + - 1221 + description: | + List of cost center ids + category_ids: + type: array + items: + $ref: '#/components/schemas/id_integer' + example: + - 2222 + - 1221 + description: | + List of category ids + observer_ids: + type: array + items: + $ref: '#/components/schemas/id_string' + example: + - usge49ielgel + fiscal_year_start_month: + type: number + example: 10 + description: Month number of start of fiscal year + minimum: 1 + maximum: 12 + budget_start_date: + type: string + nullable: true + format: date-time + example: '2022-04-01T00:00:00+00:00' + description: Start date of the current budget interval + budget_end_date: + type: string + nullable: true + format: date-time + example: '2022-04-30T00:00:00+00:00' + description: End date of the current budget interval + budget_creator: + type: object + properties: + id: + $ref: '#/components/schemas/id_string' + name: + $ref: '#/components/schemas/name' + email: + $ref: '#/components/schemas/email' + example: + id: usq8rwZj2POy + name: John Brown + email: admin1@company.com + amount_spent: + type: number + nullable: true + example: 5000 + description: Amount spent from the budget interval + amount_remaining: + type: number + nullable: true + example: 5000 + description: Amount remaining in the budget interval + utilisation_percentage: + type: number + nullable: true + example: 50 + description: Utilisation percentage of the budget interval + visibility: + $ref: '#/components/schemas/budget_visibility' code: type: string nullable: true @@ -7313,11 +7529,6 @@ components: description: | This represents the description of the resource. example: Win the trophy - is_enabled: - type: boolean - description: | - This indicates if the resource is enabled for use within the organisation. - example: true project_out: type: object additionalProperties: false @@ -7620,19 +7831,6 @@ components: example: example.com currency: $ref: '#/components/schemas/currency' - id_string: - type: string - maxLength: 15 - description: | - This id is provided by Sage Exp Mgmt to identify an object. - example: sdfd2391 - email: - type: string - maxLength: 127 - example: john.doe@example.com - description: | - An immutable field that represents the email address of the employee. - Must be compliant with RFC 822. user_out_embed: type: object additionalProperties: false @@ -7800,12 +7998,6 @@ components: This id is provided by Sage Exp Mgmt to identify a category. nullable: true example: 49058 - name: - type: string - maxLength: 255 - description: | - This represents the name of the resource. This should be unique in an organization - example: foo123 department_head_user_ids: type: array nullable: false @@ -8140,11 +8332,6 @@ components: example: cf1: string1 custom_field_2: Value 2 - amount: - type: number - description: | - amount of money - example: 47.99 report_approval_out_embed: type: object additionalProperties: false diff --git a/src/spender/openapi.yaml b/src/spender/openapi.yaml index 8f5ff6952..3bf6df27b 100644 --- a/src/spender/openapi.yaml +++ b/src/spender/openapi.yaml @@ -32,6 +32,9 @@ tags: - name: Advances description: | This API gives you access to view your Cash Advances data. + - name: Budgets + description: | + This API gives you access to view budgets that are visible to you based on budget visibility settings. - name: Automations description: | This API gives you access to organisation's automations data. @@ -110,6 +113,8 @@ tags: # Creates a file. paths: + /spender/budgets: + $ref: 'paths/spender@budgets.yaml' /spender/projects: $ref: 'paths/spender@projects.yaml' /spender/cost_centers: diff --git a/src/spender/paths/spender@budgets.yaml b/src/spender/paths/spender@budgets.yaml new file mode 100644 index 000000000..a53a3d723 --- /dev/null +++ b/src/spender/paths/spender@budgets.yaml @@ -0,0 +1,46 @@ +get: + tags: + - Budgets + summary: List budgets + operationId: budgets_list + description: | + This API returns budgets that are visible to the spender based on budget visibility settings. + Budgets are filtered based on the user's presence in the budget_user_visibility table. + + This API supports very rich filtering on all response fields and pagination via query parameters. + To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + $ref: '../../components/schemas/count.yaml' + offset: + $ref: '../../components/schemas/offset.yaml' + data: + type: array + items: + $ref: '../../components/schemas/budget.yaml#/budget_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + From c2a35e5be38bc726b617f748b5af3bf295087cd6 Mon Sep 17 00:00:00 2001 From: Devadathan M B <84301852+devadathanmb@users.noreply.github.com> Date: Mon, 22 Dec 2025 23:17:30 +0530 Subject: [PATCH 005/107] feat: Add spec for `POST /expenses/permissions/bulk` API (#760) --- reference/admin.yaml | 122 ++++++++++++++++++ reference/approver.yaml | 122 ++++++++++++++++++ reference/spender.yaml | 122 ++++++++++++++++++ src/admin/openapi.yaml | 2 + .../admin@expenses@permissions@bulk.yaml | 87 +++++++++++++ src/approver/openapi.yaml | 2 + .../approver@expenses@permissions@bulk.yaml | 87 +++++++++++++ src/components/schemas/expense.yaml | 36 ++++++ src/spender/openapi.yaml | 2 + .../spender@expenses@permissions@bulk.yaml | 87 +++++++++++++ 10 files changed, 669 insertions(+) create mode 100644 src/admin/paths/admin@expenses@permissions@bulk.yaml create mode 100644 src/approver/paths/approver@expenses@permissions@bulk.yaml create mode 100644 src/spender/paths/spender@expenses@permissions@bulk.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index fb26867da..4bd6552df 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -4272,6 +4272,94 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/expenses/permissions/bulk: + post: + tags: + - Expenses + - Expense permissions + - Permissions + summary: Bulk Expense Permissions + description: | + Returns the permissions that the principal user can perform on the given expenses, calculated based on the admin role. + + **Note:** Maximum 200 expenses per API call. + operationId: bulk_expense_permissions + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - data + properties: + data: + $ref: '#/components/schemas/expense_permissions_bulk_in' + example: + data: + - id: txAcczJOQHGR + - id: txCG82pa4yQQ + - id: txuiMc5kJbK4 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/expense_permissions_bulk_out' + example: + data: + - id: txAcczJOQHGR + can_delete: false + can_edit: true + can_verify: false + can_remove_from_report: true + can_add_to_report: false + can_assign: false + - id: txCG82pa4yQQ + can_delete: true + can_edit: true + can_verify: false + can_remove_from_report: false + can_add_to_report: true + can_assign: true + - id: txuiMc5kJbK4 + can_delete: false + can_edit: false + can_verify: true + can_remove_from_report: false + can_add_to_report: false + can_assign: false + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '#/components/schemas/bulk_error' + - $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/expenses/merge: post: tags: @@ -18852,6 +18940,40 @@ components: description: | Indicates whether the user has permission to add this expense to a report. example: true + expense_permissions_bulk_in: + type: array + maxItems: 200 + description: | + Array of expense IDs to check permissions for (maximum 200 expenses per request). + items: + type: object + required: + - id + additionalProperties: false + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + description: | + Expense ID of the expense to check permissions for. + example: txAcczJOQHGR + expense_permissions_bulk_out: + type: array + description: | + Array of permission objects for each expense. Each object corresponds to an expense from the request. + items: + allOf: + - type: object + required: + - id + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + description: | + Expense ID + example: txAcczJOQHGR + - $ref: '#/components/schemas/expense_permissions_out' target_expense_fields: type: object additionalProperties: false diff --git a/reference/approver.yaml b/reference/approver.yaml index f4b1cfcf1..6705fe447 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -629,6 +629,94 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /approver/expenses/permissions/bulk: + post: + tags: + - Expenses + - Expense permissions + - Permissions + summary: Bulk Expense Permissions + description: | + Returns the permissions that the principal user can perform on the given expenses, calculated based on the approver role. + + **Note:** Maximum 200 expenses per API call. + operationId: bulk_expense_permissions + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - data + properties: + data: + $ref: '#/components/schemas/expense_permissions_bulk_in' + example: + data: + - id: txAcczJOQHGR + - id: txCG82pa4yQQ + - id: txuiMc5kJbK4 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/expense_permissions_bulk_out' + example: + data: + - id: txAcczJOQHGR + can_delete: false + can_edit: true + can_verify: false + can_remove_from_report: true + can_add_to_report: false + can_assign: false + - id: txCG82pa4yQQ + can_delete: true + can_edit: true + can_verify: false + can_remove_from_report: false + can_add_to_report: true + can_assign: true + - id: txuiMc5kJbK4 + can_delete: false + can_edit: false + can_verify: true + can_remove_from_report: false + can_add_to_report: false + can_assign: false + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '#/components/schemas/bulk_error' + - $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /approver/reports/eject_expenses: post: tags: @@ -6676,6 +6764,40 @@ components: description: | Indicates whether the user has permission to add this expense to a report. example: true + expense_permissions_bulk_in: + type: array + maxItems: 200 + description: | + Array of expense IDs to check permissions for (maximum 200 expenses per request). + items: + type: object + required: + - id + additionalProperties: false + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + description: | + Expense ID of the expense to check permissions for. + example: txAcczJOQHGR + expense_permissions_bulk_out: + type: array + description: | + Array of permission objects for each expense. Each object corresponds to an expense from the request. + items: + allOf: + - type: object + required: + - id + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + description: | + Expense ID + example: txAcczJOQHGR + - $ref: '#/components/schemas/expense_permissions_out' report_action_with_expenses_ids_to_eject: type: object additionalProperties: false diff --git a/reference/spender.yaml b/reference/spender.yaml index 10cab1d5f..d74ea1223 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -1007,6 +1007,94 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /spender/expenses/permissions/bulk: + post: + tags: + - Expenses + - Expense permissions + - Permissions + summary: Bulk Expense Permissions + description: | + Returns the permissions that the principal user can perform on the given expenses, calculated based on the spender role. + + **Note:** Maximum 200 expenses per API call. + operationId: bulk_expense_permissions + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - data + properties: + data: + $ref: '#/components/schemas/expense_permissions_bulk_in' + example: + data: + - id: txAcczJOQHGR + - id: txCG82pa4yQQ + - id: txuiMc5kJbK4 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/expense_permissions_bulk_out' + example: + data: + - id: txAcczJOQHGR + can_delete: false + can_edit: true + can_verify: false + can_remove_from_report: true + can_add_to_report: false + can_assign: false + - id: txCG82pa4yQQ + can_delete: true + can_edit: true + can_verify: false + can_remove_from_report: false + can_add_to_report: true + can_assign: true + - id: txuiMc5kJbK4 + can_delete: false + can_edit: false + can_verify: true + can_remove_from_report: false + can_add_to_report: false + can_assign: false + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '#/components/schemas/bulk_error' + - $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /spender/per_diem_rates: get: tags: @@ -10221,6 +10309,40 @@ components: description: | Indicates whether the user has permission to add this expense to a report. example: true + expense_permissions_bulk_in: + type: array + maxItems: 200 + description: | + Array of expense IDs to check permissions for (maximum 200 expenses per request). + items: + type: object + required: + - id + additionalProperties: false + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + description: | + Expense ID of the expense to check permissions for. + example: txAcczJOQHGR + expense_permissions_bulk_out: + type: array + description: | + Array of permission objects for each expense. Each object corresponds to an expense from the request. + items: + allOf: + - type: object + required: + - id + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + description: | + Expense ID + example: txAcczJOQHGR + - $ref: '#/components/schemas/expense_permissions_out' per_diem_rate_out: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 971284d39..4d9279d76 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -263,6 +263,8 @@ paths: $ref: paths/admin@expenses@export_configurations@delete@bulk.yaml /admin/expenses/permissions: $ref: paths/admin@expenses@permissions.yaml + /admin/expenses/permissions/bulk: + $ref: paths/admin@expenses@permissions@bulk.yaml /admin/expenses/merge: $ref: paths/admin@expenses@merge.yaml /admin/advance_requests: diff --git a/src/admin/paths/admin@expenses@permissions@bulk.yaml b/src/admin/paths/admin@expenses@permissions@bulk.yaml new file mode 100644 index 000000000..0c0719457 --- /dev/null +++ b/src/admin/paths/admin@expenses@permissions@bulk.yaml @@ -0,0 +1,87 @@ +post: + tags: + - Expenses + - Expense permissions + - Permissions + summary: Bulk Expense Permissions + description: | + Returns the permissions that the principal user can perform on the given expenses, calculated based on the admin role. + + **Note:** Maximum 200 expenses per API call. + operationId: bulk_expense_permissions + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - data + properties: + data: + $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_in' + example: + data: + - id: txAcczJOQHGR + - id: txCG82pa4yQQ + - id: txuiMc5kJbK4 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + properties: + data: + $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' + example: + data: + - id: txAcczJOQHGR + can_delete: false + can_edit: true + can_verify: false + can_remove_from_report: true + can_add_to_report: false + can_assign: false + - id: txCG82pa4yQQ + can_delete: true + can_edit: true + can_verify: false + can_remove_from_report: false + can_add_to_report: true + can_assign: true + - id: txuiMc5kJbK4 + can_delete: false + can_edit: false + can_verify: true + can_remove_from_report: false + can_add_to_report: false + can_assign: false + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '../../components/schemas/bulk_error.yaml' + - $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: ../../components/schemas/401.yaml + '403': + description: Forbidden + content: + application/json: + schema: + $ref: ../../components/schemas/403.yaml + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/approver/openapi.yaml b/src/approver/openapi.yaml index 93609d907..80075d34f 100644 --- a/src/approver/openapi.yaml +++ b/src/approver/openapi.yaml @@ -83,6 +83,8 @@ paths: $ref: paths/approver@expenses@attach_files@bulk.yaml /approver/expenses/permissions: $ref: paths/approver@expenses@permissions.yaml + /approver/expenses/permissions/bulk: + $ref: paths/approver@expenses@permissions@bulk.yaml /approver/reports/eject_expenses: $ref: 'paths/approver@reports@eject_expenses.yaml' /approver/reports/filters: diff --git a/src/approver/paths/approver@expenses@permissions@bulk.yaml b/src/approver/paths/approver@expenses@permissions@bulk.yaml new file mode 100644 index 000000000..2ffce10c5 --- /dev/null +++ b/src/approver/paths/approver@expenses@permissions@bulk.yaml @@ -0,0 +1,87 @@ +post: + tags: + - Expenses + - Expense permissions + - Permissions + summary: Bulk Expense Permissions + description: | + Returns the permissions that the principal user can perform on the given expenses, calculated based on the approver role. + + **Note:** Maximum 200 expenses per API call. + operationId: bulk_expense_permissions + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - data + properties: + data: + $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_in' + example: + data: + - id: txAcczJOQHGR + - id: txCG82pa4yQQ + - id: txuiMc5kJbK4 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + properties: + data: + $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' + example: + data: + - id: txAcczJOQHGR + can_delete: false + can_edit: true + can_verify: false + can_remove_from_report: true + can_add_to_report: false + can_assign: false + - id: txCG82pa4yQQ + can_delete: true + can_edit: true + can_verify: false + can_remove_from_report: false + can_add_to_report: true + can_assign: true + - id: txuiMc5kJbK4 + can_delete: false + can_edit: false + can_verify: true + can_remove_from_report: false + can_add_to_report: false + can_assign: false + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '../../components/schemas/bulk_error.yaml' + - $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: ../../components/schemas/401.yaml + '403': + description: Forbidden + content: + application/json: + schema: + $ref: ../../components/schemas/403.yaml + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 2796bd845..15d0b16d8 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -2578,6 +2578,42 @@ expense_permissions_out: Indicates whether the user has permission to add this expense to a report. example: true +expense_permissions_bulk_in: + type: array + maxItems: 200 + description: | + Array of expense IDs to check permissions for (maximum 200 expenses per request). + items: + type: object + required: + - id + additionalProperties: false + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + description: | + Expense ID of the expense to check permissions for. + example: 'txAcczJOQHGR' + +expense_permissions_bulk_out: + type: array + description: | + Array of permission objects for each expense. Each object corresponds to an expense from the request. + items: + allOf: + - type: object + required: + - id + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + description: | + Expense ID + example: 'txAcczJOQHGR' + - $ref: '#/expense_permissions_out' + expenses_verify_bulk_in: type: object required: diff --git a/src/spender/openapi.yaml b/src/spender/openapi.yaml index 3bf6df27b..cd7f18374 100644 --- a/src/spender/openapi.yaml +++ b/src/spender/openapi.yaml @@ -151,6 +151,8 @@ paths: $ref: paths/spender@expenses@attach_files@bulk.yaml /spender/expenses/permissions: $ref: paths/spender@expenses@permissions.yaml + /spender/expenses/permissions/bulk: + $ref: paths/spender@expenses@permissions@bulk.yaml /spender/per_diem_rates: $ref: 'paths/spender@per_diem_rates.yaml' /spender/merchants: diff --git a/src/spender/paths/spender@expenses@permissions@bulk.yaml b/src/spender/paths/spender@expenses@permissions@bulk.yaml new file mode 100644 index 000000000..e6c19225c --- /dev/null +++ b/src/spender/paths/spender@expenses@permissions@bulk.yaml @@ -0,0 +1,87 @@ +post: + tags: + - Expenses + - Expense permissions + - Permissions + summary: Bulk Expense Permissions + description: | + Returns the permissions that the principal user can perform on the given expenses, calculated based on the spender role. + + **Note:** Maximum 200 expenses per API call. + operationId: bulk_expense_permissions + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - data + properties: + data: + $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_in' + example: + data: + - id: txAcczJOQHGR + - id: txCG82pa4yQQ + - id: txuiMc5kJbK4 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + properties: + data: + $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' + example: + data: + - id: txAcczJOQHGR + can_delete: false + can_edit: true + can_verify: false + can_remove_from_report: true + can_add_to_report: false + can_assign: false + - id: txCG82pa4yQQ + can_delete: true + can_edit: true + can_verify: false + can_remove_from_report: false + can_add_to_report: true + can_assign: true + - id: txuiMc5kJbK4 + can_delete: false + can_edit: false + can_verify: true + can_remove_from_report: false + can_add_to_report: false + can_assign: false + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '../../components/schemas/bulk_error.yaml' + - $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: ../../components/schemas/401.yaml + '403': + description: Forbidden + content: + application/json: + schema: + $ref: ../../components/schemas/403.yaml + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' From d3d835b54868d28bccfb8bf4fe757c98fce4ff58 Mon Sep 17 00:00:00 2001 From: Yash Ukalkar <73520396+yashUkalkar@users.noreply.github.com> Date: Fri, 2 Jan 2026 16:47:46 +0530 Subject: [PATCH 006/107] feat: added `added_to_report_by` to `GET /expenses` spec (#766) --- reference/admin.yaml | 23 +++++++++---- reference/approver.yaml | 19 ++++++++--- reference/manager.yaml | 11 ++++++ reference/spender.yaml | 15 ++++++-- src/components/schemas/expense.yaml | 53 +++++++++++++++++------------ 5 files changed, 88 insertions(+), 33 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 4bd6552df..1f86547a5 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -17517,6 +17517,7 @@ components: - seq_num - report_id - added_to_report_at + - added_to_report_by - report - is_verified - last_verified_at @@ -17797,6 +17798,16 @@ components: description: | signifies when this expense was added to a report. If this expense is not added to a report, then this could be null. + added_to_report_by: + type: string + nullable: true + enum: + - USER + - SYSTEM + - null + description: | + Indicates whether the expense was added to the report it belongs to by a user or the system. If the expense is not a part of any report, this field will be null. + example: USER report: $ref: '#/components/schemas/report_out_embed' is_verified: @@ -18143,7 +18154,7 @@ components: The expense amount which is added or modified by admin or approver. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: 1900 spent_at: type: string @@ -18154,7 +18165,7 @@ components: This date cannot be in future. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' assignee_user_email: allOf: @@ -18164,9 +18175,9 @@ components: Must be compliant with RFC 822. - **Note:** - - The expense will be assigned/re-assigned to this particular `employee`. + - The expense will be assigned/re-assigned to this particular `employee`. - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. - Admins can't assign the expense to self. source: $ref: '#/components/schemas/source' @@ -29624,7 +29635,7 @@ components: This date cannot be in future. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' is_reimbursable: $ref: '#/components/schemas/is_reimbursable' @@ -29701,7 +29712,7 @@ components: This date cannot be in future. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' category_id: allOf: diff --git a/reference/approver.yaml b/reference/approver.yaml index 6705fe447..dbbdc0292 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -5933,6 +5933,7 @@ components: - seq_num - report_id - added_to_report_at + - added_to_report_by - report - is_verified - last_verified_at @@ -6213,6 +6214,16 @@ components: description: | signifies when this expense was added to a report. If this expense is not added to a report, then this could be null. + added_to_report_by: + type: string + nullable: true + enum: + - USER + - SYSTEM + - null + description: | + Indicates whether the expense was added to the report it belongs to by a user or the system. If the expense is not a part of any report, this field will be null. + example: USER report: $ref: '#/components/schemas/report_out_embed' is_verified: @@ -6559,7 +6570,7 @@ components: description: | The expense amount which is added or modified by admin or approver. - **Note:** - - _This field is non-nullable_. + - _This field is non-nullable_. example: 1900 spent_at: type: string @@ -6569,7 +6580,7 @@ components: It signifies when this expense was made. This date cannot be in future. - **Note:** - - _This field is non-nullable_. + - _This field is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' source: $ref: '#/components/schemas/source' @@ -8709,7 +8720,7 @@ components: This date cannot be in future. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' is_reimbursable: $ref: '#/components/schemas/is_reimbursable' @@ -8786,7 +8797,7 @@ components: This date cannot be in future. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' category_id: allOf: diff --git a/reference/manager.yaml b/reference/manager.yaml index fa3a4ab70..f6a26cda8 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -2768,6 +2768,7 @@ components: - seq_num - report_id - added_to_report_at + - added_to_report_by - report - is_verified - last_verified_at @@ -3048,6 +3049,16 @@ components: description: | signifies when this expense was added to a report. If this expense is not added to a report, then this could be null. + added_to_report_by: + type: string + nullable: true + enum: + - USER + - SYSTEM + - null + description: | + Indicates whether the expense was added to the report it belongs to by a user or the system. If the expense is not a part of any report, this field will be null. + example: USER report: $ref: '#/components/schemas/report_out_embed' is_verified: diff --git a/reference/spender.yaml b/reference/spender.yaml index d74ea1223..94c0391d3 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -9272,6 +9272,7 @@ components: - seq_num - report_id - added_to_report_at + - added_to_report_by - report - is_verified - last_verified_at @@ -9552,6 +9553,16 @@ components: description: | signifies when this expense was added to a report. If this expense is not added to a report, then this could be null. + added_to_report_by: + type: string + nullable: true + enum: + - USER + - SYSTEM + - null + description: | + Indicates whether the expense was added to the report it belongs to by a user or the system. If the expense is not a part of any report, this field will be null. + example: USER report: $ref: '#/components/schemas/report_out_embed' is_verified: @@ -17613,7 +17624,7 @@ components: This date cannot be in future. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' is_reimbursable: $ref: '#/components/schemas/is_reimbursable' @@ -17690,7 +17701,7 @@ components: This date cannot be in future. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' category_id: allOf: diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 15d0b16d8..7dc69286c 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -54,6 +54,7 @@ expense_out: - seq_num - report_id - added_to_report_at + - added_to_report_by - report - is_verified - last_verified_at @@ -334,6 +335,16 @@ expense_out: description: | signifies when this expense was added to a report. If this expense is not added to a report, then this could be null. + added_to_report_by: + type: string + nullable: true + enum: + - USER + - SYSTEM + - null + description: | + Indicates whether the expense was added to the report it belongs to by a user or the system. If the expense is not a part of any report, this field will be null. + example: USER report: $ref: './report.yaml#/report_out_embed' is_verified: @@ -1037,7 +1048,7 @@ admin_expense_in: - required: - admin_amount - assignee_user_email - - required: + - required: - id properties: id: @@ -1053,7 +1064,7 @@ admin_expense_in: The expense amount which is added or modified by admin or approver. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: 1900 spent_at: type: string @@ -1064,7 +1075,7 @@ admin_expense_in: This date cannot be in future. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' assignee_user_email: allOf: @@ -1074,9 +1085,9 @@ admin_expense_in: Must be compliant with RFC 822. - **Note:** - - The expense will be assigned/re-assigned to this particular `employee`. + - The expense will be assigned/re-assigned to this particular `employee`. - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. - Admins can't assign the expense to self. source: $ref: './fields.yaml#/source' @@ -1118,7 +1129,7 @@ admin_expense_in: tax_amount: type: number nullable: true - description: | + description: | Tax amount as setup by your organization. - _Note:_ - Tax amount cannot be greater than the expense amount. @@ -1216,7 +1227,7 @@ admin_expense_in: approver_expense_in: type: object additionalProperties: false - required: + required: - id properties: id: @@ -1230,7 +1241,7 @@ approver_expense_in: description: | The expense amount which is added or modified by admin or approver. - **Note:** - - _This field is non-nullable_. + - _This field is non-nullable_. example: 1900 spent_at: type: string @@ -1240,7 +1251,7 @@ approver_expense_in: It signifies when this expense was made. This date cannot be in future. - **Note:** - - _This field is non-nullable_. + - _This field is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' source: $ref: './fields.yaml#/source' @@ -1282,7 +1293,7 @@ approver_expense_in: tax_amount: type: number nullable: true - description: | + description: | Tax amount as setup by your organization. - _Note:_ - Tax amount cannot be greater than the expense amount. @@ -1785,9 +1796,9 @@ expense_check_policies_in: Invoice number of the expense. example: 123456 - # TODO: Update the below remaining fields in this object based on how do we decide to do mileage calculations - # when mileage support comes to platform world. If we will give APIs for distance and amount calculation, - # then we will link the respective APIs in the description. If we decide to auto compute it in backend, then + # TODO: Update the below remaining fields in this object based on how do we decide to do mileage calculations + # when mileage support comes to platform world. If we will give APIs for distance and amount calculation, + # then we will link the respective APIs in the description. If we decide to auto compute it in backend, then # these fields might need to be dropped. mileage_calculated_distance: type: number @@ -1840,7 +1851,7 @@ expenses_stats_in: query_params: nullable: False type: string - description: | + description: | Query param string similar to expenses GET call. Use group_by_state=eq.true to get state-wise grouping of stats. example: id=in.('tx1263', 'tx1569')&group_by_state=eq.true @@ -1878,8 +1889,8 @@ expenses_stats_out: - PAID - UNREPORTABLE description: Expense state - # NOTE: This is a hack to maintain backward compatibility with the existing response structure - # TODO: @Dev to update the response once the hack is removed from platform-api + # NOTE: This is a hack to maintain backward compatibility with the existing response structure + # TODO: @Dev to update the response once the hack is removed from platform-api - type: object title: "Overall stats" description: Overall stats without state grouping @@ -1950,7 +1961,7 @@ accounting_export_summary_in: url: type: string description: URL Endpoint for exported / failed expense - example: https://app.example.com/expense/txwownwrng + example: https://app.example.com/expense/txwownwrng spender_expense_check_mandatory_fields_in: type: object additionalProperties: false @@ -2263,7 +2274,7 @@ expense_dismiss_duplicates_in: example: ['txwoirwlwwg', 'txwlgwkgw42'] description: | List of expense IDs that needs to be dismissed as a duplicate from the target expense - + expense_duplicate_sets_out: type: object additionalProperties: false @@ -2300,7 +2311,7 @@ expense_split_object: This date cannot be in future. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' category_id: allOf: @@ -2344,7 +2355,7 @@ split_expense_in: This date cannot be in future. - **Note:** - This field is required while creating an expense. - - _Not required when updating an expense, but is non-nullable_. + - _Not required when updating an expense, but is non-nullable_. example: '2020-06-01T01:18:19.292-08:00' is_reimbursable: $ref: './fields.yaml#/is_reimbursable' @@ -2386,7 +2397,7 @@ split_expense_in: tax_amount: type: number nullable: true - description: | + description: | Tax amount as setup by your organization. - _Note:_ - Tax amount cannot be greater than the expense amount. From 4b197962f81681ab30d22d54453263ff5ddf5673 Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Fri, 2 Jan 2026 17:10:02 +0530 Subject: [PATCH 007/107] feat: add budget status (#763) * add budget status * Auto generate API docs --- reference/admin.yaml | 12 ++++++++++++ reference/spender.yaml | 12 ++++++++++++ src/components/schemas/budget.yaml | 2 ++ src/components/schemas/fields.yaml | 11 +++++++++++ 4 files changed, 37 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 1f86547a5..e793b540d 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -25963,6 +25963,16 @@ components: description: | Visibility of the budget example: ONLY_ADMINS + budget_status: + type: string + enum: + - ON_TRACK + - NEAR_LIMIT + - EXCEEDED + - DISABLED + description: | + Status of budget usage + example: ON_TRACK budget_out: type: object additionalProperties: false @@ -26079,6 +26089,8 @@ components: description: Utilisation percentage of the budget interval visibility: $ref: '#/components/schemas/budget_visibility' + status: + $ref: '#/components/schemas/budget_status' budget_user_ids: type: array nullable: true diff --git a/reference/spender.yaml b/reference/spender.yaml index 94c0391d3..962d53b4b 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -7487,6 +7487,16 @@ components: description: | Visibility of the budget example: ONLY_ADMINS + budget_status: + type: string + enum: + - ON_TRACK + - NEAR_LIMIT + - EXCEEDED + - DISABLED + description: | + Status of budget usage + example: ON_TRACK budget_out: type: object additionalProperties: false @@ -7603,6 +7613,8 @@ components: description: Utilisation percentage of the budget interval visibility: $ref: '#/components/schemas/budget_visibility' + status: + $ref: '#/components/schemas/budget_status' code: type: string nullable: true diff --git a/src/components/schemas/budget.yaml b/src/components/schemas/budget.yaml index e18db2ff9..6e52bad47 100644 --- a/src/components/schemas/budget.yaml +++ b/src/components/schemas/budget.yaml @@ -185,6 +185,8 @@ budget_out: description: Utilisation percentage of the budget interval visibility: $ref: ./fields.yaml#/budget_visibility + status: + $ref: ./fields.yaml#/budget_status budget_out_embed: type: object diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index aca92edd1..f040f6fb2 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1246,6 +1246,17 @@ budget_visibility: Visibility of the budget example: ONLY_ADMINS +budget_status: + type: string + enum: + - ON_TRACK + - NEAR_LIMIT + - EXCEEDED + - DISABLED + description: | + Status of budget usage + example: ON_TRACK + budget_user_ids: type: array nullable: True From 7a55b9297284e2653421e70774809866c07995e9 Mon Sep 17 00:00:00 2001 From: Yash Ukalkar <73520396+yashUkalkar@users.noreply.github.com> Date: Mon, 5 Jan 2026 16:40:31 +0530 Subject: [PATCH 008/107] feat: `GET /reports` new field `creator_type` spec changes (#767) * added field creator_type to GET /reports specs * Auto generate API docs --- reference/admin.yaml | 18 ++++++++++++++++++ reference/approver.yaml | 9 +++++++++ reference/spender.yaml | 9 +++++++++ src/components/schemas/report.yaml | 18 ++++++++++++++++++ 4 files changed, 54 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index e793b540d..6ddc129ab 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -20436,6 +20436,7 @@ components: - comments - applied_advance_wallets - can_apply_advances + - creator_type properties: id: $ref: '#/components/schemas/id_string' @@ -20640,6 +20641,14 @@ components: nullable: true description: | List of applied advance wallets + creator_type: + type: string + enum: + - USER + - SYSTEM + description: | + Indicates whether the report was created by a user or the system. + example: USER admin_report_in: type: object additionalProperties: false @@ -25182,6 +25191,7 @@ components: - reimbursement_id - reimbursement - comments + - creator_type properties: id: $ref: '#/components/schemas/id_string' @@ -25381,6 +25391,14 @@ components: nullable: true description: | List of applied advance wallets + creator_type: + type: string + enum: + - USER + - SYSTEM + description: | + Indicates whether the report was created by a user or the system. + example: USER report_out_subscriptions_admin: type: object additionalProperties: false diff --git a/reference/approver.yaml b/reference/approver.yaml index dbbdc0292..2343de04f 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -4463,6 +4463,7 @@ components: - reimbursement_id - reimbursement - comments + - creator_type properties: id: $ref: '#/components/schemas/id_string' @@ -4662,6 +4663,14 @@ components: nullable: true description: | List of applied advance wallets + creator_type: + type: string + enum: + - USER + - SYSTEM + description: | + Indicates whether the report was created by a user or the system. + example: USER approver_report_in: type: object additionalProperties: false diff --git a/reference/spender.yaml b/reference/spender.yaml index 962d53b4b..f0671f0e7 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -10696,6 +10696,7 @@ components: - reimbursement_id - reimbursement - comments + - creator_type properties: id: $ref: '#/components/schemas/id_string' @@ -10895,6 +10896,14 @@ components: nullable: true description: | List of applied advance wallets + creator_type: + type: string + enum: + - USER + - SYSTEM + description: | + Indicates whether the report was created by a user or the system. + example: USER report_out_subscriptions_spender: type: object additionalProperties: false diff --git a/src/components/schemas/report.yaml b/src/components/schemas/report.yaml index 1efc1f4c3..0d42265de 100644 --- a/src/components/schemas/report.yaml +++ b/src/components/schemas/report.yaml @@ -28,6 +28,7 @@ report_out: - reimbursement_id - reimbursement - comments + - creator_type properties: id: $ref: ./fields.yaml#/id_string @@ -227,6 +228,14 @@ report_out: nullable: true description: | List of applied advance wallets + creator_type: + type: string + enum: + - USER + - SYSTEM + description: | + Indicates whether the report was created by a user or the system. + example: USER admin_report_out: type: object @@ -260,6 +269,7 @@ admin_report_out: - comments - applied_advance_wallets - can_apply_advances + - creator_type properties: id: $ref: ./fields.yaml#/id_string @@ -464,6 +474,14 @@ admin_report_out: nullable: true description: | List of applied advance wallets + creator_type: + type: string + enum: + - USER + - SYSTEM + description: | + Indicates whether the report was created by a user or the system. + example: USER admin_report_in: type: object From 6f214abce40d08777fa7c1486863fbbbb71961e5 Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Tue, 6 Jan 2026 17:38:58 +0530 Subject: [PATCH 009/107] feat: add budget export api docs (#768) * add budget export api docs * Auto generate API docs --- reference/admin.yaml | 99 ++++++++++++++++++++++ src/admin/openapi.yaml | 2 + src/admin/paths/admin@budgets@exports.yaml | 49 +++++++++++ src/components/schemas/budget_exports.yaml | 52 ++++++++++++ 4 files changed, 202 insertions(+) create mode 100644 src/admin/paths/admin@budgets@exports.yaml create mode 100644 src/components/schemas/budget_exports.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 6ddc129ab..d837943fe 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -9868,6 +9868,55 @@ paths: application/json: schema: $ref: '#/components/schemas/401' + /admin/budgets/exports: + post: + tags: + - Budgets + summary: Create Budget Export + description: | + Create a Budget Export Request. This exports budget data with the following columns: + Budget Name, Budget Frequency, Budget Amount, Utilisation (%, Amount), Remaining, Status, Created By, Start Date. + The export is generated in xlsx format. + operationId: budgets_exports_post + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/budget_exports_in' + required: + - data + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/budget_exports_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /admin/orgs: get: tags: @@ -26293,6 +26342,56 @@ components: List of project ids budget: $ref: '#/components/schemas/budget_out_embed' + budget_exports_in: + type: object + additionalProperties: false + required: + - query_params + properties: + query_params: + allOf: + - $ref: '#/components/schemas/query_params' + nullable: false + description: | + Query parameters to filter budgets for export. + example: status=eq.Exceeded + budget_exports_out: + type: object + additionalProperties: false + properties: + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: budexpXXXXXXXX + org_id: + $ref: '#/components/schemas/org_id' + user_id: + $ref: '#/components/schemas/user_id' + query_params: + allOf: + - $ref: '#/components/schemas/query_params' + nullable: false + file_id: + anyOf: + - $ref: '#/components/schemas/null_field' + - $ref: '#/components/schemas/id_string' + nullable: true + example: filumWHrlPf7K + state: + type: string + nullable: false + enum: + - PENDING + - PROCESSING + - SUCCESS + - ERROR + description: | + Status of the export. + example: PENDING org_out: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 4d9279d76..237960e1d 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -464,6 +464,8 @@ paths: $ref: 'paths/admin@budgets.yaml' /admin/budget_usages: $ref: paths/admin@budget_usages.yaml + /admin/budgets/exports: + $ref: paths/admin@budgets@exports.yaml /admin/orgs: $ref: paths/admin@orgs.yaml /admin/expense_policy_rules: diff --git a/src/admin/paths/admin@budgets@exports.yaml b/src/admin/paths/admin@budgets@exports.yaml new file mode 100644 index 000000000..a130c8ba3 --- /dev/null +++ b/src/admin/paths/admin@budgets@exports.yaml @@ -0,0 +1,49 @@ +post: + tags: + - Budgets + summary: Create Budget Export + description: | + Create a Budget Export Request. This exports budget data with the following columns: + Budget Name, Budget Frequency, Budget Amount, Utilisation (%, Amount), Remaining, Status, Created By, Start Date. + The export is generated in xlsx format. + operationId: budgets_exports_post + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/budget_exports.yaml#/budget_exports_in' + required: + - data + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/budget_exports.yaml#/budget_exports_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + diff --git a/src/components/schemas/budget_exports.yaml b/src/components/schemas/budget_exports.yaml new file mode 100644 index 000000000..d00f343c9 --- /dev/null +++ b/src/components/schemas/budget_exports.yaml @@ -0,0 +1,52 @@ +budget_exports_in: + type: object + additionalProperties: false + required: + - query_params + properties: + query_params: + allOf: + - $ref: './fields.yaml#/query_params' + nullable: false + description: | + Query parameters to filter budgets for export. + example: status=eq.Exceeded + + +budget_exports_out: + type: object + additionalProperties: false + properties: + created_at: + $ref: './fields.yaml#/created_at' + updated_at: + $ref: './fields.yaml#/updated_at' + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: budexpXXXXXXXX + org_id: + $ref: './fields.yaml#/org_id' + user_id: + $ref: './fields.yaml#/user_id' + query_params: + allOf: + - $ref: './fields.yaml#/query_params' + nullable: false + file_id: + anyOf: + - $ref: './fields.yaml#/null_field' + - $ref: './fields.yaml#/id_string' + nullable: true + example: filumWHrlPf7K + state: + type: string + nullable: false + enum: + - PENDING + - PROCESSING + - SUCCESS + - ERROR + description: | + Status of the export. + example: PENDING From efab1e7b8d261c659c780764b3826bb038de4ce8 Mon Sep 17 00:00:00 2001 From: Ashwath Kannan Date: Tue, 6 Jan 2026 21:43:32 +0530 Subject: [PATCH 010/107] feat: Add default_billable field to project's Schema (#769) * Add default_billable field to project's Schema * Auto generate API docs --- reference/admin.yaml | 6 ++++++ reference/approver.yaml | 6 ++++++ reference/spender.yaml | 6 ++++++ src/components/schemas/project.yaml | 12 ++++++++++++ 4 files changed, 30 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index d837943fe..f5e9162a1 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -13660,6 +13660,12 @@ components: type: integer example: 16570 description: List of categories that are applicable for the project. + default_billable: + type: boolean + nullable: true + description: | + Default billable flag for expenses using this project. + `null` indicates the default is not set. project_in: type: object additionalProperties: false diff --git a/reference/approver.yaml b/reference/approver.yaml index 2343de04f..84fb47ccc 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -7737,6 +7737,12 @@ components: type: integer example: 16570 description: List of categories that are applicable for the project. + default_billable: + type: boolean + nullable: true + description: | + Default billable flag for expenses using this project. + `null` indicates the default is not set. admin_approver_category_out: type: object additionalProperties: false diff --git a/reference/spender.yaml b/reference/spender.yaml index f0671f0e7..7abf932e5 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -7674,6 +7674,12 @@ components: type: integer example: 16570 description: List of categories that are applicable for the project. + default_billable: + type: boolean + nullable: true + description: | + Default billable flag for expenses using this project. + `null` indicates the default is not set. cost_center_out: type: object additionalProperties: false diff --git a/src/components/schemas/project.yaml b/src/components/schemas/project.yaml index 8b3de6b55..87ae0cf64 100644 --- a/src/components/schemas/project.yaml +++ b/src/components/schemas/project.yaml @@ -43,6 +43,12 @@ project_out: type: integer example: 16570 description: List of categories that are applicable for the project. + default_billable: + type: boolean + nullable: true + description: | + Default billable flag for expenses using this project. + `null` indicates the default is not set. project_out_embed: type: object @@ -217,6 +223,12 @@ admin_approver_project_out: type: integer example: 16570 description: List of categories that are applicable for the project. + default_billable: + type: boolean + nullable: true + description: | + Default billable flag for expenses using this project. + `null` indicates the default is not set. project_delete_summary_out: type: object From 17bc1f93f2efbe5820c8c5a7cca774b7a13878f0 Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Wed, 7 Jan 2026 13:10:57 +0530 Subject: [PATCH 011/107] fix typo in budgets export api (#770) --- reference/admin.yaml | 2 +- src/admin/openapi.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index f5e9162a1..7ac57b29e 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -9868,7 +9868,7 @@ paths: application/json: schema: $ref: '#/components/schemas/401' - /admin/budgets/exports: + /admin/budgets/export: post: tags: - Budgets diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 237960e1d..0d6ade8b3 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -464,7 +464,7 @@ paths: $ref: 'paths/admin@budgets.yaml' /admin/budget_usages: $ref: paths/admin@budget_usages.yaml - /admin/budgets/exports: + /admin/budgets/export: $ref: paths/admin@budgets@exports.yaml /admin/orgs: $ref: paths/admin@orgs.yaml From d878c97be0dbfa3968acbef1dc36e3b32a199ef2 Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Fri, 9 Jan 2026 12:55:58 +0530 Subject: [PATCH 012/107] fix: show user_ids for get admin/budgets and not for spender/budgets (#773) * show user_ids for get admin/budgets and not for spender/budgets * Auto generate API docs * remove unnecessary fields from GET spender/budgets * Auto generate API docs --- reference/admin.yaml | 8 ++ reference/spender.yaml | 116 +++---------------------- src/components/schemas/budget.yaml | 50 ++++++++++- src/spender/paths/spender@budgets.yaml | 2 +- 4 files changed, 72 insertions(+), 104 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 7ac57b29e..78ba8d1c2 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -26164,6 +26164,14 @@ components: $ref: '#/components/schemas/budget_visibility' status: $ref: '#/components/schemas/budget_status' + user_ids: + type: array + items: + $ref: '#/components/schemas/id_string' + example: + - usge49ielgel + description: | + List of user ids budget_user_ids: type: array nullable: true diff --git a/reference/spender.yaml b/reference/spender.yaml index 7abf932e5..f25193e64 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -121,7 +121,7 @@ paths: data: type: array items: - $ref: '#/components/schemas/budget_out' + $ref: '#/components/schemas/spender_budget_out' '400': description: Bad request content: @@ -7466,27 +7466,6 @@ components: description: | amount of money example: 47.99 - id_integer: - type: integer - description: | - This id is provided by Sage Exp Mgmt to identify an object. - example: 1234 - email: - type: string - maxLength: 127 - example: john.doe@example.com - description: | - An immutable field that represents the email address of the employee. - Must be compliant with RFC 822. - budget_visibility: - type: string - enum: - - ONLY_ADMINS - - SPECIFIC_EMPLOYEES - - ALL_CONTRIBUTING_EMPLOYEES - description: | - Visibility of the budget - example: ONLY_ADMINS budget_status: type: string enum: @@ -7497,7 +7476,7 @@ components: description: | Status of budget usage example: ON_TRACK - budget_out: + spender_budget_out: type: object additionalProperties: false properties: @@ -7519,83 +7498,6 @@ components: $ref: '#/components/schemas/budget_type' amount_limit: $ref: '#/components/schemas/amount' - alert_threshold: - nullable: true - type: number - example: 5000 - department_ids: - type: array - items: - $ref: '#/components/schemas/id_string' - example: - - 2222 - - 1221 - description: | - List of department ids - project_ids: - type: array - items: - $ref: '#/components/schemas/id_integer' - example: - - 2222 - - 1221 - description: | - List of project ids - cost_center_ids: - type: array - items: - $ref: '#/components/schemas/id_integer' - example: - - 2222 - - 1221 - description: | - List of cost center ids - category_ids: - type: array - items: - $ref: '#/components/schemas/id_integer' - example: - - 2222 - - 1221 - description: | - List of category ids - observer_ids: - type: array - items: - $ref: '#/components/schemas/id_string' - example: - - usge49ielgel - fiscal_year_start_month: - type: number - example: 10 - description: Month number of start of fiscal year - minimum: 1 - maximum: 12 - budget_start_date: - type: string - nullable: true - format: date-time - example: '2022-04-01T00:00:00+00:00' - description: Start date of the current budget interval - budget_end_date: - type: string - nullable: true - format: date-time - example: '2022-04-30T00:00:00+00:00' - description: End date of the current budget interval - budget_creator: - type: object - properties: - id: - $ref: '#/components/schemas/id_string' - name: - $ref: '#/components/schemas/name' - email: - $ref: '#/components/schemas/email' - example: - id: usq8rwZj2POy - name: John Brown - email: admin1@company.com amount_spent: type: number nullable: true @@ -7611,10 +7513,13 @@ components: nullable: true example: 50 description: Utilisation percentage of the budget interval - visibility: - $ref: '#/components/schemas/budget_visibility' status: $ref: '#/components/schemas/budget_status' + id_integer: + type: integer + description: | + This id is provided by Sage Exp Mgmt to identify an object. + example: 1234 code: type: string nullable: true @@ -7937,6 +7842,13 @@ components: example: example.com currency: $ref: '#/components/schemas/currency' + email: + type: string + maxLength: 127 + example: john.doe@example.com + description: | + An immutable field that represents the email address of the employee. + Must be compliant with RFC 822. user_out_embed: type: object additionalProperties: false diff --git a/src/components/schemas/budget.yaml b/src/components/schemas/budget.yaml index 6e52bad47..3e7bb0227 100644 --- a/src/components/schemas/budget.yaml +++ b/src/components/schemas/budget.yaml @@ -187,6 +187,14 @@ budget_out: $ref: ./fields.yaml#/budget_visibility status: $ref: ./fields.yaml#/budget_status + user_ids: + type: array + items: + $ref: './fields.yaml#/id_string' + example: + - usge49ielgel + description: | + List of user ids budget_out_embed: type: object @@ -205,4 +213,44 @@ budget_out_embed: - $ref: './fields.yaml#/amount' example: 10000 is_enabled: - $ref: ./fields.yaml#/is_enabled \ No newline at end of file + $ref: ./fields.yaml#/is_enabled + +spender_budget_out: + type: object + additionalProperties: False + properties: + id: + $ref: './fields.yaml#/id_string' + org_id: + $ref: ./fields.yaml#/org_id + created_at: + $ref: ./fields.yaml#/created_at + updated_at: + $ref: ./fields.yaml#/updated_at + is_enabled: + $ref: ./fields.yaml#/is_enabled + name: + allOf: + - $ref: ./fields.yaml#/name + example: Sales + type: + $ref: ./fields.yaml#/budget_type + amount_limit: + $ref: './fields.yaml#/amount' + amount_spent: + type: number + nullable: true + example: 5000 + description: Amount spent from the budget interval + amount_remaining: + type: number + nullable: true + example: 5000 + description: Amount remaining in the budget interval + utilisation_percentage: + type: number + nullable: true + example: 50 + description: Utilisation percentage of the budget interval + status: + $ref: ./fields.yaml#/budget_status diff --git a/src/spender/paths/spender@budgets.yaml b/src/spender/paths/spender@budgets.yaml index a53a3d723..3194783fe 100644 --- a/src/spender/paths/spender@budgets.yaml +++ b/src/spender/paths/spender@budgets.yaml @@ -24,7 +24,7 @@ get: data: type: array items: - $ref: '../../components/schemas/budget.yaml#/budget_out' + $ref: '../../components/schemas/budget.yaml#/spender_budget_out' '400': description: Bad request content: From 4f6398f0fc99d6229198b6152cfa3947dccb7b36 Mon Sep 17 00:00:00 2001 From: Ashwath Kannan Date: Tue, 13 Jan 2026 10:38:42 +0530 Subject: [PATCH 013/107] feat: Add default_billable to Post /projects payload (#771) * Add default_billable to Post /projects payload * Auto generate API docs --- reference/admin.yaml | 7 +++++++ src/components/schemas/project.yaml | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 78ba8d1c2..af02024e2 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -13752,6 +13752,13 @@ components: - `null` value indicates that all categories in the org are applicable for the project. - `[]` value indicates that no category in the org is applicable for the project. - The default value of `category_ids` is `null` + default_billable: + type: boolean + nullable: true + description: | + Default billable flag for expenses using this project. + `null` indicates the default is not set. + example: true bulk_error: type: object properties: diff --git a/src/components/schemas/project.yaml b/src/components/schemas/project.yaml index 87ae0cf64..18e4ce183 100644 --- a/src/components/schemas/project.yaml +++ b/src/components/schemas/project.yaml @@ -159,6 +159,13 @@ project_in: - `null` value indicates that all categories in the org are applicable for the project. - `[]` value indicates that no category in the org is applicable for the project. - The default value of `category_ids` is `null` + default_billable: + type: boolean + nullable: true + description: | + Default billable flag for expenses using this project. + `null` indicates the default is not set. + example: true project_in_only_id: type: object From bec03e5fd3740fc607d0124733d27cb9e7ca59a5 Mon Sep 17 00:00:00 2001 From: Sumit Kumar Date: Sun, 1 Feb 2026 16:17:29 +0530 Subject: [PATCH 014/107] feat: Added required elements for mobile version apis (#775) * Added required elements for mobile version apis * Added changes as per src/spender/paths/spender@expenses.yaml to mobile version docs * Removed redundant os_in and os_out and made them sameas os * Auto generate API docs --- reference/spender.yaml | 149 ++++++++++++++++++ .../schemas/mobile_app_version.yaml | 48 ++++++ src/spender/openapi.yaml | 2 + .../paths/spender@mobile_app@versions.yaml | 107 +++++++++++++ 4 files changed, 306 insertions(+) create mode 100644 src/components/schemas/mobile_app_version.yaml create mode 100644 src/spender/paths/spender@mobile_app@versions.yaml diff --git a/reference/spender.yaml b/reference/spender.yaml index f25193e64..31b3ff549 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -7338,6 +7338,107 @@ paths: error: type: string example: InvalidUsage + /spender/mobile_app/versions: + get: + tags: + - Mobile App Versions + summary: List mobile app versions + operationId: mobile_app_versions_list + description: | + This API supports filtering and pagination via query parameters. Returns mobile app version entries for the current user. + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + description: | + The total number of objects that can be requested. + type: integer + example: 10000 + offset: + description: | + offset is used to skip that many number of objects before counting.
+ For example, if there are 2000 objects,
+ The first request will have offset as 0 and limit as 1000 to return first 1000 objects.
+ The second request will have offset as 1000 and limit as 1000 to return next 1000 objects.
+ type: integer + example: 10 + data: + type: array + items: + $ref: '#/components/schemas/mobile_app_version_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + post: + tags: + - Mobile App Versions + summary: Create a mobile app version entry + operationId: mobile_app_versions_post + description: | + Creates a new mobile app version entry for the current user. Throws an error if an entry with the same (user_id, version, os.name, os.version) already exists. + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/mobile_app_version_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/mobile_app_version_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' components: securitySchemes: oauth2: @@ -19304,6 +19405,54 @@ components: properties: id: $ref: '#/components/schemas/id_string' + os: + type: object + additionalProperties: false + properties: + name: + type: string + enum: + - IOS + - ANDROID + description: Operating system name + example: IOS + version: + type: string + description: Operating system version + example: 17.0.0 + mobile_app_version_out: + type: object + additionalProperties: false + properties: + id: + type: string + description: Unique identifier for the mobile app version entry + example: appXYZ1234567 + user_id: + $ref: '#/components/schemas/user_id' + version: + type: string + description: Mobile app version + example: 8.0.1 + os: + $ref: '#/components/schemas/os' + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' + mobile_app_version_in: + type: object + additionalProperties: false + required: + - version + - os + properties: + version: + type: string + description: Mobile app version + example: 8.0.1 + os: + $ref: '#/components/schemas/os' parameters: q: in: query diff --git a/src/components/schemas/mobile_app_version.yaml b/src/components/schemas/mobile_app_version.yaml new file mode 100644 index 000000000..e4960648a --- /dev/null +++ b/src/components/schemas/mobile_app_version.yaml @@ -0,0 +1,48 @@ +mobile_app_version_out: + type: object + additionalProperties: false + properties: + id: + type: string + description: Unique identifier for the mobile app version entry + example: appXYZ1234567 + user_id: + $ref: ./fields.yaml#/user_id + version: + type: string + description: Mobile app version + example: "8.0.1" + os: + $ref: '#/os' + created_at: + $ref: ./fields.yaml#/created_at + updated_at: + $ref: ./fields.yaml#/updated_at + +mobile_app_version_in: + type: object + additionalProperties: false + required: + - version + - os + properties: + version: + type: string + description: Mobile app version + example: "8.0.1" + os: + $ref: '#/os' + +os: + type: object + additionalProperties: false + properties: + name: + type: string + enum: [IOS, ANDROID] + description: Operating system name + example: IOS + version: + type: string + description: Operating system version + example: "17.0.0" diff --git a/src/spender/openapi.yaml b/src/spender/openapi.yaml index cd7f18374..79c2f8985 100644 --- a/src/spender/openapi.yaml +++ b/src/spender/openapi.yaml @@ -385,3 +385,5 @@ paths: $ref: paths/spender@reports@export_configurations.yaml /spender/reports/export_configurations/delete/bulk: $ref: paths/spender@reports@export_configurations@delete@bulk.yaml + /spender/mobile_app/versions: + $ref: paths/spender@mobile_app@versions.yaml \ No newline at end of file diff --git a/src/spender/paths/spender@mobile_app@versions.yaml b/src/spender/paths/spender@mobile_app@versions.yaml new file mode 100644 index 000000000..cdb39888c --- /dev/null +++ b/src/spender/paths/spender@mobile_app@versions.yaml @@ -0,0 +1,107 @@ +get: + tags: + - Mobile App Versions + summary: List mobile app versions + operationId: mobile_app_versions_list + description: | + This API supports filtering and pagination via query parameters. Returns mobile app version entries for the current user. + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + description: | + The total number of objects that can be requested. + type: integer + example: 10000 + offset: + description: > + offset is used to skip that many number of objects before + counting.
+ + For example, if there are 2000 objects,
+ + The first request will have offset as 0 and limit as 1000 to + return first 1000 objects.
+ + The second request will have offset as 1000 and limit as 1000 + to return next 1000 objects.
+ type: integer + example: 10 + data: + type: array + items: + $ref: '../../components/schemas/mobile_app_version.yaml#/mobile_app_version_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + +post: + tags: + - Mobile App Versions + summary: Create a mobile app version entry + operationId: mobile_app_versions_post + description: | + Creates a new mobile app version entry for the current user. Throws an error if an entry with the same (user_id, version, os.name, os.version) already exists. + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: '../../components/schemas/mobile_app_version.yaml#/mobile_app_version_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: '../../components/schemas/mobile_app_version.yaml#/mobile_app_version_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' From 407570d06d04fe9fbf802c2b1beca640b4f52f14 Mon Sep 17 00:00:00 2001 From: Anjanna Date: Tue, 3 Feb 2026 14:37:50 +0530 Subject: [PATCH 015/107] feat: Added auto approval field in GET expenses and reports api response (#772) * added auto approval fields in reports and expenses get api * Auto generate API docs * added null to enum values * Auto generate API docs * added auto approval state field to spender reports api * Auto generate API docs * updated report approval schema for two column approach * Auto generate API docs --- reference/admin.yaml | 46 ++++++++++++++++++++- reference/approver.yaml | 37 ++++++++++++++++- reference/manager.yaml | 28 ++++++++++++- reference/spender.yaml | 37 ++++++++++++++++- src/components/schemas/expense.yaml | 9 ++++ src/components/schemas/report.yaml | 18 ++++++++ src/components/schemas/report_approval.yaml | 19 ++++++++- 7 files changed, 189 insertions(+), 5 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index af02024e2..f36e35c1d 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -16846,9 +16846,26 @@ components: approver_user_id: allOf: - $ref: '#/components/schemas/id_string' + nullable: true + description: | + The user ID of the approver. This is null when approver_type is SYSTEM (auto-approval). example: usge49ielgel + approver_type: + type: string + enum: + - USER + - SYSTEM + description: | + Type of approver. + - USER: A human approver identified by approver_user_id + - SYSTEM: Automatic approval by the system (auto-approval feature). When approver_type is SYSTEM, approver_user_id is null. + example: USER approver_user: - $ref: '#/components/schemas/user_out_embed' + allOf: + - $ref: '#/components/schemas/user_out_embed' + nullable: true + description: | + The user object of the approver. This is null when approver_type is SYSTEM. state: type: string enum: @@ -18119,6 +18136,15 @@ components: description: | Whether expenses is reconciled or not. example: true + report_auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the expense's report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null source: type: string description: | @@ -20711,6 +20737,15 @@ components: description: | Indicates whether the report was created by a user or the system. example: USER + auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null admin_report_in: type: object additionalProperties: false @@ -25461,6 +25496,15 @@ components: description: | Indicates whether the report was created by a user or the system. example: USER + auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null report_out_subscriptions_admin: type: object additionalProperties: false diff --git a/reference/approver.yaml b/reference/approver.yaml index 84fb47ccc..a2b64b554 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -4080,9 +4080,26 @@ components: approver_user_id: allOf: - $ref: '#/components/schemas/id_string' + nullable: true + description: | + The user ID of the approver. This is null when approver_type is SYSTEM (auto-approval). example: usge49ielgel + approver_type: + type: string + enum: + - USER + - SYSTEM + description: | + Type of approver. + - USER: A human approver identified by approver_user_id + - SYSTEM: Automatic approval by the system (auto-approval feature). When approver_type is SYSTEM, approver_user_id is null. + example: USER approver_user: - $ref: '#/components/schemas/user_out_embed' + allOf: + - $ref: '#/components/schemas/user_out_embed' + nullable: true + description: | + The user object of the approver. This is null when approver_type is SYSTEM. state: type: string enum: @@ -4671,6 +4688,15 @@ components: description: | Indicates whether the report was created by a user or the system. example: USER + auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null approver_report_in: type: object additionalProperties: false @@ -6482,6 +6508,15 @@ components: description: | Whether expenses is reconciled or not. example: true + report_auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the expense's report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null source: type: string description: | diff --git a/reference/manager.yaml b/reference/manager.yaml index f6a26cda8..72f8df88a 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -2021,9 +2021,26 @@ components: approver_user_id: allOf: - $ref: '#/components/schemas/id_string' + nullable: true + description: | + The user ID of the approver. This is null when approver_type is SYSTEM (auto-approval). example: usge49ielgel + approver_type: + type: string + enum: + - USER + - SYSTEM + description: | + Type of approver. + - USER: A human approver identified by approver_user_id + - SYSTEM: Automatic approval by the system (auto-approval feature). When approver_type is SYSTEM, approver_user_id is null. + example: USER approver_user: - $ref: '#/components/schemas/user_out_embed' + allOf: + - $ref: '#/components/schemas/user_out_embed' + nullable: true + description: | + The user object of the approver. This is null when approver_type is SYSTEM. state: type: string enum: @@ -3308,6 +3325,15 @@ components: description: | Whether expenses is reconciled or not. example: true + report_auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the expense's report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null expenses_stats_in: properties: query_params: diff --git a/reference/spender.yaml b/reference/spender.yaml index 31b3ff549..d50d3571c 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -8458,9 +8458,26 @@ components: approver_user_id: allOf: - $ref: '#/components/schemas/id_string' + nullable: true + description: | + The user ID of the approver. This is null when approver_type is SYSTEM (auto-approval). example: usge49ielgel + approver_type: + type: string + enum: + - USER + - SYSTEM + description: | + Type of approver. + - USER: A human approver identified by approver_user_id + - SYSTEM: Automatic approval by the system (auto-approval feature). When approver_type is SYSTEM, approver_user_id is null. + example: USER approver_user: - $ref: '#/components/schemas/user_out_embed' + allOf: + - $ref: '#/components/schemas/user_out_embed' + nullable: true + description: | + The user object of the approver. This is null when approver_type is SYSTEM. state: type: string enum: @@ -9843,6 +9860,15 @@ components: description: | Whether expenses is reconciled or not. example: true + report_auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the expense's report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null source: type: string description: | @@ -10923,6 +10949,15 @@ components: description: | Indicates whether the report was created by a user or the system. example: USER + auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null report_out_subscriptions_spender: type: object additionalProperties: false diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 7dc69286c..1b199d589 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -601,6 +601,15 @@ expense_out: description: | Whether expenses is reconciled or not. example: true + report_auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the expense's report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null expense_in: type: object diff --git a/src/components/schemas/report.yaml b/src/components/schemas/report.yaml index 0d42265de..1533d5a5a 100644 --- a/src/components/schemas/report.yaml +++ b/src/components/schemas/report.yaml @@ -236,6 +236,15 @@ report_out: description: | Indicates whether the report was created by a user or the system. example: USER + auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null admin_report_out: type: object @@ -482,6 +491,15 @@ admin_report_out: description: | Indicates whether the report was created by a user or the system. example: USER + auto_approval_state: + type: string + nullable: true + description: Indicates the auto approval evaluation status of the report. + enum: + - PENDING + - NOT_ELIGIBLE + - AUTO_APPROVED + - null admin_report_in: type: object diff --git a/src/components/schemas/report_approval.yaml b/src/components/schemas/report_approval.yaml index 1e3d4c51d..d56c9e4a1 100644 --- a/src/components/schemas/report_approval.yaml +++ b/src/components/schemas/report_approval.yaml @@ -5,9 +5,26 @@ report_approval_out_embed: approver_user_id: allOf: - $ref: ./fields.yaml#/id_string + nullable: true + description: | + The user ID of the approver. This is null when approver_type is SYSTEM (auto-approval). example: usge49ielgel + approver_type: + type: string + enum: + - USER + - SYSTEM + description: | + Type of approver. + - USER: A human approver identified by approver_user_id + - SYSTEM: Automatic approval by the system (auto-approval feature). When approver_type is SYSTEM, approver_user_id is null. + example: USER approver_user: - $ref: ./user.yaml#/user_out_embed + allOf: + - $ref: ./user.yaml#/user_out_embed + nullable: true + description: | + The user object of the approver. This is null when approver_type is SYSTEM. state: type: string enum: From 90b2d29846c879a1f19a20cc1485dad622d368c0 Mon Sep 17 00:00:00 2001 From: Nilesh Pant Date: Wed, 4 Feb 2026 11:22:47 +0530 Subject: [PATCH 016/107] feat: add mobile notification toggle in reminders api (#776) --- reference/admin.yaml | 14 ++++++++++++++ src/components/schemas/reminder.yaml | 14 ++++++++++++++ 2 files changed, 28 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index f36e35c1d..574ce0aed 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -20225,6 +20225,13 @@ components: description: | Determines whether this reminder will be added as an event in the google calendar of receiver. example: true + send_mobile_notification: + type: boolean + nullable: false + default: false + description: | + Determines whether this reminder will be used to send mobile notification + example: true receiver_user_ids: $ref: '#/components/schemas/reminder_receiver_user_ids' reminder_in: @@ -20253,6 +20260,13 @@ components: description: | Determines whether this reminder will be added as an event in the google calendar of receiver. example: true + send_mobile_notification: + type: boolean + nullable: false + default: false + description: | + Determines whether this reminder will be used to send mobile notification + example: true receiver_user_ids: $ref: '#/components/schemas/reminder_receiver_user_ids' reminder_delete_in: diff --git a/src/components/schemas/reminder.yaml b/src/components/schemas/reminder.yaml index 7d1d36f03..e9a2b7b83 100644 --- a/src/components/schemas/reminder.yaml +++ b/src/components/schemas/reminder.yaml @@ -44,6 +44,13 @@ reminder_out: description: | Determines whether this reminder will be added as an event in the google calendar of receiver. example: true + send_mobile_notification: + type: boolean + nullable: false + default: false + description: | + Determines whether this reminder will be used to send mobile notification + example: true receiver_user_ids: $ref: ./fields.yaml#/reminder_receiver_user_ids @@ -75,6 +82,13 @@ reminder_in: description: | Determines whether this reminder will be added as an event in the google calendar of receiver. example: true + send_mobile_notification: + type: boolean + nullable: false + default: false + description: | + Determines whether this reminder will be used to send mobile notification + example: true receiver_user_ids: $ref: ./fields.yaml#/reminder_receiver_user_ids From 63937a8a9e43f099b9b01249ee3502196d4c1b0a Mon Sep 17 00:00:00 2001 From: Madan Gopal <159766771+madangopal122@users.noreply.github.com> Date: Thu, 5 Feb 2026 14:29:26 +0530 Subject: [PATCH 017/107] fix: Expense matched corporate card transaction id and matched corprate card transaction fields (#774) * fix: Expense matched corporate card transaction id and matched corporate card transaction fields * Auto generate API docs * Create new schema for matched corporate card transaction field * Auto generate API docs * Added note for deprecation * Auto generate API docs * mino * Auto generate API docs * minor * Auto generate API docs --- reference/admin.yaml | 135 +++++++++++++++++++++++++++ reference/approver.yaml | 135 +++++++++++++++++++++++++++ reference/manager.yaml | 135 +++++++++++++++++++++++++++ reference/spender.yaml | 135 +++++++++++++++++++++++++++ src/components/schemas/expense.yaml | 137 ++++++++++++++++++++++++++++ 5 files changed, 677 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 574ce0aed..88fc8b5d5 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -17253,6 +17253,123 @@ components: description: | String denoting the email of the user who matched the card transaction to an expense. example: john.ooe@sage.com + matched_corporate_card_transaction_out_embed_new: + anyOf: + - type: object + additionalProperties: false + properties: {} + description: Empty object when no corporate card transaction is matched + - type: object + required: + - id + - corporate_card_id + - corporate_card_number + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: btxnwownwrng + corporate_card_id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + corporate_card_number: + $ref: '#/components/schemas/card_number' + corporate_card_nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: Business Card + corporate_card_cardholder_name: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the card holder's name + example: John Cena + capitalone_virtual_card_last_four: + type: string + nullable: true + description: | + Last four digits of capitalone virtual card. + example: '4521' + masked_corporate_card_number: + $ref: '#/components/schemas/card_number' + bank_name: + nullable: true + $ref: '#/components/schemas/bank_name' + corporate_card_user_full_name: + nullable: true + allOf: + - $ref: '#/components/schemas/name_nullable' + maxLength: 255 + description: | + String denoting the card holder's full name + example: John Doe + amount: + $ref: '#/components/schemas/amount' + currency: + $ref: '#/components/schemas/currency' + spent_at: + allOf: + - $ref: '#/components/schemas/spent_at' + description: | + Signifies spent date of a card transaction. + This date cannot be in future. + posted_at: + nullable: true + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies post date of a card transaction. + This date cannot be in future. + status: + type: string + nullable: true + enum: + - PENDING + - POSTED + - null + example: PENDING + description: | + Signifies status of a card transaction. + description: + type: string + nullable: true + description: | + Holds the description of the card transaction + example: Team lunch + foreign_currency: + nullable: true + allOf: + - $ref: '#/components/schemas/foreign_currency' + foreign_amount: + nullable: true + allOf: + - $ref: '#/components/schemas/foreign_amount' + merchant: + nullable: true + allOf: + - $ref: '#/components/schemas/merchant' + description: | + String denoting the name of the vendor to which the card transaction was made. + Note: This is not same as the merchant added in Sage Exp Mgmt but just a string + category: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the category of the card transaction + Note: This is not same as the category added in Sage Exp Mgmt but just a string + example: Travel + matched_by: + type: string + nullable: true + description: | + String denoting the email of the user who matched the card transaction to an expense. + example: john.ooe@sage.com missing_mandatory_fields: type: object nullable: false @@ -17609,6 +17726,8 @@ components: - is_corporate_card_transaction_auto_matched - matched_corporate_card_transaction_ids - matched_corporate_card_transactions + - matched_corporate_card_transaction_id + - matched_corporate_card_transaction - last_settled_at - missing_mandatory_fields - activity_details @@ -17959,6 +18078,8 @@ components: $ref: '#/components/schemas/id_string' description: | Holds the corporate card transaction ids which are matched to this expense + + **NOTE**: This array field is planned for deprecation in future. Please consider using the field `matched_corporate_card_transaction_id` instead, as this array always contains a single value. example: - btxnwownwrng matched_corporate_card_transactions: @@ -17968,6 +18089,20 @@ components: description: | Holds the corporate card transactions which are matched to this expense. NOTE: The data of this field is not realtime. It will get updated later even if `matched_corporate_card_transaction_ids` is already up-to-date. + + **NOTE**: This array field is planned for deprecation in future. Please consider using the field `matched_corporate_card_transaction` instead, as this array always contains a single value. + matched_corporate_card_transaction_id: + type: string + nullable: true + description: | + Holds the corporate card transaction id which is matched to this expense + example: btxnwownwrng + matched_corporate_card_transaction: + allOf: + - $ref: '#/components/schemas/matched_corporate_card_transaction_out_embed_new' + description: | + Holds the corporate card transaction which is matched to this expense. + NOTE: The data of this field is not realtime. It will get updated later even if `matched_corporate_card_transaction_id` is already up-to-date. last_settled_at: allOf: - $ref: '#/components/schemas/timestamptz_utc' diff --git a/reference/approver.yaml b/reference/approver.yaml index a2b64b554..2348f9448 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -5625,6 +5625,123 @@ components: description: | String denoting the email of the user who matched the card transaction to an expense. example: john.ooe@sage.com + matched_corporate_card_transaction_out_embed_new: + anyOf: + - type: object + additionalProperties: false + properties: {} + description: Empty object when no corporate card transaction is matched + - type: object + required: + - id + - corporate_card_id + - corporate_card_number + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: btxnwownwrng + corporate_card_id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + corporate_card_number: + $ref: '#/components/schemas/card_number' + corporate_card_nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: Business Card + corporate_card_cardholder_name: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the card holder's name + example: John Cena + capitalone_virtual_card_last_four: + type: string + nullable: true + description: | + Last four digits of capitalone virtual card. + example: '4521' + masked_corporate_card_number: + $ref: '#/components/schemas/card_number' + bank_name: + nullable: true + $ref: '#/components/schemas/bank_name' + corporate_card_user_full_name: + nullable: true + allOf: + - $ref: '#/components/schemas/name_nullable' + maxLength: 255 + description: | + String denoting the card holder's full name + example: John Doe + amount: + $ref: '#/components/schemas/amount' + currency: + $ref: '#/components/schemas/currency' + spent_at: + allOf: + - $ref: '#/components/schemas/spent_at' + description: | + Signifies spent date of a card transaction. + This date cannot be in future. + posted_at: + nullable: true + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies post date of a card transaction. + This date cannot be in future. + status: + type: string + nullable: true + enum: + - PENDING + - POSTED + - null + example: PENDING + description: | + Signifies status of a card transaction. + description: + type: string + nullable: true + description: | + Holds the description of the card transaction + example: Team lunch + foreign_currency: + nullable: true + allOf: + - $ref: '#/components/schemas/foreign_currency' + foreign_amount: + nullable: true + allOf: + - $ref: '#/components/schemas/foreign_amount' + merchant: + nullable: true + allOf: + - $ref: '#/components/schemas/merchant' + description: | + String denoting the name of the vendor to which the card transaction was made. + Note: This is not same as the merchant added in Sage Exp Mgmt but just a string + category: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the category of the card transaction + Note: This is not same as the category added in Sage Exp Mgmt but just a string + example: Travel + matched_by: + type: string + nullable: true + description: | + String denoting the email of the user who matched the card transaction to an expense. + example: john.ooe@sage.com missing_mandatory_fields: type: object nullable: false @@ -5981,6 +6098,8 @@ components: - is_corporate_card_transaction_auto_matched - matched_corporate_card_transaction_ids - matched_corporate_card_transactions + - matched_corporate_card_transaction_id + - matched_corporate_card_transaction - last_settled_at - missing_mandatory_fields - activity_details @@ -6331,6 +6450,8 @@ components: $ref: '#/components/schemas/id_string' description: | Holds the corporate card transaction ids which are matched to this expense + + **NOTE**: This array field is planned for deprecation in future. Please consider using the field `matched_corporate_card_transaction_id` instead, as this array always contains a single value. example: - btxnwownwrng matched_corporate_card_transactions: @@ -6340,6 +6461,20 @@ components: description: | Holds the corporate card transactions which are matched to this expense. NOTE: The data of this field is not realtime. It will get updated later even if `matched_corporate_card_transaction_ids` is already up-to-date. + + **NOTE**: This array field is planned for deprecation in future. Please consider using the field `matched_corporate_card_transaction` instead, as this array always contains a single value. + matched_corporate_card_transaction_id: + type: string + nullable: true + description: | + Holds the corporate card transaction id which is matched to this expense + example: btxnwownwrng + matched_corporate_card_transaction: + allOf: + - $ref: '#/components/schemas/matched_corporate_card_transaction_out_embed_new' + description: | + Holds the corporate card transaction which is matched to this expense. + NOTE: The data of this field is not realtime. It will get updated later even if `matched_corporate_card_transaction_id` is already up-to-date. last_settled_at: allOf: - $ref: '#/components/schemas/timestamptz_utc' diff --git a/reference/manager.yaml b/reference/manager.yaml index 72f8df88a..a8fb97e22 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -2442,6 +2442,123 @@ components: description: | String denoting the email of the user who matched the card transaction to an expense. example: john.ooe@sage.com + matched_corporate_card_transaction_out_embed_new: + anyOf: + - type: object + additionalProperties: false + properties: {} + description: Empty object when no corporate card transaction is matched + - type: object + required: + - id + - corporate_card_id + - corporate_card_number + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: btxnwownwrng + corporate_card_id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + corporate_card_number: + $ref: '#/components/schemas/card_number' + corporate_card_nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: Business Card + corporate_card_cardholder_name: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the card holder's name + example: John Cena + capitalone_virtual_card_last_four: + type: string + nullable: true + description: | + Last four digits of capitalone virtual card. + example: '4521' + masked_corporate_card_number: + $ref: '#/components/schemas/card_number' + bank_name: + nullable: true + $ref: '#/components/schemas/bank_name' + corporate_card_user_full_name: + nullable: true + allOf: + - $ref: '#/components/schemas/name_nullable' + maxLength: 255 + description: | + String denoting the card holder's full name + example: John Doe + amount: + $ref: '#/components/schemas/amount' + currency: + $ref: '#/components/schemas/currency' + spent_at: + allOf: + - $ref: '#/components/schemas/spent_at' + description: | + Signifies spent date of a card transaction. + This date cannot be in future. + posted_at: + nullable: true + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies post date of a card transaction. + This date cannot be in future. + status: + type: string + nullable: true + enum: + - PENDING + - POSTED + - null + example: PENDING + description: | + Signifies status of a card transaction. + description: + type: string + nullable: true + description: | + Holds the description of the card transaction + example: Team lunch + foreign_currency: + nullable: true + allOf: + - $ref: '#/components/schemas/foreign_currency' + foreign_amount: + nullable: true + allOf: + - $ref: '#/components/schemas/foreign_amount' + merchant: + nullable: true + allOf: + - $ref: '#/components/schemas/merchant' + description: | + String denoting the name of the vendor to which the card transaction was made. + Note: This is not same as the merchant added in Sage Exp Mgmt but just a string + category: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the category of the card transaction + Note: This is not same as the category added in Sage Exp Mgmt but just a string + example: Travel + matched_by: + type: string + nullable: true + description: | + String denoting the email of the user who matched the card transaction to an expense. + example: john.ooe@sage.com missing_mandatory_fields: type: object nullable: false @@ -2798,6 +2915,8 @@ components: - is_corporate_card_transaction_auto_matched - matched_corporate_card_transaction_ids - matched_corporate_card_transactions + - matched_corporate_card_transaction_id + - matched_corporate_card_transaction - last_settled_at - missing_mandatory_fields - activity_details @@ -3148,6 +3267,8 @@ components: $ref: '#/components/schemas/id_string' description: | Holds the corporate card transaction ids which are matched to this expense + + **NOTE**: This array field is planned for deprecation in future. Please consider using the field `matched_corporate_card_transaction_id` instead, as this array always contains a single value. example: - btxnwownwrng matched_corporate_card_transactions: @@ -3157,6 +3278,20 @@ components: description: | Holds the corporate card transactions which are matched to this expense. NOTE: The data of this field is not realtime. It will get updated later even if `matched_corporate_card_transaction_ids` is already up-to-date. + + **NOTE**: This array field is planned for deprecation in future. Please consider using the field `matched_corporate_card_transaction` instead, as this array always contains a single value. + matched_corporate_card_transaction_id: + type: string + nullable: true + description: | + Holds the corporate card transaction id which is matched to this expense + example: btxnwownwrng + matched_corporate_card_transaction: + allOf: + - $ref: '#/components/schemas/matched_corporate_card_transaction_out_embed_new' + description: | + Holds the corporate card transaction which is matched to this expense. + NOTE: The data of this field is not realtime. It will get updated later even if `matched_corporate_card_transaction_id` is already up-to-date. last_settled_at: allOf: - $ref: '#/components/schemas/timestamptz_utc' diff --git a/reference/spender.yaml b/reference/spender.yaml index d50d3571c..08a93477f 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -8977,6 +8977,123 @@ components: description: | String denoting the email of the user who matched the card transaction to an expense. example: john.ooe@sage.com + matched_corporate_card_transaction_out_embed_new: + anyOf: + - type: object + additionalProperties: false + properties: {} + description: Empty object when no corporate card transaction is matched + - type: object + required: + - id + - corporate_card_id + - corporate_card_number + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: btxnwownwrng + corporate_card_id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + corporate_card_number: + $ref: '#/components/schemas/card_number' + corporate_card_nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: Business Card + corporate_card_cardholder_name: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the card holder's name + example: John Cena + capitalone_virtual_card_last_four: + type: string + nullable: true + description: | + Last four digits of capitalone virtual card. + example: '4521' + masked_corporate_card_number: + $ref: '#/components/schemas/card_number' + bank_name: + nullable: true + $ref: '#/components/schemas/bank_name' + corporate_card_user_full_name: + nullable: true + allOf: + - $ref: '#/components/schemas/name_nullable' + maxLength: 255 + description: | + String denoting the card holder's full name + example: John Doe + amount: + $ref: '#/components/schemas/amount' + currency: + $ref: '#/components/schemas/currency' + spent_at: + allOf: + - $ref: '#/components/schemas/spent_at' + description: | + Signifies spent date of a card transaction. + This date cannot be in future. + posted_at: + nullable: true + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies post date of a card transaction. + This date cannot be in future. + status: + type: string + nullable: true + enum: + - PENDING + - POSTED + - null + example: PENDING + description: | + Signifies status of a card transaction. + description: + type: string + nullable: true + description: | + Holds the description of the card transaction + example: Team lunch + foreign_currency: + nullable: true + allOf: + - $ref: '#/components/schemas/foreign_currency' + foreign_amount: + nullable: true + allOf: + - $ref: '#/components/schemas/foreign_amount' + merchant: + nullable: true + allOf: + - $ref: '#/components/schemas/merchant' + description: | + String denoting the name of the vendor to which the card transaction was made. + Note: This is not same as the merchant added in Sage Exp Mgmt but just a string + category: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the category of the card transaction + Note: This is not same as the category added in Sage Exp Mgmt but just a string + example: Travel + matched_by: + type: string + nullable: true + description: | + String denoting the email of the user who matched the card transaction to an expense. + example: john.ooe@sage.com missing_mandatory_fields: type: object nullable: false @@ -9333,6 +9450,8 @@ components: - is_corporate_card_transaction_auto_matched - matched_corporate_card_transaction_ids - matched_corporate_card_transactions + - matched_corporate_card_transaction_id + - matched_corporate_card_transaction - last_settled_at - missing_mandatory_fields - activity_details @@ -9683,6 +9802,8 @@ components: $ref: '#/components/schemas/id_string' description: | Holds the corporate card transaction ids which are matched to this expense + + **NOTE**: This array field is planned for deprecation in future. Please consider using the field `matched_corporate_card_transaction_id` instead, as this array always contains a single value. example: - btxnwownwrng matched_corporate_card_transactions: @@ -9692,6 +9813,20 @@ components: description: | Holds the corporate card transactions which are matched to this expense. NOTE: The data of this field is not realtime. It will get updated later even if `matched_corporate_card_transaction_ids` is already up-to-date. + + **NOTE**: This array field is planned for deprecation in future. Please consider using the field `matched_corporate_card_transaction` instead, as this array always contains a single value. + matched_corporate_card_transaction_id: + type: string + nullable: true + description: | + Holds the corporate card transaction id which is matched to this expense + example: btxnwownwrng + matched_corporate_card_transaction: + allOf: + - $ref: '#/components/schemas/matched_corporate_card_transaction_out_embed_new' + description: | + Holds the corporate card transaction which is matched to this expense. + NOTE: The data of this field is not realtime. It will get updated later even if `matched_corporate_card_transaction_id` is already up-to-date. last_settled_at: allOf: - $ref: '#/components/schemas/timestamptz_utc' diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 1b199d589..b3e67a21d 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -67,6 +67,8 @@ expense_out: - is_corporate_card_transaction_auto_matched - matched_corporate_card_transaction_ids - matched_corporate_card_transactions + - matched_corporate_card_transaction_id + - matched_corporate_card_transaction - last_settled_at - missing_mandatory_fields - activity_details @@ -424,6 +426,8 @@ expense_out: $ref: './fields.yaml#/id_string' description: | Holds the corporate card transaction ids which are matched to this expense + + **NOTE**: This array field is planned for deprecation in future. Please consider using the field `matched_corporate_card_transaction_id` instead, as this array always contains a single value. example: - btxnwownwrng matched_corporate_card_transactions: @@ -433,6 +437,20 @@ expense_out: description: | Holds the corporate card transactions which are matched to this expense. NOTE: The data of this field is not realtime. It will get updated later even if `matched_corporate_card_transaction_ids` is already up-to-date. + + **NOTE**: This array field is planned for deprecation in future. Please consider using the field `matched_corporate_card_transaction` instead, as this array always contains a single value. + matched_corporate_card_transaction_id: + type: string + nullable: true + description: | + Holds the corporate card transaction id which is matched to this expense + example: btxnwownwrng + matched_corporate_card_transaction: + allOf: + - $ref: '#/matched_corporate_card_transaction_out_embed_new' + description: | + Holds the corporate card transaction which is matched to this expense. + NOTE: The data of this field is not realtime. It will get updated later even if `matched_corporate_card_transaction_id` is already up-to-date. last_settled_at: allOf: - $ref: './fields.yaml#/timestamptz_utc' @@ -1601,6 +1619,125 @@ matched_corporate_card_transaction_out_embed: example: john.ooe@sage.com +matched_corporate_card_transaction_out_embed_new: + anyOf: + - type: object + additionalProperties: false + properties: {} + description: Empty object when no corporate card transaction is matched + - type: object + required: + - id + - corporate_card_id + - corporate_card_number + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: btxnwownwrng + corporate_card_id: + allOf: + - $ref: './fields.yaml#/id_string' + example: bawownwrng + corporate_card_number: + $ref: './fields.yaml#/card_number' + corporate_card_nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: 'Business Card' + corporate_card_cardholder_name: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the card holder's name + example: John Cena + capitalone_virtual_card_last_four: + type: string + nullable: true + description: | + Last four digits of capitalone virtual card. + example: "4521" + masked_corporate_card_number: + $ref: './fields.yaml#/card_number' + bank_name: + nullable: true + $ref: './fields.yaml#/bank_name' + corporate_card_user_full_name: + nullable: true + allOf: + - $ref: './fields.yaml#/name_nullable' + maxLength: 255 + description: | + String denoting the card holder's full name + example: John Doe + amount: + $ref: './fields.yaml#/amount' + currency: + $ref: './fields.yaml#/currency' + spent_at: + allOf: + - $ref: './fields.yaml#/spent_at' + description: | + Signifies spent date of a card transaction. + This date cannot be in future. + posted_at: + nullable: true + allOf: + - $ref: './fields.yaml#/timestamptz_utc' + description: | + Signifies post date of a card transaction. + This date cannot be in future. + status: + type: string + nullable: true + enum: + - PENDING + - POSTED + - null + example: PENDING + description: | + Signifies status of a card transaction. + description: + type: string + nullable: true + description: | + Holds the description of the card transaction + example: Team lunch + foreign_currency: + nullable: true + allOf: + - $ref: './fields.yaml#/foreign_currency' + foreign_amount: + nullable: true + allOf: + - $ref: './fields.yaml#/foreign_amount' + merchant: + nullable: true + allOf: + - $ref: './fields.yaml#/merchant' + description: | + String denoting the name of the vendor to which the card transaction was made. + Note: This is not same as the merchant added in Sage Exp Mgmt but just a string + category: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the category of the card transaction + Note: This is not same as the category added in Sage Exp Mgmt but just a string + example: Travel + matched_by: + type: string + nullable: true + description: | + String denoting the email of the user who matched the card transaction to an expense. + example: john.ooe@sage.com + + expense_attach_receipt_in: type: object required: From 789a756f355ab45f105d40cc249a943fab4e9f1d Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Tue, 17 Feb 2026 10:59:33 +0530 Subject: [PATCH 018/107] feat: add scopes to delegatee-related apis (#777) * add scopes to delegatee-related apis * Auto generate API docs --- reference/admin.yaml | 12 ++++++++++++ reference/approver.yaml | 12 ++++++++++++ reference/manager.yaml | 12 ++++++++++++ reference/spender.yaml | 12 ++++++++++++ src/components/schemas/fields.yaml | 10 ++++++++++ 5 files changed, 58 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 88fc8b5d5..8a4e58748 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -15195,6 +15195,18 @@ components: description: | Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: true + scopes: + type: array + nullable: true + items: + type: string + enum: + - ALL + - SUBMIT + - APPROVE + example: + - SUBMIT + - APPROVE category_out_embed: type: object nullable: true diff --git a/reference/approver.yaml b/reference/approver.yaml index 2348f9448..d68ad9315 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -9453,6 +9453,18 @@ components: description: | Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: true + scopes: + type: array + nullable: true + items: + type: string + enum: + - ALL + - SUBMIT + - APPROVE + example: + - SUBMIT + - APPROVE employee_out: type: object additionalProperties: false diff --git a/reference/manager.yaml b/reference/manager.yaml index a8fb97e22..3a6b9e41b 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -1632,6 +1632,18 @@ components: description: | Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: true + scopes: + type: array + nullable: true + items: + type: string + enum: + - ALL + - SUBMIT + - APPROVE + example: + - SUBMIT + - APPROVE category_out_embed: type: object nullable: true diff --git a/reference/spender.yaml b/reference/spender.yaml index 08a93477f..3df1b9274 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -14662,6 +14662,18 @@ components: description: | Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: true + scopes: + type: array + nullable: true + items: + type: string + enum: + - ALL + - SUBMIT + - APPROVE + example: + - SUBMIT + - APPROVE spender_employee_out: type: object additionalProperties: false diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index f040f6fb2..bdd21ec78 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1645,6 +1645,16 @@ delegatees: description: | Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: True + scopes: + type: array + nullable: True + items: + type: string + enum: + - ALL + - SUBMIT + - APPROVE + example: ["SUBMIT", "APPROVE"] locale: type: object From cfc00aba9e99e07a42fc2ea8d4f742ce1fffbb45 Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Thu, 19 Feb 2026 13:14:08 +0530 Subject: [PATCH 019/107] update redocly version to fix React not defined error (#780) --- .github/workflows/bundler.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bundler.yml b/.github/workflows/bundler.yml index e71212efd..d7f0cb626 100644 --- a/.github/workflows/bundler.yml +++ b/.github/workflows/bundler.yml @@ -28,7 +28,7 @@ jobs: node-version: 22.x - name: Install dependencies - run: npm install -g @redocly/cli@2.0.5 + run: npm install -g @redocly/cli@2.19.0 - name: Update authorization docs run: openapi bundle -o reference/authorization.yaml src/authorization/openapi.yaml From 455ed24aff3e58194dcaff13b203026f35dd6782 Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Fri, 20 Feb 2026 11:45:41 +0530 Subject: [PATCH 020/107] fix: add scopes to employee_rot delegatees (#779) * add scopes to employee_rot delegatees * Auto generate API docs * use common scopes component * Auto generate API docs --- reference/admin.yaml | 29 ++++++++++++++++++---------- reference/approver.yaml | 25 ++++++++++++++---------- reference/manager.yaml | 25 ++++++++++++++---------- reference/spender.yaml | 29 ++++++++++++++++++---------- src/components/schemas/employee.yaml | 4 ++++ src/components/schemas/fields.yaml | 24 +++++++++++++++-------- 6 files changed, 88 insertions(+), 48 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 8a4e58748..be398c495 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -15153,6 +15153,19 @@ components: description: | String denoting the full name of an employee. example: Jon Snow + delegation_access_scope: + type: array + description: | + List of scopes for the delegate. + items: + type: string + enum: + - ALL + - SUBMIT + - APPROVE + example: + - SUBMIT + - APPROVE delegatees: type: object additionalProperties: false @@ -15196,17 +15209,9 @@ components: Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: true scopes: - type: array + allOf: + - $ref: '#/components/schemas/delegation_access_scope' nullable: true - items: - type: string - enum: - - ALL - - SUBMIT - - APPROVE - example: - - SUBMIT - - APPROVE category_out_embed: type: object nullable: true @@ -15736,6 +15741,10 @@ components: description: | Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: true + scopes: + allOf: + - $ref: '#/components/schemas/delegation_access_scope' + nullable: true invitation_in: type: object additionalProperties: false diff --git a/reference/approver.yaml b/reference/approver.yaml index d68ad9315..72d10921d 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -9411,6 +9411,19 @@ components: description: | String denoting the full name of an employee. example: Jon Snow + delegation_access_scope: + type: array + description: | + List of scopes for the delegate. + items: + type: string + enum: + - ALL + - SUBMIT + - APPROVE + example: + - SUBMIT + - APPROVE delegatees: type: object additionalProperties: false @@ -9454,17 +9467,9 @@ components: Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: true scopes: - type: array + allOf: + - $ref: '#/components/schemas/delegation_access_scope' nullable: true - items: - type: string - enum: - - ALL - - SUBMIT - - APPROVE - example: - - SUBMIT - - APPROVE employee_out: type: object additionalProperties: false diff --git a/reference/manager.yaml b/reference/manager.yaml index 3a6b9e41b..d0dc25f41 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -1590,6 +1590,19 @@ components: description: | String denoting the full name of an employee. example: Jon Snow + delegation_access_scope: + type: array + description: | + List of scopes for the delegate. + items: + type: string + enum: + - ALL + - SUBMIT + - APPROVE + example: + - SUBMIT + - APPROVE delegatees: type: object additionalProperties: false @@ -1633,17 +1646,9 @@ components: Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: true scopes: - type: array + allOf: + - $ref: '#/components/schemas/delegation_access_scope' nullable: true - items: - type: string - enum: - - ALL - - SUBMIT - - APPROVE - example: - - SUBMIT - - APPROVE category_out_embed: type: object nullable: true diff --git a/reference/spender.yaml b/reference/spender.yaml index 3df1b9274..56bf201f4 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -14620,6 +14620,19 @@ components: description: | String denoting the full name of an employee. example: Jon Snow + delegation_access_scope: + type: array + description: | + List of scopes for the delegate. + items: + type: string + enum: + - ALL + - SUBMIT + - APPROVE + example: + - SUBMIT + - APPROVE delegatees: type: object additionalProperties: false @@ -14663,17 +14676,9 @@ components: Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: true scopes: - type: array + allOf: + - $ref: '#/components/schemas/delegation_access_scope' nullable: true - items: - type: string - enum: - - ALL - - SUBMIT - - APPROVE - example: - - SUBMIT - - APPROVE spender_employee_out: type: object additionalProperties: false @@ -15088,6 +15093,10 @@ components: description: | Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: true + scopes: + allOf: + - $ref: '#/components/schemas/delegation_access_scope' + nullable: true spender_delegatees_post_out: type: object additionalProperties: false diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index a8f54b335..b80725aed 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -801,6 +801,10 @@ spender_delegatees_post_in: description: | Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: True + scopes: + allOf: + - $ref: './fields.yaml#/delegation_access_scope' + nullable: True spender_delegatees_post_out: type: object diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index bdd21ec78..8d97403fb 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -346,6 +346,15 @@ contains_operator: Value signifying the operator for the field example: IN +delegation_access_scope: + type: array + description: | + List of scopes for the delegate. + items: + type: string + enum: [ALL, SUBMIT, APPROVE] + example: ["SUBMIT", "APPROVE"] + expense_policy_rule_embed: type: object additionalProperties: false @@ -1646,15 +1655,9 @@ delegatees: Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: True scopes: - type: array + allOf: + - $ref: './fields.yaml#/delegation_access_scope' nullable: True - items: - type: string - enum: - - ALL - - SUBMIT - - APPROVE - example: ["SUBMIT", "APPROVE"] locale: type: object @@ -1982,6 +1985,11 @@ delegatee: description: | Date and time till which the delegation is active. If null, delegation is active indefinitely. nullable: True + scopes: + allOf: + - $ref: './fields.yaml#/delegation_access_scope' + nullable: True + subscribed_resources: type: array From a219a372159b7afafec4cdedee39942ba7b3e2b4 Mon Sep 17 00:00:00 2001 From: shubham-fyle Date: Tue, 24 Feb 2026 11:41:06 +0530 Subject: [PATCH 021/107] chore: Clean hash urls (#778) Clickup https://app.clickup.com/ Co-authored-by: Cursor --- docs/concepts/oauth2-application.md | 2 +- reference/accountant.yaml | 2 +- reference/admin.yaml | 2 +- reference/approver.yaml | 2 +- reference/authorization.yaml | 2 +- reference/common.yaml | 2 +- reference/hod.yaml | 2 +- reference/hop.yaml | 2 +- reference/manager.yaml | 2 +- reference/owner.yaml | 2 +- reference/spender.yaml | 2 +- reference/super_admin.yaml | 2 +- src/accountant/openapi.yaml | 2 +- src/admin/openapi.yaml | 2 +- src/approver/openapi.yaml | 2 +- src/authorization/openapi.yaml | 2 +- src/common/openapi.yaml | 2 +- src/hod/openapi.yaml | 2 +- src/hop/openapi.yaml | 2 +- src/manager/openapi.yaml | 2 +- src/owner/openapi.yaml | 2 +- src/spender/openapi.yaml | 2 +- src/super_admin/openapi.yaml | 2 +- 23 files changed, 23 insertions(+), 23 deletions(-) diff --git a/docs/concepts/oauth2-application.md b/docs/concepts/oauth2-application.md index 86872977c..f62e8f46a 100644 --- a/docs/concepts/oauth2-application.md +++ b/docs/concepts/oauth2-application.md @@ -35,7 +35,7 @@ You can add the redirect URIs that you want to allow in the OAuth 2.0 flows. Aft We currently support the "Authorization Code" flow and "Refresh Token Flow" of OAuth 2.0. If you want a primer on these flows, head to this great [blogpost](https://darutk.medium.com/diagrams-and-movies-of-all-the-oauth-2-0-flows-194f3c3ade85), but come back soon! We plan on adding support for PKCE Authorization request in the near future. To authorize the app: -* use the following URL: `https://app.fylehq.com/app/developers/#/oauth/authorize?client_id=&redirect_uri=` +* use the following URL: `https://app.fylehq.com/app/developers/oauth/authorize?client_id=&redirect_uri=` * replace the `` with your `client_id` * replace the `` with your redirect URI * if no redirect URI is setup for your app, you may remove the following from the above URL `&redirect_uri=` diff --git a/reference/accountant.yaml b/reference/accountant.yaml index 55a0ed1ca..4e6ca6648 100644 --- a/reference/accountant.yaml +++ b/reference/accountant.yaml @@ -117,7 +117,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/reference/admin.yaml b/reference/admin.yaml index be398c495..b4c10f3bb 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -13427,7 +13427,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/reference/approver.yaml b/reference/approver.yaml index 72d10921d..8ded31293 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -3961,7 +3961,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/reference/authorization.yaml b/reference/authorization.yaml index 620f476c9..b42cb58a3 100644 --- a/reference/authorization.yaml +++ b/reference/authorization.yaml @@ -126,7 +126,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/reference/common.yaml b/reference/common.yaml index e4e3588a2..e9eee6cde 100644 --- a/reference/common.yaml +++ b/reference/common.yaml @@ -434,7 +434,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/reference/hod.yaml b/reference/hod.yaml index 8a7c782e1..8578423e9 100644 --- a/reference/hod.yaml +++ b/reference/hod.yaml @@ -60,7 +60,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/reference/hop.yaml b/reference/hop.yaml index b32e7f01e..3c64a0008 100644 --- a/reference/hop.yaml +++ b/reference/hop.yaml @@ -60,7 +60,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/reference/manager.yaml b/reference/manager.yaml index d0dc25f41..aef7d349d 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -586,7 +586,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/reference/owner.yaml b/reference/owner.yaml index 0dbb232d8..cb2e521c8 100644 --- a/reference/owner.yaml +++ b/reference/owner.yaml @@ -249,7 +249,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/reference/spender.yaml b/reference/spender.yaml index 56bf201f4..cc2f8ec62 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -7445,7 +7445,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/reference/super_admin.yaml b/reference/super_admin.yaml index f9bb9d177..62716ddb2 100644 --- a/reference/super_admin.yaml +++ b/reference/super_admin.yaml @@ -134,7 +134,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: https://app.fylehq.com/app/developers/#/oauth/authorize + authorizationUrl: https://app.fylehq.com/app/developers/oauth/authorize tokenUrl: https://accounts.fylehq.com/oauth/token scopes: '*': Grant all actions diff --git a/src/accountant/openapi.yaml b/src/accountant/openapi.yaml index ff21fd23c..3f0544412 100644 --- a/src/accountant/openapi.yaml +++ b/src/accountant/openapi.yaml @@ -18,7 +18,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 0d6ade8b3..91c1f0000 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -18,7 +18,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' diff --git a/src/approver/openapi.yaml b/src/approver/openapi.yaml index 80075d34f..e6e1071db 100644 --- a/src/approver/openapi.yaml +++ b/src/approver/openapi.yaml @@ -18,7 +18,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' diff --git a/src/authorization/openapi.yaml b/src/authorization/openapi.yaml index 1e6d58393..2f4dd63ac 100644 --- a/src/authorization/openapi.yaml +++ b/src/authorization/openapi.yaml @@ -18,7 +18,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' diff --git a/src/common/openapi.yaml b/src/common/openapi.yaml index e2ee5a21f..4d8aa455c 100644 --- a/src/common/openapi.yaml +++ b/src/common/openapi.yaml @@ -18,7 +18,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' diff --git a/src/hod/openapi.yaml b/src/hod/openapi.yaml index d28fb4adf..f7a137076 100644 --- a/src/hod/openapi.yaml +++ b/src/hod/openapi.yaml @@ -19,7 +19,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' diff --git a/src/hop/openapi.yaml b/src/hop/openapi.yaml index ba504a9ab..2fe582df1 100644 --- a/src/hop/openapi.yaml +++ b/src/hop/openapi.yaml @@ -19,7 +19,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' diff --git a/src/manager/openapi.yaml b/src/manager/openapi.yaml index e13ed8e37..cb87e3710 100644 --- a/src/manager/openapi.yaml +++ b/src/manager/openapi.yaml @@ -18,7 +18,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' diff --git a/src/owner/openapi.yaml b/src/owner/openapi.yaml index d8675d02a..57c549362 100644 --- a/src/owner/openapi.yaml +++ b/src/owner/openapi.yaml @@ -19,7 +19,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' diff --git a/src/spender/openapi.yaml b/src/spender/openapi.yaml index 79c2f8985..433dd9d2d 100644 --- a/src/spender/openapi.yaml +++ b/src/spender/openapi.yaml @@ -20,7 +20,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' diff --git a/src/super_admin/openapi.yaml b/src/super_admin/openapi.yaml index 4a83d9100..9d7176336 100644 --- a/src/super_admin/openapi.yaml +++ b/src/super_admin/openapi.yaml @@ -18,7 +18,7 @@ components: type: oauth2 flows: authorizationCode: - authorizationUrl: 'https://app.fylehq.com/app/developers/#/oauth/authorize' + authorizationUrl: 'https://app.fylehq.com/app/developers/oauth/authorize' tokenUrl: 'https://accounts.fylehq.com/oauth/token' scopes: '*': 'Grant all actions' From 6bc6336b7d701888708f23b6adc83f499a91f255 Mon Sep 17 00:00:00 2001 From: Kulsekar4 Date: Mon, 9 Mar 2026 09:54:50 +0530 Subject: [PATCH 022/107] feat: FYLE-86d0686td-eligible-cards-new-stats (#781) --- reference/admin.yaml | 8 ++++++++ src/components/schemas/reconciliation_eligible_cards.yaml | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index b4c10f3bb..b618a8374 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -30821,6 +30821,14 @@ components: type: integer description: Number of cards that have only matching issues. example: 0 + card_with_no_issues_found_count: + type: integer + description: Number of cards that have no matching issues found. + example: 0 + card_with_no_transactions_count: + type: integer + description: Number of cards that have no transactions in the period. + example: 0 reconciled_card_count: type: integer description: Number of cards that are reconciled. diff --git a/src/components/schemas/reconciliation_eligible_cards.yaml b/src/components/schemas/reconciliation_eligible_cards.yaml index 1bbf0b7b9..dcdaa36f2 100644 --- a/src/components/schemas/reconciliation_eligible_cards.yaml +++ b/src/components/schemas/reconciliation_eligible_cards.yaml @@ -139,6 +139,14 @@ reconciliation_eligible_cards_stats_out: type: integer description: Number of cards that have only matching issues. example: 0 + card_with_no_issues_found_count: + type: integer + description: Number of cards that have no matching issues found. + example: 0 + card_with_no_transactions_count: + type: integer + description: Number of cards that have no transactions in the period. + example: 0 reconciled_card_count: type: integer description: Number of cards that are reconciled. From b8ac1257179cec4ed7434b167924dedd31da885e Mon Sep 17 00:00:00 2001 From: Kulsekar4 Date: Tue, 17 Mar 2026 13:25:39 +0530 Subject: [PATCH 023/107] feat: FYLE-86d0d4neu-reconcile-action-apis (#732) --- reference/admin.yaml | 1016 +++++++++++++++-- src/admin/openapi.yaml | 22 +- .../admin@reconciliation_entries@close.yaml | 65 ++ ...iation_entries@eligible_cards@exports.yaml | 56 + ...tion_entries@transactions@delete@bulk.yaml | 83 ++ ...iliation_entries@transactions@exports.yaml | 56 + ...ation_entries@transactions@find_match.yaml | 70 ++ ...transactions@match_and_reconcile@bulk.yaml | 90 ++ ...n_entries@transactions@reconcile@bulk.yaml | 83 ++ ...es@transactions@resolve_multi_matches.yaml | 70 ++ ...ion_entries@transactions@unmatch@bulk.yaml | 83 ++ .../schemas/reconciliation_exports.yaml | 138 +++ 12 files changed, 1718 insertions(+), 114 deletions(-) create mode 100644 src/admin/paths/admin@reconciliation_entries@close.yaml create mode 100644 src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml create mode 100644 src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml create mode 100644 src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml create mode 100644 src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml create mode 100644 src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml create mode 100644 src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml create mode 100644 src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml create mode 100644 src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml create mode 100644 src/components/schemas/reconciliation_exports.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index b618a8374..072cba77f 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -12136,36 +12136,207 @@ paths: application/json: schema: $ref: '#/components/schemas/403' - /admin/reconciliation_entries/eligible_cards: - get: + /admin/reconciliation_entries/transactions/reconcile/bulk: + post: tags: - Reconciliation - summary: List eligible cards for a reconciliation entry + summary: Bulk reconcile reconciliation transactions description: | - Returns the list of corporate cards that are eligible for a given reconciliation entry. - To understand filtering, ordering and pagination, see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) - operationId: reconciliation_entries_eligible_cards_list - parameters: - - in: query - name: reconciliation_entry_id - required: true - schema: - type: string - example: receabc12345 - description: | - Reconciliation entry id for which eligible cards should be listed. - - in: query - name: status - required: false - schema: - type: string - example: RECONCILED - description: | - Optional status filter for eligible cards. - - $ref: '#/components/parameters/q' - - $ref: '#/components/parameters/order' - - $ref: '#/components/parameters/offset' - - $ref: '#/components/parameters/limit' + Reconcile multiple reconciliation transactions in bulk. + operationId: reconciliation_transactions_reconcile_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: List of reconciliation transaction identifiers to reconcile. + items: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: Unique id of the reconciliation transaction to reconcile. + example: rectx8abc123 + example: + - id: rectx8abc123 + - id: rectx8xyz789 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: object + description: Result of bulk reconcile. Empty object on success. + example: {} + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '#/components/schemas/bulk_error' + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/reconciliation_entries/transactions/match_and_reconcile/bulk: + post: + tags: + - Reconciliation + summary: Bulk match and reconcile reconciliation transactions + description: | + Match reconciliation transactions with target transactions/expenses and reconcile in bulk. + operationId: reconciliation_transactions_match_and_reconcile_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: List of source and target reconciliation transaction identifiers to match and reconcile. + items: + type: object + additionalProperties: false + required: + - source_id + - target_id + properties: + source_id: + type: string + description: Source reconciliation transaction id. + example: rectx8abc123 + target_id: + type: string + description: Target reconciliation transaction or expense id to match with. + example: rectx8xyz789 + example: + - source_id: rectx8abc123 + target_id: rectx8xyz789 + - source_id: rectx8def456 + target_id: rectx8uvw000 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: object + description: Result of bulk match and reconcile. Empty object on success. + example: {} + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '#/components/schemas/bulk_error' + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/reconciliation_entries/transactions/find_match: + post: + tags: + - Reconciliation + summary: Find matches for a reconciliation transaction + description: | + Find potential matching expenses for a reconciliation transaction. + operationId: reconciliation_transactions_find_match + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: Unique id of the reconciliation transaction for which to find matches. + example: rectx8abc123 responses: '200': description: OK @@ -12173,15 +12344,17 @@ paths: application/json: schema: type: object + additionalProperties: false properties: + data: + type: array + description: List of potential matches for the provided reconciliation transaction. + items: + $ref: '#/components/schemas/reconciliation_transaction_out' count: $ref: '#/components/schemas/count' offset: $ref: '#/components/schemas/offset' - data: - type: array - items: - $ref: '#/components/schemas/reconciliation_eligible_card_out' '400': description: Bad request content: @@ -12206,16 +12379,483 @@ paths: application/json: schema: $ref: '#/components/schemas/404' - /admin/reconciliation_entries/eligible_cards/stats: + /admin/reconciliation_entries/transactions/stats: post: tags: - Reconciliation - summary: Stats for eligible cards of a reconciliation entry + summary: Reconciliation Transactions Stats description: | - Returns aggregate stats for corporate cards eligible under a reconciliation entry. + Retrieve stats for reconciliation transactions within a reconciliation period and optional filters. - Use this endpoint to get period window, transaction and expense totals, differences, and card-level aggregate counts such as matching issues and reconciliation status. - operationId: reconciliation_entries_eligible_cards_stats + Use this endpoint to compute counts and totals of statement transactions and matched expenses, and identify differences for reconciliation analysis. Pass filters using `query_params` similar to the reconciliation transactions GET list API. + operationId: reconciliation_transactions_stats + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/reconciliation_transactions_stats_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/reconciliation_transactions_stats_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/reconciliation_entries/eligible_cards: + get: + tags: + - Reconciliation + summary: List eligible cards for a reconciliation entry + description: | + Returns the list of corporate cards that are eligible for a given reconciliation entry. + To understand filtering, ordering and pagination, see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + operationId: reconciliation_entries_eligible_cards_list + parameters: + - in: query + name: reconciliation_entry_id + required: true + schema: + type: string + example: receabc12345 + description: | + Reconciliation entry id for which eligible cards should be listed. + - in: query + name: status + required: false + schema: + type: string + example: RECONCILED + description: | + Optional status filter for eligible cards. + - $ref: '#/components/parameters/q' + - $ref: '#/components/parameters/order' + - $ref: '#/components/parameters/offset' + - $ref: '#/components/parameters/limit' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + $ref: '#/components/schemas/count' + offset: + $ref: '#/components/schemas/offset' + data: + type: array + items: + $ref: '#/components/schemas/reconciliation_eligible_card_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/reconciliation_entries/eligible_cards/stats: + post: + tags: + - Reconciliation + summary: Stats for eligible cards of a reconciliation entry + description: | + Returns aggregate stats for corporate cards eligible under a reconciliation entry. + + Use this endpoint to get period window, transaction and expense totals, differences, and card-level aggregate counts such as matching issues and reconciliation status. + operationId: reconciliation_entries_eligible_cards_stats + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/reconciliation_eligible_cards_stats_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/reconciliation_eligible_cards_stats_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/reconciliation_entries/eligible_cards/exports: + post: + tags: + - Reconciliation + summary: Create eligible cards export + description: | + Create an export request for reconciliation eligible cards. The export is processed asynchronously. + When ready, the specified notify_emails will receive the export file. Use query_params to filter + the eligible cards (e.g. reconciliation_entry_id=eq.). + operationId: reconciliation_eligible_cards_exports_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/reconciliation_export_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/reconciliation_export_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/reconciliation_entries/transactions/delete/bulk: + post: + tags: + - Reconciliation + summary: Bulk delete reconciliation transactions + description: | + Delete multiple reconciliation transactions in bulk. + operationId: reconciliation_transactions_delete_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: List of reconciliation transaction identifiers to delete. + items: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: Unique id of the reconciliation transaction to delete. + example: rectx8abc123 + example: + - id: rectx8abc123 + - id: rectx8xyz789 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: object + description: Result of bulk delete. Empty object on success. + example: {} + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '#/components/schemas/bulk_error' + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/reconciliation_entries/transactions/unmatch/bulk: + post: + tags: + - Reconciliation + summary: Bulk unmatch reconciliation transactions + description: | + Unmatch multiple reconciliation transactions in bulk. + operationId: reconciliation_transactions_unmatch_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: List of reconciliation transaction identifiers to unmatch. + items: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: Unique id of the reconciliation transaction to unmatch. + example: rectx8abc123 + example: + - id: rectx8abc123 + - id: rectx8xyz789 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: object + description: Result of bulk unmatch. Empty object on success. + example: {} + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '#/components/schemas/bulk_error' + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/reconciliation_entries/transactions/move_to_next_period/bulk: + post: + tags: + - Reconciliation + summary: Move reconciliation transactions to next period + description: | + This API moves one or more reconciliation transactions from their current reconciliation period + to the next reconciliation period. This is useful when transactions need to be deferred to a + future reconciliation cycle. + operationId: post_move_to_next_period_reconciliation_transactions_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '#/components/schemas/move_to_next_period_from_reconciliation_transaction_in' + description: List of reconciliation transaction objects to move to the next period. + example: + - id: rectx8abc123 + - id: rectx9def456 + required: + - data + responses: + '200': + description: OK - Transactions successfully moved to next period + content: + application/json: + schema: + type: object + properties: + data: + type: object + description: Empty object on success + '400': + description: Bad request - Invalid transaction IDs, transactions already reconciled, transactions from different periods, or inconsistent reconciliation entries + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden - User doesn't have required permissions (ADMIN, FINANCE, VERIFIER, PAYMENT_PROCESSOR, or AUDITOR role required) + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found - Reconciliation transaction not found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/reconciliation_entries/transactions/resolve_multi_matches: + post: + tags: + - Reconciliation + summary: Resolve multiple matches for a reconciliation transaction + description: | + Resolve multiple potential matches by selecting a specific expense for a reconciliation transaction. + operationId: reconciliation_transactions_resolve_multi_matches requestBody: required: true content: @@ -12227,7 +12867,20 @@ paths: - data properties: data: - $ref: '#/components/schemas/reconciliation_eligible_cards_stats_in' + type: object + additionalProperties: false + required: + - id + - expense_id + properties: + id: + type: string + description: Reconciliation transaction id for which to resolve multiple matches. + example: rectx8abc123 + expense_id: + type: string + description: Selected expense id to resolve against. + example: txuXDH16HzK responses: '200': description: OK @@ -12238,7 +12891,9 @@ paths: additionalProperties: false properties: data: - $ref: '#/components/schemas/reconciliation_eligible_cards_stats_out' + type: object + description: Result of resolve operation. Empty object on success. + example: {} '400': description: Bad request content: @@ -12263,16 +12918,16 @@ paths: application/json: schema: $ref: '#/components/schemas/404' - /admin/reconciliation_entries/transactions/stats: + /admin/reconciliation_entries/transactions/exports: post: tags: - Reconciliation - summary: Reconciliation Transactions Stats + summary: Create transactions export description: | - Retrieve stats for reconciliation transactions within a reconciliation period and optional filters. - - Use this endpoint to compute counts and totals of statement transactions and matched expenses, and identify differences for reconciliation analysis. Pass filters using `query_params` similar to the reconciliation transactions GET list API. - operationId: reconciliation_transactions_stats + Create an export request for reconciliation transactions. The export is processed asynchronously. + When ready, the specified notify_emails will receive the export file. Use query_params to filter + the transactions (e.g. reconciliation_entry_id=eq.). + operationId: reconciliation_transactions_exports_post requestBody: required: true content: @@ -12284,7 +12939,7 @@ paths: - data properties: data: - $ref: '#/components/schemas/reconciliation_transactions_stats_in' + $ref: '#/components/schemas/reconciliation_export_in' responses: '200': description: OK @@ -12295,7 +12950,7 @@ paths: additionalProperties: false properties: data: - $ref: '#/components/schemas/reconciliation_transactions_stats_out' + $ref: '#/components/schemas/reconciliation_export_out' '400': description: Bad request content: @@ -12320,46 +12975,49 @@ paths: application/json: schema: $ref: '#/components/schemas/404' - /admin/reconciliation_entries/transactions/move_to_next_period/bulk: + /admin/reconciliation_entries/close: post: tags: - Reconciliation - summary: Move reconciliation transactions to next period + summary: Close reconciliation entry description: | - This API moves one or more reconciliation transactions from their current reconciliation period - to the next reconciliation period. This is useful when transactions need to be deferred to a - future reconciliation cycle. - operationId: post_move_to_next_period_reconciliation_transactions_bulk + Mark a reconciliation entry as reconciled/closed. + operationId: reconciliation_entries_close requestBody: required: true content: application/json: schema: type: object - properties: - data: - type: array - items: - $ref: '#/components/schemas/move_to_next_period_from_reconciliation_transaction_in' - description: List of reconciliation transaction objects to move to the next period. - example: - - id: rectx8abc123 - - id: rectx9def456 + additionalProperties: false required: - data + properties: + data: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: Reconciliation entry id to close. + example: receabc12345 responses: '200': - description: OK - Transactions successfully moved to next period + description: OK content: application/json: schema: type: object + additionalProperties: false properties: data: type: object - description: Empty object on success + description: Result of close operation. Empty object on success. + example: {} '400': - description: Bad request - Invalid transaction IDs, transactions already reconciled, transactions from different periods, or inconsistent reconciliation entries + description: Bad request content: application/json: schema: @@ -12371,13 +13029,13 @@ paths: schema: $ref: '#/components/schemas/401' '403': - description: Forbidden - User doesn't have required permissions (ADMIN, FINANCE, VERIFIER, PAYMENT_PROCESSOR, or AUDITOR role required) + description: Forbidden content: application/json: schema: $ref: '#/components/schemas/403' '404': - description: Not Found - Reconciliation transaction not found + description: Not Found content: application/json: schema: @@ -30682,6 +31340,63 @@ components: updated_at: $ref: '#/components/schemas/updated_at' description: Timestamp when this reconciliation transaction record was last updated. + reconciliation_transactions_stats_in: + type: object + additionalProperties: false + description: | + Input to fetch reconciliation transactions stats for a specific card or filter. + Pass filters using the `query_params` string similar to the GET list API. + For example, filter by a single card using `corporate_card_id=eq.`. + properties: + query_params: + type: string + description: | + Query param string similar to reconciliation transactions GET call. Use this to filter the population + before computing stats. For individual card stats, pass `corporate_card_id=eq.`. + example: corporate_card_id=eq.bawownwrng + reconciliation_transactions_stats_out: + type: object + additionalProperties: false + description: | + Reconciliation transactions statistics for the selected filter period. + properties: + period_start: + type: string + format: date-time + description: Start of the reconciliation period in UTC. + example: '2025-10-01T00:00:00.000+00:00' + period_end: + type: string + format: date-time + description: End of the reconciliation period in UTC. + example: '2025-10-31T23:59:59.999+00:00' + statement_transaction_count: + type: integer + description: Number of statement transactions considered in the period. + example: 3 + expense_count: + type: integer + description: Number of expenses considered in the period. + example: 2 + statement_total: + type: number + format: double + description: Sum of statement transaction amounts considered in the period. + example: 45 + expense_total: + type: number + format: double + description: Sum of expense amounts considered in the period. + example: 30 + difference: + type: number + format: double + description: Difference between statement total and expense total (statement_total - expense_total). + example: 15 + matching_issue_count: + type: integer + description: Count of matching issues for transactions in the period. + example: 3 reconciliation_eligible_card_out: type: object additionalProperties: false @@ -30833,63 +31548,140 @@ components: type: integer description: Number of cards that are reconciled. example: 0 - reconciliation_transactions_stats_in: + reconciliation_export_config_column_formula: type: object - additionalProperties: false + properties: + function: + type: string + example: Field + parameters: + type: array + items: + anyOf: + - type: object + - type: string + - type: number + - type: integer + - type: boolean description: | - Input to fetch reconciliation transactions stats for a specific card or filter. - Pass filters using the `query_params` string similar to the GET list API. - For example, filter by a single card using `corporate_card_id=eq.`. + Export column formula used to transform the data. + reconciliation_export_config: + type: object + additionalProperties: true + required: + - type + - is_header_visible + - columns + properties: + type: + type: string + enum: + - xlsx + - csv + description: Type of the export file. + example: csv + is_header_visible: + type: boolean + description: Whether to show the header in the export file. + example: true + separate_line_items_entry: + type: object + nullable: true + properties: + enabled: + type: boolean + description: Whether to show the double rows for each line item in the export file. + debit_entries_only: + type: array + items: + type: string + description: Configure which columns to show for debit entries. + credit_entries_only: + type: array + items: + type: string + description: Configure which columns to show for credit entries. + description: Configure how to show the double rows for each line item, if enabled. + columns: + type: array + items: + type: object + properties: + name: + type: string + description: Name of the column. + formula: + $ref: '#/components/schemas/reconciliation_export_config_column_formula' + required: + - name + - formula + description: Configure the columns to show in the export file. + reconciliation_export_in: + type: object + additionalProperties: false + required: + - query_params + - notify_emails + - config properties: query_params: type: string + nullable: false description: | - Query param string similar to reconciliation transactions GET call. Use this to filter the population - before computing stats. For individual card stats, pass `corporate_card_id=eq.`. - example: corporate_card_id=eq.bawownwrng - reconciliation_transactions_stats_out: + Query param string similar to the GET list API for the resource (eligible cards or transactions). + For eligible cards export use e.g. reconciliation_entry_id=eq.. + For transactions export use e.g. reconciliation_entry_id=eq.. + example: reconciliation_entry_id=eq.rece_seed_2 + notify_emails: + type: array + nullable: false + items: + $ref: '#/components/schemas/email' + description: List of emails to notify when the export is ready. + config: + $ref: '#/components/schemas/reconciliation_export_config' + nullable: false + description: Configuration for the export. + reconciliation_export_out: type: object additionalProperties: false - description: | - Reconciliation transactions statistics for the selected filter period. properties: - period_start: + id: + allOf: + - $ref: '#/components/schemas/id_string' + description: Unique id of the export. + org_id: + $ref: '#/components/schemas/org_id' + file_id: + anyOf: + - $ref: '#/components/schemas/null_field' + - $ref: '#/components/schemas/id_string' + nullable: true + description: File id when export is completed (null while pending/processing). + state: type: string - format: date-time - description: Start of the reconciliation period in UTC. - example: '2025-10-01T00:00:00.000+00:00' - period_end: + nullable: false + enum: + - PENDING + - PROCESSING + - SUCCESS + - ERROR + description: Status of the export. + example: PENDING + query_params: type: string - format: date-time - description: End of the reconciliation period in UTC. - example: '2025-10-31T23:59:59.999+00:00' - statement_transaction_count: - type: integer - description: Number of statement transactions considered in the period. - example: 3 - expense_count: - type: integer - description: Number of expenses considered in the period. - example: 2 - statement_total: - type: number - format: double - description: Sum of statement transaction amounts considered in the period. - example: 45 - expense_total: - type: number - format: double - description: Sum of expense amounts considered in the period. - example: 30 - difference: - type: number - format: double - description: Difference between statement total and expense total (statement_total - expense_total). - example: 15 - matching_issue_count: - type: integer - description: Count of matching issues for transactions in the period. - example: 3 + nullable: false + description: Query params used for this export. + notify_emails: + type: array + nullable: false + items: + $ref: '#/components/schemas/email' + description: List of emails to notify when the export is ready. + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' move_to_next_period_from_reconciliation_transaction_in: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 91c1f0000..f66e2c651 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -544,14 +544,32 @@ paths: $ref: paths/admin@reconciliation_entries@create.yaml /admin/reconciliation_entries/transactions: $ref: paths/admin@reconciliation_entries@transactions.yaml + /admin/reconciliation_entries/transactions/reconcile/bulk: + $ref: paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml + /admin/reconciliation_entries/transactions/match_and_reconcile/bulk: + $ref: paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml + /admin/reconciliation_entries/transactions/find_match: + $ref: paths/admin@reconciliation_entries@transactions@find_match.yaml + /admin/reconciliation_entries/transactions/stats: + $ref: paths/admin@reconciliation_entries@transactions@stats.yaml /admin/reconciliation_entries/eligible_cards: $ref: paths/admin@reconciliation_entries@eligible_cards.yaml /admin/reconciliation_entries/eligible_cards/stats: $ref: paths/admin@reconciliation_entries@eligible_cards@stats.yaml - /admin/reconciliation_entries/transactions/stats: - $ref: paths/admin@reconciliation_entries@transactions@stats.yaml + /admin/reconciliation_entries/eligible_cards/exports: + $ref: paths/admin@reconciliation_entries@eligible_cards@exports.yaml + /admin/reconciliation_entries/transactions/delete/bulk: + $ref: paths/admin@reconciliation_entries@transactions@delete@bulk.yaml + /admin/reconciliation_entries/transactions/unmatch/bulk: + $ref: paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml /admin/reconciliation_entries/transactions/move_to_next_period/bulk: $ref: paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml + /admin/reconciliation_entries/transactions/resolve_multi_matches: + $ref: paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml + /admin/reconciliation_entries/transactions/exports: + $ref: paths/admin@reconciliation_entries@transactions@exports.yaml + /admin/reconciliation_entries/close: + $ref: paths/admin@reconciliation_entries@close.yaml /admin/expenses/delete/bulk: $ref: paths/admin@expenses@delete@bulk.yaml /admin/employee_settings: diff --git a/src/admin/paths/admin@reconciliation_entries@close.yaml b/src/admin/paths/admin@reconciliation_entries@close.yaml new file mode 100644 index 000000000..5e8b56b7d --- /dev/null +++ b/src/admin/paths/admin@reconciliation_entries@close.yaml @@ -0,0 +1,65 @@ +post: + tags: + - Reconciliation + summary: Close reconciliation entry + description: | + Mark a reconciliation entry as reconciled/closed. + operationId: reconciliation_entries_close + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: Reconciliation entry id to close. + example: receabc12345 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: object + description: Result of close operation. Empty object on success. + example: {} + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' + diff --git a/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml b/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml new file mode 100644 index 000000000..3755c345e --- /dev/null +++ b/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml @@ -0,0 +1,56 @@ +post: + tags: + - Reconciliation + summary: Create eligible cards export + description: | + Create an export request for reconciliation eligible cards. The export is processed asynchronously. + When ready, the specified notify_emails will receive the export file. Use query_params to filter + the eligible cards (e.g. reconciliation_entry_id=eq.). + operationId: reconciliation_eligible_cards_exports_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../../components/schemas/reconciliation_exports.yaml#/reconciliation_export_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '../../components/schemas/reconciliation_exports.yaml#/reconciliation_export_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml new file mode 100644 index 000000000..698c0e4be --- /dev/null +++ b/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml @@ -0,0 +1,83 @@ +post: + tags: + - Reconciliation + summary: Bulk delete reconciliation transactions + description: | + Delete multiple reconciliation transactions in bulk. + operationId: reconciliation_transactions_delete_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: List of reconciliation transaction identifiers to delete. + items: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: Unique id of the reconciliation transaction to delete. + example: rectx8abc123 + example: + - id: rectx8abc123 + - id: rectx8xyz789 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: object + description: Result of bulk delete. Empty object on success. + example: {} + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '../../components/schemas/bulk_error.yaml' + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' + diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml new file mode 100644 index 000000000..0d4f54b96 --- /dev/null +++ b/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml @@ -0,0 +1,56 @@ +post: + tags: + - Reconciliation + summary: Create transactions export + description: | + Create an export request for reconciliation transactions. The export is processed asynchronously. + When ready, the specified notify_emails will receive the export file. Use query_params to filter + the transactions (e.g. reconciliation_entry_id=eq.). + operationId: reconciliation_transactions_exports_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../../components/schemas/reconciliation_exports.yaml#/reconciliation_export_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '../../components/schemas/reconciliation_exports.yaml#/reconciliation_export_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml new file mode 100644 index 000000000..2585e3f40 --- /dev/null +++ b/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml @@ -0,0 +1,70 @@ +post: + tags: + - Reconciliation + summary: Find matches for a reconciliation transaction + description: | + Find potential matching expenses for a reconciliation transaction. + operationId: reconciliation_transactions_find_match + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: Unique id of the reconciliation transaction for which to find matches. + example: rectx8abc123 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: array + description: List of potential matches for the provided reconciliation transaction. + items: + $ref: '../../components/schemas/reconciliation_transactions.yaml#/reconciliation_transaction_out' + count: + $ref: '../../components/schemas/count.yaml' + offset: + $ref: '../../components/schemas/offset.yaml' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' + diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml new file mode 100644 index 000000000..70600a3d6 --- /dev/null +++ b/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml @@ -0,0 +1,90 @@ +post: + tags: + - Reconciliation + summary: Bulk match and reconcile reconciliation transactions + description: | + Match reconciliation transactions with target transactions/expenses and reconcile in bulk. + operationId: reconciliation_transactions_match_and_reconcile_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: List of source and target reconciliation transaction identifiers to match and reconcile. + items: + type: object + additionalProperties: false + required: + - source_id + - target_id + properties: + source_id: + type: string + description: Source reconciliation transaction id. + example: rectx8abc123 + target_id: + type: string + description: Target reconciliation transaction or expense id to match with. + example: rectx8xyz789 + example: + - source_id: rectx8abc123 + target_id: rectx8xyz789 + - source_id: rectx8def456 + target_id: rectx8uvw000 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: object + description: Result of bulk match and reconcile. Empty object on success. + example: {} + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '../../components/schemas/bulk_error.yaml' + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' + diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml new file mode 100644 index 000000000..92b38f5be --- /dev/null +++ b/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml @@ -0,0 +1,83 @@ +post: + tags: + - Reconciliation + summary: Bulk reconcile reconciliation transactions + description: | + Reconcile multiple reconciliation transactions in bulk. + operationId: reconciliation_transactions_reconcile_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: List of reconciliation transaction identifiers to reconcile. + items: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: Unique id of the reconciliation transaction to reconcile. + example: rectx8abc123 + example: + - id: rectx8abc123 + - id: rectx8xyz789 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: object + description: Result of bulk reconcile. Empty object on success. + example: {} + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '../../components/schemas/bulk_error.yaml' + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' + diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml new file mode 100644 index 000000000..d54070960 --- /dev/null +++ b/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml @@ -0,0 +1,70 @@ +post: + tags: + - Reconciliation + summary: Resolve multiple matches for a reconciliation transaction + description: | + Resolve multiple potential matches by selecting a specific expense for a reconciliation transaction. + operationId: reconciliation_transactions_resolve_multi_matches + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: object + additionalProperties: false + required: + - id + - expense_id + properties: + id: + type: string + description: Reconciliation transaction id for which to resolve multiple matches. + example: rectx8abc123 + expense_id: + type: string + description: Selected expense id to resolve against. + example: txuXDH16HzK + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: object + description: Result of resolve operation. Empty object on success. + example: {} + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' + diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml new file mode 100644 index 000000000..fbd004c12 --- /dev/null +++ b/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml @@ -0,0 +1,83 @@ +post: + tags: + - Reconciliation + summary: Bulk unmatch reconciliation transactions + description: | + Unmatch multiple reconciliation transactions in bulk. + operationId: reconciliation_transactions_unmatch_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: List of reconciliation transaction identifiers to unmatch. + items: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: Unique id of the reconciliation transaction to unmatch. + example: rectx8abc123 + example: + - id: rectx8abc123 + - id: rectx8xyz789 + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + type: object + description: Result of bulk unmatch. Empty object on success. + example: {} + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '../../components/schemas/bulk_error.yaml' + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' + diff --git a/src/components/schemas/reconciliation_exports.yaml b/src/components/schemas/reconciliation_exports.yaml new file mode 100644 index 000000000..2b13a5630 --- /dev/null +++ b/src/components/schemas/reconciliation_exports.yaml @@ -0,0 +1,138 @@ +# Shared config for reconciliation exports (eligible cards and transactions) +reconciliation_export_config_column_formula: + type: object + properties: + function: + type: string + example: Field + parameters: + type: array + items: + anyOf: + - type: object + - type: string + - type: number + - type: integer + - type: boolean + description: | + Export column formula used to transform the data. + +reconciliation_export_config: + type: object + additionalProperties: true + required: + - type + - is_header_visible + - columns + properties: + type: + type: string + enum: + - xlsx + - csv + description: Type of the export file. + example: csv + is_header_visible: + type: boolean + description: Whether to show the header in the export file. + example: true + separate_line_items_entry: + type: object + nullable: true + properties: + enabled: + type: boolean + description: Whether to show the double rows for each line item in the export file. + debit_entries_only: + type: array + items: + type: string + description: Configure which columns to show for debit entries. + credit_entries_only: + type: array + items: + type: string + description: Configure which columns to show for credit entries. + description: Configure how to show the double rows for each line item, if enabled. + columns: + type: array + items: + type: object + properties: + name: + type: string + description: Name of the column. + formula: + $ref: '#/reconciliation_export_config_column_formula' + required: + - name + - formula + description: Configure the columns to show in the export file. + +reconciliation_export_in: + type: object + additionalProperties: false + required: + - query_params + - notify_emails + - config + properties: + query_params: + type: string + nullable: false + description: | + Query param string similar to the GET list API for the resource (eligible cards or transactions). + For eligible cards export use e.g. reconciliation_entry_id=eq.. + For transactions export use e.g. reconciliation_entry_id=eq.. + example: reconciliation_entry_id=eq.rece_seed_2 + notify_emails: + type: array + nullable: false + items: + $ref: './fields.yaml#/email' + description: List of emails to notify when the export is ready. + config: + $ref: '#/reconciliation_export_config' + nullable: false + description: Configuration for the export. + +reconciliation_export_out: + type: object + additionalProperties: false + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + description: Unique id of the export. + org_id: + $ref: './fields.yaml#/org_id' + file_id: + anyOf: + - $ref: './fields.yaml#/null_field' + - $ref: './fields.yaml#/id_string' + nullable: true + description: File id when export is completed (null while pending/processing). + state: + type: string + nullable: false + enum: + - PENDING + - PROCESSING + - SUCCESS + - ERROR + description: Status of the export. + example: PENDING + query_params: + type: string + nullable: false + description: Query params used for this export. + notify_emails: + type: array + nullable: false + items: + $ref: './fields.yaml#/email' + description: List of emails to notify when the export is ready. + created_at: + $ref: './fields.yaml#/created_at' + updated_at: + $ref: './fields.yaml#/updated_at' From 0f3c28eca78790355f5f5d0164bbdf69c4bc5ef3 Mon Sep 17 00:00:00 2001 From: Anjanna Date: Tue, 17 Mar 2026 14:51:46 +0530 Subject: [PATCH 024/107] feat: Added api docs for report Revert to Processing api (#782) * added api docs for revert to processing report api * Auto generate API docs --- reference/admin.yaml | 69 +++++++++++++++++++ src/admin/openapi.yaml | 2 + .../admin@reports@revert_to_processing.yaml | 59 ++++++++++++++++ src/components/schemas/report.yaml | 10 +++ 4 files changed, 140 insertions(+) create mode 100644 src/admin/paths/admin@reports@revert_to_processing.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 072cba77f..784343321 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -5985,6 +5985,66 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/reports/revert_to_processing: + post: + tags: + - Reports + summary: Revert report to Processing + description: | + Move a Closed report back to Processing state. + operationId: report_revert_to_processing + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/revert_to_processing_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/admin_report_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + type: object + properties: + message: + type: string + description: | + This error means current user does not have enough permissions to perform this operation. + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/reports/process_ach/bulk: post: tags: @@ -21756,6 +21816,15 @@ components: description: | Specify why you are sending back the report. example: Amount is incorrect + revert_to_processing_in: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: rp13tP1HVeqa + required: + - id process_ach_in: type: object properties: diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index f66e2c651..f88928376 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -315,6 +315,8 @@ paths: $ref: 'paths/admin@reports@admin_approve@bulk.yaml' /admin/reports/send_back: $ref: 'paths/admin@reports@send_back.yaml' + /admin/reports/revert_to_processing: + $ref: 'paths/admin@reports@revert_to_processing.yaml' /admin/reports/process_ach/bulk: $ref: paths/admin@reports@process_ach@bulk.yaml /admin/reports/mark_paid/bulk: diff --git a/src/admin/paths/admin@reports@revert_to_processing.yaml b/src/admin/paths/admin@reports@revert_to_processing.yaml new file mode 100644 index 000000000..6d00142dd --- /dev/null +++ b/src/admin/paths/admin@reports@revert_to_processing.yaml @@ -0,0 +1,59 @@ +post: + tags: + - Reports + summary: Revert report to Processing + description: | + Move a Closed report back to Processing state. + operationId: report_revert_to_processing + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../../components/schemas/report.yaml#/revert_to_processing_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '../../components/schemas/report.yaml#/admin_report_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + type: object + properties: + message: + type: string + description: | + This error means current user does not have enough permissions to perform this operation. + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/components/schemas/report.yaml b/src/components/schemas/report.yaml index 1533d5a5a..886d35c1b 100644 --- a/src/components/schemas/report.yaml +++ b/src/components/schemas/report.yaml @@ -937,6 +937,16 @@ process_ach_in: required: - id +revert_to_processing_in: + type: object + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: rp13tP1HVeqa + required: + - id + mark_paid_bulk_in: type: object required: From 1199418ec42a8779608cc29bb2e125a89dc7457b Mon Sep 17 00:00:00 2001 From: satyamyesj <49139311+satyamyesj@users.noreply.github.com> Date: Wed, 18 Mar 2026 13:35:18 +0530 Subject: [PATCH 025/107] feat: Updated doc for reconciliation txn expense obj (#783) * feat: Updated doc for reconciliation txn expense obj * Auto generate API docs --------- Co-authored-by: satyamyesj-outlook --- reference/admin.yaml | 50 +++++++++++++++++-- ...ation_entries@transactions@find_match.yaml | 4 -- .../schemas/reconciliation_transactions.yaml | 46 +++++++++++++++++ 3 files changed, 92 insertions(+), 8 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 784343321..d8be0261d 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -12411,10 +12411,6 @@ paths: description: List of potential matches for the provided reconciliation transaction. items: $ref: '#/components/schemas/reconciliation_transaction_out' - count: - $ref: '#/components/schemas/count' - offset: - $ref: '#/components/schemas/offset' '400': description: Bad request content: @@ -31241,6 +31237,29 @@ components: nullable: true example: Team lunch description: Purpose or description of this split line. + matched_corporate_card_transaction: + type: object + nullable: true + description: Matched corporate card transaction details for this expense, if any. + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: btxnwownwrng + description: Id of the matched corporate card transaction. + status: + type: string + enum: + - PENDING + - POSTED + description: Status of the matched corporate card transaction. + example: POSTED + files: + type: array + nullable: true + description: List of files attached to this expense split. + items: + $ref: '#/components/schemas/file_out_embed' reconciliation_matched_expense_out_embed: type: object additionalProperties: false @@ -31322,6 +31341,29 @@ components: nullable: true example: Team lunch description: Purpose or description of the expense. + matched_corporate_card_transaction: + type: object + nullable: true + description: Matched corporate card transaction details for this expense, if any. + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: btxnwownwrng + description: Id of the matched corporate card transaction. + status: + type: string + enum: + - PENDING + - POSTED + description: Status of the matched corporate card transaction. + example: POSTED + files: + type: array + nullable: true + description: List of files attached to this expense. + items: + $ref: '#/components/schemas/file_out_embed' splits: type: array nullable: true diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml index 2585e3f40..40c7ee40e 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml @@ -39,10 +39,6 @@ post: description: List of potential matches for the provided reconciliation transaction. items: $ref: '../../components/schemas/reconciliation_transactions.yaml#/reconciliation_transaction_out' - count: - $ref: '../../components/schemas/count.yaml' - offset: - $ref: '../../components/schemas/offset.yaml' '400': description: Bad request content: diff --git a/src/components/schemas/reconciliation_transactions.yaml b/src/components/schemas/reconciliation_transactions.yaml index d2b5d7923..15e651cad 100644 --- a/src/components/schemas/reconciliation_transactions.yaml +++ b/src/components/schemas/reconciliation_transactions.yaml @@ -149,6 +149,29 @@ reconciliation_expense_split_out_embed: nullable: true example: Team lunch description: Purpose or description of this split line. + matched_corporate_card_transaction: + type: object + nullable: true + description: Matched corporate card transaction details for this expense, if any. + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: btxnwownwrng + description: Id of the matched corporate card transaction. + status: + type: string + enum: + - PENDING + - POSTED + description: Status of the matched corporate card transaction. + example: POSTED + files: + type: array + nullable: true + description: List of files attached to this expense split. + items: + $ref: './file.yaml#/file_out_embed' reconciliation_matched_expense_out_embed: type: object @@ -229,6 +252,29 @@ reconciliation_matched_expense_out_embed: nullable: true example: Team lunch description: Purpose or description of the expense. + matched_corporate_card_transaction: + type: object + nullable: true + description: Matched corporate card transaction details for this expense, if any. + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: btxnwownwrng + description: Id of the matched corporate card transaction. + status: + type: string + enum: + - PENDING + - POSTED + description: Status of the matched corporate card transaction. + example: POSTED + files: + type: array + nullable: true + description: List of files attached to this expense. + items: + $ref: './file.yaml#/file_out_embed' splits: type: array nullable: true From 15e0b10881f5f4e00779685ab3fadb415b0c0321 Mon Sep 17 00:00:00 2001 From: Anjanna Date: Mon, 23 Mar 2026 09:45:40 +0530 Subject: [PATCH 026/107] feat: Added api docs for revert report to approved state api (#784) * added api docs for revert report to approved state api * updated summary of the api * Auto generate API docs --- reference/admin.yaml | 69 +++++++++++++++++++ src/admin/openapi.yaml | 2 + .../admin@reports@revert_to_approved.yaml | 59 ++++++++++++++++ src/components/schemas/report.yaml | 10 +++ 4 files changed, 140 insertions(+) create mode 100644 src/admin/paths/admin@reports@revert_to_approved.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index d8be0261d..3971f34a6 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -6045,6 +6045,66 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/reports/revert_to_approved: + post: + tags: + - Reports + summary: Revert report to Approved state + description: | + Move a Closed or Processing report back to Approved state. + operationId: report_revert_to_approved + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/revert_to_approved_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/admin_report_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + type: object + properties: + message: + type: string + description: | + This error means current user does not have enough permissions to perform this operation. + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/reports/process_ach/bulk: post: tags: @@ -21821,6 +21881,15 @@ components: example: rp13tP1HVeqa required: - id + revert_to_approved_in: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: rp13tP1HVeqa + required: + - id process_ach_in: type: object properties: diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index f88928376..b6c56fb60 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -317,6 +317,8 @@ paths: $ref: 'paths/admin@reports@send_back.yaml' /admin/reports/revert_to_processing: $ref: 'paths/admin@reports@revert_to_processing.yaml' + /admin/reports/revert_to_approved: + $ref: 'paths/admin@reports@revert_to_approved.yaml' /admin/reports/process_ach/bulk: $ref: paths/admin@reports@process_ach@bulk.yaml /admin/reports/mark_paid/bulk: diff --git a/src/admin/paths/admin@reports@revert_to_approved.yaml b/src/admin/paths/admin@reports@revert_to_approved.yaml new file mode 100644 index 000000000..7c411b0ba --- /dev/null +++ b/src/admin/paths/admin@reports@revert_to_approved.yaml @@ -0,0 +1,59 @@ +post: + tags: + - Reports + summary: Revert report to Approved state + description: | + Move a Closed or Processing report back to Approved state. + operationId: report_revert_to_approved + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../../components/schemas/report.yaml#/revert_to_approved_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '../../components/schemas/report.yaml#/admin_report_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + type: object + properties: + message: + type: string + description: | + This error means current user does not have enough permissions to perform this operation. + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/components/schemas/report.yaml b/src/components/schemas/report.yaml index 886d35c1b..7114ecd27 100644 --- a/src/components/schemas/report.yaml +++ b/src/components/schemas/report.yaml @@ -947,6 +947,16 @@ revert_to_processing_in: required: - id +revert_to_approved_in: + type: object + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: rp13tP1HVeqa + required: + - id + mark_paid_bulk_in: type: object required: From d4ea46c61e1bc4675e993131ec872ab1cd131e50 Mon Sep 17 00:00:00 2001 From: Sumit Kumar Date: Fri, 10 Apr 2026 11:27:56 +0530 Subject: [PATCH 027/107] feat: spender in_app_rating_state GET/POST OpenAPI (#785) * Added relevant description and API details for mobile rating prompt state in platform docs --- reference/spender.yaml | 130 ++++++++++++++++++ .../schemas/rating_prompt_state.yaml | 41 ++++++ src/spender/openapi.yaml | 4 +- ...pender@mobile_app@rating_prompt_state.yaml | 90 ++++++++++++ 4 files changed, 264 insertions(+), 1 deletion(-) create mode 100644 src/spender/components/schemas/rating_prompt_state.yaml create mode 100644 src/spender/paths/spender@mobile_app@rating_prompt_state.yaml diff --git a/reference/spender.yaml b/reference/spender.yaml index cc2f8ec62..17beffaba 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -7439,6 +7439,96 @@ paths: application/json: schema: $ref: '#/components/schemas/403' + /spender/mobile_app/rating_prompt_state: + get: + tags: + - Mobile app + summary: Get mobile app rating prompt state for the current user + operationId: mobile_app_rating_prompt_state_get + description: | + Returns persisted timestamps for in-app rating pre-prompt cooldowns. + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/rating_prompt_state_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + post: + tags: + - Mobile app + summary: Update mobile app rating prompt state for the current user + operationId: mobile_app_rating_prompt_state_post + description: | + Records either a pre-prompt dismiss (`is_pre_prompt_dismissed: true`, native prompt not shown) or that the native + rating prompt was shown (`false`), using server UTC time. `created_at` is set only on first insert. + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/rating_prompt_state_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/rating_prompt_state_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' components: securitySchemes: oauth2: @@ -19644,6 +19734,46 @@ components: example: 8.0.1 os: $ref: '#/components/schemas/os' + rating_prompt_state_out: + type: object + additionalProperties: false + properties: + last_rating_pre_prompt_dismiss_at: + type: string + format: date-time + nullable: true + description: | + When the user last dismissed the pre-prompt (native rating prompt not shown). Used for cooldown. + last_native_review_prompt_at: + type: string + format: date-time + nullable: true + description: | + When the client last invoked the OS in-app review API after the user accepted the pre-prompt. + Used for cooldown. + updated_at: + type: string + format: date-time + nullable: true + description: | + Server time of the last persisted update. Null when no row exists yet for the user. + created_at: + type: string + format: date-time + nullable: true + description: | + Server time when the row was first created for the user. Null when no row exists yet. + rating_prompt_state_in: + type: object + additionalProperties: false + required: + - is_pre_prompt_dismissed + properties: + is_pre_prompt_dismissed: + type: boolean + description: | + `true` if the user dismissed the pre-prompt (native rating prompt was not shown); `false` if the native + rating prompt was shown. The server records the corresponding timestamp at request time using server UTC time. parameters: q: in: query diff --git a/src/spender/components/schemas/rating_prompt_state.yaml b/src/spender/components/schemas/rating_prompt_state.yaml new file mode 100644 index 000000000..22eb864f4 --- /dev/null +++ b/src/spender/components/schemas/rating_prompt_state.yaml @@ -0,0 +1,41 @@ +rating_prompt_state_out: + type: object + additionalProperties: false + properties: + last_rating_pre_prompt_dismiss_at: + type: string + format: date-time + nullable: true + description: | + When the user last dismissed the pre-prompt (native rating prompt not shown). Used for cooldown. + last_native_review_prompt_at: + type: string + format: date-time + nullable: true + description: | + When the client last invoked the OS in-app review API after the user accepted the pre-prompt. + Used for cooldown. + updated_at: + type: string + format: date-time + nullable: true + description: | + Server time of the last persisted update. Null when no row exists yet for the user. + created_at: + type: string + format: date-time + nullable: true + description: | + Server time when the row was first created for the user. Null when no row exists yet. + +rating_prompt_state_in: + type: object + additionalProperties: false + required: + - is_pre_prompt_dismissed + properties: + is_pre_prompt_dismissed: + type: boolean + description: | + `true` if the user dismissed the pre-prompt (native rating prompt was not shown); `false` if the native + rating prompt was shown. The server records the corresponding timestamp at request time using server UTC time. diff --git a/src/spender/openapi.yaml b/src/spender/openapi.yaml index 433dd9d2d..42d044303 100644 --- a/src/spender/openapi.yaml +++ b/src/spender/openapi.yaml @@ -386,4 +386,6 @@ paths: /spender/reports/export_configurations/delete/bulk: $ref: paths/spender@reports@export_configurations@delete@bulk.yaml /spender/mobile_app/versions: - $ref: paths/spender@mobile_app@versions.yaml \ No newline at end of file + $ref: paths/spender@mobile_app@versions.yaml + /spender/mobile_app/rating_prompt_state: + $ref: paths/spender@mobile_app@rating_prompt_state.yaml \ No newline at end of file diff --git a/src/spender/paths/spender@mobile_app@rating_prompt_state.yaml b/src/spender/paths/spender@mobile_app@rating_prompt_state.yaml new file mode 100644 index 000000000..7546c421c --- /dev/null +++ b/src/spender/paths/spender@mobile_app@rating_prompt_state.yaml @@ -0,0 +1,90 @@ +get: + tags: + - Mobile app + summary: Get mobile app rating prompt state for the current user + operationId: mobile_app_rating_prompt_state_get + description: | + Returns persisted timestamps for in-app rating pre-prompt cooldowns. + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../components/schemas/rating_prompt_state.yaml#/rating_prompt_state_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + +post: + tags: + - Mobile app + summary: Update mobile app rating prompt state for the current user + operationId: mobile_app_rating_prompt_state_post + description: | + Records either a pre-prompt dismiss (`is_pre_prompt_dismissed: true`, native prompt not shown) or that the native + rating prompt was shown (`false`), using server UTC time. `created_at` is set only on first insert. + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../components/schemas/rating_prompt_state.yaml#/rating_prompt_state_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../components/schemas/rating_prompt_state.yaml#/rating_prompt_state_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' From 3253245735e0c16208772bbf5fbf4110ba019a98 Mon Sep 17 00:00:00 2001 From: Kulsekar4 Date: Tue, 28 Apr 2026 15:18:38 +0530 Subject: [PATCH 028/107] feat: FYLE-tax-requirement-column-addition (#787) --- reference/admin.yaml | 7 +++++++ reference/approver.yaml | 7 +++++++ reference/manager.yaml | 7 +++++++ reference/spender.yaml | 7 +++++++ src/components/schemas/expense.yaml | 7 +++++++ 5 files changed, 35 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 3971f34a6..e5e6e0f72 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -18484,6 +18484,7 @@ components: - source_account - tax_amount - tax_group_id + - calculated_tax_amount - is_billable - is_reimbursable - distance @@ -18658,6 +18659,12 @@ components: allOf: - $ref: '#/components/schemas/fk_string' nullable: true + calculated_tax_amount: + type: number + nullable: true + readOnly: true + description: | + System-derived tax amount for the expense amount and the selected tax group's rate. is_billable: type: boolean nullable: true diff --git a/reference/approver.yaml b/reference/approver.yaml index 8ded31293..907899150 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -6061,6 +6061,7 @@ components: - source_account - tax_amount - tax_group_id + - calculated_tax_amount - is_billable - is_reimbursable - distance @@ -6235,6 +6236,12 @@ components: allOf: - $ref: '#/components/schemas/fk_string' nullable: true + calculated_tax_amount: + type: number + nullable: true + readOnly: true + description: | + System-derived tax amount for the expense amount and the selected tax group's rate. is_billable: type: boolean nullable: true diff --git a/reference/manager.yaml b/reference/manager.yaml index aef7d349d..4fdb18873 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -2895,6 +2895,7 @@ components: - source_account - tax_amount - tax_group_id + - calculated_tax_amount - is_billable - is_reimbursable - distance @@ -3069,6 +3070,12 @@ components: allOf: - $ref: '#/components/schemas/fk_string' nullable: true + calculated_tax_amount: + type: number + nullable: true + readOnly: true + description: | + System-derived tax amount for the expense amount and the selected tax group's rate. is_billable: type: boolean nullable: true diff --git a/reference/spender.yaml b/reference/spender.yaml index 17beffaba..9a8aee0ad 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -9503,6 +9503,7 @@ components: - source_account - tax_amount - tax_group_id + - calculated_tax_amount - is_billable - is_reimbursable - distance @@ -9677,6 +9678,12 @@ components: allOf: - $ref: '#/components/schemas/fk_string' nullable: true + calculated_tax_amount: + type: number + nullable: true + readOnly: true + description: | + System-derived tax amount for the expense amount and the selected tax group's rate. is_billable: type: boolean nullable: true diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index b3e67a21d..d9ceb0245 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -30,6 +30,7 @@ expense_out: - source_account - tax_amount - tax_group_id + - calculated_tax_amount - is_billable - is_reimbursable - distance @@ -204,6 +205,12 @@ expense_out: allOf: - $ref: './fields.yaml#/fk_string' nullable: true + calculated_tax_amount: + type: number + nullable: true + readOnly: true + description: | + System-derived tax amount for the expense amount and the selected tax group's rate. is_billable: type: boolean nullable: true From 0745dff6c061df342fc5237178babdfc81731503 Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Thu, 30 Apr 2026 15:20:15 +0530 Subject: [PATCH 029/107] add claude.md (#790) --- CLAUDE.md | 108 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 108 insertions(+) create mode 100644 CLAUDE.md diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 000000000..36034e405 --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1,108 @@ +# CLAUDE.md + +This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. + +## Overview + +`fyle-platform-docs` is the OpenAPI documentation repository for the Sage Expense Management Platform APIs, published at [docs.fylehq.com](https://docs.fylehq.com). It uses Redocly CLI to lint and bundle modular OpenAPI 3.0 specs, and Stoplight Prism for mock servers. + +## Prerequisites + +- Node.js >= v14.15.3 +- Redocly CLI: `npm install -g @redocly/openapi-cli` + +## Common Commands + +### Linting + +Lint any role's spec before committing changes: + +```bash +openapi lint src/admin/openapi.yaml +openapi lint src/spender/openapi.yaml +openapi lint src/approver/openapi.yaml +openapi lint src/authorization/openapi.yaml +openapi lint src/hod/openapi.yaml +openapi lint src/hop/openapi.yaml +openapi lint src/common/openapi.yaml +openapi lint src/accountant/openapi.yaml +openapi lint src/super_admin/openapi.yaml +``` + +### Bundling + +Bundle a role's modular spec into a single reference file (required before the mock server picks up changes): + +```bash +openapi bundle -o reference/admin.yaml src/admin/openapi.yaml +openapi bundle -o reference/spender.yaml src/spender/openapi.yaml +# etc. — pattern: openapi bundle -o reference/.yaml src//openapi.yaml +``` + +Bundling also runs automatically via GitHub Actions on push/PR to `main`. + +### Preview Docs + +```bash +openapi preview-docs src/admin/openapi.yaml +``` + +### Mock Server + +The mock server reads from the bundled `reference/` files, so bundle first if you've made changes: + +```bash +docker-compose up +``` + +| Role | Port | +|---|---| +| Admin | 4011 | +| Spender | 4012 | +| Approver | 4013 | +| Common / Accountant / Super Admin | 4014 | +| Manager | 4015 | + +## Deployment + +After a feature PR is merged to `main`, deploy to production by merging `main` into the `v1` branch: + +```bash +git checkout main && git pull origin main +git checkout v1 && git pull origin v1 +git merge main +git push origin v1 +``` + +## Architecture + +### Source specs (`src/`) + +Each user role has its own OpenAPI module: + +``` +src/ +├── / +│ ├── openapi.yaml # Root spec — declares servers, tags, security, and $ref paths +│ └── paths/ # One YAML file per endpoint, named [@].yaml +├── components/ +│ ├── parameters/ # Shared query/header parameters +│ └── schemas/ # Shared request/response schemas +``` + +Roles: `admin`, `spender`, `approver`, `authorization`, `common`, `accountant`, `hod`, `hop`, `owner`, `manager`, `super_admin`. + +Path files use `@` as a URL separator in filenames (e.g., `admin@expenses@bulk.yaml` → `POST /admin/expenses/bulk`). + +### Bundled specs (`reference/`) + +The `reference/` directory contains fully-resolved, single-file versions of each role's spec, generated by `openapi bundle`. These are what the mock server and docs platform consume. Do not edit these files directly — they are generated. + +### Docs content (`docs/`) + +Markdown files for conceptual documentation (auth flows, data API guide, event subscriptions, cluster/region routing, error reference). Structured via `toc.json`. + +## PR Requirements + +- Title must match: `^(fix|feat|test|chore|refactor|build):` (case-insensitive) +- Description must contain a ClickUp link (`app.clickup.com`) From 1121d7cb5b01d8c17e7efbfc312ec83f8e0c8903 Mon Sep 17 00:00:00 2001 From: Prabhakar Mishra Date: Mon, 18 May 2026 15:01:40 +0530 Subject: [PATCH 030/107] feat: Admin Approver expenses/check policy/check mandatory bulk APIs (#788) * feat: Admin Approver expenses/check policy/check mandatory bulk APIs * Auto generate API docs --- reference/admin.yaml | 659 ++++++++++++----- reference/approver.yaml | 667 +++++++++++++----- src/admin/openapi.yaml | 6 + src/admin/paths/admin@expenses@bulk.yaml | 52 ++ ...@expenses@check_mandatory_fields_bulk.yaml | 57 ++ .../admin@expenses@check_policies_bulk.yaml | 51 ++ src/approver/openapi.yaml | 6 + .../paths/approver@expenses@bulk.yaml | 52 ++ ...@expenses@check_mandatory_fields_bulk.yaml | 57 ++ ...approver@expenses@check_policies_bulk.yaml | 51 ++ src/components/schemas/expense.yaml | 48 ++ 11 files changed, 1384 insertions(+), 322 deletions(-) create mode 100644 src/admin/paths/admin@expenses@bulk.yaml create mode 100644 src/admin/paths/admin@expenses@check_mandatory_fields_bulk.yaml create mode 100644 src/admin/paths/admin@expenses@check_policies_bulk.yaml create mode 100644 src/approver/paths/approver@expenses@bulk.yaml create mode 100644 src/approver/paths/approver@expenses@check_mandatory_fields_bulk.yaml create mode 100644 src/approver/paths/approver@expenses@check_policies_bulk.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index e5e6e0f72..01a77f663 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -3543,6 +3543,59 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/expenses/bulk: + post: + tags: + - Expenses + summary: Update expenses in bulk + description: | + Update expenses in bulk by admin. + operationId: admin_expenses_post_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/admin_expenses_bulk_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '#/components/schemas/expense_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/expenses/attach_files/bulk: post: tags: @@ -11484,6 +11537,116 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/expenses/check_mandatory_fields/bulk: + post: + tags: + - Expenses + summary: Check multiple expenses for missing mandatory fields in bulk + description: | + Before updating multiple expense objects as an admin, you can validate + if all mandatory fields are present using this bulk endpoint. + operationId: admin_check_mandatory_fields_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/admin_expense_check_mandatory_fields_bulk_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/expense_check_mandatory_fields_bulk_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/expenses/check_policies/bulk: + post: + tags: + - Expenses + summary: Check multiple expenses for policy violations in bulk + description: | + Admin bulk version of the check_policies API that allows checking + multiple expenses for policy violations in one request. + + **NOTE:** This API can only be used to check policies for existing expenses that you want to update. The API will evaluate all the expenses against the configured policy rules and return an array of policy violation information for each expense in the request payload. + operationId: admin_check_policies_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/admin_check_policies_bulk_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/expense_check_policies_bulk_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/expenses/comments: get: tags: @@ -19338,6 +19501,110 @@ components: description: | Specific to per diem related expenses, number of days for which per diem claim is made.
This field is required for creating Per Diem Expenses. + items: + type: object + required: + - id + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + description: | + Expense id of the expense to be updated. + example: txwownwrng + merchant: + $ref: '#/components/schemas/merchant' + nullable: true + description: | + String denoting the name of the merchant to which the expense was made. + example: Uber + purpose: + type: string + nullable: true + description: | + Purpose of this expense. + example: Team lunch + cost_center_id: + allOf: + - $ref: '#/components/schemas/fk_integer' + nullable: true + description: | + This represents the cost_center's id given by Sage Exp Mgmt during creation of cost center + for which this expense is created. + example: 1049 + category_id: + allOf: + - $ref: '#/components/schemas/fk_integer' + nullable: false + description: | + This represents the category's id given by Sage Exp Mgmt during creation of category + for which this expense is created. + example: 49058 + project_id: + allOf: + - $ref: '#/components/schemas/fk_integer' + nullable: true + description: | + This represents the project's id given by Sage Exp Mgmt during creation of project + for which this expense is created. + example: 92895 + is_billable: + $ref: '#/components/schemas/is_billable' + nullable: true + description: This fields marks whether a given expense is billable or not. + example: true + custom_fields: + $ref: '#/components/schemas/custom_fields' + nullable: false + started_at: + $ref: '#/components/schemas/timestamptz_pst' + nullable: true + description: | + Start date for travel or per diem related expenses. + ended_at: + $ref: '#/components/schemas/timestamptz_pst' + nullable: true + description: | + End date for travel or per diem related expenses. + travel_classes: + $ref: '#/components/schemas/travel_classes' + nullable: false + description: | + This field is applicable only for `Flight`, `Train`, `Bus`, `Taxi` category. + index 0 holds onward journey class, index 1 holds return journey travel class. + example: + - ECONOMY + - BUSINESS + locations: + $ref: '#/components/schemas/locations' + nullable: false + description: | + This field will be present for travel related categories. + For travel between Place A to Place B, this array will contain two items, From location at array index 0 and To location at array index 1. + distance: + $ref: '#/components/schemas/distance' + nullable: true + description: Actual distance travelled by employee in travel related expenses. + distance_unit: + enum: + - KM + - MILES + - null + nullable: true + description: Unit of distance travelled. + example: MILES + hotel_is_breakfast_provided: + type: boolean + nullable: true + description: | + This field is applicable for only `Hotel` category. + admin_expenses_bulk_in: + type: array + additionalProperties: false + description: | + Array of expenses to be updated in bulk by the admin. + items: + $ref: '#/components/schemas/items' attach_files_to_expense_in: type: object required: @@ -30536,27 +30803,240 @@ components: - 12423 description: | List of IDs of expense fields which are mandatory but are missing. - expense_comments_out: - type: object + admin_expense_check_mandatory_fields_bulk_in: + type: array additionalProperties: false - required: - - id - - comment - - action - - action_data - - expense_id - - creator_type - - org_id - - updated_at - - created_at - properties: - id: - $ref: '#/components/schemas/id_string' - comment: - type: string - description: comment on the report - example: We don't accept laundry bills - action: + description: | + Array of expenses to be checked for missing mandatory fields by admin. + items: + $ref: '#/components/schemas/items' + expense_check_mandatory_fields_bulk_out: + type: array + additionalProperties: false + items: + type: object + required: + - id + - missing_amount + - missing_currency + - missing_receipt + - missing_expense_field_ids + properties: + id: + $ref: '#/components/schemas/id_string' + example: tx0agOdICdbV + missing_amount: + type: boolean + description: | + If this is set to true, then you need to send amount field with expense object. + example: false + missing_currency: + type: boolean + description: | + If this is set to true, then you need to send currency field with expense object. + example: false + missing_receipt: + type: boolean + description: | + If this is set to true, then you need to attach receipt to the expense. + example: false + missing_expense_field_ids: + type: array + nullable: false + items: + type: integer + nullable: true + description: | + This id provided by Sage Exp Mgmt to identify an expense field. + example: 123 + example: + - 123 + - 12423 + description: | + List of IDs of expense fields which are mandatory but are missing. + admin_check_policies_bulk_in: + type: array + additionalProperties: false + description: | + Array of expenses to be validated against expense policy rules by admin. + items: + $ref: '#/components/schemas/items' + expense_check_policies_individual_desired_states: + type: object + properties: + add_approver_user_ids: + nullable: true + type: array + items: + type: string + description: | + List of approver ids that the policy calculation suggests adding to report that contains this expense. + example: + - usBdsdfscl + - usLSsdfwqt + approver_policy_order: + type: integer + nullable: true + description: | + This represents the order of the approver policy related to this individual desired state record. + If the policy does not add any approver, this field will be null. + example: 1 + approver_source: + type: string + enum: + - PRIMARY_APPROVER + - SECONDARY_APPROVER_1 + - SECONDARY_APPROVER_2 + - PROJECT_APPROVER_1 + - PROJECT_APPROVER_2 + - DEPARTMENT_HEAD_APPROVER + - EMAIL_APPROVER + - null + nullable: true + description: | + This represents the type of approver(source) that was added by the approver policy related to this individual + desired state record. If the policy does not add any approver, this field will be null. + example: PROJECT_APPROVER_1 + expense_policy_rule_id: + type: string + description: | + This represents the id of the expense policy rule. + example: tprabsdfSYqd + expense_policy_rule: + $ref: '#/components/schemas/expense_policy_rule_embed' + run_status: + nullable: false + type: string + enum: + - VIOLATED_ACTION_SUCCESS + - VIOLATED_ACTION_FAILURE + - UNVIOLATED + description: | + This represents the status of policy computation for the input expense object against the policy represented by `expense_policy_rule_id`. + If the state is `UNVIOLATED`, it means that the expense is not violating this policy. If the state is `VIOLATION_ACTION_SUCCESS`, + it means that the expense is violating this policy and action stated in the object will be applied to the expense when it is saved. + However, if the state is `VIOLATION_ACTION_FAILURE`, it means that this policy is violated for the expense but since some approver was + missing or not set up properly, it will fail to take action on the expense when it is saved. + example: SUCCESS + run_result: + type: array + items: + type: string + description: | + List of human-readable action summaries that the policy calculation suggests for this expense. Note that, in + case some approver was not setup properly for the given violation, this array will contain description of + missing approvers. For example, Department approver, Project head, etc. + example: + - flag the expense + - cap the amount + amount: + nullable: true + anyOf: + - $ref: '#/components/schemas/amount' + - $ref: '#/components/schemas/null_field' + description: | + Amount that the policy calculation suggests for this expense. + example: 500 + expenses_query_object_params: + nullable: true + $ref: '#/components/schemas/expense_policy_expenses_query_object' + expense_check_policies_final_desired_state: + type: object + properties: + flag: + type: boolean + description: | + A true value here means, that as per policy calculation this expense should be flagged. + example: true + amount: + nullable: true + anyOf: + - $ref: '#/components/schemas/amount' + - $ref: '#/components/schemas/null_field' + description: | + Amount that the policy calculation suggests for this expense. + example: 500 + unreportable: + type: boolean + nullable: false + description: | + A true value here means, that as per policy calculation this expense should be made unreportable. + example: true + is_receipt_mandatory: + type: boolean + description: | + A true value here means, that as per policy calculation this expense requires receipt. + example: true + add_approver_user_ids: + nullable: true + type: array + items: + type: string + description: | + List of approver ids that the policy calculation suggests adding to report that contains this expense. + example: + - usBdsdfscl + - usLSsdfwqt + remove_employee_approver1: + type: boolean + description: | + A true value here means, that as per policy calculation, the employee's first approver should be removed from the report that contains this expense. + example: true + run_status: + nullable: false + type: string + enum: + - SUCCESS + - FAILURE + description: | + This represent the run status of the policy. + example: SUCCESS + run_summary: + type: array + items: + type: string + description: | + List of human-readable action summaries that the policy calculation suggests for this expense. + example: + - flag the expense + - cap the amount + expense_check_policies_bulk_out: + type: array + additionalProperties: false + items: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: tx0agOdICdbV + individual_desired_states: + type: array + items: + $ref: '#/components/schemas/expense_check_policies_individual_desired_states' + final_desired_state: + $ref: '#/components/schemas/expense_check_policies_final_desired_state' + expense_comments_out: + type: object + additionalProperties: false + required: + - id + - comment + - action + - action_data + - expense_id + - creator_type + - org_id + - updated_at + - created_at + properties: + id: + $ref: '#/components/schemas/id_string' + comment: + type: string + description: comment on the report + example: We don't accept laundry bills + action: type: string description: Expense action for which comment is added. enum: @@ -30942,145 +31422,6 @@ components: null or default value will be taken for that attribute in the resultant split. allOf: - $ref: '#/components/schemas/admin_expense_split_object' - expense_check_policies_individual_desired_states: - type: object - properties: - add_approver_user_ids: - nullable: true - type: array - items: - type: string - description: | - List of approver ids that the policy calculation suggests adding to report that contains this expense. - example: - - usBdsdfscl - - usLSsdfwqt - approver_policy_order: - type: integer - nullable: true - description: | - This represents the order of the approver policy related to this individual desired state record. - If the policy does not add any approver, this field will be null. - example: 1 - approver_source: - type: string - enum: - - PRIMARY_APPROVER - - SECONDARY_APPROVER_1 - - SECONDARY_APPROVER_2 - - PROJECT_APPROVER_1 - - PROJECT_APPROVER_2 - - DEPARTMENT_HEAD_APPROVER - - EMAIL_APPROVER - - null - nullable: true - description: | - This represents the type of approver(source) that was added by the approver policy related to this individual - desired state record. If the policy does not add any approver, this field will be null. - example: PROJECT_APPROVER_1 - expense_policy_rule_id: - type: string - description: | - This represents the id of the expense policy rule. - example: tprabsdfSYqd - expense_policy_rule: - $ref: '#/components/schemas/expense_policy_rule_embed' - run_status: - nullable: false - type: string - enum: - - VIOLATED_ACTION_SUCCESS - - VIOLATED_ACTION_FAILURE - - UNVIOLATED - description: | - This represents the status of policy computation for the input expense object against the policy represented by `expense_policy_rule_id`. - If the state is `UNVIOLATED`, it means that the expense is not violating this policy. If the state is `VIOLATION_ACTION_SUCCESS`, - it means that the expense is violating this policy and action stated in the object will be applied to the expense when it is saved. - However, if the state is `VIOLATION_ACTION_FAILURE`, it means that this policy is violated for the expense but since some approver was - missing or not set up properly, it will fail to take action on the expense when it is saved. - example: SUCCESS - run_result: - type: array - items: - type: string - description: | - List of human-readable action summaries that the policy calculation suggests for this expense. Note that, in - case some approver was not setup properly for the given violation, this array will contain description of - missing approvers. For example, Department approver, Project head, etc. - example: - - flag the expense - - cap the amount - amount: - nullable: true - anyOf: - - $ref: '#/components/schemas/amount' - - $ref: '#/components/schemas/null_field' - description: | - Amount that the policy calculation suggests for this expense. - example: 500 - expenses_query_object_params: - nullable: true - $ref: '#/components/schemas/expense_policy_expenses_query_object' - expense_check_policies_final_desired_state: - type: object - properties: - flag: - type: boolean - description: | - A true value here means, that as per policy calculation this expense should be flagged. - example: true - amount: - nullable: true - anyOf: - - $ref: '#/components/schemas/amount' - - $ref: '#/components/schemas/null_field' - description: | - Amount that the policy calculation suggests for this expense. - example: 500 - unreportable: - type: boolean - nullable: false - description: | - A true value here means, that as per policy calculation this expense should be made unreportable. - example: true - is_receipt_mandatory: - type: boolean - description: | - A true value here means, that as per policy calculation this expense requires receipt. - example: true - add_approver_user_ids: - nullable: true - type: array - items: - type: string - description: | - List of approver ids that the policy calculation suggests adding to report that contains this expense. - example: - - usBdsdfscl - - usLSsdfwqt - remove_employee_approver1: - type: boolean - description: | - A true value here means, that as per policy calculation, the employee's first approver should be removed from the report that contains this expense. - example: true - run_status: - nullable: false - type: string - enum: - - SUCCESS - - FAILURE - description: | - This represent the run status of the policy. - example: SUCCESS - run_summary: - type: array - items: - type: string - description: | - List of human-readable action summaries that the policy calculation suggests for this expense. - example: - - flag the expense - - cap the amount expense_check_policies_out: type: object additionalProperties: false diff --git a/reference/approver.yaml b/reference/approver.yaml index 907899150..cd59e5745 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -519,6 +519,59 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /approver/expenses/bulk: + post: + tags: + - Expenses + summary: Update expenses in bulk + description: | + Update expenses in bulk by approver. + operationId: approver_expenses_post_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/approver_expenses_bulk_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '#/components/schemas/expense_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /approver/expenses/attach_files/bulk: post: tags: @@ -1758,6 +1811,116 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /approver/expenses/check_mandatory_fields/bulk: + post: + tags: + - Expenses + summary: Check multiple expenses for missing mandatory fields in bulk + description: | + Before updating multiple expense objects as an approver, you can validate + if all mandatory fields are present using this bulk endpoint. + operationId: approver_check_mandatory_fields_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/approver_expense_check_mandatory_fields_bulk_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/expense_check_mandatory_fields_bulk_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /approver/expenses/check_policies/bulk: + post: + tags: + - Expenses + summary: Check multiple expenses for policy violations in bulk + description: | + Approver bulk version of the check_policies API that allows checking + multiple expenses for policy violations in one request. + + **NOTE:** This API can only be used to check policies for existing expenses that you want to update. The API will evaluate all the expenses against the configured policy rules and return an array of policy violation information for each expense in the request payload. + operationId: approver_check_policies_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/approver_check_policies_bulk_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/expense_check_policies_bulk_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /approver/expenses/comments: get: tags: @@ -6893,6 +7056,110 @@ components: description: | Specific to per diem related expenses, number of days for which per diem claim is made.
This field is required for creating Per Diem Expenses. + items: + type: object + required: + - id + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + description: | + Expense id of the expense to be updated. + example: txwownwrng + merchant: + $ref: '#/components/schemas/merchant' + nullable: true + description: | + String denoting the name of the merchant to which the expense was made. + example: Uber + purpose: + type: string + nullable: true + description: | + Purpose of this expense. + example: Team lunch + cost_center_id: + allOf: + - $ref: '#/components/schemas/fk_integer' + nullable: true + description: | + This represents the cost_center's id given by Sage Exp Mgmt during creation of cost center + for which this expense is created. + example: 1049 + category_id: + allOf: + - $ref: '#/components/schemas/fk_integer' + nullable: false + description: | + This represents the category's id given by Sage Exp Mgmt during creation of category + for which this expense is created. + example: 49058 + project_id: + allOf: + - $ref: '#/components/schemas/fk_integer' + nullable: true + description: | + This represents the project's id given by Sage Exp Mgmt during creation of project + for which this expense is created. + example: 92895 + is_billable: + $ref: '#/components/schemas/is_billable' + nullable: true + description: This fields marks whether a given expense is billable or not. + example: true + custom_fields: + $ref: '#/components/schemas/custom_fields' + nullable: false + started_at: + $ref: '#/components/schemas/timestamptz_pst' + nullable: true + description: | + Start date for travel or per diem related expenses. + ended_at: + $ref: '#/components/schemas/timestamptz_pst' + nullable: true + description: | + End date for travel or per diem related expenses. + travel_classes: + $ref: '#/components/schemas/travel_classes' + nullable: false + description: | + This field is applicable only for `Flight`, `Train`, `Bus`, `Taxi` category. + index 0 holds onward journey class, index 1 holds return journey travel class. + example: + - ECONOMY + - BUSINESS + locations: + $ref: '#/components/schemas/locations' + nullable: false + description: | + This field will be present for travel related categories. + For travel between Place A to Place B, this array will contain two items, From location at array index 0 and To location at array index 1. + distance: + $ref: '#/components/schemas/distance' + nullable: true + description: Actual distance travelled by employee in travel related expenses. + distance_unit: + enum: + - KM + - MILES + - null + nullable: true + description: Unit of distance travelled. + example: MILES + hotel_is_breakfast_provided: + type: boolean + nullable: true + description: | + This field is applicable for only `Hotel` category. + approver_expenses_bulk_in: + type: array + additionalProperties: false + description: | + Array of expenses to be updated in bulk by the approver. + items: + $ref: '#/components/schemas/items' attach_files_to_expense_in: type: object required: @@ -8482,31 +8749,244 @@ components: - 12423 description: | List of IDs of expense fields which are mandatory but are missing. - expense_comments_out: - type: object + approver_expense_check_mandatory_fields_bulk_in: + type: array additionalProperties: false - required: - - id - - comment - - action - - action_data - - expense_id - - creator_type - - org_id - - updated_at - - created_at - properties: - id: - $ref: '#/components/schemas/id_string' - comment: - type: string - description: comment on the report - example: We don't accept laundry bills - action: - type: string - description: Expense action for which comment is added. - enum: - - ADMIN_APPROVED + description: | + Array of expenses to be checked for missing mandatory fields by approver. + items: + $ref: '#/components/schemas/items' + expense_check_mandatory_fields_bulk_out: + type: array + additionalProperties: false + items: + type: object + required: + - id + - missing_amount + - missing_currency + - missing_receipt + - missing_expense_field_ids + properties: + id: + $ref: '#/components/schemas/id_string' + example: tx0agOdICdbV + missing_amount: + type: boolean + description: | + If this is set to true, then you need to send amount field with expense object. + example: false + missing_currency: + type: boolean + description: | + If this is set to true, then you need to send currency field with expense object. + example: false + missing_receipt: + type: boolean + description: | + If this is set to true, then you need to attach receipt to the expense. + example: false + missing_expense_field_ids: + type: array + nullable: false + items: + type: integer + nullable: true + description: | + This id provided by Sage Exp Mgmt to identify an expense field. + example: 123 + example: + - 123 + - 12423 + description: | + List of IDs of expense fields which are mandatory but are missing. + approver_check_policies_bulk_in: + type: array + additionalProperties: false + description: | + Array of expenses to be validated against expense policy rules by approver. + items: + $ref: '#/components/schemas/items' + expense_check_policies_individual_desired_states: + type: object + properties: + add_approver_user_ids: + nullable: true + type: array + items: + type: string + description: | + List of approver ids that the policy calculation suggests adding to report that contains this expense. + example: + - usBdsdfscl + - usLSsdfwqt + approver_policy_order: + type: integer + nullable: true + description: | + This represents the order of the approver policy related to this individual desired state record. + If the policy does not add any approver, this field will be null. + example: 1 + approver_source: + type: string + enum: + - PRIMARY_APPROVER + - SECONDARY_APPROVER_1 + - SECONDARY_APPROVER_2 + - PROJECT_APPROVER_1 + - PROJECT_APPROVER_2 + - DEPARTMENT_HEAD_APPROVER + - EMAIL_APPROVER + - null + nullable: true + description: | + This represents the type of approver(source) that was added by the approver policy related to this individual + desired state record. If the policy does not add any approver, this field will be null. + example: PROJECT_APPROVER_1 + expense_policy_rule_id: + type: string + description: | + This represents the id of the expense policy rule. + example: tprabsdfSYqd + expense_policy_rule: + $ref: '#/components/schemas/expense_policy_rule_embed' + run_status: + nullable: false + type: string + enum: + - VIOLATED_ACTION_SUCCESS + - VIOLATED_ACTION_FAILURE + - UNVIOLATED + description: | + This represents the status of policy computation for the input expense object against the policy represented by `expense_policy_rule_id`. + If the state is `UNVIOLATED`, it means that the expense is not violating this policy. If the state is `VIOLATION_ACTION_SUCCESS`, + it means that the expense is violating this policy and action stated in the object will be applied to the expense when it is saved. + However, if the state is `VIOLATION_ACTION_FAILURE`, it means that this policy is violated for the expense but since some approver was + missing or not set up properly, it will fail to take action on the expense when it is saved. + example: SUCCESS + run_result: + type: array + items: + type: string + description: | + List of human-readable action summaries that the policy calculation suggests for this expense. Note that, in + case some approver was not setup properly for the given violation, this array will contain description of + missing approvers. For example, Department approver, Project head, etc. + example: + - flag the expense + - cap the amount + amount: + nullable: true + anyOf: + - $ref: '#/components/schemas/amount' + - $ref: '#/components/schemas/null_field' + description: | + Amount that the policy calculation suggests for this expense. + example: 500 + expenses_query_object_params: + nullable: true + $ref: '#/components/schemas/expense_policy_expenses_query_object' + expense_check_policies_final_desired_state: + type: object + properties: + flag: + type: boolean + description: | + A true value here means, that as per policy calculation this expense should be flagged. + example: true + amount: + nullable: true + anyOf: + - $ref: '#/components/schemas/amount' + - $ref: '#/components/schemas/null_field' + description: | + Amount that the policy calculation suggests for this expense. + example: 500 + unreportable: + type: boolean + nullable: false + description: | + A true value here means, that as per policy calculation this expense should be made unreportable. + example: true + is_receipt_mandatory: + type: boolean + description: | + A true value here means, that as per policy calculation this expense requires receipt. + example: true + add_approver_user_ids: + nullable: true + type: array + items: + type: string + description: | + List of approver ids that the policy calculation suggests adding to report that contains this expense. + example: + - usBdsdfscl + - usLSsdfwqt + remove_employee_approver1: + type: boolean + description: | + A true value here means, that as per policy calculation, the employee's first approver should be removed from the report that contains this expense. + example: true + run_status: + nullable: false + type: string + enum: + - SUCCESS + - FAILURE + description: | + This represent the run status of the policy. + example: SUCCESS + run_summary: + type: array + items: + type: string + description: | + List of human-readable action summaries that the policy calculation suggests for this expense. + example: + - flag the expense + - cap the amount + expense_check_policies_bulk_out: + type: array + additionalProperties: false + items: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: tx0agOdICdbV + individual_desired_states: + type: array + items: + $ref: '#/components/schemas/expense_check_policies_individual_desired_states' + final_desired_state: + $ref: '#/components/schemas/expense_check_policies_final_desired_state' + expense_comments_out: + type: object + additionalProperties: false + required: + - id + - comment + - action + - action_data + - expense_id + - creator_type + - org_id + - updated_at + - created_at + properties: + id: + $ref: '#/components/schemas/id_string' + comment: + type: string + description: comment on the report + example: We don't accept laundry bills + action: + type: string + description: Expense action for which comment is added. + enum: + - ADMIN_APPROVED - APPROVED - APPROVER_REMOVED - AUTO_MATCHED @@ -9056,145 +9536,6 @@ components: null or default value will be taken for that attribute in the resultant split. allOf: - $ref: '#/components/schemas/admin_expense_split_object' - expense_check_policies_individual_desired_states: - type: object - properties: - add_approver_user_ids: - nullable: true - type: array - items: - type: string - description: | - List of approver ids that the policy calculation suggests adding to report that contains this expense. - example: - - usBdsdfscl - - usLSsdfwqt - approver_policy_order: - type: integer - nullable: true - description: | - This represents the order of the approver policy related to this individual desired state record. - If the policy does not add any approver, this field will be null. - example: 1 - approver_source: - type: string - enum: - - PRIMARY_APPROVER - - SECONDARY_APPROVER_1 - - SECONDARY_APPROVER_2 - - PROJECT_APPROVER_1 - - PROJECT_APPROVER_2 - - DEPARTMENT_HEAD_APPROVER - - EMAIL_APPROVER - - null - nullable: true - description: | - This represents the type of approver(source) that was added by the approver policy related to this individual - desired state record. If the policy does not add any approver, this field will be null. - example: PROJECT_APPROVER_1 - expense_policy_rule_id: - type: string - description: | - This represents the id of the expense policy rule. - example: tprabsdfSYqd - expense_policy_rule: - $ref: '#/components/schemas/expense_policy_rule_embed' - run_status: - nullable: false - type: string - enum: - - VIOLATED_ACTION_SUCCESS - - VIOLATED_ACTION_FAILURE - - UNVIOLATED - description: | - This represents the status of policy computation for the input expense object against the policy represented by `expense_policy_rule_id`. - If the state is `UNVIOLATED`, it means that the expense is not violating this policy. If the state is `VIOLATION_ACTION_SUCCESS`, - it means that the expense is violating this policy and action stated in the object will be applied to the expense when it is saved. - However, if the state is `VIOLATION_ACTION_FAILURE`, it means that this policy is violated for the expense but since some approver was - missing or not set up properly, it will fail to take action on the expense when it is saved. - example: SUCCESS - run_result: - type: array - items: - type: string - description: | - List of human-readable action summaries that the policy calculation suggests for this expense. Note that, in - case some approver was not setup properly for the given violation, this array will contain description of - missing approvers. For example, Department approver, Project head, etc. - example: - - flag the expense - - cap the amount - amount: - nullable: true - anyOf: - - $ref: '#/components/schemas/amount' - - $ref: '#/components/schemas/null_field' - description: | - Amount that the policy calculation suggests for this expense. - example: 500 - expenses_query_object_params: - nullable: true - $ref: '#/components/schemas/expense_policy_expenses_query_object' - expense_check_policies_final_desired_state: - type: object - properties: - flag: - type: boolean - description: | - A true value here means, that as per policy calculation this expense should be flagged. - example: true - amount: - nullable: true - anyOf: - - $ref: '#/components/schemas/amount' - - $ref: '#/components/schemas/null_field' - description: | - Amount that the policy calculation suggests for this expense. - example: 500 - unreportable: - type: boolean - nullable: false - description: | - A true value here means, that as per policy calculation this expense should be made unreportable. - example: true - is_receipt_mandatory: - type: boolean - description: | - A true value here means, that as per policy calculation this expense requires receipt. - example: true - add_approver_user_ids: - nullable: true - type: array - items: - type: string - description: | - List of approver ids that the policy calculation suggests adding to report that contains this expense. - example: - - usBdsdfscl - - usLSsdfwqt - remove_employee_approver1: - type: boolean - description: | - A true value here means, that as per policy calculation, the employee's first approver should be removed from the report that contains this expense. - example: true - run_status: - nullable: false - type: string - enum: - - SUCCESS - - FAILURE - description: | - This represent the run status of the policy. - example: SUCCESS - run_summary: - type: array - items: - type: string - description: | - List of human-readable action summaries that the policy calculation suggests for this expense. - example: - - flag the expense - - cap the amount expense_check_policies_out: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index b6c56fb60..5364f6249 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -243,6 +243,8 @@ paths: $ref: paths/admin@accounting_export_lineitems@bulk.yaml /admin/expenses: $ref: paths/admin@expenses.yaml + /admin/expenses/bulk: + $ref: paths/admin@expenses@bulk.yaml /admin/expenses/attach_files/bulk : $ref: paths/admin@expenses@attach_files@bulk.yaml /admin/expenses/accounting_export_summary/bulk: @@ -518,6 +520,10 @@ paths: $ref: paths/admin@expense_rules@delete.yaml /admin/expenses/check_mandatory_fields: $ref: paths/admin@expenses@check_mandatory_fields.yaml + /admin/expenses/check_mandatory_fields/bulk: + $ref: paths/admin@expenses@check_mandatory_fields_bulk.yaml + /admin/expenses/check_policies/bulk: + $ref: paths/admin@expenses@check_policies_bulk.yaml /admin/expenses/comments: $ref: paths/admin@expenses@comments.yaml /admin/expenses/comments/bulk: diff --git a/src/admin/paths/admin@expenses@bulk.yaml b/src/admin/paths/admin@expenses@bulk.yaml new file mode 100644 index 000000000..7d4a8e59e --- /dev/null +++ b/src/admin/paths/admin@expenses@bulk.yaml @@ -0,0 +1,52 @@ +post: + tags: + - Expenses + summary: Update expenses in bulk + description: | + Update expenses in bulk by admin. + operationId: admin_expenses_post_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/expense.yaml#/admin_expenses_bulk_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '../../components/schemas/expense.yaml#/expense_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' \ No newline at end of file diff --git a/src/admin/paths/admin@expenses@check_mandatory_fields_bulk.yaml b/src/admin/paths/admin@expenses@check_mandatory_fields_bulk.yaml new file mode 100644 index 000000000..262c86847 --- /dev/null +++ b/src/admin/paths/admin@expenses@check_mandatory_fields_bulk.yaml @@ -0,0 +1,57 @@ +post: + tags: + - Expenses + summary: Check multiple expenses for missing mandatory fields in bulk + description: | + Before updating multiple expense objects as an admin, you can validate + if all mandatory fields are present using this bulk endpoint. + operationId: admin_check_mandatory_fields_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: '../../components/schemas/expense.yaml#/admin_expense_check_mandatory_fields_bulk_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: ../../components/schemas/expense.yaml#/expense_check_mandatory_fields_bulk_out + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' \ No newline at end of file diff --git a/src/admin/paths/admin@expenses@check_policies_bulk.yaml b/src/admin/paths/admin@expenses@check_policies_bulk.yaml new file mode 100644 index 000000000..89319cc95 --- /dev/null +++ b/src/admin/paths/admin@expenses@check_policies_bulk.yaml @@ -0,0 +1,51 @@ +post: + tags: + - Expenses + summary: Check multiple expenses for policy violations in bulk + description: | + Admin bulk version of the check_policies API that allows checking + multiple expenses for policy violations in one request. + + **NOTE:** This API can only be used to check policies for existing expenses that you want to update. The API will evaluate all the expenses against the configured policy rules and return an array of policy violation information for each expense in the request payload. + operationId: admin_check_policies_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: "../../components/schemas/expense.yaml#/admin_check_policies_bulk_in" + responses: + "200": + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + properties: + data: + $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out + "401": + description: Unauthorised request + content: + application/json: + schema: + $ref: "../../components/schemas/401.yaml" + "400": + description: Bad request + content: + application/json: + schema: + $ref: "../../components/schemas/400.yaml" + "404": + description: Not Found + content: + application/json: + schema: + $ref: "../../components/schemas/404.yaml" \ No newline at end of file diff --git a/src/approver/openapi.yaml b/src/approver/openapi.yaml index e6e1071db..b59a4e2ea 100644 --- a/src/approver/openapi.yaml +++ b/src/approver/openapi.yaml @@ -79,6 +79,8 @@ paths: $ref: paths/approver@reports@exports.yaml /approver/expenses: $ref: 'paths/approver@expenses.yaml' + /approver/expenses/bulk: + $ref: 'paths/approver@expenses@bulk.yaml' /approver/expenses/attach_files/bulk : $ref: paths/approver@expenses@attach_files@bulk.yaml /approver/expenses/permissions: @@ -136,6 +138,10 @@ paths: $ref: paths/approver@expense_policies@states.yaml /approver/expenses/check_mandatory_fields: $ref: paths/approver@expenses@check_mandatory_fields.yaml + /approver/expenses/check_mandatory_fields/bulk: + $ref: paths/approver@expenses@check_mandatory_fields_bulk.yaml + /approver/expenses/check_policies/bulk: + $ref: paths/approver@expenses@check_policies_bulk.yaml /approver/expenses/comments: $ref: paths/approver@expenses@comments.yaml /approver/expenses/comments/bulk: diff --git a/src/approver/paths/approver@expenses@bulk.yaml b/src/approver/paths/approver@expenses@bulk.yaml new file mode 100644 index 000000000..1e777f6e0 --- /dev/null +++ b/src/approver/paths/approver@expenses@bulk.yaml @@ -0,0 +1,52 @@ +post: + tags: + - Expenses + summary: Update expenses in bulk + description: | + Update expenses in bulk by approver. + operationId: approver_expenses_post_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/expense.yaml#/approver_expenses_bulk_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '../../components/schemas/expense.yaml#/expense_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' \ No newline at end of file diff --git a/src/approver/paths/approver@expenses@check_mandatory_fields_bulk.yaml b/src/approver/paths/approver@expenses@check_mandatory_fields_bulk.yaml new file mode 100644 index 000000000..234574023 --- /dev/null +++ b/src/approver/paths/approver@expenses@check_mandatory_fields_bulk.yaml @@ -0,0 +1,57 @@ +post: + tags: + - Expenses + summary: Check multiple expenses for missing mandatory fields in bulk + description: | + Before updating multiple expense objects as an approver, you can validate + if all mandatory fields are present using this bulk endpoint. + operationId: approver_check_mandatory_fields_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: '../../components/schemas/expense.yaml#/approver_expense_check_mandatory_fields_bulk_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: ../../components/schemas/expense.yaml#/expense_check_mandatory_fields_bulk_out + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' \ No newline at end of file diff --git a/src/approver/paths/approver@expenses@check_policies_bulk.yaml b/src/approver/paths/approver@expenses@check_policies_bulk.yaml new file mode 100644 index 000000000..99296b6ba --- /dev/null +++ b/src/approver/paths/approver@expenses@check_policies_bulk.yaml @@ -0,0 +1,51 @@ +post: + tags: + - Expenses + summary: Check multiple expenses for policy violations in bulk + description: | + Approver bulk version of the check_policies API that allows checking + multiple expenses for policy violations in one request. + + **NOTE:** This API can only be used to check policies for existing expenses that you want to update. The API will evaluate all the expenses against the configured policy rules and return an array of policy violation information for each expense in the request payload. + operationId: approver_check_policies_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: "../../components/schemas/expense.yaml#/approver_check_policies_bulk_in" + responses: + "200": + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + properties: + data: + $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out + "401": + description: Unauthorised request + content: + application/json: + schema: + $ref: "../../components/schemas/401.yaml" + "400": + description: Bad request + content: + application/json: + schema: + $ref: "../../components/schemas/400.yaml" + "404": + description: Not Found + content: + application/json: + schema: + $ref: "../../components/schemas/404.yaml" \ No newline at end of file diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index d9ceb0245..1878901b9 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -1075,6 +1075,54 @@ spender_check_policies_bulk_in: items: $ref: '#/spender_expenses_bulk_in/items' +admin_expenses_bulk_in: + type: array + additionalProperties: false + description: | + Array of expenses to be updated in bulk by the admin. + items: + $ref: '#/spender_expenses_bulk_in/items' + +admin_expense_check_mandatory_fields_bulk_in: + type: array + additionalProperties: false + description: | + Array of expenses to be checked for missing mandatory fields by admin. + items: + $ref: '#/spender_expenses_bulk_in/items' + +admin_check_policies_bulk_in: + type: array + additionalProperties: false + description: | + Array of expenses to be validated against expense policy rules by admin. + items: + $ref: '#/spender_expenses_bulk_in/items' + +approver_expenses_bulk_in: + type: array + additionalProperties: false + description: | + Array of expenses to be updated in bulk by the approver. + items: + $ref: '#/spender_expenses_bulk_in/items' + +approver_expense_check_mandatory_fields_bulk_in: + type: array + additionalProperties: false + description: | + Array of expenses to be checked for missing mandatory fields by approver. + items: + $ref: '#/spender_expenses_bulk_in/items' + +approver_check_policies_bulk_in: + type: array + additionalProperties: false + description: | + Array of expenses to be validated against expense policy rules by approver. + items: + $ref: '#/spender_expenses_bulk_in/items' + admin_expense_in: type: object additionalProperties: false From 433da1022629e26aca3f5a6dc7b83862319abb8f Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Thu, 11 Jun 2026 16:55:49 +0530 Subject: [PATCH 031/107] feat: Add corporate cards merge api spec (#792) * feat: Add corporate card merge api spec * minor * Auto generate API docs * minor * Auto generate API docs --- reference/admin.yaml | 72 +++++++++++++++++++ src/admin/openapi.yaml | 2 + .../paths/admin@corporate_cards@merge.yaml | 54 ++++++++++++++ src/components/schemas/corporate_card.yaml | 20 ++++++ 4 files changed, 148 insertions(+) create mode 100644 src/admin/paths/admin@corporate_cards@merge.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 01a77f663..7673c7b69 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -7529,6 +7529,60 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/corporate_cards/merge: + post: + tags: + - Corporate Cards + summary: Merge Duplicate Corporate Cards + description: | + Merges a source card into a destination card by consolidating all associated data into the destination and removing the source card. + operationId: corporate_cards_merge + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/corporate_card_merge_in' + required: + - data + additionalProperties: false + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/corporate_card_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/corporate_card_transactions: get: tags: @@ -23449,6 +23503,24 @@ components: required: - id - user_id + corporate_card_merge_in: + type: object + properties: + destination_card_id: + allOf: + - $ref: '#/components/schemas/id_string' + description: | + The ID of the destination card into which the source card will be merged + example: bawownwrng + source_card_id: + allOf: + - $ref: '#/components/schemas/id_string' + description: | + The ID of the source card that will be merged into the destination card + example: uswjwgnwwgo + required: + - destination_card_id + - source_card_id string_detail: type: string description: Additional string details of the card transaction. Can hold details upto 256 characters in length. diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 5364f6249..0b01a25c6 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -367,6 +367,8 @@ paths: $ref: paths/admin@corporate_cards@reassign.yaml /admin/corporate_cards/delete: $ref: paths/admin@corporate_cards@delete.yaml + /admin/corporate_cards/merge: + $ref: paths/admin@corporate_cards@merge.yaml /admin/corporate_card_transactions: $ref: paths/admin@corporate_card_transactions.yaml diff --git a/src/admin/paths/admin@corporate_cards@merge.yaml b/src/admin/paths/admin@corporate_cards@merge.yaml new file mode 100644 index 000000000..e2850c21d --- /dev/null +++ b/src/admin/paths/admin@corporate_cards@merge.yaml @@ -0,0 +1,54 @@ +post: + tags: + - Corporate Cards + summary: Merge Duplicate Corporate Cards + description: | + Merges a source card into a destination card by consolidating all associated data into the destination and removing the source card. + operationId: corporate_cards_merge + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: ../../components/schemas/corporate_card.yaml#/corporate_card_merge_in + required: + - data + additionalProperties: False + + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index bd41e0ebf..8a7da5e2d 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -632,3 +632,23 @@ yodlee_accounts_out: - yodlee_fastlink_params - created_at - updated_at + + +corporate_card_merge_in: + type: object + properties: + destination_card_id: + allOf: + - $ref: './fields.yaml#/id_string' + description: | + The ID of the destination card into which the source card will be merged + example: bawownwrng + source_card_id: + allOf: + - $ref: './fields.yaml#/id_string' + description: | + The ID of the source card that will be merged into the destination card + example: uswjwgnwwgo + required: + - destination_card_id + - source_card_id \ No newline at end of file From bc458b9c9dfde2a6816712beed1d9fbabb846151 Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Tue, 16 Jun 2026 16:39:47 +0530 Subject: [PATCH 032/107] feat: Add corporate card duplicate suggestions list api spec (#793) * feat: Add corporate card duplicate suggestions list api * minor * Auto generate API docs * minor * Auto generate API docs --- reference/admin.yaml | 151 ++++++++++++++++++ src/admin/openapi.yaml | 2 + ...corporate_cards@duplicate_suggestions.yaml | 42 +++++ src/components/schemas/corporate_card.yaml | 114 ++++++++++++- 4 files changed, 308 insertions(+), 1 deletion(-) create mode 100644 src/admin/paths/admin@corporate_cards@duplicate_suggestions.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 7673c7b69..44ecb22ae 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -7583,6 +7583,49 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/corporate_cards/duplicate_suggestions: + get: + tags: + - Corporate Cards + summary: List corporate card duplicate suggestions + description: | + This API supports very rich filtering on all response fields and pagination via query parameters. To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + operationId: corporate_card_duplicate_suggestions_list + parameters: + - $ref: '#/components/parameters/q' + - $ref: '#/components/parameters/created_at' + - $ref: '#/components/parameters/updated_at' + - $ref: '#/components/parameters/order' + - $ref: '#/components/parameters/offset' + - $ref: '#/components/parameters/limit' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + $ref: '#/components/schemas/count' + offset: + $ref: '#/components/schemas/offset' + data: + type: array + items: + $ref: '#/components/schemas/corporate_card_duplicate_suggestion_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' /admin/corporate_card_transactions: get: tags: @@ -23521,6 +23564,114 @@ components: required: - destination_card_id - source_card_id + duplicate_suggestion_corporate_card_out_embed: + type: object + additionalProperties: false + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + bank_name: + type: string + description: | + Specifies the name of bank who issued the card. + example: Bank of America + card_number: + type: string + description: | + Specifies the masked number of the card. + example: xxxx-4543 + nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: Business Card + total_transactions_count: + type: integer + nullable: false + description: | + The total number of transactions for the card, in Sage Exp Mgmt + example: 100 + is_visa_enrolled: + type: boolean + description: | + If the card is enrolled with real time feed from visa + nullable: false + is_mastercard_enrolled: + type: boolean + description: | + If the card is enrolled with realtime feed from Mastercard + nullable: false + data_feed_source: + type: string + nullable: true + description: | + signifies the source of how card is added and how further card transactions could be synced + example: BANK FEED - CDF + feed_display_name: + type: string + nullable: true + description: | + A user-friendly name for the data feed source. + example: Bank Feed + corporate_card_duplicate_suggestion_out: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + org_id: + $ref: '#/components/schemas/org_id' + user_id: + type: string + maxLength: 255 + nullable: true + description: | + The unique id of an user to whom the card is assigned + example: uswjwgnwwgo + user: + $ref: '#/components/schemas/user_out_embed_nullable' + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' + destination_card_id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + description: | + The ID of the destination card into which the source card will be merged + destination_card: + $ref: '#/components/schemas/duplicate_suggestion_corporate_card_out_embed' + source_card_id: + allOf: + - $ref: '#/components/schemas/id_string' + example: baccownwrng + description: | + The ID of the source card that will be merged into the destination card + source_card: + $ref: '#/components/schemas/duplicate_suggestion_corporate_card_out_embed' + is_dismissed: + type: boolean + description: | + Indicates whether the duplicate suggestion has been dismissed by an admin + nullable: false + required: + - id + - org_id + - user_id + - user + - created_at + - updated_at + - destination_card_id + - destination_card + - source_card_id + - source_card + - is_dismissed string_detail: type: string description: Additional string details of the card transaction. Can hold details upto 256 characters in length. diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 0b01a25c6..527f7d7c5 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -369,6 +369,8 @@ paths: $ref: paths/admin@corporate_cards@delete.yaml /admin/corporate_cards/merge: $ref: paths/admin@corporate_cards@merge.yaml + /admin/corporate_cards/duplicate_suggestions: + $ref: paths/admin@corporate_cards@duplicate_suggestions.yaml /admin/corporate_card_transactions: $ref: paths/admin@corporate_card_transactions.yaml diff --git a/src/admin/paths/admin@corporate_cards@duplicate_suggestions.yaml b/src/admin/paths/admin@corporate_cards@duplicate_suggestions.yaml new file mode 100644 index 000000000..c7ef84e80 --- /dev/null +++ b/src/admin/paths/admin@corporate_cards@duplicate_suggestions.yaml @@ -0,0 +1,42 @@ +get: + tags: + - Corporate Cards + summary: List corporate card duplicate suggestions + description: | + This API supports very rich filtering on all response fields and pagination via query parameters. To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + operationId: corporate_card_duplicate_suggestions_list + parameters: + - $ref: '../../components/parameters/q.yaml' + - $ref: '../../components/parameters/created_at.yaml' + - $ref: '../../components/parameters/updated_at.yaml' + - $ref: '../../components/parameters/order.yaml' + - $ref: '../../components/parameters/offset.yaml' + - $ref: '../../components/parameters/limit.yaml' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + $ref: '../../components/schemas/count.yaml' + offset: + $ref: '../../components/schemas/offset.yaml' + data: + type: array + items: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_duplicate_suggestion_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index 8a7da5e2d..117467784 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -511,6 +511,61 @@ corporate_card_out_embed: example: john.doe@example.com +duplicate_suggestion_corporate_card_out_embed: + type: object + additionalProperties: false + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: bawownwrng + bank_name: + type: string + description: | + Specifies the name of bank who issued the card. + example: Bank of America + card_number: + type: string + description: | + Specifies the masked number of the card. + example: xxxx-4543 + nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: 'Business Card' + total_transactions_count: + type: integer + nullable: false + description: | + The total number of transactions for the card, in Sage Exp Mgmt + example: 100 + is_visa_enrolled: + type: boolean + description: | + If the card is enrolled with real time feed from visa + nullable: false + is_mastercard_enrolled: + type: boolean + description: | + If the card is enrolled with realtime feed from Mastercard + nullable: false + data_feed_source: + type: string + nullable: true + description: | + signifies the source of how card is added and how further card transactions could be synced + example: BANK FEED - CDF + feed_display_name: + type: string + nullable: true + description: | + A user-friendly name for the data feed source. + example: Bank Feed + + corporate_card_stats_in: properties: query_params: @@ -651,4 +706,61 @@ corporate_card_merge_in: example: uswjwgnwwgo required: - destination_card_id - - source_card_id \ No newline at end of file + - source_card_id + + +corporate_card_duplicate_suggestion_out: + type: object + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: bawownwrng + org_id: + $ref: './fields.yaml#/org_id' + user_id: + type: string + maxLength: 255 + nullable: true + description: | + The unique id of an user to whom the card is assigned + example: uswjwgnwwgo + user: + $ref: ./user.yaml#/user_out_embed_nullable + created_at: + $ref: './fields.yaml#/created_at' + updated_at: + $ref: './fields.yaml#/updated_at' + destination_card_id: + allOf: + - $ref: './fields.yaml#/id_string' + example: bawownwrng + description: | + The ID of the destination card into which the source card will be merged + destination_card: + $ref: ./corporate_card.yaml#/duplicate_suggestion_corporate_card_out_embed + source_card_id: + allOf: + - $ref: './fields.yaml#/id_string' + example: baccownwrng + description: | + The ID of the source card that will be merged into the destination card + source_card: + $ref: ./corporate_card.yaml#/duplicate_suggestion_corporate_card_out_embed + is_dismissed: + type: boolean + description: | + Indicates whether the duplicate suggestion has been dismissed by an admin + nullable: false + required: + - id + - org_id + - user_id + - user + - created_at + - updated_at + - destination_card_id + - destination_card + - source_card_id + - source_card + - is_dismissed \ No newline at end of file From f28b516d3b16f6a1f9cbd5ac923c824e2b63c0b3 Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Wed, 17 Jun 2026 13:12:43 +0530 Subject: [PATCH 033/107] feat: Add corporate card duplicate suggestions dismiss api spec (#794) * feat: Add corporate card duplicate suggestions dismiss api spec * Auto generate API docs --- reference/admin.yaml | 65 +++++++++++++++++++ src/admin/openapi.yaml | 2 + ...e_cards@duplicate_suggestions@dismiss.yaml | 53 +++++++++++++++ src/components/schemas/corporate_card.yaml | 14 +++- 4 files changed, 133 insertions(+), 1 deletion(-) create mode 100644 src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 44ecb22ae..49681585c 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -7626,6 +7626,60 @@ paths: application/json: schema: $ref: '#/components/schemas/401' + /admin/corporate_cards/duplicate_suggestions/dismiss: + post: + tags: + - Corporate Cards + summary: Dismiss a corporate card duplicate suggestion + description: | + Dismiss a corporate card duplicate suggestion + operationId: corporate_cards_dismiss_duplicate_suggestion + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/corporate_card_duplicate_suggestion_dismiss_in' + required: + - data + additionalProperties: false + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/corporate_card_duplicate_suggestion_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/corporate_card_transactions: get: tags: @@ -23672,6 +23726,17 @@ components: - source_card_id - source_card - is_dismissed + corporate_card_duplicate_suggestion_dismiss_in: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: ccdswownwrng + description: | + The ID of the duplicate suggestion to be dismissed + required: + - id string_detail: type: string description: Additional string details of the card transaction. Can hold details upto 256 characters in length. diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 527f7d7c5..e0a66598f 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -371,6 +371,8 @@ paths: $ref: paths/admin@corporate_cards@merge.yaml /admin/corporate_cards/duplicate_suggestions: $ref: paths/admin@corporate_cards@duplicate_suggestions.yaml + /admin/corporate_cards/duplicate_suggestions/dismiss: + $ref: paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml /admin/corporate_card_transactions: $ref: paths/admin@corporate_card_transactions.yaml diff --git a/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml b/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml new file mode 100644 index 000000000..88ed5f0b2 --- /dev/null +++ b/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml @@ -0,0 +1,53 @@ +post: + tags: + - Corporate Cards + summary: Dismiss a corporate card duplicate suggestion + description: | + Dismiss a corporate card duplicate suggestion + operationId: corporate_cards_dismiss_duplicate_suggestion + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: ../../components/schemas/corporate_card.yaml#/corporate_card_duplicate_suggestion_dismiss_in + required: + - data + additionalProperties: False + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_duplicate_suggestion_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index 117467784..5bd16a3ac 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -763,4 +763,16 @@ corporate_card_duplicate_suggestion_out: - destination_card - source_card_id - source_card - - is_dismissed \ No newline at end of file + - is_dismissed + +corporate_card_duplicate_suggestion_dismiss_in: + type: object + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: ccdswownwrng + description: | + The ID of the duplicate suggestion to be dismissed + required: + - id From 889e6d0cdfb3a91fc7e1b9a9c5052a7f981e8e03 Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Mon, 22 Jun 2026 12:49:33 +0530 Subject: [PATCH 034/107] feat: Add corporate card is_archived field to cct response schema (#795) * Add corporate card is_archived field to cct response schema * Auto generate API docs --- reference/admin.yaml | 5 +++++ reference/spender.yaml | 5 +++++ src/components/schemas/corporate_card.yaml | 5 +++++ 3 files changed, 15 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 49681585c..f56bd791a 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -23794,6 +23794,11 @@ components: description: | String denoting the card holder's email example: john.doe@example.com + is_archived: + type: boolean + description: | + Indicates whether the corporate card is archived. + nullable: false matched_expense_out_embed: type: object nullable: true diff --git a/reference/spender.yaml b/reference/spender.yaml index 9a8aee0ad..b719d7557 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -12879,6 +12879,11 @@ components: description: | String denoting the card holder's email example: john.doe@example.com + is_archived: + type: boolean + description: | + Indicates whether the corporate card is archived. + nullable: false matched_expense_out_embed: type: object nullable: true diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index 5bd16a3ac..0e158874e 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -509,6 +509,11 @@ corporate_card_out_embed: description: | String denoting the card holder's email example: john.doe@example.com + is_archived: + type: boolean + description: | + Indicates whether the corporate card is archived. + nullable: false duplicate_suggestion_corporate_card_out_embed: From 2cf3479b61f737a50a9d5469ff4dc4f9d48b4fd5 Mon Sep 17 00:00:00 2001 From: satyamyesj <49139311+satyamyesj@users.noreply.github.com> Date: Thu, 25 Jun 2026 12:38:38 +0530 Subject: [PATCH 035/107] feat: Adding API Docs for approver/corporate_cards API (#797) * feat: Adding API Docs for approver/corporate_cards API * Auto generate API docs --------- Co-authored-by: satyamyesj-outlook --- reference/approver.yaml | 281 ++++++++++++++++-- src/approver/openapi.yaml | 8 +- .../paths/approver@corporate_cards.yaml | 50 ++++ 3 files changed, 316 insertions(+), 23 deletions(-) create mode 100644 src/approver/paths/approver@corporate_cards.yaml diff --git a/reference/approver.yaml b/reference/approver.yaml index cd59e5745..53a22a810 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -25,6 +25,9 @@ tags: - name: Cost Centers description: | These APIs gives you access to manage your organisation's Cost Centers + - name: Corporate Cards + description: | + This API gives you access to view Corporate Cards across organisations where user is approver. - name: Per Diem Rates description: | This API gives you access to manage your organisation's Per Diem Rates @@ -1543,6 +1546,57 @@ paths: application/json: schema: $ref: '#/components/schemas/401' + /approver/corporate_cards: + get: + tags: + - Corporate Cards + summary: List corporate cards + description: | + Returns corporate cards from all organisations where user is approver. + + This API supports very rich filtering on all response fields and pagination via query parameters. To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + operationId: corporate_cards_list + parameters: + - $ref: '#/components/parameters/q' + - $ref: '#/components/parameters/created_at' + - $ref: '#/components/parameters/updated_at' + - $ref: '#/components/parameters/order' + - $ref: '#/components/parameters/offset' + - $ref: '#/components/parameters/limit' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + $ref: '#/components/schemas/count' + offset: + $ref: '#/components/schemas/offset' + data: + type: array + items: + $ref: '#/components/schemas/corporate_card_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /approver/cost_centers: get: tags: @@ -8238,6 +8292,193 @@ components: List of project ids for which this category can be used. If project_ids is null, then this category can be used for any project. restricted_spender_user_ids: $ref: '#/components/schemas/restricted_spender_user_ids' + corporate_card_out: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + org_id: + $ref: '#/components/schemas/org_id' + user_id: + type: string + maxLength: 255 + nullable: true + description: | + The unique id of an user to whom the card is assigned + example: uswjwgnwwgo + user: + $ref: '#/components/schemas/user_out_embed_nullable' + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' + bank_name: + $ref: '#/components/schemas/bank_name' + card_number: + $ref: '#/components/schemas/card_number' + cardholder_name: + type: string + maxLength: 255 + nullable: true + description: | + String denoting the card holder's name + example: John Cena + data_feed_source: + type: string + nullable: true + description: | + signifies the source of how card is added and how further card transactions could be synced + example: BANK FEED - CDF + code: + type: string + nullable: true + description: | + Id given by external systems like Gmail. To identify whether that entity + has been already added to Sage Exp Mgmt or not. + example: wgjwgo3ihwljnlsww + yodlee_account_id: + type: string + nullable: true + description: | + Identifier for the linked Yodlee account. + example: yac2cqC4eSaS6 + last_synced_at: + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + nullable: true + description: | + Signifies when this card was last synced. + last_assigned_at: + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + nullable: true + description: | + Signifies when this card was last assigned. + assignor_user_id: + type: string + description: | + The unique id of an user who assigned the card. + nullable: true + example: uswjwgnwwgo + is_visa_enrolled: + type: boolean + description: | + If the card is enrolled with real time feed from visa + nullable: false + is_mastercard_enrolled: + type: boolean + description: | + If the card is enrolled with realtime feed from Mastercard + nullable: false + is_capitalone_enrolled: + type: boolean + description: | + If the card is enrolled with realtime feed from Capital One + nullable: true + is_dummy: + type: boolean + description: | + If the card is a test card + nullable: false + last_ready_for_verification_at: + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies when the card was ready to be verified + example: '2022-02-01T07:20:30.951475+00:00' + nullable: true + last_verification_attempt_at: + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies when the last card verification was attempted + nullable: true + last_verified_at: + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies when the card was verified + example: '2022-02-01T07:20:39.207250+00:00' + nullable: true + verification_status: + type: string + nullable: false + description: | + Verification status of the corporate card + enum: + - VERIFIED + - NOT_VERIFIED + - READY_FOR_VERIFICATION + virtual_card_id: + type: string + description: | + The unique id of the virtual card, if the card is created from virtual card. + nullable: true + example: viasdfasdfddd + virtual_card_state: + type: string + description: | + Status of the virtual card + nullable: true + enum: + - ACTIVE + - PREACTIVE + - INACTIVE + - EXPIRED + - DELETED + - USED + - null + example: ACTIVE + nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: Business Card + total_transactions_count: + type: integer + nullable: false + description: | + The total number of transactions for the card, in Sage Exp Mgmt + example: 100 + unassigned_transactions_count: + type: integer + nullable: false + description: | + The total number of unassigned transactions for the card, in Sage Exp Mgmt + example: 50 + required: + - id + - org_id + - user_id + - user + - created_at + - updated_at + - bank_name + - card_number + - cardholder_name + - data_feed_source + - code + - yodlee_account_id + - last_synced_at + - last_assigned_at + - assignor_user_id + - is_visa_enrolled + - is_mastercard_enrolled + - is_capitalone_enrolled + - is_dummy + - last_ready_for_verification_at + - last_verification_attempt_at + - last_verified_at + - verification_status + - virtual_card_id + - virtual_card_state + - nickname + - total_transactions_count + - unassigned_transactions_count approver_cost_center_out: type: object additionalProperties: false @@ -11166,15 +11407,13 @@ components: id: $ref: '#/components/schemas/id_string' parameters: - id: + q: in: query - name: id - description: | - A resource ID + name: q + description: A search query to filter the results. schema: type: string - example: - - eq.ouwruogwnngg + example: Ritas created_at: in: query name: created_at @@ -11191,15 +11430,15 @@ components: schema: type: string example: gte.2020-06-01T00:00:00.000-08:00 - display_name: + order: in: query - name: display_name + name: order description: | - Supported operators are `eq`, `like`, `in`.
- display_name=in.(value1,value2) + use comma separated column names for sorting the results.
+ For sorting in descending order, use `column_name.desc` schema: type: string - example: like.Fast* + example: updated_at.desc,id offset: in: query name: offset @@ -11218,22 +11457,24 @@ components: example: 20 default: 50 maximum: 200 - order: + id: in: query - name: order + name: id description: | - use comma separated column names for sorting the results.
- For sorting in descending order, use `column_name.desc` + A resource ID schema: type: string - example: updated_at.desc,id - q: + example: + - eq.ouwruogwnngg + display_name: in: query - name: q - description: A search query to filter the results. + name: display_name + description: | + Supported operators are `eq`, `like`, `in`.
+ display_name=in.(value1,value2) schema: type: string - example: Ritas + example: like.Fast* expense_id: in: query name: expense_id diff --git a/src/approver/openapi.yaml b/src/approver/openapi.yaml index b59a4e2ea..b09ca9d7d 100644 --- a/src/approver/openapi.yaml +++ b/src/approver/openapi.yaml @@ -35,9 +35,9 @@ tags: - name: Cost Centers description: | These APIs gives you access to manage your organisation's Cost Centers -# - name: Corporate Cards -# description: | -# This API gives you access to perform action on Corporate Cards and their transactions. + - name: Corporate Cards + description: | + This API gives you access to view Corporate Cards across organisations where user is approver. - name: Per Diem Rates description: | This API gives you access to manage your organisation's Per Diem Rates @@ -122,6 +122,8 @@ paths: $ref: paths/approver@projects.yaml /approver/categories: $ref: paths/approver@categories.yaml + /approver/corporate_cards: + $ref: paths/approver@corporate_cards.yaml /approver/cost_centers: $ref: paths/approver@cost_centers.yaml /approver/per_diem_rates: diff --git a/src/approver/paths/approver@corporate_cards.yaml b/src/approver/paths/approver@corporate_cards.yaml new file mode 100644 index 000000000..76b9ba1e9 --- /dev/null +++ b/src/approver/paths/approver@corporate_cards.yaml @@ -0,0 +1,50 @@ +get: + tags: + - Corporate Cards + summary: List corporate cards + description: | + Returns corporate cards from all organisations where user is approver. + + This API supports very rich filtering on all response fields and pagination via query parameters. To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + operationId: corporate_cards_list + parameters: + - $ref: '../../components/parameters/q.yaml' + - $ref: '../../components/parameters/created_at.yaml' + - $ref: '../../components/parameters/updated_at.yaml' + - $ref: '../../components/parameters/order.yaml' + - $ref: '../../components/parameters/offset.yaml' + - $ref: '../../components/parameters/limit.yaml' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + $ref: '../../components/schemas/count.yaml' + offset: + $ref: '../../components/schemas/offset.yaml' + data: + type: array + items: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' From 35f69c1f5103dc522adfa57fcb7969c3724fc70d Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Thu, 25 Jun 2026 14:31:20 +0530 Subject: [PATCH 036/107] feat: Added archival fields to corporate card api response schemas (#796) * feat: Added archival fields to corporate card api response schemas * Auto generate API docs * Added in matched corporate card transaction schema * Auto generate API docs * Auto generate API docs --- reference/admin.yaml | 50 ++++++++++++++++++++++ reference/approver.yaml | 30 +++++++++++++ reference/manager.yaml | 10 +++++ reference/spender.yaml | 30 +++++++++++++ src/components/schemas/corporate_card.yaml | 40 +++++++++++++++++ src/components/schemas/expense.yaml | 10 +++++ 6 files changed, 170 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index f56bd791a..c2b4a372f 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -18300,6 +18300,11 @@ components: description: | String denoting the card holder's full name example: John Doe + is_corporate_card_archived: + type: boolean + description: | + Signifies whether the corporate card is archived or not. + nullable: false amount: $ref: '#/components/schemas/amount' currency: @@ -18417,6 +18422,11 @@ components: description: | String denoting the card holder's full name example: John Doe + is_corporate_card_archived: + type: boolean + description: | + Signifies whether the corporate card is archived or not. + nullable: false amount: $ref: '#/components/schemas/amount' currency: @@ -23234,6 +23244,23 @@ components: description: | Unique nickname assigned to the card example: Business Card + is_archived: + type: boolean + description: | + Indicates whether the corporate card is archived. + nullable: false + archived_at: + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies when the card was archived + example: '2022-02-01T07:20:39.207250+00:00' + nullable: true + archived_by_user_id: + type: string + description: | + The unique id of an user who archived the card. + nullable: true total_transactions_count: type: integer nullable: false @@ -23273,6 +23300,9 @@ components: - virtual_card_id - virtual_card_state - nickname + - is_archived + - archived_at + - archived_by_user_id - total_transactions_count - unassigned_transactions_count corporate_card_in: @@ -23544,6 +23574,23 @@ components: description: | Unique nickname assigned to the card example: Business Card + is_archived: + type: boolean + description: | + Indicates whether the corporate card is archived. + nullable: false + archived_at: + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies when the card was archived + example: '2022-02-01T07:20:39.207250+00:00' + nullable: true + archived_by_user_id: + type: string + description: | + The unique id of an user who archived the card. + nullable: true total_transactions_count: type: integer nullable: false @@ -23583,6 +23630,9 @@ components: - virtual_card_id - virtual_card_state - nickname + - is_archived + - archived_at + - archived_by_user_id - total_transactions_count - unassigned_transactions_count corporate_card_reassign_in: diff --git a/reference/approver.yaml b/reference/approver.yaml index 53a22a810..55d46c167 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -5780,6 +5780,11 @@ components: description: | String denoting the card holder's full name example: John Doe + is_corporate_card_archived: + type: boolean + description: | + Signifies whether the corporate card is archived or not. + nullable: false amount: $ref: '#/components/schemas/amount' currency: @@ -5897,6 +5902,11 @@ components: description: | String denoting the card holder's full name example: John Doe + is_corporate_card_archived: + type: boolean + description: | + Signifies whether the corporate card is archived or not. + nullable: false amount: $ref: '#/components/schemas/amount' currency: @@ -8438,6 +8448,23 @@ components: description: | Unique nickname assigned to the card example: Business Card + is_archived: + type: boolean + description: | + Indicates whether the corporate card is archived. + nullable: false + archived_at: + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies when the card was archived + example: '2022-02-01T07:20:39.207250+00:00' + nullable: true + archived_by_user_id: + type: string + description: | + The unique id of an user who archived the card. + nullable: true total_transactions_count: type: integer nullable: false @@ -8477,6 +8504,9 @@ components: - virtual_card_id - virtual_card_state - nickname + - is_archived + - archived_at + - archived_by_user_id - total_transactions_count - unassigned_transactions_count approver_cost_center_out: diff --git a/reference/manager.yaml b/reference/manager.yaml index 4fdb18873..8473ae648 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -2397,6 +2397,11 @@ components: description: | String denoting the card holder's full name example: John Doe + is_corporate_card_archived: + type: boolean + description: | + Signifies whether the corporate card is archived or not. + nullable: false amount: $ref: '#/components/schemas/amount' currency: @@ -2514,6 +2519,11 @@ components: description: | String denoting the card holder's full name example: John Doe + is_corporate_card_archived: + type: boolean + description: | + Signifies whether the corporate card is archived or not. + nullable: false amount: $ref: '#/components/schemas/amount' currency: diff --git a/reference/spender.yaml b/reference/spender.yaml index b719d7557..597002e6c 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -9005,6 +9005,11 @@ components: description: | String denoting the card holder's full name example: John Doe + is_corporate_card_archived: + type: boolean + description: | + Signifies whether the corporate card is archived or not. + nullable: false amount: $ref: '#/components/schemas/amount' currency: @@ -9122,6 +9127,11 @@ components: description: | String denoting the card holder's full name example: John Doe + is_corporate_card_archived: + type: boolean + description: | + Signifies whether the corporate card is archived or not. + nullable: false amount: $ref: '#/components/schemas/amount' currency: @@ -12703,6 +12713,23 @@ components: description: | Unique nickname assigned to the card example: Business Card + is_archived: + type: boolean + description: | + Indicates whether the corporate card is archived. + nullable: false + archived_at: + allOf: + - $ref: '#/components/schemas/timestamptz_utc' + description: | + Signifies when the card was archived + example: '2022-02-01T07:20:39.207250+00:00' + nullable: true + archived_by_user_id: + type: string + description: | + The unique id of an user who archived the card. + nullable: true total_transactions_count: type: integer nullable: false @@ -12742,6 +12769,9 @@ components: - virtual_card_id - virtual_card_state - nickname + - is_archived + - archived_at + - archived_by_user_id - total_transactions_count - unassigned_transactions_count yodlee_accounts_out: diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index 0e158874e..40f09621e 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -144,6 +144,23 @@ corporate_card_out: description: | Unique nickname assigned to the card example: 'Business Card' + is_archived: + type: boolean + description: | + Indicates whether the corporate card is archived. + nullable: false + archived_at: + allOf: + - $ref: './fields.yaml#/timestamptz_utc' + description: | + Signifies when the card was archived + example: "2022-02-01T07:20:39.207250+00:00" + nullable: true + archived_by_user_id: + type: string + description: | + The unique id of an user who archived the card. + nullable: true total_transactions_count: type: integer nullable: false @@ -183,6 +200,9 @@ corporate_card_out: - virtual_card_id - virtual_card_state - nickname + - is_archived + - archived_at + - archived_by_user_id - total_transactions_count - unassigned_transactions_count corporate_card_in: @@ -416,6 +436,23 @@ corporate_card_unassign_out: description: | Unique nickname assigned to the card example: 'Business Card' + is_archived: + type: boolean + description: | + Indicates whether the corporate card is archived. + nullable: false + archived_at: + allOf: + - $ref: './fields.yaml#/timestamptz_utc' + description: | + Signifies when the card was archived + example: "2022-02-01T07:20:39.207250+00:00" + nullable: true + archived_by_user_id: + type: string + description: | + The unique id of an user who archived the card. + nullable: true total_transactions_count: type: integer nullable: false @@ -455,6 +492,9 @@ corporate_card_unassign_out: - virtual_card_id - virtual_card_state - nickname + - is_archived + - archived_at + - archived_by_user_id - total_transactions_count - unassigned_transactions_count corporate_card_out_embed: diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 1878901b9..88e9c4a81 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -1610,6 +1610,11 @@ matched_corporate_card_transaction_out_embed: description: | String denoting the card holder's full name example: John Doe + is_corporate_card_archived: + type: boolean + description: | + Signifies whether the corporate card is archived or not. + nullable: false amount: $ref: './fields.yaml#/amount' currency: @@ -1729,6 +1734,11 @@ matched_corporate_card_transaction_out_embed_new: description: | String denoting the card holder's full name example: John Doe + is_corporate_card_archived: + type: boolean + description: | + Signifies whether the corporate card is archived or not. + nullable: false amount: $ref: './fields.yaml#/amount' currency: From b9de536a372f0896ad3b426d5278509fe3a1e5f4 Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Fri, 3 Jul 2026 12:13:03 +0530 Subject: [PATCH 037/107] =?UTF-8?q?feat:=20Add=20corporate=20card=20is=20a?= =?UTF-8?q?rchived=20column=20to=20reconciliation=20eligibl=E2=80=A6=20(#7?= =?UTF-8?q?98)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat: Add corporate card is archived column to reconciliation eligible cards view * Auto generate API docs --- reference/admin.yaml | 5 +++++ src/components/schemas/reconciliation_eligible_cards.yaml | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index c2b4a372f..eaf069562 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -32277,6 +32277,7 @@ components: - reconciliation_entry_id - card_number - card_nickname + - is_archived - user - reconciled_on - statement_transaction_count @@ -32308,6 +32309,10 @@ components: maxLength: 25 description: Unique nickname assigned to the card. example: Business Card + is_archived: + type: boolean + description: Indicate whether the card is archived. + example: false user: $ref: '#/components/schemas/user_out_embed_nullable' reconciled_on: diff --git a/src/components/schemas/reconciliation_eligible_cards.yaml b/src/components/schemas/reconciliation_eligible_cards.yaml index dcdaa36f2..0b3f8fa67 100644 --- a/src/components/schemas/reconciliation_eligible_cards.yaml +++ b/src/components/schemas/reconciliation_eligible_cards.yaml @@ -7,6 +7,7 @@ reconciliation_eligible_card_out: - reconciliation_entry_id - card_number - card_nickname + - is_archived - user - reconciled_on - statement_transaction_count @@ -38,6 +39,10 @@ reconciliation_eligible_card_out: maxLength: 25 description: Unique nickname assigned to the card. example: Business Card + is_archived: + type: boolean + description: Indicate whether the card is archived. + example: false user: $ref: './user.yaml#/user_out_embed_nullable' reconciled_on: From b64caafd97cdea86d3e7c88886133aa4c9055562 Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Fri, 3 Jul 2026 15:35:59 +0530 Subject: [PATCH 038/107] feat: Add corporate card archive api spec (#799) * feat: Add corporate card archive api spec * Auto generate API docs --- reference/admin.yaml | 63 +++++++++++++++++++ src/admin/openapi.yaml | 2 + .../paths/admin@corporate_cards@archive.yaml | 54 ++++++++++++++++ src/components/schemas/corporate_card.yaml | 10 +++ 4 files changed, 129 insertions(+) create mode 100644 src/admin/paths/admin@corporate_cards@archive.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index eaf069562..238aaf474 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -7583,6 +7583,60 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/corporate_cards/archive: + post: + tags: + - Corporate Cards + summary: Archive a corporate card + description: | + Archive a corporate card + operationId: corporate_cards_archive + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/corporate_card_archive_in' + required: + - data + additionalProperties: false + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/corporate_card_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/corporate_cards/duplicate_suggestions: get: tags: @@ -23668,6 +23722,15 @@ components: required: - destination_card_id - source_card_id + corporate_card_archive_in: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + required: + - id duplicate_suggestion_corporate_card_out_embed: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index e0a66598f..2f2267640 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -369,6 +369,8 @@ paths: $ref: paths/admin@corporate_cards@delete.yaml /admin/corporate_cards/merge: $ref: paths/admin@corporate_cards@merge.yaml + /admin/corporate_cards/archive: + $ref: paths/admin@corporate_cards@archive.yaml /admin/corporate_cards/duplicate_suggestions: $ref: paths/admin@corporate_cards@duplicate_suggestions.yaml /admin/corporate_cards/duplicate_suggestions/dismiss: diff --git a/src/admin/paths/admin@corporate_cards@archive.yaml b/src/admin/paths/admin@corporate_cards@archive.yaml new file mode 100644 index 000000000..704fde701 --- /dev/null +++ b/src/admin/paths/admin@corporate_cards@archive.yaml @@ -0,0 +1,54 @@ +post: + tags: + - Corporate Cards + summary: Archive a corporate card + description: | + Archive a corporate card + operationId: corporate_cards_archive + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: ../../components/schemas/corporate_card.yaml#/corporate_card_archive_in + required: + - data + additionalProperties: False + + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index 40f09621e..b102440f8 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -821,3 +821,13 @@ corporate_card_duplicate_suggestion_dismiss_in: The ID of the duplicate suggestion to be dismissed required: - id + +corporate_card_archive_in: + type: object + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: bawownwrng + required: + - id From a4160cb51402ac598862aca93f9625601ab11d11 Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Fri, 3 Jul 2026 16:17:23 +0530 Subject: [PATCH 039/107] feat: Add corporate card unarchive api specs (#800) * feat: Add corporate card unarchive api specs * Auto generate API docs --- reference/admin.yaml | 126 ++++++++++++++++++ src/admin/openapi.yaml | 4 + .../admin@corporate_cards@unarchive.yaml | 54 ++++++++ .../admin@corporate_cards@unarchive@bulk.yaml | 62 +++++++++ src/components/schemas/corporate_card.yaml | 11 ++ 5 files changed, 257 insertions(+) create mode 100644 src/admin/paths/admin@corporate_cards@unarchive.yaml create mode 100644 src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 238aaf474..4908b310c 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -7637,6 +7637,123 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/corporate_cards/unarchive: + post: + tags: + - Corporate Cards + summary: Unarchive a corporate card + description: | + Unarchive a corporate card + operationId: corporate_cards_unarchive + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/corporate_card_unarchive_in' + required: + - data + additionalProperties: false + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/corporate_card_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/corporate_cards/unarchive/bulk: + post: + tags: + - Corporate Cards + summary: Bulk unarchive corporate cards + description: | + Unarchive corporate cards in bulk. + operationId: corporate_cards_unarchive_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '#/components/schemas/corporate_card_unarchive_in' + required: + - data + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '#/components/schemas/corporate_card_out' + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '#/components/schemas/bulk_error' + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /admin/corporate_cards/duplicate_suggestions: get: tags: @@ -23731,6 +23848,15 @@ components: example: bawownwrng required: - id + corporate_card_unarchive_in: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + required: + - id duplicate_suggestion_corporate_card_out_embed: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 2f2267640..fd5954f4b 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -371,6 +371,10 @@ paths: $ref: paths/admin@corporate_cards@merge.yaml /admin/corporate_cards/archive: $ref: paths/admin@corporate_cards@archive.yaml + /admin/corporate_cards/unarchive: + $ref: paths/admin@corporate_cards@unarchive.yaml + /admin/corporate_cards/unarchive/bulk: + $ref: paths/admin@corporate_cards@unarchive@bulk.yaml /admin/corporate_cards/duplicate_suggestions: $ref: paths/admin@corporate_cards@duplicate_suggestions.yaml /admin/corporate_cards/duplicate_suggestions/dismiss: diff --git a/src/admin/paths/admin@corporate_cards@unarchive.yaml b/src/admin/paths/admin@corporate_cards@unarchive.yaml new file mode 100644 index 000000000..3e21aabdf --- /dev/null +++ b/src/admin/paths/admin@corporate_cards@unarchive.yaml @@ -0,0 +1,54 @@ +post: + tags: + - Corporate Cards + summary: Unarchive a corporate card + description: | + Unarchive a corporate card + operationId: corporate_cards_unarchive + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: ../../components/schemas/corporate_card.yaml#/corporate_card_unarchive_in + required: + - data + additionalProperties: False + + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml b/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml new file mode 100644 index 000000000..bce9c0ae3 --- /dev/null +++ b/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml @@ -0,0 +1,62 @@ +post: + tags: + - Corporate Cards + summary: Bulk unarchive corporate cards + description: | + Unarchive corporate cards in bulk. + operationId: corporate_cards_unarchive_bulk + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_unarchive_in' + required: + - data + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: ../../components/schemas/bulk_error.yaml + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index b102440f8..073346dc2 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -831,3 +831,14 @@ corporate_card_archive_in: example: bawownwrng required: - id + +corporate_card_unarchive_in: + type: object + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: bawownwrng + required: + - id + From 0d701324067c2fd83a0eb76eaf3964d47877669e Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Tue, 7 Jul 2026 19:03:26 +0530 Subject: [PATCH 040/107] feat: Add spec for api to list archived cards in the statement upload (#801) * feat: Add spec for api to list archived cards in the statement upload * Auto generate API docs --- reference/admin.yaml | 106 ++++++++++++++++++ src/admin/openapi.yaml | 2 + .../admin@statements@archived_cards.yaml | 54 +++++++++ src/components/schemas/statements.yaml | 54 +++++++++ 4 files changed, 216 insertions(+) create mode 100644 src/admin/paths/admin@statements@archived_cards.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 4908b310c..26fcded62 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -11606,6 +11606,61 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/statements/archived_cards: + post: + tags: + - Statements + summary: Archived cards present in Sage Exp Mgmt + description: | + Returns archived cards present in Sage Exp Mgmt for cards in Statement + operationId: archived_cards + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/statement_archived_cards_in' + required: + - data + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '#/components/schemas/statement_archived_cards_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/expense_rules: post: tags: @@ -30998,6 +31053,57 @@ components: description: | RTF Confidence percentage indicates what % of the transactions in last uploaded statement are already existing in Sage Exp Mgmt via RTF. example: 99.22 + statement_archived_cards_in: + allOf: + - $ref: '#/components/schemas/summary_from_statement_in' + - type: object + properties: + card_mapping: + $ref: '#/components/schemas/card_mapping_in' + required: + - card_mapping + statement_archived_cards_out: + properties: + number_of_cards: + type: integer + description: | + Number of cards in the statement + example: 3 + number_of_archived_cards: + type: integer + description: | + Number of cards in the statement that are archived in Sage Exp Mgmt + example: 1 + archived_cards: + type: array + items: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + card_number: + $ref: '#/components/schemas/card_number' + nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: Business Card + user: + $ref: '#/components/schemas/user_out_embed_nullable' + is_archived: + type: boolean + description: | + If the card is archived in Sage Exp Mgmt + nullable: false + archived_at: + $ref: '#/components/schemas/timestamptz_utc' + description: | + Timestamp when the card was archived in Sage Exp Mgmt + nullable: true expense_rule_if_out: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index fd5954f4b..f47c383a0 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -524,6 +524,8 @@ paths: $ref: paths/admin@statements@create_card_transactions.yaml /admin/statements/rtf_stats: $ref: paths/admin@statements@rtf_stats.yaml + /admin/statements/archived_cards: + $ref: paths/admin@statements@archived_cards.yaml /admin/expense_rules: $ref: paths/admin@expense_rules.yaml /admin/expense_rules/dismiss_suggestion: diff --git a/src/admin/paths/admin@statements@archived_cards.yaml b/src/admin/paths/admin@statements@archived_cards.yaml new file mode 100644 index 000000000..60b5d27b6 --- /dev/null +++ b/src/admin/paths/admin@statements@archived_cards.yaml @@ -0,0 +1,54 @@ +post: + tags: + - Statements + summary: Archived cards present in Sage Exp Mgmt + description: | + Returns archived cards present in Sage Exp Mgmt for cards in Statement + operationId: archived_cards + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/statements.yaml#/statement_archived_cards_in' + required: + - data + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + type: array + items: + $ref: '../../components/schemas/statements.yaml#/statement_archived_cards_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/components/schemas/statements.yaml b/src/components/schemas/statements.yaml index 28b867edc..e54d3038f 100644 --- a/src/components/schemas/statements.yaml +++ b/src/components/schemas/statements.yaml @@ -1320,3 +1320,57 @@ unassigned_cards_from_statement_in: example: stmtwownwrng required: - statement_id + +statement_archived_cards_out: + properties: + number_of_cards: + type: integer + description: | + Number of cards in the statement + example: 3 + number_of_archived_cards: + type: integer + description: | + Number of cards in the statement that are archived in Sage Exp Mgmt + example: 1 + archived_cards: + type: array + items: + type: object + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: bawownwrng + card_number: + $ref: './fields.yaml#/card_number' + nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: 'Business Card' + user: + $ref: ./user.yaml#/user_out_embed_nullable + is_archived: + type: boolean + description: | + If the card is archived in Sage Exp Mgmt + nullable: false + archived_at: + $ref: './fields.yaml#/timestamptz_utc' + description: | + Timestamp when the card was archived in Sage Exp Mgmt + nullable: true + + +statement_archived_cards_in: + allOf: + - $ref: '#/summary_from_statement_in' + - type: object + properties: + card_mapping: + $ref: '#/card_mapping_in' + required: + - card_mapping From 91ca9356227a0329676a5221eb4b4bae46e2292a Mon Sep 17 00:00:00 2001 From: kulasekar Date: Wed, 8 Jul 2026 14:25:16 +0530 Subject: [PATCH 041/107] feat: FYLE-default-tax-group-changes (#803) --- reference/admin.yaml | 10 ++++++++++ reference/spender.yaml | 5 +++++ src/components/schemas/tax_group.yaml | 12 +++++++++++- 3 files changed, 26 insertions(+), 1 deletion(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 26fcded62..9c739a1b1 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -27859,6 +27859,11 @@ components: description: percentage of tax levied. is_enabled: $ref: '#/components/schemas/is_enabled' + is_default: + type: boolean + nullable: true + description: Indicates whether this tax group is the default for its percentage bucket. + example: false code: $ref: '#/components/schemas/code' tax_group_in: @@ -27886,6 +27891,11 @@ components: description: percentage of tax levied. is_enabled: $ref: '#/components/schemas/is_enabled' + is_default: + type: boolean + nullable: true + description: Indicates whether this tax group should be set as default for its percentage bucket. + example: false code: $ref: '#/components/schemas/code' budget_type: diff --git a/reference/spender.yaml b/reference/spender.yaml index 597002e6c..8da466ae6 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -15981,6 +15981,11 @@ components: description: percentage of tax levied. is_enabled: $ref: '#/components/schemas/is_enabled' + is_default: + type: boolean + nullable: true + description: Indicates whether this tax group is the default for its percentage bucket. + example: false code: $ref: '#/components/schemas/code' file_in: diff --git a/src/components/schemas/tax_group.yaml b/src/components/schemas/tax_group.yaml index 462bc9463..6ebccc83f 100644 --- a/src/components/schemas/tax_group.yaml +++ b/src/components/schemas/tax_group.yaml @@ -25,6 +25,11 @@ tax_group_out: description: percentage of tax levied. is_enabled: $ref: './fields.yaml#/is_enabled' + is_default: + type: boolean + nullable: true + description: Indicates whether this tax group is the default for its percentage bucket. + example: false code: $ref: './fields.yaml#/code' @@ -54,5 +59,10 @@ tax_group_in: description: percentage of tax levied. is_enabled: $ref: './fields.yaml#/is_enabled' + is_default: + type: boolean + nullable: true + description: Indicates whether this tax group should be set as default for its percentage bucket. + example: false code: - $ref: './fields.yaml#/code' \ No newline at end of file + $ref: './fields.yaml#/code' From 8a270ae82a98c1cdbde13de2b57ebff9c7f845a5 Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Mon, 13 Jul 2026 12:10:24 +0530 Subject: [PATCH 042/107] feat: Ignore stmt line items associated with archived cards api spec (#802) * feat: Ignore stmt line items associated with archived cards api spec * Auto generate API docs --- reference/admin.yaml | 69 +++++++++++++++++++ src/admin/openapi.yaml | 2 + ...dmin@statements@archived_cards@ignore.yaml | 53 ++++++++++++++ src/components/schemas/statements.yaml | 17 +++++ 4 files changed, 141 insertions(+) create mode 100644 src/admin/paths/admin@statements@archived_cards@ignore.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 9c739a1b1..4c560b4cf 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -11661,6 +11661,60 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/statements/archived_cards/ignore: + post: + tags: + - Statements + summary: Ignore archived cards present in the statement + description: | + Ignores archived cards present in the statement + operationId: archived_cards + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/statement_archived_cards_ignore_in' + required: + - data + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + type: object + description: Empty object on successfully ignoring archived cards + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/expense_rules: post: tags: @@ -31114,6 +31168,21 @@ components: description: | Timestamp when the card was archived in Sage Exp Mgmt nullable: true + statement_archived_cards_ignore_in: + allOf: + - $ref: '#/components/schemas/statement_archived_cards_in' + - type: object + properties: + archived_card_ids: + type: array + items: + type: string + description: | + List of archived card ids to be ignored in the statement. + example: + - bawownwrng + required: + - archived_card_ids expense_rule_if_out: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index f47c383a0..5725e2691 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -526,6 +526,8 @@ paths: $ref: paths/admin@statements@rtf_stats.yaml /admin/statements/archived_cards: $ref: paths/admin@statements@archived_cards.yaml + /admin/statements/archived_cards/ignore: + $ref: paths/admin@statements@archived_cards@ignore.yaml /admin/expense_rules: $ref: paths/admin@expense_rules.yaml /admin/expense_rules/dismiss_suggestion: diff --git a/src/admin/paths/admin@statements@archived_cards@ignore.yaml b/src/admin/paths/admin@statements@archived_cards@ignore.yaml new file mode 100644 index 000000000..2c5545caf --- /dev/null +++ b/src/admin/paths/admin@statements@archived_cards@ignore.yaml @@ -0,0 +1,53 @@ +post: + tags: + - Statements + summary: Ignore archived cards present in the statement + description: | + Ignores archived cards present in the statement + operationId: archived_cards + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/statements.yaml#/statement_archived_cards_ignore_in' + required: + - data + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + type: object + description: Empty object on successfully ignoring archived cards + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/components/schemas/statements.yaml b/src/components/schemas/statements.yaml index e54d3038f..bd88a8534 100644 --- a/src/components/schemas/statements.yaml +++ b/src/components/schemas/statements.yaml @@ -1374,3 +1374,20 @@ statement_archived_cards_in: $ref: '#/card_mapping_in' required: - card_mapping + + +statement_archived_cards_ignore_in: + allOf: + - $ref: '#/statement_archived_cards_in' + - type: object + properties: + archived_card_ids: + type: array + items: + type: string + description: | + List of archived card ids to be ignored in the statement. + example: + - bawownwrng + required: + - archived_card_ids \ No newline at end of file From fd88094cdef640d0254f1e1e006a9007e4ae11da Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Mon, 13 Jul 2026 13:17:55 +0530 Subject: [PATCH 043/107] fix: Update operationId of ignore archived cards api to be unique (#809) * fix: Update operationId of ignore archived cards api to be unique * Auto generate API docs --- reference/admin.yaml | 2 +- src/admin/paths/admin@statements@archived_cards@ignore.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 4c560b4cf..91be9569f 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -11668,7 +11668,7 @@ paths: summary: Ignore archived cards present in the statement description: | Ignores archived cards present in the statement - operationId: archived_cards + operationId: ignore_archived_cards requestBody: required: true content: diff --git a/src/admin/paths/admin@statements@archived_cards@ignore.yaml b/src/admin/paths/admin@statements@archived_cards@ignore.yaml index 2c5545caf..e3a06ac61 100644 --- a/src/admin/paths/admin@statements@archived_cards@ignore.yaml +++ b/src/admin/paths/admin@statements@archived_cards@ignore.yaml @@ -4,7 +4,7 @@ post: summary: Ignore archived cards present in the statement description: | Ignores archived cards present in the statement - operationId: archived_cards + operationId: ignore_archived_cards requestBody: required: true content: From f68b537ce28ee109a5c538c87844a547ec25cbd4 Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Wed, 15 Jul 2026 11:26:14 +0530 Subject: [PATCH 044/107] feat: Add corporate card archive suggestions list api spec (#810) * feat: Add corporate card archive suggestions list api spec * Auto generate API docs --- reference/admin.yaml | 122 ++++++++++++++++++ src/admin/openapi.yaml | 2 + ...n@corporate_cards@archive_suggestions.yaml | 42 ++++++ src/components/schemas/corporate_card.yaml | 79 ++++++++++++ 4 files changed, 245 insertions(+) create mode 100644 src/admin/paths/admin@corporate_cards@archive_suggestions.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 91be9569f..96ce52620 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -7851,6 +7851,49 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/corporate_cards/archive_suggestions: + get: + tags: + - Corporate Cards + summary: List corporate card archive suggestions + description: | + This API supports very rich filtering on all response fields and pagination via query parameters. To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + operationId: corporate_card_archive_suggestions_list + parameters: + - $ref: '#/components/parameters/q' + - $ref: '#/components/parameters/created_at' + - $ref: '#/components/parameters/updated_at' + - $ref: '#/components/parameters/order' + - $ref: '#/components/parameters/offset' + - $ref: '#/components/parameters/limit' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + $ref: '#/components/schemas/count' + offset: + $ref: '#/components/schemas/offset' + data: + type: array + items: + $ref: '#/components/schemas/corporate_card_archive_suggestion_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' /admin/corporate_card_transactions: get: tags: @@ -24085,6 +24128,85 @@ components: The ID of the duplicate suggestion to be dismissed required: - id + corporate_card_archive_suggestion_out: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + org_id: + $ref: '#/components/schemas/org_id' + user_id: + type: string + maxLength: 255 + nullable: true + description: | + The unique id of an user to whom the card is assigned + example: uswjwgnwwgo + user: + $ref: '#/components/schemas/user_out_embed_nullable' + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' + corporate_card_id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng + card_number: + type: string + description: | + Specifies the masked number of the card. + example: xxxx-4543 + bank_name: + type: string + description: | + Specifies the name of bank who issued the card. + example: Bank of America + nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: Business Card + data_feed_source: + type: string + nullable: true + description: | + signifies the source of how card is added and how further card transactions could be synced + example: BANK FEED - CDF + is_visa_enrolled: + type: boolean + description: | + If the card is enrolled with real time feed from visa + nullable: false + is_mastercard_enrolled: + type: boolean + description: | + If the card is enrolled with realtime feed from Mastercard + nullable: false + is_dismissed: + type: boolean + description: | + Indicates whether the archive suggestion has been dismissed by an admin + nullable: false + required: + - id + - org_id + - user_id + - user + - created_at + - updated_at + - corporate_card_id + - is_dismissed + - card_number + - bank_name + - nickname + - data_feed_source + - is_visa_enrolled + - is_mastercard_enrolled string_detail: type: string description: Additional string details of the card transaction. Can hold details upto 256 characters in length. diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 5725e2691..24b2aeeb7 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -379,6 +379,8 @@ paths: $ref: paths/admin@corporate_cards@duplicate_suggestions.yaml /admin/corporate_cards/duplicate_suggestions/dismiss: $ref: paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml + /admin/corporate_cards/archive_suggestions: + $ref: paths/admin@corporate_cards@archive_suggestions.yaml /admin/corporate_card_transactions: $ref: paths/admin@corporate_card_transactions.yaml diff --git a/src/admin/paths/admin@corporate_cards@archive_suggestions.yaml b/src/admin/paths/admin@corporate_cards@archive_suggestions.yaml new file mode 100644 index 000000000..b41cbc0f4 --- /dev/null +++ b/src/admin/paths/admin@corporate_cards@archive_suggestions.yaml @@ -0,0 +1,42 @@ +get: + tags: + - Corporate Cards + summary: List corporate card archive suggestions + description: | + This API supports very rich filtering on all response fields and pagination via query parameters. To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + operationId: corporate_card_archive_suggestions_list + parameters: + - $ref: '../../components/parameters/q.yaml' + - $ref: '../../components/parameters/created_at.yaml' + - $ref: '../../components/parameters/updated_at.yaml' + - $ref: '../../components/parameters/order.yaml' + - $ref: '../../components/parameters/offset.yaml' + - $ref: '../../components/parameters/limit.yaml' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + count: + $ref: '../../components/schemas/count.yaml' + offset: + $ref: '../../components/schemas/offset.yaml' + data: + type: array + items: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_archive_suggestion_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index 073346dc2..65bb48b5a 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -842,3 +842,82 @@ corporate_card_unarchive_in: required: - id +corporate_card_archive_suggestion_out: + type: object + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: bawownwrng + org_id: + $ref: './fields.yaml#/org_id' + user_id: + type: string + maxLength: 255 + nullable: true + description: | + The unique id of an user to whom the card is assigned + example: uswjwgnwwgo + user: + $ref: ./user.yaml#/user_out_embed_nullable + created_at: + $ref: './fields.yaml#/created_at' + updated_at: + $ref: './fields.yaml#/updated_at' + corporate_card_id: + allOf: + - $ref: './fields.yaml#/id_string' + example: bawownwrng + card_number: + type: string + description: | + Specifies the masked number of the card. + example: xxxx-4543 + bank_name: + type: string + description: | + Specifies the name of bank who issued the card. + example: Bank of America + nickname: + type: string + maxLength: 25 + nullable: true + description: | + Unique nickname assigned to the card + example: 'Business Card' + data_feed_source: + type: string + nullable: true + description: | + signifies the source of how card is added and how further card transactions could be synced + example: BANK FEED - CDF + is_visa_enrolled: + type: boolean + description: | + If the card is enrolled with real time feed from visa + nullable: false + is_mastercard_enrolled: + type: boolean + description: | + If the card is enrolled with realtime feed from Mastercard + nullable: false + is_dismissed: + type: boolean + description: | + Indicates whether the archive suggestion has been dismissed by an admin + nullable: false + required: + - id + - org_id + - user_id + - user + - created_at + - updated_at + - corporate_card_id + - is_dismissed + - card_number + - bank_name + - nickname + - data_feed_source + - is_visa_enrolled + - is_mastercard_enrolled From 758f49503f663e47b7760b80796272b903afb8d0 Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Wed, 15 Jul 2026 11:45:18 +0530 Subject: [PATCH 045/107] feat: Add corporate card archive suggestion dismiss api spec (#834) * feat: Add corporate card archive suggestion dismiss api spec * Auto generate API docs --- reference/admin.yaml | 65 +++++++++++++++++++ src/admin/openapi.yaml | 2 + ...ate_cards@archive_suggestions@dismiss.yaml | 53 +++++++++++++++ src/components/schemas/corporate_card.yaml | 13 ++++ 4 files changed, 133 insertions(+) create mode 100644 src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 96ce52620..cb73b6e1d 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -7894,6 +7894,60 @@ paths: application/json: schema: $ref: '#/components/schemas/401' + /admin/corporate_cards/archive_suggestions/dismiss: + post: + tags: + - Corporate Cards + summary: Dismiss a corporate card archive suggestion + description: | + Dismiss a corporate card archive suggestion + operationId: corporate_cards_archive_suggestion_dismiss + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/corporate_card_archive_suggestion_dismiss_in' + required: + - data + additionalProperties: false + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '#/components/schemas/corporate_card_archive_suggestion_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/corporate_card_transactions: get: tags: @@ -24207,6 +24261,17 @@ components: - data_feed_source - is_visa_enrolled - is_mastercard_enrolled + corporate_card_archive_suggestion_dismiss_in: + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: ccaswownwrng + description: | + The ID of the archive suggestion to be dismissed + required: + - id string_detail: type: string description: Additional string details of the card transaction. Can hold details upto 256 characters in length. diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 24b2aeeb7..e5edc7ff4 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -381,6 +381,8 @@ paths: $ref: paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml /admin/corporate_cards/archive_suggestions: $ref: paths/admin@corporate_cards@archive_suggestions.yaml + /admin/corporate_cards/archive_suggestions/dismiss: + $ref: paths/admin@corporate_cards@archive_suggestions@dismiss.yaml /admin/corporate_card_transactions: $ref: paths/admin@corporate_card_transactions.yaml diff --git a/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml b/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml new file mode 100644 index 000000000..e52b39b20 --- /dev/null +++ b/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml @@ -0,0 +1,53 @@ +post: + tags: + - Corporate Cards + summary: Dismiss a corporate card archive suggestion + description: | + Dismiss a corporate card archive suggestion + operationId: corporate_cards_archive_suggestion_dismiss + requestBody: + required: true + content: + application/json: + schema: + type: object + properties: + data: + $ref: ../../components/schemas/corporate_card.yaml#/corporate_card_archive_suggestion_dismiss_in + required: + - data + additionalProperties: False + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + properties: + data: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_archive_suggestion_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index 65bb48b5a..ad233810a 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -921,3 +921,16 @@ corporate_card_archive_suggestion_out: - data_feed_source - is_visa_enrolled - is_mastercard_enrolled + + +corporate_card_archive_suggestion_dismiss_in: + type: object + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: ccaswownwrng + description: | + The ID of the archive suggestion to be dismissed + required: + - id From c0863a3ee9a9c327d08c46798b2ceef9b93c0310 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 15 Jul 2026 17:26:41 +0530 Subject: [PATCH 046/107] fix: Fix required OpenAPI drift for Budgets (#812) * Fix required OpenAPI drift for Budgets * Auto generate API docs --- reference/admin.yaml | 32 ++++++++++++++++++++ reference/hod.yaml | 8 +++++ reference/hop.yaml | 8 +++++ reference/spender.yaml | 13 +++++++++ src/components/schemas/budget.yaml | 37 ++++++++++++++++++++++++ src/components/schemas/budget_usage.yaml | 8 +++++ 6 files changed, 106 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index cb73b6e1d..78472cf54 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -28174,6 +28174,30 @@ components: budget_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - alert_threshold + - is_enabled + - type + - amount_limit + - observer_ids + - project_ids + - cost_center_ids + - category_ids + - department_ids + - budget_start_date + - budget_end_date + - amount_spent + - amount_remaining + - utilisation_percentage + - budget_creator + - visibility + - status + - user_ids properties: id: $ref: '#/components/schemas/id_string' @@ -28423,6 +28447,14 @@ components: - spent - amount_limit - budget + - created_at + - updated_at + - id + - org_id + - start_date + - end_date + - budget_department_ids + - budget_project_ids additionalProperties: false properties: id: diff --git a/reference/hod.yaml b/reference/hod.yaml index 8578423e9..b05eac38c 100644 --- a/reference/hod.yaml +++ b/reference/hod.yaml @@ -174,6 +174,14 @@ components: - spent - amount_limit - budget + - created_at + - updated_at + - id + - org_id + - start_date + - end_date + - budget_department_ids + - budget_project_ids additionalProperties: false properties: id: diff --git a/reference/hop.yaml b/reference/hop.yaml index 3c64a0008..0066a116e 100644 --- a/reference/hop.yaml +++ b/reference/hop.yaml @@ -174,6 +174,14 @@ components: - spent - amount_limit - budget + - created_at + - updated_at + - id + - org_id + - start_date + - end_date + - budget_department_ids + - budget_project_ids additionalProperties: false properties: id: diff --git a/reference/spender.yaml b/reference/spender.yaml index 8da466ae6..bfba00901 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -7670,6 +7670,19 @@ components: spender_budget_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - is_enabled + - type + - amount_limit + - amount_spent + - amount_remaining + - utilisation_percentage + - status properties: id: $ref: '#/components/schemas/id_string' diff --git a/src/components/schemas/budget.yaml b/src/components/schemas/budget.yaml index 3e7bb0227..0da630aa2 100644 --- a/src/components/schemas/budget.yaml +++ b/src/components/schemas/budget.yaml @@ -80,6 +80,30 @@ budget_in: budget_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - name + - alert_threshold + - is_enabled + - type + - amount_limit + - observer_ids + - project_ids + - cost_center_ids + - category_ids + - department_ids + - budget_start_date + - budget_end_date + - amount_spent + - amount_remaining + - utilisation_percentage + - budget_creator + - visibility + - status + - user_ids properties: id: $ref: './fields.yaml#/id_string' @@ -218,6 +242,19 @@ budget_out_embed: spender_budget_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - name + - is_enabled + - type + - amount_limit + - amount_spent + - amount_remaining + - utilisation_percentage + - status properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/budget_usage.yaml b/src/components/schemas/budget_usage.yaml index 8cf5c0f92..abb343bc5 100644 --- a/src/components/schemas/budget_usage.yaml +++ b/src/components/schemas/budget_usage.yaml @@ -6,6 +6,14 @@ budget_usage_out: - spent - amount_limit - budget + - created_at + - updated_at + - id + - org_id + - start_date + - end_date + - budget_department_ids + - budget_project_ids additionalProperties: False properties: id: From 3589719e732a4699e3c1a013ad283fd2376aa9fb Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 15 Jul 2026 17:27:57 +0530 Subject: [PATCH 047/107] fix: Fix required OpenAPI drift for Categories (#814) --- reference/admin.yaml | 15 +++++++++++++++ reference/approver.yaml | 13 +++++++++++++ reference/spender.yaml | 12 ++++++++++++ src/components/schemas/category.yaml | 27 +++++++++++++++++++++++++++ 4 files changed, 67 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 78472cf54..cae3bf8b8 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -15365,6 +15365,19 @@ components: admin_approver_category_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - display_name + - code + - is_enabled + - name + - sub_category + - system_category + - restricted_project_ids + - restricted_spender_user_ids properties: id: $ref: '#/components/schemas/id_integer' @@ -15499,6 +15512,8 @@ components: system_category_out: type: object additionalProperties: false + required: + - name properties: name: type: string diff --git a/reference/approver.yaml b/reference/approver.yaml index 55d46c167..2757e64db 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -8254,6 +8254,19 @@ components: admin_approver_category_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - display_name + - code + - is_enabled + - name + - sub_category + - system_category + - restricted_project_ids + - restricted_spender_user_ids properties: id: $ref: '#/components/schemas/id_integer' diff --git a/reference/spender.yaml b/reference/spender.yaml index bfba00901..6962cde14 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -7816,6 +7816,18 @@ components: category_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - display_name + - code + - is_enabled + - name + - sub_category + - system_category + - restricted_project_ids properties: id: $ref: '#/components/schemas/id_integer' diff --git a/src/components/schemas/category.yaml b/src/components/schemas/category.yaml index 3cb48a21c..e82a28f13 100644 --- a/src/components/schemas/category.yaml +++ b/src/components/schemas/category.yaml @@ -1,6 +1,18 @@ category_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - display_name + - code + - is_enabled + - name + - sub_category + - system_category + - restricted_project_ids properties: id: $ref: './fields.yaml#/id_integer' @@ -148,6 +160,8 @@ category_in_only_id: system_category_out: type: object additionalProperties: False + required: + - name properties: name: type: string @@ -158,6 +172,19 @@ system_category_out: admin_approver_category_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - display_name + - code + - is_enabled + - name + - sub_category + - system_category + - restricted_project_ids + - restricted_spender_user_ids properties: id: $ref: './fields.yaml#/id_integer' From a4dbf9a36007e06ccdd670d701a77d70fd2d5e7c Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 15 Jul 2026 17:29:26 +0530 Subject: [PATCH 048/107] fix:Fix required OpenAPI drift for Corporate Cards Transactions (#815) --- reference/admin.yaml | 4 ++++ reference/spender.yaml | 4 ++++ src/components/schemas/corporate_card_transaction.yaml | 4 ++++ 3 files changed, 12 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index cae3bf8b8..b7379ea94 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -24762,6 +24762,10 @@ components: - last_user_matched_at - is_exported - metadata + - transaction_status + - mcc + - bank_transaction_number + - capitalone_virtual_card_last_four corporate_card_transaction_in: type: object properties: diff --git a/reference/spender.yaml b/reference/spender.yaml index 6962cde14..2292799e3 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -13352,6 +13352,10 @@ components: - last_user_matched_at - is_exported - metadata + - transaction_status + - mcc + - bank_transaction_number + - capitalone_virtual_card_last_four corporate_card_transactions_expenses_stats_in: type: object properties: diff --git a/src/components/schemas/corporate_card_transaction.yaml b/src/components/schemas/corporate_card_transaction.yaml index 207e0b00f..9146aaa5d 100644 --- a/src/components/schemas/corporate_card_transaction.yaml +++ b/src/components/schemas/corporate_card_transaction.yaml @@ -309,6 +309,10 @@ corporate_card_transaction_list_out: - last_user_matched_at - is_exported - metadata + - transaction_status + - mcc + - bank_transaction_number + - capitalone_virtual_card_last_four corporate_card_transaction_in: type: object From b3486b05ad7d32897568322d1f1016f94fa62c6c Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 15 Jul 2026 17:30:41 +0530 Subject: [PATCH 049/107] fix: Fix required OpenAPI drift for Personal Cards (#824) * Fix required OpenAPI drift for Personal Cards * Auto generate API docs --- reference/spender.yaml | 19 +++++++++++++++++++ src/components/schemas/personal_card.yaml | 17 +++++++++++++++++ .../schemas/personal_card_transaction.yaml | 2 ++ 3 files changed, 38 insertions(+) diff --git a/reference/spender.yaml b/reference/spender.yaml index 2292799e3..5760b72e6 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -18424,6 +18424,23 @@ components: personal_card_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - card_number + - bank_name + - currency + - account_type + - yodlee_account_id + - yodlee_login_id + - yodlee_last_synced_at + - yodlee_is_mfa_required + - yodlee_fastlink_params + - yodlee_is_credential_update_required + - yodlee_provider_account_id properties: id: $ref: '#/components/schemas/id_string' @@ -18660,6 +18677,8 @@ components: id: $ref: '#/components/schemas/id_string' personal_card_transactions_stats_in: + required: + - query_params properties: query_params: nullable: false diff --git a/src/components/schemas/personal_card.yaml b/src/components/schemas/personal_card.yaml index 7c0e9c65e..5319ea146 100644 --- a/src/components/schemas/personal_card.yaml +++ b/src/components/schemas/personal_card.yaml @@ -55,6 +55,23 @@ fastlink_params: personal_card_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - card_number + - bank_name + - currency + - account_type + - yodlee_account_id + - yodlee_login_id + - yodlee_last_synced_at + - yodlee_is_mfa_required + - yodlee_fastlink_params + - yodlee_is_credential_update_required + - yodlee_provider_account_id properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/personal_card_transaction.yaml b/src/components/schemas/personal_card_transaction.yaml index 4eeaa34d1..a074c296a 100644 --- a/src/components/schemas/personal_card_transaction.yaml +++ b/src/components/schemas/personal_card_transaction.yaml @@ -143,6 +143,8 @@ personal_card_transaction_expense_suggestions: additionalProperties: False personal_card_transactions_stats_in: + required: + - query_params properties: query_params: nullable: false From fc5a334dc0cab559653e8821a98c8eba1a337774 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 15 Jul 2026 17:32:05 +0530 Subject: [PATCH 050/107] fix: Fix required OpenAPI drift for Reconciliation (#827) --- reference/admin.yaml | 21 +++++++++++++++++++ .../reconciliation_eligible_cards.yaml | 4 ++++ .../schemas/reconciliation_entry.yaml | 15 +++++++++++++ .../schemas/reconciliation_transactions.yaml | 2 ++ 4 files changed, 42 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index b7379ea94..6e1afa3c0 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -32433,6 +32433,21 @@ components: reconciliation_entry_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - period_start + - period_end + - status + - reconciled_on + - reconciled_by + - bridging_entry_change_type + - statement_transaction_count + - expense_count + - statement_total + - expense_total properties: id: type: string @@ -32830,6 +32845,8 @@ components: Input to fetch reconciliation transactions stats for a specific card or filter. Pass filters using the `query_params` string similar to the GET list API. For example, filter by a single card using `corporate_card_id=eq.`. + required: + - query_params properties: query_params: type: string @@ -32898,6 +32915,8 @@ components: - expense_total - matching_issue_count - status + - created_at + - updated_at properties: created_at: $ref: '#/components/schemas/created_at' @@ -32963,6 +32982,8 @@ components: updated_at: $ref: '#/components/schemas/updated_at' reconciliation_eligible_cards_stats_in: + required: + - query_params properties: query_params: nullable: false diff --git a/src/components/schemas/reconciliation_eligible_cards.yaml b/src/components/schemas/reconciliation_eligible_cards.yaml index 0b3f8fa67..572089e49 100644 --- a/src/components/schemas/reconciliation_eligible_cards.yaml +++ b/src/components/schemas/reconciliation_eligible_cards.yaml @@ -16,6 +16,8 @@ reconciliation_eligible_card_out: - expense_total - matching_issue_count - status + - created_at + - updated_at properties: created_at: $ref: './fields.yaml#/created_at' @@ -82,6 +84,8 @@ reconciliation_eligible_card_out: $ref: './fields.yaml#/updated_at' reconciliation_eligible_cards_stats_in: + required: + - query_params properties: query_params: nullable: False diff --git a/src/components/schemas/reconciliation_entry.yaml b/src/components/schemas/reconciliation_entry.yaml index 0e4e10900..b32d0754c 100644 --- a/src/components/schemas/reconciliation_entry.yaml +++ b/src/components/schemas/reconciliation_entry.yaml @@ -1,6 +1,21 @@ reconciliation_entry_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - period_start + - period_end + - status + - reconciled_on + - reconciled_by + - bridging_entry_change_type + - statement_transaction_count + - expense_count + - statement_total + - expense_total properties: id: type: string diff --git a/src/components/schemas/reconciliation_transactions.yaml b/src/components/schemas/reconciliation_transactions.yaml index 15e651cad..218cc460e 100644 --- a/src/components/schemas/reconciliation_transactions.yaml +++ b/src/components/schemas/reconciliation_transactions.yaml @@ -289,6 +289,8 @@ reconciliation_transactions_stats_in: Input to fetch reconciliation transactions stats for a specific card or filter. Pass filters using the `query_params` string similar to the GET list API. For example, filter by a single card using `corporate_card_id=eq.`. + required: + - query_params properties: query_params: type: string From e1ac6ca08769a1cedb5155215c66d21b6063bc15 Mon Sep 17 00:00:00 2001 From: Aniruddha Shriwant Date: Wed, 15 Jul 2026 18:03:14 +0530 Subject: [PATCH 051/107] feat: add cost centers delete and delete_summary bulk API contracts (#804) --- reference/admin.yaml | 128 ++++++++++++++++++ src/admin/openapi.yaml | 4 + .../paths/admin@cost_centers@delete@bulk.yaml | 58 ++++++++ ...dmin@cost_centers@delete_summary@bulk.yaml | 41 ++++++ src/components/schemas/cost_center.yaml | 29 ++++ 5 files changed, 260 insertions(+) create mode 100644 src/admin/paths/admin@cost_centers@delete@bulk.yaml create mode 100644 src/admin/paths/admin@cost_centers@delete_summary@bulk.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 6e1afa3c0..8ef454fb4 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -513,6 +513,107 @@ paths: application/json: schema: $ref: '#/components/schemas/403' + /admin/cost_centers/delete/bulk: + post: + tags: + - Cost Centers + summary: Deletes cost centers + description: | + Deletes unused cost centers. If any of the cost center in input is used in other resources then validation error is raised. + operationId: cost_centers_delete_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/cost_center_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + nullable: true + example: | + Can not delete cost center(s) used in other resources like expense, expense policy, expense rules, budgets, dependent fields. + data: + type: object + example: null + error: + type: string + example: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + /admin/cost_centers/delete_summary/bulk: + post: + tags: + - Cost Centers + summary: Create delete summary for cost centers + description: | + Delete summary tells that how many cost centers could be deleted from given cost centers, it also + returns cost centers that could be deleted. + operationId: cost_centers_delete_summary_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/cost_center_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/cost_center_delete_summary_out' + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /admin/categories: get: tags: @@ -15362,6 +15463,33 @@ components: - _While creating cost_centers, if both `restricted_spender_user_ids` and `restricted_spender_user_group` keys are not set, restrictions defaults to `"restricted_spender_user_group": {"with_no_cost_center_restrictions": "true"}`_ - _While updating cost_centers, if both `restricted_spender_user_ids` and `restricted_spender_user_group` keys are not set, restrictions remains unchanged._ example: true + cost_center_in_only_id: + type: object + required: + - id + additionalProperties: false + properties: + id: + $ref: '#/components/schemas/id_integer' + cost_center_delete_summary_out: + type: object + additionalProperties: false + properties: + data: + type: object + properties: + delete_count: + type: integer + description: Count of cost centers that could be deleted from input cost centers. + example: 2 + cost_centers: + type: array + description: Cost centers that could be deleted. + example: + - id: 1234 + - id: 4567 + items: + $ref: '#/components/schemas/cost_center_in_only_id' admin_approver_category_out: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index e5edc7ff4..ecc56f2f5 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -155,6 +155,10 @@ paths: $ref: paths/admin@cost_centers.yaml /admin/cost_centers/bulk: $ref: paths/admin@cost_centers@bulk.yaml + /admin/cost_centers/delete/bulk: + $ref: paths/admin@cost_centers@delete@bulk.yaml + /admin/cost_centers/delete_summary/bulk: + $ref: paths/admin@cost_centers@delete_summary@bulk.yaml /admin/categories: $ref: paths/admin@categories.yaml /admin/categories/bulk: diff --git a/src/admin/paths/admin@cost_centers@delete@bulk.yaml b/src/admin/paths/admin@cost_centers@delete@bulk.yaml new file mode 100644 index 000000000..e0183b7fc --- /dev/null +++ b/src/admin/paths/admin@cost_centers@delete@bulk.yaml @@ -0,0 +1,58 @@ +post: + tags: + - Cost Centers + summary: Deletes cost centers + description: | + Deletes unused cost centers. If any of the cost center in input is used in other resources then validation error is raised. + operationId: cost_centers_delete_bulk_post + requestBody: + required: True + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: '../../components/schemas/cost_center.yaml#/cost_center_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: "../../components/schemas/401.yaml" + '403': + description: Forbidden + content: + application/json: + schema: + $ref: "../../components/schemas/403.yaml" + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + nullable: true + example: | + Can not delete cost center(s) used in other resources like expense, expense policy, expense rules, budgets, dependent fields. + data: + type: object + example: null + error: + type: string + example: InvalidUsage diff --git a/src/admin/paths/admin@cost_centers@delete_summary@bulk.yaml b/src/admin/paths/admin@cost_centers@delete_summary@bulk.yaml new file mode 100644 index 000000000..873c93adb --- /dev/null +++ b/src/admin/paths/admin@cost_centers@delete_summary@bulk.yaml @@ -0,0 +1,41 @@ +post: + tags: + - Cost Centers + summary: Create delete summary for cost centers + description: | + Delete summary tells that how many cost centers could be deleted from given cost centers, it also + returns cost centers that could be deleted. + operationId: cost_centers_delete_summary_bulk_post + requestBody: + required: True + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: '../../components/schemas/cost_center.yaml#/cost_center_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '../../components/schemas/cost_center.yaml#/cost_center_delete_summary_out' + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: "../../components/schemas/401.yaml" + '403': + description: Forbidden + content: + application/json: + schema: + $ref: "../../components/schemas/403.yaml" diff --git a/src/components/schemas/cost_center.yaml b/src/components/schemas/cost_center.yaml index b02a31c5a..353e8bc66 100644 --- a/src/components/schemas/cost_center.yaml +++ b/src/components/schemas/cost_center.yaml @@ -148,3 +148,32 @@ approver_cost_center_out: $ref: ./fields.yaml#/updated_at restricted_spender_user_ids: $ref: ./fields.yaml#/restricted_spender_user_ids + +cost_center_in_only_id: + type: object + required: + - id + additionalProperties: False + properties: + id: + $ref: './fields.yaml#/id_integer' + +cost_center_delete_summary_out: + type: object + additionalProperties: False + properties: + data: + type: object + properties: + delete_count: + type: integer + description: Count of cost centers that could be deleted from input cost centers. + example: 2 + cost_centers: + type: array + description: Cost centers that could be deleted. + example: + - id: 1234 + - id: 4567 + items: + $ref: './cost_center.yaml#/cost_center_in_only_id' From 72d257d4dca4845d602c0f88abe0b840c698372e Mon Sep 17 00:00:00 2001 From: Aniruddha Shriwant Date: Wed, 15 Jul 2026 18:49:59 +0530 Subject: [PATCH 052/107] feat: add per diem rates delete bulk API contracts (#808) --- reference/admin.yaml | 128 ++++++++++++++++++ src/admin/openapi.yaml | 4 + .../admin@per_diem_rates@delete@bulk.yaml | 58 ++++++++ ...in@per_diem_rates@delete_summary@bulk.yaml | 41 ++++++ src/components/schemas/per_diem_rate.yaml | 31 +++++ 5 files changed, 262 insertions(+) create mode 100644 src/admin/paths/admin@per_diem_rates@delete@bulk.yaml create mode 100644 src/admin/paths/admin@per_diem_rates@delete_summary@bulk.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 8ef454fb4..7719eb5f5 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -1574,6 +1574,107 @@ paths: application/json: schema: $ref: '#/components/schemas/403' + /admin/per_diem_rates/delete/bulk: + post: + tags: + - Per Diem Rates + summary: Deletes per diem rates + description: | + Deletes unused per diem rates. If any of the per diem rate in input is used in other resources then validation error is raised. + operationId: per_diem_rates_delete_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/per_diem_rate_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + nullable: true + example: | + Can not delete per diem rate(s) used in other resources like expense. + data: + type: object + example: null + error: + type: string + example: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + /admin/per_diem_rates/delete_summary/bulk: + post: + tags: + - Per Diem Rates + summary: Create delete summary for per diem rates + description: | + Delete summary tells that how many per diem rates could be deleted from given per diem rates, it also + returns per diem rates that could be deleted. + operationId: per_diem_rates_delete_summary_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/per_diem_rate_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/per_diem_rate_delete_summary_out' + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /admin/departments: get: tags: @@ -16187,6 +16288,33 @@ components: type: number example: 10 description: Amount per night + per_diem_rate_in_only_id: + type: object + required: + - id + additionalProperties: false + properties: + id: + $ref: '#/components/schemas/id_integer' + per_diem_rate_delete_summary_out: + type: object + additionalProperties: false + properties: + data: + type: object + properties: + delete_count: + type: integer + description: Count of per diem rates that could be deleted from input per diem rates. + example: 2 + per_diem_rates: + type: array + description: Per diem rates that could be deleted. + example: + - id: 1234 + - id: 4567 + items: + $ref: '#/components/schemas/per_diem_rate_in_only_id' department_head_user_ids: type: array nullable: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index ecc56f2f5..578720bb0 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -187,6 +187,10 @@ paths: $ref: paths/admin@per_diem_rates.yaml /admin/per_diem_rates/bulk: $ref: paths/admin@per_diem_rates@bulk.yaml + /admin/per_diem_rates/delete/bulk: + $ref: paths/admin@per_diem_rates@delete@bulk.yaml + /admin/per_diem_rates/delete_summary/bulk: + $ref: paths/admin@per_diem_rates@delete_summary@bulk.yaml /admin/departments: $ref: paths/admin@departments.yaml /admin/mileage_rates: diff --git a/src/admin/paths/admin@per_diem_rates@delete@bulk.yaml b/src/admin/paths/admin@per_diem_rates@delete@bulk.yaml new file mode 100644 index 000000000..8d4984072 --- /dev/null +++ b/src/admin/paths/admin@per_diem_rates@delete@bulk.yaml @@ -0,0 +1,58 @@ +post: + tags: + - Per Diem Rates + summary: Deletes per diem rates + description: | + Deletes unused per diem rates. If any of the per diem rate in input is used in other resources then validation error is raised. + operationId: per_diem_rates_delete_bulk_post + requestBody: + required: True + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: '../../components/schemas/per_diem_rate.yaml#/per_diem_rate_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: "../../components/schemas/401.yaml" + '403': + description: Forbidden + content: + application/json: + schema: + $ref: "../../components/schemas/403.yaml" + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + nullable: true + example: | + Can not delete per diem rate(s) used in other resources like expense. + data: + type: object + example: null + error: + type: string + example: InvalidUsage diff --git a/src/admin/paths/admin@per_diem_rates@delete_summary@bulk.yaml b/src/admin/paths/admin@per_diem_rates@delete_summary@bulk.yaml new file mode 100644 index 000000000..b0b8db765 --- /dev/null +++ b/src/admin/paths/admin@per_diem_rates@delete_summary@bulk.yaml @@ -0,0 +1,41 @@ +post: + tags: + - Per Diem Rates + summary: Create delete summary for per diem rates + description: | + Delete summary tells that how many per diem rates could be deleted from given per diem rates, it also + returns per diem rates that could be deleted. + operationId: per_diem_rates_delete_summary_bulk_post + requestBody: + required: True + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: '../../components/schemas/per_diem_rate.yaml#/per_diem_rate_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '../../components/schemas/per_diem_rate.yaml#/per_diem_rate_delete_summary_out' + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: "../../components/schemas/401.yaml" + '403': + description: Forbidden + content: + application/json: + schema: + $ref: "../../components/schemas/403.yaml" diff --git a/src/components/schemas/per_diem_rate.yaml b/src/components/schemas/per_diem_rate.yaml index 7cd67f415..3916d0bf5 100644 --- a/src/components/schemas/per_diem_rate.yaml +++ b/src/components/schemas/per_diem_rate.yaml @@ -72,3 +72,34 @@ per_diem_rate_in: type: number example: 10.0 description: Amount per night + + +per_diem_rate_in_only_id: + type: object + required: + - id + additionalProperties: False + properties: + id: + $ref: './fields.yaml#/id_integer' + + +per_diem_rate_delete_summary_out: + type: object + additionalProperties: False + properties: + data: + type: object + properties: + delete_count: + type: integer + description: Count of per diem rates that could be deleted from input per diem rates. + example: 2 + per_diem_rates: + type: array + description: Per diem rates that could be deleted. + example: + - id: 1234 + - id: 4567 + items: + $ref: './per_diem_rate.yaml#/per_diem_rate_in_only_id' From 7ab874b9822776103715eba3f17ee8cadecce041 Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Thu, 16 Jul 2026 10:20:34 +0530 Subject: [PATCH 053/107] fix: remove dept display_name where api does not return it (#789) * fix apis where spec showed department display_name and actual api does not return display_name - treating actual api as soruce of truth * Auto generate API docs --- reference/admin.yaml | 35 ++++-- reference/approver.yaml | 35 ++++-- reference/manager.yaml | 31 +++-- reference/spender.yaml | 107 +++++++++++++++++- src/components/schemas/department.yaml | 20 ++++ src/components/schemas/employee.yaml | 87 +++++++++++++- src/components/schemas/expense.yaml | 9 ++ ..._card_transactions@expense_suggestion.yaml | 2 +- 8 files changed, 292 insertions(+), 34 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 7719eb5f5..c42ad0928 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -16566,7 +16566,7 @@ components: description: | This id is provided by Sage Exp Mgmt to identify an object. example: sdfd2391 - department_out_embed: + department_out_employee_embed: type: object additionalProperties: false nullable: true @@ -16583,11 +16583,6 @@ components: type: string nullable: true example: Outbound Sales - display_name: - type: string - example: Sales / Outbound Sales - description: | - This is a combination of name and sub_department separated by a / and spaces. In case if no sub_department is present it is same as name of the department. null_field: type: string nullable: true @@ -17011,7 +17006,7 @@ components: department_id: $ref: '#/components/schemas/fk_string' department: - $ref: '#/components/schemas/department_out_embed' + $ref: '#/components/schemas/department_out_employee_embed' is_enabled: allOf: - $ref: '#/components/schemas/is_enabled' @@ -18799,6 +18794,28 @@ components: maxLength: 255 nullable: true example: dept9in4oIHpdR + department_out_embed: + type: object + additionalProperties: false + nullable: true + properties: + id: + $ref: '#/components/schemas/id_string' + code: + $ref: '#/components/schemas/code' + name: + allOf: + - $ref: '#/components/schemas/name' + example: Sales + sub_department: + type: string + nullable: true + example: Outbound Sales + display_name: + type: string + example: Sales / Outbound Sales + description: | + This is a combination of name and sub_department separated by a / and spaces. In case if no sub_department is present it is same as name of the department. employee_out_embed_for_expense: type: object additionalProperties: false @@ -21320,7 +21337,7 @@ components: $ref: '#/components/schemas/department_id' department: nullable: true - $ref: '#/components/schemas/department_out_embed' + $ref: '#/components/schemas/department_out_employee_embed' user_id_nullable: type: string description: | @@ -22341,7 +22358,7 @@ components: $ref: '#/components/schemas/department_id' department: nullable: true - $ref: '#/components/schemas/department_out_embed' + $ref: '#/components/schemas/department_out_employee_embed' level: $ref: '#/components/schemas/level_out_embed' ach_account: diff --git a/reference/approver.yaml b/reference/approver.yaml index 2757e64db..42a5a5d33 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -4368,7 +4368,7 @@ components: description: | This represents the name of the resource. This should be unique in an organization example: foo123 - department_out_embed: + department_out_employee_embed: type: object additionalProperties: false nullable: true @@ -4385,11 +4385,6 @@ components: type: string nullable: true example: Outbound Sales - display_name: - type: string - example: Sales / Outbound Sales - description: | - This is a combination of name and sub_department separated by a / and spaces. In case if no sub_department is present it is same as name of the department. level_out_embed: type: object additionalProperties: false @@ -4472,7 +4467,7 @@ components: $ref: '#/components/schemas/department_id' department: nullable: true - $ref: '#/components/schemas/department_out_embed' + $ref: '#/components/schemas/department_out_employee_embed' level: $ref: '#/components/schemas/level_out_embed' ach_account: @@ -5589,6 +5584,28 @@ components: example: usge49ielgel verifier_user: $ref: '#/components/schemas/user_out_embed' + department_out_embed: + type: object + additionalProperties: false + nullable: true + properties: + id: + $ref: '#/components/schemas/id_string' + code: + $ref: '#/components/schemas/code' + name: + allOf: + - $ref: '#/components/schemas/name' + example: Sales + sub_department: + type: string + nullable: true + example: Outbound Sales + display_name: + type: string + example: Sales / Outbound Sales + description: | + This is a combination of name and sub_department separated by a / and spaces. In case if no sub_department is present it is same as name of the department. custom_field: type: object description: | @@ -7869,7 +7886,7 @@ components: $ref: '#/components/schemas/department_id' department: nullable: true - $ref: '#/components/schemas/department_out_embed' + $ref: '#/components/schemas/department_out_employee_embed' user_id_nullable: type: string description: | @@ -10134,7 +10151,7 @@ components: department_id: $ref: '#/components/schemas/fk_string' department: - $ref: '#/components/schemas/department_out_embed' + $ref: '#/components/schemas/department_out_employee_embed' is_enabled: allOf: - $ref: '#/components/schemas/is_enabled' diff --git a/reference/manager.yaml b/reference/manager.yaml index 8473ae648..aed929268 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -1276,7 +1276,7 @@ components: description: | This represents the name of the resource. This should be unique in an organization example: foo123 - department_out_embed: + department_out_employee_embed: type: object additionalProperties: false nullable: true @@ -1293,11 +1293,6 @@ components: type: string nullable: true example: Outbound Sales - display_name: - type: string - example: Sales / Outbound Sales - description: | - This is a combination of name and sub_department separated by a / and spaces. In case if no sub_department is present it is same as name of the department. timestamptz_utc: type: string format: date-time @@ -1712,7 +1707,7 @@ components: department_id: $ref: '#/components/schemas/fk_string' department: - $ref: '#/components/schemas/department_out_embed' + $ref: '#/components/schemas/department_out_employee_embed' is_enabled: allOf: - $ref: '#/components/schemas/is_enabled' @@ -2235,6 +2230,28 @@ components: maxLength: 255 nullable: true example: dept9in4oIHpdR + department_out_embed: + type: object + additionalProperties: false + nullable: true + properties: + id: + $ref: '#/components/schemas/id_string' + code: + $ref: '#/components/schemas/code' + name: + allOf: + - $ref: '#/components/schemas/name' + example: Sales + sub_department: + type: string + nullable: true + example: Outbound Sales + display_name: + type: string + example: Sales / Outbound Sales + description: | + This is a combination of name and sub_department separated by a / and spaces. In case if no sub_department is present it is same as name of the department. employee_out_embed_for_expense: type: object additionalProperties: false diff --git a/reference/spender.yaml b/reference/spender.yaml index 5760b72e6..26852dbd3 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -5950,7 +5950,7 @@ paths: data: type: array items: - $ref: '#/components/schemas/expense_out' + $ref: '#/components/schemas/expense_out_with_department_name' '400': description: Bad request content: @@ -10756,6 +10756,23 @@ components: $ref: '#/components/schemas/is_enabled' webhook_url: $ref: '#/components/schemas/webhook_url' + department_out_employee_embed: + type: object + additionalProperties: false + nullable: true + properties: + id: + $ref: '#/components/schemas/id_string' + code: + $ref: '#/components/schemas/code' + name: + allOf: + - $ref: '#/components/schemas/name' + example: Sales + sub_department: + type: string + nullable: true + example: Outbound Sales employee_out_embed_for_report: type: object additionalProperties: false @@ -10783,7 +10800,7 @@ components: $ref: '#/components/schemas/department_id' department: nullable: true - $ref: '#/components/schemas/department_out_embed' + $ref: '#/components/schemas/department_out_employee_embed' level: $ref: '#/components/schemas/level_out_embed' ach_account: @@ -12140,7 +12157,7 @@ components: $ref: '#/components/schemas/department_id' department: nullable: true - $ref: '#/components/schemas/department_out_embed' + $ref: '#/components/schemas/department_out_employee_embed' user_id_nullable: type: string description: | @@ -15039,7 +15056,7 @@ components: department_id: $ref: '#/components/schemas/fk_string' department: - $ref: '#/components/schemas/department_out_embed' + $ref: '#/components/schemas/department_out_employee_embed' level_id: $ref: '#/components/schemas/fk_string' level: @@ -18676,6 +18693,88 @@ components: properties: id: $ref: '#/components/schemas/id_string' + employee_out_embed_for_expense_with_department_name: + type: object + additionalProperties: false + nullable: true + properties: + id: + $ref: '#/components/schemas/id_string' + user_id: + $ref: '#/components/schemas/user_id' + user: + $ref: '#/components/schemas/user_out_embed' + code: + type: string + maxLength: 255 + nullable: true + example: E84122 + description: | + This field refers to any string that the client programs can use to refer to an employee's unique id. + This could be any field such as an UUID from an Active Directory server or employee id in a HRMS system. + org_id: + $ref: '#/components/schemas/org_id' + org_name: + $ref: '#/components/schemas/org_name' + department_id: + nullable: true + $ref: '#/components/schemas/department_id' + department: + nullable: true + $ref: '#/components/schemas/department_out_embed' + level: + $ref: '#/components/schemas/level_out_embed' + location: + type: string + maxLength: 255 + nullable: true + example: Bangalore Ofc + title: + type: string + maxLength: 255 + nullable: true + example: Branch Manager + business_unit: + type: string + maxLength: 255 + nullable: true + example: Finance ops + custom_fields: + type: array + nullable: true + description: | + Custom fields + items: + $ref: '#/components/schemas/custom_field' + flattened_custom_field: + $ref: '#/components/schemas/flattened_custom_field' + has_accepted_invite: + $ref: '#/components/schemas/has_accepted_invite' + is_enabled: + allOf: + - $ref: '#/components/schemas/is_enabled' + description: | + This field indicates whether the employee is enabled in the org. + mobile: + type: string + nullable: true + example: '+12131234567' + items: + $ref: '#/components/schemas/phone_number' + description: | + Mobile number of the employee + joined_at: + $ref: '#/components/schemas/joined_at' + description: | + NOTE: The data of this field is not realtime. It will get updated later even if `employee_id` is already up-to-date. + expense_out_with_department_name: + allOf: + - $ref: '#/components/schemas/expense_out' + - type: object + properties: + employee: + nullable: true + $ref: '#/components/schemas/employee_out_embed_for_expense_with_department_name' personal_card_transactions_stats_in: required: - query_params diff --git a/src/components/schemas/department.yaml b/src/components/schemas/department.yaml index 073f289f5..07914aec0 100644 --- a/src/components/schemas/department.yaml +++ b/src/components/schemas/department.yaml @@ -73,6 +73,26 @@ department_out_embed: spaces. In case if no sub_department is present it is same as name of the department. + +department_out_employee_embed: + type: object + additionalProperties: False + nullable: true + properties: + id: + $ref: './fields.yaml#/id_string' + code: + $ref: ./fields.yaml#/code + name: + allOf: + - $ref: ./fields.yaml#/name + example: Sales + sub_department: + type: string + nullable: true + example: Outbound Sales + + department_in: type: object required: diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index b80725aed..55fa9ba0c 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -33,7 +33,7 @@ employee_out: department_id: $ref: './fields.yaml#/fk_string' department: - $ref: './department.yaml#/department_out_embed' + $ref: './department.yaml#/department_out_employee_embed' is_enabled: allOf: - $ref: ./fields.yaml#/is_enabled @@ -257,7 +257,7 @@ employee_out_embed: $ref: './fields.yaml#/department_id' department: nullable: True - $ref: './department.yaml#/department_out_embed' + $ref: './department.yaml#/department_out_employee_embed' # level: # $ref: './level.yaml#/level_out_embed' # location: @@ -374,9 +374,10 @@ employee_out_embed_for_expense: NOTE: The data of this field is not realtime. It will get updated later even if `employee_id` is already up-to-date. -employee_out_embed_for_report: +employee_out_embed_for_expense_with_department_name: type: object additionalProperties: False + nullable: True properties: id: $ref: ./fields.yaml#/id_string @@ -407,6 +408,84 @@ employee_out_embed_for_report: $ref: './department.yaml#/department_out_embed' level: $ref: './level.yaml#/level_out_embed' + location: + type: string + maxLength: 255 + nullable: True + example: Bangalore Ofc + title: + type: string + maxLength: 255 + nullable: True + example: Branch Manager + business_unit: + type: string + maxLength: 255 + nullable: true + example: Finance ops + custom_fields: + type: array + nullable: true + description: | + Custom fields + items: + $ref: './fields.yaml#/custom_field' + flattened_custom_field: + $ref: './fields.yaml#/flattened_custom_field' + has_accepted_invite: + $ref: ./fields.yaml#/has_accepted_invite + is_enabled: + allOf: + - $ref: ./fields.yaml#/is_enabled + description: | + This field indicates whether the employee is enabled in the org. + mobile: + type: string + nullable: True + example: '+12131234567' + items: + $ref: './fields.yaml#/phone_number' + description: | + Mobile number of the employee + joined_at: + $ref: ./fields.yaml#/joined_at + description: | + NOTE: The data of this field is not realtime. It will get updated later even if `employee_id` is already up-to-date. + + +employee_out_embed_for_report: + type: object + additionalProperties: False + properties: + id: + $ref: ./fields.yaml#/id_string + user_id: + $ref: './fields.yaml#/user_id' + user: + $ref: ./user.yaml#/user_out_embed + code: + type: string + maxLength: 255 + nullable: True + example: E84122 + description: > + This field refers to any string that the client programs can use to refer + to an employee's unique id. + + This could be any field such as an UUID from an Active Directory server or + employee id in a HRMS system. + org_id: + $ref: ./fields.yaml#/org_id + org_name: + $ref: ./fields.yaml#/org_name + department_id: + nullable: True + $ref: './fields.yaml#/department_id' + department: + nullable: True + $ref: './department.yaml#/department_out_employee_embed' + level: + $ref: './level.yaml#/level_out_embed' ach_account: additionalProperties: False type: object @@ -1107,7 +1186,7 @@ spender_employee_current_out: department_id: $ref: './fields.yaml#/fk_string' department: - $ref: './department.yaml#/department_out_embed' + $ref: './department.yaml#/department_out_employee_embed' level_id: $ref: './fields.yaml#/fk_string' level: diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 88e9c4a81..222cd7899 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -1461,6 +1461,15 @@ approver_expense_in: Specific to per diem related expenses, number of days for which per diem claim is made.
This field is required for creating Per Diem Expenses. +expense_out_with_department_name: + allOf: + - $ref: '#/expense_out' + - type: object + properties: + employee: + nullable: true + $ref: './employee.yaml#/employee_out_embed_for_expense_with_department_name' + expense_out_embed: type: object required: diff --git a/src/spender/paths/spender@personal_card_transactions@expense_suggestion.yaml b/src/spender/paths/spender@personal_card_transactions@expense_suggestion.yaml index 4f80a06aa..e8b1886b4 100644 --- a/src/spender/paths/spender@personal_card_transactions@expense_suggestion.yaml +++ b/src/spender/paths/spender@personal_card_transactions@expense_suggestion.yaml @@ -33,7 +33,7 @@ get: data: type: array items: - $ref: ../../components/schemas/expense.yaml#/expense_out + $ref: ../../components/schemas/expense.yaml#/expense_out_with_department_name '400': description: Bad request content: From a21e0feed327ffb5ac74e9ad84172eb325eb163c Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Thu, 16 Jul 2026 12:09:14 +0530 Subject: [PATCH 054/107] fix: create new schema for budget POST API response (#840) * fix: create new schema for budget POST API response * Auto generate API docs --- reference/admin.yaml | 88 +++++++++++++++++++++++++++++- src/admin/paths/admin@budgets.yaml | 2 +- src/components/schemas/budget.yaml | 79 +++++++++++++++++++++++++++ 3 files changed, 167 insertions(+), 2 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index c42ad0928..3e1599575 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -10562,7 +10562,7 @@ paths: additionalProperties: false properties: data: - $ref: '#/components/schemas/budget_out' + $ref: '#/components/schemas/budget_post_out' '400': description: Bad request content: @@ -28713,6 +28713,92 @@ components: $ref: '#/components/schemas/budget_visibility' user_ids: $ref: '#/components/schemas/budget_user_ids' + budget_post_out: + type: object + additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - alert_threshold + - is_enabled + - type + - amount_limit + - observer_ids + - project_ids + - cost_center_ids + - category_ids + - department_ids + - visibility + properties: + id: + $ref: '#/components/schemas/id_string' + org_id: + $ref: '#/components/schemas/org_id' + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' + is_enabled: + $ref: '#/components/schemas/is_enabled' + name: + allOf: + - $ref: '#/components/schemas/name' + example: Sales + type: + $ref: '#/components/schemas/budget_type' + amount_limit: + $ref: '#/components/schemas/amount' + alert_threshold: + nullable: true + type: number + example: 5000 + department_ids: + type: array + items: + $ref: '#/components/schemas/id_string' + example: + - 2222 + - 1221 + description: | + List of department ids + project_ids: + type: array + items: + $ref: '#/components/schemas/id_integer' + example: + - 2222 + - 1221 + description: | + List of project ids + cost_center_ids: + type: array + items: + $ref: '#/components/schemas/id_integer' + example: + - 2222 + - 1221 + description: | + List of cost center ids + category_ids: + type: array + items: + $ref: '#/components/schemas/id_integer' + example: + - 2222 + - 1221 + description: | + List of category ids + observer_ids: + type: array + items: + $ref: '#/components/schemas/id_string' + example: + - usge49ielgel + visibility: + $ref: '#/components/schemas/budget_visibility' budget_out_embed: type: object additionalProperties: false diff --git a/src/admin/paths/admin@budgets.yaml b/src/admin/paths/admin@budgets.yaml index 901f56121..269866fd7 100644 --- a/src/admin/paths/admin@budgets.yaml +++ b/src/admin/paths/admin@budgets.yaml @@ -27,7 +27,7 @@ post: additionalProperties: False properties: data: - $ref: ../../components/schemas/budget.yaml#/budget_out + $ref: ../../components/schemas/budget.yaml#/budget_post_out '400': description: Bad request content: diff --git a/src/components/schemas/budget.yaml b/src/components/schemas/budget.yaml index 0da630aa2..71199ca3d 100644 --- a/src/components/schemas/budget.yaml +++ b/src/components/schemas/budget.yaml @@ -77,6 +77,85 @@ budget_in: $ref: ./fields.yaml#/budget_user_ids +budget_post_out: + type: object + additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - name + - alert_threshold + - is_enabled + - type + - amount_limit + - observer_ids + - project_ids + - cost_center_ids + - category_ids + - department_ids + - visibility + properties: + id: + $ref: './fields.yaml#/id_string' + org_id: + $ref: ./fields.yaml#/org_id + created_at: + $ref: ./fields.yaml#/created_at + updated_at: + $ref: ./fields.yaml#/updated_at + is_enabled: + $ref: ./fields.yaml#/is_enabled + name: + allOf: + - $ref: ./fields.yaml#/name + example: Sales + type: + $ref: ./fields.yaml#/budget_type + amount_limit: + $ref: './fields.yaml#/amount' + alert_threshold: + nullable: true + type: number + example: 5000 + department_ids: + type: array + items: + $ref: './fields.yaml#/id_string' + example: [2222, 1221] + description: | + List of department ids + project_ids: + type: array + items: + $ref: './fields.yaml#/id_integer' + example: [2222, 1221] + description: | + List of project ids + cost_center_ids: + type: array + items: + $ref: './fields.yaml#/id_integer' + example: [2222, 1221] + description: | + List of cost center ids + category_ids: + type: array + items: + $ref: './fields.yaml#/id_integer' + example: [2222, 1221] + description: | + List of category ids + observer_ids: + type: array + items: + $ref: './fields.yaml#/id_string' + example: + - usge49ielgel + visibility: + $ref: ./fields.yaml#/budget_visibility + budget_out: type: object additionalProperties: False From 5427936199bcbade90d4fc868a2396ce7dd4a97b Mon Sep 17 00:00:00 2001 From: Krupa Hebbar Date: Thu, 16 Jul 2026 15:29:42 +0530 Subject: [PATCH 055/107] fix: employee embed used in reports apis (#841) * fix employee embed used in reports apis * Auto generate API docs --- reference/admin.yaml | 2 +- reference/approver.yaml | 48 ++++++++++++++-------------- reference/spender.yaml | 36 ++++++++++----------- src/components/schemas/employee.yaml | 2 +- 4 files changed, 44 insertions(+), 44 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 3e1599575..b792b7bfd 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -22358,7 +22358,7 @@ components: $ref: '#/components/schemas/department_id' department: nullable: true - $ref: '#/components/schemas/department_out_employee_embed' + $ref: '#/components/schemas/department_out_embed' level: $ref: '#/components/schemas/level_out_embed' ach_account: diff --git a/reference/approver.yaml b/reference/approver.yaml index 42a5a5d33..02c10c2f6 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -4368,7 +4368,7 @@ components: description: | This represents the name of the resource. This should be unique in an organization example: foo123 - department_out_employee_embed: + department_out_embed: type: object additionalProperties: false nullable: true @@ -4385,6 +4385,11 @@ components: type: string nullable: true example: Outbound Sales + display_name: + type: string + example: Sales / Outbound Sales + description: | + This is a combination of name and sub_department separated by a / and spaces. In case if no sub_department is present it is same as name of the department. level_out_embed: type: object additionalProperties: false @@ -4467,7 +4472,7 @@ components: $ref: '#/components/schemas/department_id' department: nullable: true - $ref: '#/components/schemas/department_out_employee_embed' + $ref: '#/components/schemas/department_out_embed' level: $ref: '#/components/schemas/level_out_embed' ach_account: @@ -5584,28 +5589,6 @@ components: example: usge49ielgel verifier_user: $ref: '#/components/schemas/user_out_embed' - department_out_embed: - type: object - additionalProperties: false - nullable: true - properties: - id: - $ref: '#/components/schemas/id_string' - code: - $ref: '#/components/schemas/code' - name: - allOf: - - $ref: '#/components/schemas/name' - example: Sales - sub_department: - type: string - nullable: true - example: Outbound Sales - display_name: - type: string - example: Sales / Outbound Sales - description: | - This is a combination of name and sub_department separated by a / and spaces. In case if no sub_department is present it is same as name of the department. custom_field: type: object description: | @@ -7861,6 +7844,23 @@ components: - APPROVAL_REJECTED description: | State of this advance request approval + department_out_employee_embed: + type: object + additionalProperties: false + nullable: true + properties: + id: + $ref: '#/components/schemas/id_string' + code: + $ref: '#/components/schemas/code' + name: + allOf: + - $ref: '#/components/schemas/name' + example: Sales + sub_department: + type: string + nullable: true + example: Outbound Sales employee_out_embed: type: object additionalProperties: false diff --git a/reference/spender.yaml b/reference/spender.yaml index 26852dbd3..cea155e3b 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -10756,23 +10756,6 @@ components: $ref: '#/components/schemas/is_enabled' webhook_url: $ref: '#/components/schemas/webhook_url' - department_out_employee_embed: - type: object - additionalProperties: false - nullable: true - properties: - id: - $ref: '#/components/schemas/id_string' - code: - $ref: '#/components/schemas/code' - name: - allOf: - - $ref: '#/components/schemas/name' - example: Sales - sub_department: - type: string - nullable: true - example: Outbound Sales employee_out_embed_for_report: type: object additionalProperties: false @@ -10800,7 +10783,7 @@ components: $ref: '#/components/schemas/department_id' department: nullable: true - $ref: '#/components/schemas/department_out_employee_embed' + $ref: '#/components/schemas/department_out_embed' level: $ref: '#/components/schemas/level_out_embed' ach_account: @@ -12132,6 +12115,23 @@ components: - APPROVAL_REJECTED description: | State of this advance request approval + department_out_employee_embed: + type: object + additionalProperties: false + nullable: true + properties: + id: + $ref: '#/components/schemas/id_string' + code: + $ref: '#/components/schemas/code' + name: + allOf: + - $ref: '#/components/schemas/name' + example: Sales + sub_department: + type: string + nullable: true + example: Outbound Sales employee_out_embed: type: object additionalProperties: false diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index 55fa9ba0c..8535e180c 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -483,7 +483,7 @@ employee_out_embed_for_report: $ref: './fields.yaml#/department_id' department: nullable: True - $ref: './department.yaml#/department_out_employee_embed' + $ref: './department.yaml#/department_out_embed' level: $ref: './level.yaml#/level_out_embed' ach_account: From 5352bdc9a1dffa514f5aa84e82bd0cfeffbb4190 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Thu, 16 Jul 2026 17:01:11 +0530 Subject: [PATCH 056/107] fix: Fix required OpenAPI drift for Statement Upload (#832) * Fix required OpenAPI drift for Statement Upload * Auto generate API docs --- reference/admin.yaml | 32 -------------------------- src/components/schemas/statements.yaml | 32 -------------------------- 2 files changed, 64 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index b792b7bfd..2ae42a7a9 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -30869,19 +30869,12 @@ components: example: VISA nullable: true required: - - description_column - transaction_date_column - - transaction_id_column - amount_column - card_number_column - merchant_column - - foreign_amount_column - - foreign_currency_column - - post_date_column - bank_name - is_debit_positive - - name - - card_network ignored_line_item_ids: type: array items: @@ -30893,7 +30886,6 @@ components: required: - id - statement_mapping - - ignored_line_item_ids summary_out: properties: id: @@ -31036,19 +31028,12 @@ components: example: VISA nullable: true required: - - description_column - transaction_date_column - - transaction_id_column - amount_column - card_number_column - merchant_column - - foreign_amount_column - - foreign_currency_column - - post_date_column - bank_name - is_debit_positive - - name - - card_network ignored_line_item_ids: type: array items: @@ -31079,7 +31064,6 @@ components: required: - id - statement_mapping - - ignored_line_item_ids - reconciliation_entry_ids _reconciliation_summary_object: properties: @@ -31188,19 +31172,12 @@ components: example: VISA nullable: true required: - - description_column - transaction_date_column - - transaction_id_column - amount_column - card_number_column - merchant_column - - foreign_amount_column - - foreign_currency_column - - post_date_column - bank_name - is_debit_positive - - name - - card_network ignored_line_item_ids: type: array items: @@ -31239,7 +31216,6 @@ components: required: - id - statement_mapping - - ignored_line_item_ids - reconciliation_method - reconciliation_entry_ids unassigned_cards_from_statement_in: @@ -31337,19 +31313,12 @@ components: example: VISA nullable: true required: - - description_column - transaction_date_column - - transaction_id_column - amount_column - card_number_column - merchant_column - - foreign_amount_column - - foreign_currency_column - - post_date_column - bank_name - is_debit_positive - - name - - card_network ignored_line_item_ids: type: array items: @@ -31371,7 +31340,6 @@ components: required: - id - statement_mapping - - ignored_line_item_ids card_stats_out: properties: missing_transactions_count: diff --git a/src/components/schemas/statements.yaml b/src/components/schemas/statements.yaml index bd88a8534..99426b3d6 100644 --- a/src/components/schemas/statements.yaml +++ b/src/components/schemas/statements.yaml @@ -238,19 +238,12 @@ card_transaction_from_statement_in: example: VISA nullable: true required: - - description_column - transaction_date_column - - transaction_id_column - amount_column - card_number_column - merchant_column - - foreign_amount_column - - foreign_currency_column - - post_date_column - bank_name - is_debit_positive - - name - - card_network ignored_line_item_ids: type: array items: @@ -272,7 +265,6 @@ card_transaction_from_statement_in: required: - id - statement_mapping - - ignored_line_item_ids preview_from_statement_in: type: object @@ -473,19 +465,12 @@ summary_from_statement_in: example: VISA nullable: true required: - - description_column - transaction_date_column - - transaction_id_column - amount_column - card_number_column - merchant_column - - foreign_amount_column - - foreign_currency_column - - post_date_column - bank_name - is_debit_positive - - name - - card_network ignored_line_item_ids: type: array items: @@ -497,7 +482,6 @@ summary_from_statement_in: required: - id - statement_mapping - - ignored_line_item_ids card_mapping_in: type: array @@ -729,19 +713,12 @@ reconciliation_summary_from_statement_in: example: VISA nullable: true required: - - description_column - transaction_date_column - - transaction_id_column - amount_column - card_number_column - merchant_column - - foreign_amount_column - - foreign_currency_column - - post_date_column - bank_name - is_debit_positive - - name - - card_network ignored_line_item_ids: type: array items: @@ -772,7 +749,6 @@ reconciliation_summary_from_statement_in: required: - id - statement_mapping - - ignored_line_item_ids - reconciliation_entry_ids reconcile_from_statement_in: @@ -859,19 +835,12 @@ reconcile_from_statement_in: example: VISA nullable: true required: - - description_column - transaction_date_column - - transaction_id_column - amount_column - card_number_column - merchant_column - - foreign_amount_column - - foreign_currency_column - - post_date_column - bank_name - is_debit_positive - - name - - card_network ignored_line_item_ids: type: array items: @@ -910,7 +879,6 @@ reconcile_from_statement_in: required: - id - statement_mapping - - ignored_line_item_ids - reconciliation_method - reconciliation_entry_ids From a5067fdf8016a7807b3b0e6f6572ee875e02ae4a Mon Sep 17 00:00:00 2001 From: Sumit Kumar Date: Fri, 17 Jul 2026 15:01:47 +0530 Subject: [PATCH 057/107] feat: Added changes in API documentation for supported policy_violation_reason_required field (#791) * Updated openapi docs for policy violation reason * Made updates to support mandatory policy violation reason * Auto generate API docs --- reference/admin.yaml | 22 ++++++++++++++++++++ reference/approver.yaml | 8 +++++++ reference/manager.yaml | 8 +++++++ reference/spender.yaml | 14 +++++++++++++ src/components/schemas/expense.yaml | 3 +++ src/components/schemas/expense_policies.yaml | 14 +++++++++++++ src/components/schemas/fields.yaml | 5 +++++ 7 files changed, 74 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 2ae42a7a9..cf3984b7a 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -18769,6 +18769,9 @@ components: example: epc1a2f3farmk comment_type: type: string + enum: + - LOST_RECEIPT_REASON + - POLICY_VIOLATION_REASON description: Type of the policy comment comment_text: type: string @@ -29427,6 +29430,12 @@ components: If it is set to true, then a warning is shown to the employee, whenever he attempts to create an expense that violates this policy rule. default: false example: true + policy_violation_reason_required: + type: boolean + description: | + If it is set to true, then entering a policy violation reason becomes mandatory for expenses violating this policy rule. + default: false + example: false action_make_unreportable: type: boolean description: | @@ -29543,6 +29552,7 @@ components: - employee_titles_op - action_flag - action_show_warning + - policy_violation_reason_required - action_make_unreportable - description default: true @@ -29886,6 +29896,13 @@ components: If it is set to true, then a warning is shown to the employee, whenever he attempts to create an expense that violates this policy rule. default: false example: true + policy_violation_reason_required: + type: boolean + description: | + If it is set to true, then entering a policy violation reason becomes mandatory for expenses violating this policy rule.
+ _Note: This can be true only when `action_show_warning` is true._ + default: false + example: false action_make_unreportable: type: boolean description: | @@ -29981,6 +29998,11 @@ components: description: | A true value here means that policy calculation suggests showing a warning when the user attempts to create an expense that violates this expense policy rule. example: true + policy_violation_reason_required: + type: boolean + description: | + A true value here means that entering a policy violation reason is mandatory for this policy rule. + example: false action_make_unreportable: type: boolean nullable: false diff --git a/reference/approver.yaml b/reference/approver.yaml index 02c10c2f6..840bf5615 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -5575,6 +5575,9 @@ components: example: epc1a2f3farmk comment_type: type: string + enum: + - LOST_RECEIPT_REASON + - POLICY_VIOLATION_REASON description: Type of the policy comment comment_text: type: string @@ -8672,6 +8675,11 @@ components: description: | A true value here means that policy calculation suggests showing a warning when the user attempts to create an expense that violates this expense policy rule. example: true + policy_violation_reason_required: + type: boolean + description: | + A true value here means that entering a policy violation reason is mandatory for this policy rule. + example: false action_make_unreportable: type: boolean nullable: false diff --git a/reference/manager.yaml b/reference/manager.yaml index aed929268..56b8bf0f9 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -843,6 +843,11 @@ components: description: | A true value here means that policy calculation suggests showing a warning when the user attempts to create an expense that violates this expense policy rule. example: true + policy_violation_reason_required: + type: boolean + description: | + A true value here means that entering a policy violation reason is mandatory for this policy rule. + example: false action_make_unreportable: type: boolean nullable: false @@ -2204,6 +2209,9 @@ components: example: epc1a2f3farmk comment_type: type: string + enum: + - LOST_RECEIPT_REASON + - POLICY_VIOLATION_REASON description: Type of the policy comment comment_text: type: string diff --git a/reference/spender.yaml b/reference/spender.yaml index cea155e3b..7b991d7ca 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -8744,6 +8744,9 @@ components: example: epc1a2f3farmk comment_type: type: string + enum: + - LOST_RECEIPT_REASON + - POLICY_VIOLATION_REASON description: Type of the policy comment comment_text: type: string @@ -16570,6 +16573,12 @@ components: If it is set to true, then a warning is shown to the employee, whenever he attempts to create an expense that violates this policy rule. default: false example: true + policy_violation_reason_required: + type: boolean + description: | + If it is set to true, then entering a policy violation reason becomes mandatory for expenses violating this policy rule. + default: false + example: false action_make_unreportable: type: boolean description: | @@ -16658,6 +16667,11 @@ components: description: | A true value here means that policy calculation suggests showing a warning when the user attempts to create an expense that violates this expense policy rule. example: true + policy_violation_reason_required: + type: boolean + description: | + A true value here means that entering a policy violation reason is mandatory for this policy rule. + example: false action_make_unreportable: type: boolean nullable: false diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 222cd7899..218a40257 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -2989,6 +2989,9 @@ expense_policy_comment_out_embed: example: epc1a2f3farmk comment_type: type: string + enum: + - LOST_RECEIPT_REASON + - POLICY_VIOLATION_REASON description: Type of the policy comment comment_text: type: string diff --git a/src/components/schemas/expense_policies.yaml b/src/components/schemas/expense_policies.yaml index 15b79ad9c..08a6d88a5 100644 --- a/src/components/schemas/expense_policies.yaml +++ b/src/components/schemas/expense_policies.yaml @@ -45,6 +45,7 @@ expense_policy_in: - employee_titles_op - action_flag - action_show_warning + - policy_violation_reason_required - action_make_unreportable - description default: True @@ -374,6 +375,13 @@ expense_policy_in: If it is set to true, then a warning is shown to the employee, whenever he attempts to create an expense that violates this policy rule. default: False example: True + policy_violation_reason_required: + type: boolean + description: | + If it is set to true, then entering a policy violation reason becomes mandatory for expenses violating this policy rule.
+ _Note: This can be true only when `action_show_warning` is true._ + default: False + example: False action_make_unreportable: type: boolean description: | @@ -789,6 +797,12 @@ expense_policy_out: If it is set to true, then a warning is shown to the employee, whenever he attempts to create an expense that violates this policy rule. default: False example: True + policy_violation_reason_required: + type: boolean + description: | + If it is set to true, then entering a policy violation reason becomes mandatory for expenses violating this policy rule. + default: False + example: False action_make_unreportable: type: boolean description: | diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index 8d97403fb..5d4520429 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -374,6 +374,11 @@ expense_policy_rule_embed: description: | A true value here means that policy calculation suggests showing a warning when the user attempts to create an expense that violates this expense policy rule. example: True + policy_violation_reason_required: + type: boolean + description: | + A true value here means that entering a policy violation reason is mandatory for this policy rule. + example: false action_make_unreportable: type: boolean nullable: false From a0b215e0dc821bdc017343cd95a56f6524f6ae22 Mon Sep 17 00:00:00 2001 From: Sumit Kumar Date: Fri, 17 Jul 2026 16:39:07 +0530 Subject: [PATCH 058/107] =?UTF-8?q?feat:=20Added=20information=20for=20sup?= =?UTF-8?q?port=20of=20expense=5Fmerchants=20and=20expense=5Fmerchants=5Fo?= =?UTF-8?q?p=E2=80=A6=20(#843)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Added infor for support of expense_merchants and expense_merchants_op for expense_without_receipt_allowed false --- reference/admin.yaml | 44 ++++++++++++++++++++ reference/spender.yaml | 25 +++++++++++ src/components/schemas/expense_policies.yaml | 31 ++++++++++++++ src/components/schemas/fields.yaml | 10 +++++ 4 files changed, 110 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index cf3984b7a..0dc0d5070 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -29050,6 +29050,15 @@ components: - COMPANY_ACCOUNT - null example: PERSONAL_CASH_ACCOUNT + contains_from_list_operator: + nullable: true + type: string + enum: + - CONTAINS_ANY_FROM_LIST + - CONTAINS_NONE_FROM_LIST + description: | + Value signifying the operator for matching values from a list field. + example: CONTAINS_ANY_FROM_LIST vehicle_type: type: string enum: @@ -29292,6 +29301,22 @@ components: nullable: true allOf: - $ref: '#/components/schemas/contains_operator' + expense_merchants: + nullable: true + type: array + items: + type: string + description: | + List of merchant names considered by this policy rule. + example: + - Uber + - Amazon + expense_merchants_op: + nullable: true + allOf: + - $ref: '#/components/schemas/contains_from_list_operator' + description: | + Operator to apply on `expense_merchants`. expense_without_ccc_match_allowed: type: boolean description: | @@ -29542,6 +29567,8 @@ components: - expense_amount_max - expense_payment_modes - expense_payment_modes_op + - expense_merchants + - expense_merchants_op - expense_without_ccc_match_allowed - employee_department_ids - employee_department_ids_op @@ -29745,6 +29772,23 @@ components: - $ref: '#/components/schemas/contains_operator' description: | _Note: This field is mandatory if the field `expense_payment_modes` is present in the request body._ + expense_merchants: + type: array + items: + type: string + description: | + List of merchant names to be checked against expense merchant for applying this policy rule.
+ _Note: You need to use field `expense_merchants_op` along with this field._
+ _Note: This field is allowed only when `expense_without_receipt_allowed` is false._ + example: + - Uber + - Amazon + expense_merchants_op: + allOf: + - $ref: '#/components/schemas/contains_from_list_operator' + description: | + _Note: This field is mandatory if the field `expense_merchants` is present in the request body._
+ _Note: This field is allowed only when `expense_without_receipt_allowed` is false._ expense_without_ccc_match_allowed: type: boolean description: | diff --git a/reference/spender.yaml b/reference/spender.yaml index 7b991d7ca..e1dac01c9 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -16193,6 +16193,15 @@ components: - COMPANY_ACCOUNT - null example: PERSONAL_CASH_ACCOUNT + contains_from_list_operator: + nullable: true + type: string + enum: + - CONTAINS_ANY_FROM_LIST + - CONTAINS_NONE_FROM_LIST + description: | + Value signifying the operator for matching values from a list field. + example: CONTAINS_ANY_FROM_LIST vehicle_type: type: string enum: @@ -16435,6 +16444,22 @@ components: nullable: true allOf: - $ref: '#/components/schemas/contains_operator' + expense_merchants: + nullable: true + type: array + items: + type: string + description: | + List of merchant names considered by this policy rule. + example: + - Uber + - Amazon + expense_merchants_op: + nullable: true + allOf: + - $ref: '#/components/schemas/contains_from_list_operator' + description: | + Operator to apply on `expense_merchants`. expense_without_ccc_match_allowed: type: boolean description: | diff --git a/src/components/schemas/expense_policies.yaml b/src/components/schemas/expense_policies.yaml index 08a6d88a5..25af94979 100644 --- a/src/components/schemas/expense_policies.yaml +++ b/src/components/schemas/expense_policies.yaml @@ -35,6 +35,8 @@ expense_policy_in: - expense_amount_max - expense_payment_modes - expense_payment_modes_op + - expense_merchants + - expense_merchants_op - expense_without_ccc_match_allowed - employee_department_ids - employee_department_ids_op @@ -232,6 +234,21 @@ expense_policy_in: - $ref: ./fields.yaml#/contains_operator description: | _Note: This field is mandatory if the field `expense_payment_modes` is present in the request body._ + expense_merchants: + type: array + items: + type: string + description: | + List of merchant names to be checked against expense merchant for applying this policy rule.
+ _Note: You need to use field `expense_merchants_op` along with this field._
+ _Note: This field is allowed only when `expense_without_receipt_allowed` is false._ + example: ['Uber', 'Amazon'] + expense_merchants_op: + allOf: + - $ref: ./fields.yaml#/contains_from_list_operator + description: | + _Note: This field is mandatory if the field `expense_merchants` is present in the request body._
+ _Note: This field is allowed only when `expense_without_receipt_allowed` is false._ expense_without_ccc_match_allowed: type: boolean description: | @@ -669,6 +686,20 @@ expense_policy_out: nullable: true allOf: - $ref: ./fields.yaml#/contains_operator + expense_merchants: + nullable: true + type: array + items: + type: string + description: | + List of merchant names considered by this policy rule. + example: ['Uber', 'Amazon'] + expense_merchants_op: + nullable: true + allOf: + - $ref: ./fields.yaml#/contains_from_list_operator + description: | + Operator to apply on `expense_merchants`. expense_without_ccc_match_allowed: type: boolean description: | diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index 5d4520429..a489a5cd1 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -346,6 +346,16 @@ contains_operator: Value signifying the operator for the field example: IN +contains_from_list_operator: + nullable: true + type: string + enum: + - CONTAINS_ANY_FROM_LIST + - CONTAINS_NONE_FROM_LIST + description: > + Value signifying the operator for matching values from a list field. + example: CONTAINS_ANY_FROM_LIST + delegation_access_scope: type: array description: | From 8dfa9957b7fe4c87cb6b15d8a4f9f4ba9100cbf4 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 09:34:33 +0530 Subject: [PATCH 059/107] fix: Fix required OpenAPI drift for Departments (#837) * Fix required OpenAPI drift for Departments * Auto generate API docs --- reference/admin.yaml | 14 ++++++++++++++ reference/spender.yaml | 14 ++++++++++++++ src/components/schemas/department.yaml | 14 ++++++++++++++ 3 files changed, 42 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 0dc0d5070..e766393da 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -16333,6 +16333,20 @@ components: department_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - sub_department + - is_enabled + - code + - description + - department_head_user_ids + - doc_url + - department_head_users + - display_name properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/spender.yaml b/reference/spender.yaml index e1dac01c9..8eb6c3c78 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -8250,6 +8250,20 @@ components: department_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - sub_department + - is_enabled + - code + - description + - department_head_user_ids + - doc_url + - department_head_users + - display_name properties: id: $ref: '#/components/schemas/id_string' diff --git a/src/components/schemas/department.yaml b/src/components/schemas/department.yaml index 07914aec0..ac65cb43d 100644 --- a/src/components/schemas/department.yaml +++ b/src/components/schemas/department.yaml @@ -1,6 +1,20 @@ department_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - name + - sub_department + - is_enabled + - code + - description + - department_head_user_ids + - doc_url + - department_head_users + - display_name properties: id: $ref: './fields.yaml#/id_string' From a4f3aabee06cb428ba0b30c312840e90788df308 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 09:35:55 +0530 Subject: [PATCH 060/107] fix: Fix required OpenAPI drift for Files (#819) * Fix required OpenAPI drift for Files * Auto generate API docs --- reference/admin.yaml | 2 ++ reference/approver.yaml | 2 ++ reference/manager.yaml | 2 ++ reference/spender.yaml | 2 ++ src/components/schemas/file.yaml | 2 ++ 5 files changed, 10 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index e766393da..ca9e239d5 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -18176,6 +18176,8 @@ components: Returns null if linked to an expense or advance request in approved or higher state. file_generate_urls_action_in: type: object + required: + - id properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/approver.yaml b/reference/approver.yaml index 840bf5615..6e4b1043f 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -9939,6 +9939,8 @@ components: Returns null if linked to an expense or advance request in approved or higher state. file_generate_urls_action_in: type: object + required: + - id properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/manager.yaml b/reference/manager.yaml index 56b8bf0f9..3499ec982 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -790,6 +790,8 @@ components: $ref: '#/components/schemas/org_id' file_generate_urls_action_in: type: object + required: + - id properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/spender.yaml b/reference/spender.yaml index 8eb6c3c78..c9bf2ddc8 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -16119,6 +16119,8 @@ components: Returns null if linked to an expense or advance request in approved or higher state. file_generate_urls_action_in: type: object + required: + - id properties: id: $ref: '#/components/schemas/id_string' diff --git a/src/components/schemas/file.yaml b/src/components/schemas/file.yaml index 862e1c120..ebcb48815 100644 --- a/src/components/schemas/file.yaml +++ b/src/components/schemas/file.yaml @@ -43,6 +43,8 @@ file_out: file_generate_urls_action_in: type: object + required: + - id properties: id: $ref: './fields.yaml#/id_string' From 7cee78bb681e7719726d9c53dfeb043855619832 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 10:20:25 +0530 Subject: [PATCH 061/107] fix: Fix required OpenAPI drift for Org user settings (#823) * Fix required OpenAPI drift for Org user settings * Auto generate API docs * Apply suggestions from code review Co-authored-by: Yash Ukalkar * employee settings locale changes * Auto generate API docs --------- Co-authored-by: Yash Ukalkar --- reference/admin.yaml | 10 ++-- reference/approver.yaml | 10 ++-- reference/spender.yaml | 52 +++++++++++++++++-- src/components/schemas/employee_settings.yaml | 52 +++++++++++++++++-- 4 files changed, 108 insertions(+), 16 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index ca9e239d5..8d33a8966 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -33851,20 +33851,24 @@ components: nullable: true additionalProperties: false description: Settings for user's locale and timezone + required: + - timezone + - abbreviation + - offset properties: timezone: type: string - nullable: true + nullable: false example: Asia/Kolkata description: User's timezone abbreviation: type: string - nullable: true + nullable: false example: IST description: Timezone abbreviation offset: type: string - nullable: true + nullable: false example: '05:30:00' description: Timezone offset from UTC is_personal_cards_enabled: diff --git a/reference/approver.yaml b/reference/approver.yaml index 6e4b1043f..9b3f845db 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -10645,20 +10645,24 @@ components: nullable: true additionalProperties: false description: Settings for user's locale and timezone + required: + - timezone + - abbreviation + - offset properties: timezone: type: string - nullable: true + nullable: false example: Asia/Kolkata description: User's timezone abbreviation: type: string - nullable: true + nullable: false example: IST description: Timezone abbreviation offset: type: string - nullable: true + nullable: false example: '05:30:00' description: Timezone offset from UTC is_personal_cards_enabled: diff --git a/reference/spender.yaml b/reference/spender.yaml index c9bf2ddc8..b62a93249 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -15678,20 +15678,24 @@ components: nullable: true additionalProperties: false description: Settings for user's locale and timezone + required: + - timezone + - abbreviation + - offset properties: timezone: type: string - nullable: true + nullable: false example: Asia/Kolkata description: User's timezone abbreviation: type: string - nullable: true + nullable: false example: IST description: Timezone abbreviation offset: type: string - nullable: true + nullable: false example: '05:30:00' description: Timezone offset from UTC is_personal_cards_enabled: @@ -15716,13 +15720,16 @@ components: spender_employee_settings_in: type: object additionalProperties: false + required: + - id + - employee_id properties: id: $ref: '#/components/schemas/id_string' - description: Unique identifier for the employee settings (optional) + description: Unique identifier for the employee settings employee_id: $ref: '#/components/schemas/id_string' - description: Unique identifier of the employee (optional) + description: Unique identifier of the employee cost_center_ids: type: array items: @@ -15750,22 +15757,35 @@ components: description: List of categories that the employee has access to locale: type: object + nullable: true additionalProperties: false description: Settings for user's locale and timezone + required: + - timezone + - abbreviation + - offset properties: timezone: type: string + nullable: false description: User's timezone abbreviation: type: string + nullable: false description: Timezone abbreviation offset: type: string + nullable: false description: Timezone offset from UTC insta_fyle_settings: type: object additionalProperties: false description: Settings for InstaFyle receipt scanning and data extraction + required: + - allowed + - enabled + - static_camera_overlay_enabled + - extract_fields properties: allowed: type: boolean @@ -15785,6 +15805,15 @@ components: type: object additionalProperties: false description: Settings for email and push notifications + required: + - email_allowed + - email_enabled + - email_unsubscribed_events + - push_allowed + - push_enabled + - push_unsubscribed_events + - notify_user + - notify_delegatee properties: email_allowed: type: boolean @@ -15818,6 +15847,9 @@ components: type: object additionalProperties: false description: Settings for automatic form filling in expenses + required: + - allowed + - enabled properties: allowed: type: boolean @@ -15829,6 +15861,9 @@ components: type: object additionalProperties: false description: Settings for data extraction from receipts + required: + - allowed + - enabled properties: allowed: type: boolean @@ -15840,6 +15875,9 @@ components: type: object additionalProperties: false description: Settings for in-app chat functionality + required: + - allowed + - enabled properties: allowed: type: boolean @@ -15855,6 +15893,10 @@ components: type: object additionalProperties: false description: Settings for payment modes + required: + - allowed + - enabled + - allowed_payment_modes properties: allowed: type: boolean diff --git a/src/components/schemas/employee_settings.yaml b/src/components/schemas/employee_settings.yaml index 0c1ee61ff..1902e4b44 100644 --- a/src/components/schemas/employee_settings.yaml +++ b/src/components/schemas/employee_settings.yaml @@ -227,20 +227,24 @@ spender_employee_settings_out: nullable: true additionalProperties: false description: Settings for user's locale and timezone + required: + - timezone + - abbreviation + - offset properties: timezone: type: string - nullable: true + nullable: false example: "Asia/Kolkata" description: User's timezone abbreviation: type: string - nullable: true + nullable: false example: "IST" description: Timezone abbreviation offset: type: string - nullable: true + nullable: false example: "05:30:00" description: Timezone offset from UTC is_personal_cards_enabled: @@ -266,13 +270,16 @@ spender_employee_settings_out: spender_employee_settings_in: type: object additionalProperties: false + required: + - id + - employee_id properties: id: $ref: './fields.yaml#/id_string' - description: Unique identifier for the employee settings (optional) + description: Unique identifier for the employee settings employee_id: $ref: './fields.yaml#/id_string' - description: Unique identifier of the employee (optional) + description: Unique identifier of the employee cost_center_ids: type: array items: @@ -300,22 +307,35 @@ spender_employee_settings_in: description: List of categories that the employee has access to locale: type: object + nullable: true additionalProperties: false description: Settings for user's locale and timezone + required: + - timezone + - abbreviation + - offset properties: timezone: type: string + nullable: false description: User's timezone abbreviation: type: string + nullable: false description: Timezone abbreviation offset: type: string + nullable: false description: Timezone offset from UTC insta_fyle_settings: type: object additionalProperties: false description: Settings for InstaFyle receipt scanning and data extraction + required: + - allowed + - enabled + - static_camera_overlay_enabled + - extract_fields properties: allowed: type: boolean @@ -335,6 +355,15 @@ spender_employee_settings_in: type: object additionalProperties: false description: Settings for email and push notifications + required: + - email_allowed + - email_enabled + - email_unsubscribed_events + - push_allowed + - push_enabled + - push_unsubscribed_events + - notify_user + - notify_delegatee properties: email_allowed: type: boolean @@ -368,6 +397,9 @@ spender_employee_settings_in: type: object additionalProperties: false description: Settings for automatic form filling in expenses + required: + - allowed + - enabled properties: allowed: type: boolean @@ -379,6 +411,9 @@ spender_employee_settings_in: type: object additionalProperties: false description: Settings for data extraction from receipts + required: + - allowed + - enabled properties: allowed: type: boolean @@ -390,6 +425,9 @@ spender_employee_settings_in: type: object additionalProperties: false description: Settings for in-app chat functionality + required: + - allowed + - enabled properties: allowed: type: boolean @@ -405,6 +443,10 @@ spender_employee_settings_in: type: object additionalProperties: false description: Settings for payment modes + required: + - allowed + - enabled + - allowed_payment_modes properties: allowed: type: boolean From ad5a4fc649179951d5ef80d3c3009321f0868966 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 10:22:21 +0530 Subject: [PATCH 062/107] fix: Fix required OpenAPI drift for Projects (#826) * Fix required OpenAPI drift for Projects * Auto generate API docs --- reference/admin.yaml | 16 ++++++++++++++++ reference/approver.yaml | 16 ++++++++++++++++ reference/spender.yaml | 13 +++++++++++++ src/components/schemas/project.yaml | 29 +++++++++++++++++++++++++++++ 4 files changed, 74 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 8d33a8966..d2dc814ca 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -15276,6 +15276,22 @@ components: admin_approver_project_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - sub_project + - display_name + - is_enabled + - code + - description + - restricted_spender_user_ids + - approver_user_ids + - approver_users + - category_ids + - default_billable properties: id: $ref: '#/components/schemas/id_integer' diff --git a/reference/approver.yaml b/reference/approver.yaml index 9b3f845db..6fbb27d6a 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -8214,6 +8214,22 @@ components: admin_approver_project_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - sub_project + - display_name + - is_enabled + - code + - description + - restricted_spender_user_ids + - approver_user_ids + - approver_users + - category_ids + - default_billable properties: id: $ref: '#/components/schemas/id_integer' diff --git a/reference/spender.yaml b/reference/spender.yaml index b62a93249..20e957e70 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -7741,6 +7741,19 @@ components: project_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - sub_project + - display_name + - is_enabled + - code + - description + - category_ids + - default_billable properties: id: $ref: '#/components/schemas/id_integer' diff --git a/src/components/schemas/project.yaml b/src/components/schemas/project.yaml index 18e4ce183..3e779062f 100644 --- a/src/components/schemas/project.yaml +++ b/src/components/schemas/project.yaml @@ -1,6 +1,19 @@ project_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - name + - sub_project + - display_name + - is_enabled + - code + - description + - category_ids + - default_billable properties: id: $ref: './fields.yaml#/id_integer' @@ -179,6 +192,22 @@ project_in_only_id: admin_approver_project_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - name + - sub_project + - display_name + - is_enabled + - code + - description + - restricted_spender_user_ids + - approver_user_ids + - approver_users + - category_ids + - default_billable properties: id: $ref: './fields.yaml#/id_integer' From f9ad3e49883ebc358e449e541cc85fdc2211a2f4 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 10:29:27 +0530 Subject: [PATCH 063/107] fix: Fix required OpenAPI drift for Policies (#825) * Fix required OpenAPI drift for Policies * Auto generate API docs * code comment fixes * Auto generate API docs --- reference/admin.yaml | 75 +++++++++++++++++++ reference/approver.yaml | 4 + reference/manager.yaml | 4 + reference/spender.yaml | 75 +++++++++++++++++++ .../paths/admin@expense_policy_comments.yaml | 3 + src/components/schemas/expense_policies.yaml | 72 ++++++++++++++++++ .../spender@expense_policy_comments.yaml | 3 + 7 files changed, 236 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index d2dc814ca..56c2d09c7 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -14295,6 +14295,9 @@ paths: type: array items: type: object + required: + - comment_type + - comment_text properties: comment_type: type: string @@ -29106,6 +29109,74 @@ components: expense_policy_out: type: object additionalProperties: true + required: + - created_at + - updated_at + - id + - org_id + - is_enabled + - is_retired + - description + - source + - creator_user_id + - creator_user + - approver_order + - is_approver_policy + - employee_department_ids + - employee_department_ids_op + - employee_level_ids + - employee_level_ids_op + - employee_titles + - employee_titles_op + - employee_user_ids + - employee_user_ids_op + - employee_custom_fields + - employee_custom_fields_op + - employee_locations + - employee_locations_op + - expense_category_ids + - expense_category_ids_op + - expense_limit_type + - expense_amount_max + - expense_amount_min + - expense_creation_delay_days_max + - expense_currency + - expense_without_receipt_allowed + - expense_allowed_distance_difference_percentage + - expense_flight_travel_class + - expense_project_ids + - expense_project_ids_op + - expense_train_travel_class + - expense_spent_at_max + - expense_spent_at_min + - expense_locations + - expense_locations_op + - expense_allowed_exchange_rate_difference_percentage + - expense_include_foreign_currency + - expense_annual_distance_max + - expense_vehicle_type + - expense_cost_center_ids + - expense_cost_center_ids_op + - expense_distance_max + - expense_distance_min + - expense_custom_fields + - expense_custom_fields_op + - expense_without_ccc_match_allowed + - expense_fiscal_start_month + - expense_payment_modes + - expense_payment_modes_op + - action_flag + - action_show_warning + - action_cap_amount + - action_make_unreportable + - action_remove_employee_approver1 + - action_add_employee_approver2 + - action_add_employee_approver3 + - action_add_project_approver1 + - action_add_project_approver2 + - action_add_department_head_approver + - action_add_approver_user_ids + - action_override_distance_slab_rate properties: id: allOf: @@ -30290,6 +30361,10 @@ components: expense_policy_states_out: type: object additionalProperties: false + required: + - expense_id + - individual_desired_states + - final_desired_state properties: expense_id: type: string diff --git a/reference/approver.yaml b/reference/approver.yaml index 6fbb27d6a..a56adc75b 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -8907,6 +8907,10 @@ components: expense_policy_states_out: type: object additionalProperties: false + required: + - expense_id + - individual_desired_states + - final_desired_state properties: expense_id: type: string diff --git a/reference/manager.yaml b/reference/manager.yaml index 3499ec982..8cb0f2812 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -1069,6 +1069,10 @@ components: expense_policy_states_out: type: object additionalProperties: false + required: + - expense_id + - individual_desired_states + - final_desired_state properties: expense_id: type: string diff --git a/reference/spender.yaml b/reference/spender.yaml index 20e957e70..b6c8dc796 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -6121,6 +6121,9 @@ paths: type: array items: type: object + required: + - comment_type + - comment_text properties: comment_type: type: string @@ -16288,6 +16291,74 @@ components: expense_policy_out: type: object additionalProperties: true + required: + - created_at + - updated_at + - id + - org_id + - is_enabled + - is_retired + - description + - source + - creator_user_id + - creator_user + - approver_order + - is_approver_policy + - employee_department_ids + - employee_department_ids_op + - employee_level_ids + - employee_level_ids_op + - employee_titles + - employee_titles_op + - employee_user_ids + - employee_user_ids_op + - employee_custom_fields + - employee_custom_fields_op + - employee_locations + - employee_locations_op + - expense_category_ids + - expense_category_ids_op + - expense_limit_type + - expense_amount_max + - expense_amount_min + - expense_creation_delay_days_max + - expense_currency + - expense_without_receipt_allowed + - expense_allowed_distance_difference_percentage + - expense_flight_travel_class + - expense_project_ids + - expense_project_ids_op + - expense_train_travel_class + - expense_spent_at_max + - expense_spent_at_min + - expense_locations + - expense_locations_op + - expense_allowed_exchange_rate_difference_percentage + - expense_include_foreign_currency + - expense_annual_distance_max + - expense_vehicle_type + - expense_cost_center_ids + - expense_cost_center_ids_op + - expense_distance_max + - expense_distance_min + - expense_custom_fields + - expense_custom_fields_op + - expense_without_ccc_match_allowed + - expense_fiscal_start_month + - expense_payment_modes + - expense_payment_modes_op + - action_flag + - action_show_warning + - action_cap_amount + - action_make_unreportable + - action_remove_employee_approver1 + - action_add_employee_approver2 + - action_add_employee_approver3 + - action_add_project_approver1 + - action_add_project_approver2 + - action_add_department_head_approver + - action_add_approver_user_ids + - action_override_distance_slab_rate properties: id: allOf: @@ -16979,6 +17050,10 @@ components: expense_policy_states_out: type: object additionalProperties: false + required: + - expense_id + - individual_desired_states + - final_desired_state properties: expense_id: type: string diff --git a/src/admin/paths/admin@expense_policy_comments.yaml b/src/admin/paths/admin@expense_policy_comments.yaml index 527955494..32672860a 100644 --- a/src/admin/paths/admin@expense_policy_comments.yaml +++ b/src/admin/paths/admin@expense_policy_comments.yaml @@ -26,6 +26,9 @@ post: type: array items: type: object + required: + - comment_type + - comment_text properties: comment_type: type: string diff --git a/src/components/schemas/expense_policies.yaml b/src/components/schemas/expense_policies.yaml index 25af94979..df806737b 100644 --- a/src/components/schemas/expense_policies.yaml +++ b/src/components/schemas/expense_policies.yaml @@ -465,6 +465,74 @@ expense_policy_in: expense_policy_out: type: object additionalProperties: True + required: + - created_at + - updated_at + - id + - org_id + - is_enabled + - is_retired + - description + - source + - creator_user_id + - creator_user + - approver_order + - is_approver_policy + - employee_department_ids + - employee_department_ids_op + - employee_level_ids + - employee_level_ids_op + - employee_titles + - employee_titles_op + - employee_user_ids + - employee_user_ids_op + - employee_custom_fields + - employee_custom_fields_op + - employee_locations + - employee_locations_op + - expense_category_ids + - expense_category_ids_op + - expense_limit_type + - expense_amount_max + - expense_amount_min + - expense_creation_delay_days_max + - expense_currency + - expense_without_receipt_allowed + - expense_allowed_distance_difference_percentage + - expense_flight_travel_class + - expense_project_ids + - expense_project_ids_op + - expense_train_travel_class + - expense_spent_at_max + - expense_spent_at_min + - expense_locations + - expense_locations_op + - expense_allowed_exchange_rate_difference_percentage + - expense_include_foreign_currency + - expense_annual_distance_max + - expense_vehicle_type + - expense_cost_center_ids + - expense_cost_center_ids_op + - expense_distance_max + - expense_distance_min + - expense_custom_fields + - expense_custom_fields_op + - expense_without_ccc_match_allowed + - expense_fiscal_start_month + - expense_payment_modes + - expense_payment_modes_op + - action_flag + - action_show_warning + - action_cap_amount + - action_make_unreportable + - action_remove_employee_approver1 + - action_add_employee_approver2 + - action_add_employee_approver3 + - action_add_project_approver1 + - action_add_project_approver2 + - action_add_department_head_approver + - action_add_approver_user_ids + - action_override_distance_slab_rate properties: id: allOf: @@ -919,6 +987,10 @@ expense_policy_state_change_in: expense_policy_states_out: type: object additionalProperties: False + required: + - expense_id + - individual_desired_states + - final_desired_state properties: expense_id: type: string diff --git a/src/spender/paths/spender@expense_policy_comments.yaml b/src/spender/paths/spender@expense_policy_comments.yaml index 527955494..32672860a 100644 --- a/src/spender/paths/spender@expense_policy_comments.yaml +++ b/src/spender/paths/spender@expense_policy_comments.yaml @@ -26,6 +26,9 @@ post: type: array items: type: object + required: + - comment_type + - comment_text properties: comment_type: type: string From 7c665ba94ba9fc4c68b23ef7f9bc5170af73622c Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 10:31:12 +0530 Subject: [PATCH 064/107] fix: Fix required OpenAPI drift for Mileage (#821) * Fix required OpenAPI drift for Mileage * Auto generate API docs --- reference/admin.yaml | 14 ++++++++++++++ reference/approver.yaml | 14 ++++++++++++++ reference/spender.yaml | 14 ++++++++++++++ src/components/schemas/mileage_rate.yaml | 14 ++++++++++++++ 4 files changed, 56 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 56c2d09c7..32000d7a4 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -16442,6 +16442,17 @@ components: mileage_rate_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - unit + - vehicle_type + - rate + - slab_rates + - is_enabled + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -16468,6 +16479,9 @@ components: type: array items: type: object + required: + - rate + - limit properties: rate: type: number diff --git a/reference/approver.yaml b/reference/approver.yaml index a56adc75b..4d1a1abbf 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -8635,6 +8635,17 @@ components: mileage_rate_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - unit + - vehicle_type + - rate + - slab_rates + - is_enabled + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -8661,6 +8672,9 @@ components: type: array items: type: object + required: + - rate + - limit properties: rate: type: number diff --git a/reference/spender.yaml b/reference/spender.yaml index b6c8dc796..9bff73ee2 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -8007,6 +8007,17 @@ components: mileage_rate_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - unit + - vehicle_type + - rate + - slab_rates + - is_enabled + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -8033,6 +8044,9 @@ components: type: array items: type: object + required: + - rate + - limit properties: rate: type: number diff --git a/src/components/schemas/mileage_rate.yaml b/src/components/schemas/mileage_rate.yaml index ccf066916..0a31d355e 100644 --- a/src/components/schemas/mileage_rate.yaml +++ b/src/components/schemas/mileage_rate.yaml @@ -1,6 +1,17 @@ mileage_rate_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - unit + - vehicle_type + - rate + - slab_rates + - is_enabled + - code properties: id: $ref: './fields.yaml#/id_integer' @@ -31,6 +42,9 @@ mileage_rate_out: type: array items: type: object + required: + - rate + - limit properties: rate: type: number From 7f3d31ae7e2ef42632cd7029b823a37585a9e4cf Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 10:34:53 +0530 Subject: [PATCH 065/107] fix: Fix required OpenAPI drift for Business Expenses (#813) * Fix required OpenAPI drift for Business Expenses * Auto generate API docs * code comment fixes * Auto generate API docs --- reference/admin.yaml | 21 ++++++++++++ reference/approver.yaml | 11 +++++++ reference/spender.yaml | 32 +++++++++++++++++++ src/components/schemas/per_diem_rate.yaml | 11 +++++++ .../schemas/recently_used_fields.yaml | 11 +++++++ src/components/schemas/tax_group.yaml | 10 ++++++ 6 files changed, 96 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 32000d7a4..06a790dce 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -16249,6 +16249,17 @@ components: per_diem_rate_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - is_enabled + - name + - currency + - rate + - code + - description properties: id: $ref: '#/components/schemas/id_integer' @@ -28420,6 +28431,16 @@ components: tax_group_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - code + - name + - percentage + - is_enabled + - is_default properties: id: allOf: diff --git a/reference/approver.yaml b/reference/approver.yaml index 4d1a1abbf..5cda5ba05 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -8587,6 +8587,17 @@ components: per_diem_rate_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - is_enabled + - name + - currency + - rate + - code + - description properties: id: $ref: '#/components/schemas/id_integer' diff --git a/reference/spender.yaml b/reference/spender.yaml index 9bff73ee2..343d0fc2d 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -8149,6 +8149,17 @@ components: recently_used_fields_out: type: object additionalProperties: false + required: + - org_id + - user_id + - category_ids + - cost_center_ids + - project_ids + - start_locations + - locations + - end_locations + - vehicle_types + - currencies properties: user_id: $ref: '#/components/schemas/user_id' @@ -10728,6 +10739,17 @@ components: per_diem_rate_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - is_enabled + - name + - currency + - rate + - code + - description properties: id: $ref: '#/components/schemas/id_integer' @@ -16092,6 +16114,16 @@ components: tax_group_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - code + - name + - percentage + - is_enabled + - is_default properties: id: allOf: diff --git a/src/components/schemas/per_diem_rate.yaml b/src/components/schemas/per_diem_rate.yaml index 3916d0bf5..43d01f8ed 100644 --- a/src/components/schemas/per_diem_rate.yaml +++ b/src/components/schemas/per_diem_rate.yaml @@ -1,6 +1,17 @@ per_diem_rate_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - is_enabled + - name + - currency + - rate + - code + - description properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/recently_used_fields.yaml b/src/components/schemas/recently_used_fields.yaml index 4fb18e5de..284358813 100644 --- a/src/components/schemas/recently_used_fields.yaml +++ b/src/components/schemas/recently_used_fields.yaml @@ -1,6 +1,17 @@ recently_used_fields_out: type: object additionalProperties: false + required: + - org_id + - user_id + - category_ids + - cost_center_ids + - project_ids + - start_locations + - locations + - end_locations + - vehicle_types + - currencies properties: user_id: diff --git a/src/components/schemas/tax_group.yaml b/src/components/schemas/tax_group.yaml index 6ebccc83f..7d13a4335 100644 --- a/src/components/schemas/tax_group.yaml +++ b/src/components/schemas/tax_group.yaml @@ -1,6 +1,16 @@ tax_group_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - code + - name + - percentage + - is_enabled + - is_default properties: id: allOf: From 97aea03df4dbbb301ae8d5a87a3d7e2525ca3208 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 10:37:04 +0530 Subject: [PATCH 066/107] fix: Fix required OpenAPI drift for Saved filters (#831) * Fix required OpenAPI drift for Saved filters * Auto generate API docs --- reference/admin.yaml | 38 +++++++++++++++++++ reference/approver.yaml | 20 ++++++++++ reference/spender.yaml | 20 ++++++++++ .../corporate_card_transaction_filters.yaml | 9 +++++ src/components/schemas/employee_filters.yaml | 9 +++++ src/components/schemas/expense_filters.yaml | 10 +++++ src/components/schemas/report_filters.yaml | 10 +++++ 7 files changed, 116 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 06a790dce..aea2235dc 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -17730,6 +17730,15 @@ components: employee_filters_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - name + - is_shared + - query_string properties: id: allOf: @@ -20553,6 +20562,16 @@ components: expense_filters_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - name + - is_shared + - query_string + - sub_feature properties: id: allOf: @@ -22889,6 +22908,16 @@ components: report_filters_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - is_shared + - name + - org_id + - query_string + - user_id + - sub_feature properties: id: allOf: @@ -25454,6 +25483,15 @@ components: corporate_card_transaction_filters_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - name + - is_shared + - query_string properties: id: allOf: diff --git a/reference/approver.yaml b/reference/approver.yaml index 5cda5ba05..bfbc7cfce 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -7380,6 +7380,16 @@ components: report_filters_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - is_shared + - name + - org_id + - query_string + - user_id + - sub_feature properties: id: allOf: @@ -9526,6 +9536,16 @@ components: expense_filters_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - name + - is_shared + - query_string + - sub_feature properties: id: allOf: diff --git a/reference/spender.yaml b/reference/spender.yaml index 343d0fc2d..94bfae5ed 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -11765,6 +11765,16 @@ components: report_filters_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - is_shared + - name + - org_id + - query_string + - user_id + - sub_feature properties: id: allOf: @@ -18049,6 +18059,16 @@ components: expense_filters_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - name + - is_shared + - query_string + - sub_feature properties: id: allOf: diff --git a/src/components/schemas/corporate_card_transaction_filters.yaml b/src/components/schemas/corporate_card_transaction_filters.yaml index cfbec1ad3..c864516eb 100644 --- a/src/components/schemas/corporate_card_transaction_filters.yaml +++ b/src/components/schemas/corporate_card_transaction_filters.yaml @@ -15,6 +15,15 @@ corporate_card_transaction_filters_in: corporate_card_transaction_filters_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - user_id + - name + - is_shared + - query_string properties: id: allOf: diff --git a/src/components/schemas/employee_filters.yaml b/src/components/schemas/employee_filters.yaml index d993b0f9d..f834479c8 100644 --- a/src/components/schemas/employee_filters.yaml +++ b/src/components/schemas/employee_filters.yaml @@ -16,6 +16,15 @@ employee_filters_in: employee_filters_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - user_id + - name + - is_shared + - query_string properties: id: allOf: diff --git a/src/components/schemas/expense_filters.yaml b/src/components/schemas/expense_filters.yaml index 9ccbd4954..624c87c9d 100644 --- a/src/components/schemas/expense_filters.yaml +++ b/src/components/schemas/expense_filters.yaml @@ -18,6 +18,16 @@ expense_filters_in: expense_filters_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - user_id + - name + - is_shared + - query_string + - sub_feature properties: id: allOf: diff --git a/src/components/schemas/report_filters.yaml b/src/components/schemas/report_filters.yaml index b0acfc75e..3311fc3d2 100644 --- a/src/components/schemas/report_filters.yaml +++ b/src/components/schemas/report_filters.yaml @@ -18,6 +18,16 @@ report_filters_in: report_filters_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - is_shared + - name + - org_id + - query_string + - user_id + - sub_feature properties: id: allOf: From c6ef211ddf8fe540419edb4ea98eaec28cb3ebe4 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 10:39:18 +0530 Subject: [PATCH 067/107] fix: Fix required OpenAPI drift for Reminders (#836) * Fix required OpenAPI drift for Reminders * Auto generate API docs --- reference/admin.yaml | 13 +++++++++++++ src/components/schemas/reminder.yaml | 13 +++++++++++++ 2 files changed, 26 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index aea2235dc..b99c9d453 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -22296,6 +22296,19 @@ components: reminder_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - type + - message + - schedule_config + - add_to_calendar + - receiver_user_ids + - send_mobile_notification + - last_reminded_at + - next_reminder_at properties: id: type: string diff --git a/src/components/schemas/reminder.yaml b/src/components/schemas/reminder.yaml index e9a2b7b83..f9bb5e011 100644 --- a/src/components/schemas/reminder.yaml +++ b/src/components/schemas/reminder.yaml @@ -1,6 +1,19 @@ reminder_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - type + - message + - schedule_config + - add_to_calendar + - receiver_user_ids + - send_mobile_notification + - last_reminded_at + - next_reminder_at properties: id: type: string From cd195c74f02aae91a35ea1618d010f2184cbcc63 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 11:09:09 +0530 Subject: [PATCH 068/107] fix:Fix required OpenAPI drift for Recurrences (#828) * Fix required OpenAPI drift for Recurrences * Auto generate API docs --- reference/admin.yaml | 5 +++++ reference/spender.yaml | 5 +++++ src/components/schemas/fields.yaml | 3 +++ src/components/schemas/schedule.yaml | 2 ++ 4 files changed, 15 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index b99c9d453..0d9eb0711 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -18268,6 +18268,9 @@ components: schedule_config: type: object nullable: false + required: + - type + - when properties: type: nullable: false @@ -28192,6 +28195,8 @@ components: example: TRANSACTION schedule_in: type: object + required: + - is_enabled properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/spender.yaml b/reference/spender.yaml index 94bfae5ed..adcea0de8 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -11333,6 +11333,9 @@ components: schedule_config: type: object nullable: false + required: + - type + - when properties: type: nullable: false @@ -11454,6 +11457,8 @@ components: example: TRANSACTION schedule_in: type: object + required: + - is_enabled properties: id: $ref: '#/components/schemas/id_string' diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index a489a5cd1..6f9965211 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1148,6 +1148,9 @@ missing_mandatory_fields: schedule_config: type: object nullable: false + required: + - type + - when properties: type: nullable: false diff --git a/src/components/schemas/schedule.yaml b/src/components/schemas/schedule.yaml index 794154f47..d8e8726ea 100644 --- a/src/components/schemas/schedule.yaml +++ b/src/components/schemas/schedule.yaml @@ -1,5 +1,7 @@ schedule_in: type: object + required: + - is_enabled properties: id: $ref: './fields.yaml#/id_string' From 74e68280613049bbca8e9f06be6909cec4aa61a2 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 11:11:11 +0530 Subject: [PATCH 069/107] fix:Fix required OpenAPI drift for Team expenses (#833) * Fix required OpenAPI drift for Team expenses * Auto generate API docs --- reference/admin.yaml | 44 +++++++++++++++++++ reference/approver.yaml | 65 ++++++++++++++++++++++++++++ reference/manager.yaml | 65 ++++++++++++++++++++++++++++ reference/spender.yaml | 2 + src/components/schemas/employee.yaml | 63 +++++++++++++++++++++++++++ src/components/schemas/expense.yaml | 2 + 6 files changed, 241 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 0d9eb0711..bcefaa94f 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -17035,6 +17035,48 @@ components: employee_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - business_unit + - code + - custom_fields + - department + - department_id + - is_enabled + - joined_at + - level + - level_id + - location + - org_id + - roles + - special_email + - title + - user_id + - user + - mileage_rate_ids + - mileage_rates + - cost_center_ids + - cost_centers + - per_diem_rate_ids + - per_diem_rates + - project_ids + - projects + - approver_user_ids + - approver_users + - has_accepted_invite + - branch_account + - branch_ifsc + - mobile + - locale + - mileage_settings + - ach_account + - delegatees + - category_ids + - categories + - flattened_custom_field + - is_mobile_verified properties: id: $ref: '#/components/schemas/id_string' @@ -32575,6 +32617,8 @@ components: - org_id - updated_at - created_at + - creator_user_id + - creator_user properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/approver.yaml b/reference/approver.yaml index bfbc7cfce..e64ea12a5 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -9339,6 +9339,8 @@ components: - org_id - updated_at - created_at + - creator_user_id + - creator_user properties: id: $ref: '#/components/schemas/id_string' @@ -10197,6 +10199,48 @@ components: employee_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - business_unit + - code + - custom_fields + - department + - department_id + - is_enabled + - joined_at + - level + - level_id + - location + - org_id + - roles + - special_email + - title + - user_id + - user + - mileage_rate_ids + - mileage_rates + - cost_center_ids + - cost_centers + - per_diem_rate_ids + - per_diem_rates + - project_ids + - projects + - approver_user_ids + - approver_users + - has_accepted_invite + - branch_account + - branch_ifsc + - mobile + - locale + - mileage_settings + - ach_account + - delegatees + - category_ids + - categories + - flattened_custom_field + - is_mobile_verified properties: id: $ref: '#/components/schemas/id_string' @@ -10943,6 +10987,15 @@ components: employee_hierarchy_out: type: object additionalProperties: false + required: + - user_id + - org_id + - name + - email + - title + - depth + - has_accepted_invite + - primary_approver_user_id properties: user_id: $ref: '#/components/schemas/user_id' @@ -10976,6 +11029,18 @@ components: employee_overview_out: type: object additionalProperties: false + required: + - user_id + - org_id + - user + - employee_id + - employee + - primary_approver_id + - primary_approver + - department_id + - department + - expense_total_amount + - expense_count properties: user: type: object diff --git a/reference/manager.yaml b/reference/manager.yaml index 8cb0f2812..ad535129e 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -733,6 +733,8 @@ components: - org_id - updated_at - created_at + - creator_user_id + - creator_user properties: id: $ref: '#/components/schemas/id_string' @@ -1099,6 +1101,15 @@ components: employee_hierarchy_out: type: object additionalProperties: false + required: + - user_id + - org_id + - name + - email + - title + - depth + - has_accepted_invite + - primary_approver_user_id properties: user_id: $ref: '#/components/schemas/user_id' @@ -1143,6 +1154,18 @@ components: employee_overview_out: type: object additionalProperties: false + required: + - user_id + - org_id + - user + - employee_id + - employee + - primary_approver_id + - primary_approver + - department_id + - department + - expense_total_amount + - expense_count properties: user: type: object @@ -1689,6 +1712,48 @@ components: employee_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - business_unit + - code + - custom_fields + - department + - department_id + - is_enabled + - joined_at + - level + - level_id + - location + - org_id + - roles + - special_email + - title + - user_id + - user + - mileage_rate_ids + - mileage_rates + - cost_center_ids + - cost_centers + - per_diem_rate_ids + - per_diem_rates + - project_ids + - projects + - approver_user_ids + - approver_users + - has_accepted_invite + - branch_account + - branch_ifsc + - mobile + - locale + - mileage_settings + - ach_account + - delegatees + - category_ids + - categories + - flattened_custom_field + - is_mobile_verified properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/spender.yaml b/reference/spender.yaml index adcea0de8..cfbce3d5d 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -17867,6 +17867,8 @@ components: - org_id - updated_at - created_at + - creator_user_id + - creator_user properties: id: $ref: '#/components/schemas/id_string' diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index 8535e180c..0d106a267 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -1,6 +1,48 @@ employee_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - business_unit + - code + - custom_fields + - department + - department_id + - is_enabled + - joined_at + - level + - level_id + - location + - org_id + - roles + - special_email + - title + - user_id + - user + - mileage_rate_ids + - mileage_rates + - cost_center_ids + - cost_centers + - per_diem_rate_ids + - per_diem_rates + - project_ids + - projects + - approver_user_ids + - approver_users + - has_accepted_invite + - branch_account + - branch_ifsc + - mobile + - locale + - mileage_settings + - ach_account + - delegatees + - category_ids + - categories + - flattened_custom_field + - is_mobile_verified properties: id: $ref: './fields.yaml#/id_string' @@ -1077,6 +1119,15 @@ spender_employee_in: employee_hierarchy_out: type: object additionalProperties: False + required: + - user_id + - org_id + - name + - email + - title + - depth + - has_accepted_invite + - primary_approver_user_id properties: user_id: $ref: './fields.yaml#/user_id' @@ -1266,6 +1317,18 @@ spender_employee_current_out: employee_overview_out: type: object additionalProperties: False + required: + - user_id + - org_id + - user + - employee_id + - employee + - primary_approver_id + - primary_approver + - department_id + - department + - expense_total_amount + - expense_count properties: user: type: object diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 218a40257..a326ce173 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -2398,6 +2398,8 @@ expense_comments_out: - org_id - updated_at - created_at + - creator_user_id + - creator_user properties: id: $ref: './fields.yaml#/id_string' From e4074e3646e5f83b7b4a0136093f1f9888820208 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 11:14:40 +0530 Subject: [PATCH 070/107] fix: Fix Openapi drift required expenses (#817) * Fix required OpenAPI drift for Expenses * Preserve dismiss duplicates required fields * Auto generate API docs * revert custom field changes * Auto generate API docs --- reference/admin.yaml | 3 ++- reference/approver.yaml | 3 ++- reference/spender.yaml | 5 ++--- src/components/schemas/expense.yaml | 5 ++--- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index bcefaa94f..d94a4b4a9 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -17334,6 +17334,8 @@ components: expense_duplicate_sets_out: type: object additionalProperties: false + required: + - expense_ids properties: expense_ids: type: array @@ -32684,7 +32686,6 @@ components: required: - expense_id - comment - - notify properties: expense_id: $ref: '#/components/schemas/id_string' diff --git a/reference/approver.yaml b/reference/approver.yaml index e64ea12a5..5bfb6498d 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -9406,7 +9406,6 @@ components: required: - expense_id - comment - - notify properties: expense_id: $ref: '#/components/schemas/id_string' @@ -9440,6 +9439,8 @@ components: expense_duplicate_sets_out: type: object additionalProperties: false + required: + - expense_ids properties: expense_ids: type: array diff --git a/reference/spender.yaml b/reference/spender.yaml index cfbce3d5d..870439656 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -10282,8 +10282,6 @@ components: spender_expense_in: type: object additionalProperties: false - required: - - claim_amount properties: id: $ref: '#/components/schemas/id_string' @@ -17934,7 +17932,6 @@ components: required: - expense_id - comment - - notify properties: expense_id: $ref: '#/components/schemas/id_string' @@ -17968,6 +17965,8 @@ components: expense_duplicate_sets_out: type: object additionalProperties: false + required: + - expense_ids properties: expense_ids: type: array diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index a326ce173..32bd291b3 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -794,8 +794,6 @@ expense_in: spender_expense_in: type: object additionalProperties: false - required: - - claim_amount properties: id: $ref: './fields.yaml#/id_string' @@ -2466,7 +2464,6 @@ expense_comments_bulk_in: required: - expense_id - comment - - notify properties: expense_id: $ref: './fields.yaml#/id_string' @@ -2500,6 +2497,8 @@ expense_dismiss_duplicates_in: expense_duplicate_sets_out: type: object additionalProperties: false + required: + - expense_ids properties: expense_ids: type: array From 3b8107162bc86e3a775405694da94859e248bd3a Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 11:20:19 +0530 Subject: [PATCH 071/107] fix: Fix required OpenAPI drift for Employees (#835) * Fix required OpenAPI drift for Employees * Auto generate API docs * code comment fixes * revert custom field changes * Auto generate API docs --- reference/admin.yaml | 49 ++++++++++++++++++++++ reference/spender.yaml | 12 ++++++ src/components/schemas/employee.yaml | 34 +++++++++++++++ src/components/schemas/employee_field.yaml | 10 +++++ src/components/schemas/fields.yaml | 17 ++++++++ 5 files changed, 122 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index d94a4b4a9..7cbc743e6 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -16152,6 +16152,16 @@ components: employee_field_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - type + - options + - is_mandatory + - is_enabled properties: id: $ref: '#/components/schemas/id_integer' @@ -17350,6 +17360,10 @@ components: employee_out_potential_duplicate_expenses: type: object additionalProperties: false + required: + - user_id + - email + - full_name properties: user_id: $ref: '#/components/schemas/user_id' @@ -17556,6 +17570,11 @@ components: delegatee: type: object additionalProperties: false + required: + - user_id + - start_at + - end_at + - scopes properties: user_id: type: string @@ -17828,6 +17847,15 @@ components: employees_upload_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - user_id + - org_id + - file_id + - error_file_id + - state properties: id: allOf: @@ -17872,6 +17900,13 @@ components: employees_download_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - file_id + - state properties: id: allOf: @@ -17918,6 +17953,20 @@ components: employee_summary_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - user + - approver_users + - unreported_expenses_total + - unapproved_reports_total + - reimbursable_amount + - advance_account_ids + - advance_accounts_balance + - liability_amount properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/spender.yaml b/reference/spender.yaml index 870439656..bef2f3f9e 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -15219,6 +15219,13 @@ components: commute_location_not_nullable: type: object nullable: false + required: + - city + - state + - country + - formatted_address + - latitude + - longitude properties: city: type: string @@ -15250,6 +15257,11 @@ components: additionalProperties: false description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. + required: + - distance + - distance_unit + - home_location + - work_location properties: home_location: allOf: diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index 0d106a267..ff2a7e622 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -321,6 +321,10 @@ employee_out_embed: employee_out_potential_duplicate_expenses: type: object additionalProperties: False + required: + - user_id + - email + - full_name properties: user_id: $ref: './fields.yaml#/user_id' @@ -740,6 +744,15 @@ employees_upload_in: employees_upload_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - user_id + - org_id + - file_id + - error_file_id + - state properties: id: allOf: @@ -777,6 +790,13 @@ employees_upload_out: employees_download_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - file_id + - state properties: id: allOf: @@ -988,6 +1008,20 @@ spender_delegatees_post_out: employee_summary_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - user_id + - user + - approver_users + - unreported_expenses_total + - unapproved_reports_total + - reimbursable_amount + - advance_account_ids + - advance_accounts_balance + - liability_amount properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/employee_field.yaml b/src/components/schemas/employee_field.yaml index 2faf10e2d..e610a2b2d 100644 --- a/src/components/schemas/employee_field.yaml +++ b/src/components/schemas/employee_field.yaml @@ -1,6 +1,16 @@ employee_field_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - type + - options + - is_mandatory + - is_enabled properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index 6f9965211..9098ffd82 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1915,6 +1915,13 @@ commute_details: commute_location_not_nullable: type: object nullable: false + required: + - city + - state + - country + - formatted_address + - latitude + - longitude properties: city: type: string @@ -1947,6 +1954,11 @@ commute_details_in: additionalProperties: False description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. + required: + - distance + - distance_unit + - home_location + - work_location properties: home_location: allOf: @@ -1985,6 +1997,11 @@ has_accepted_invite: delegatee: type: object additionalProperties: False + required: + - user_id + - start_at + - end_at + - scopes properties: user_id: type: string From efdf434e4edc8526f4a52a6bca1ad05925ec951a Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 20 Jul 2026 11:21:43 +0530 Subject: [PATCH 072/107] fix:Fix required OpenAPI drift for Cost Centers (#816) * Fix required OpenAPI drift for Cost Centers * Auto generate API docs --- reference/admin.yaml | 10 +++++++++ reference/approver.yaml | 10 +++++++++ reference/spender.yaml | 9 ++++++++ src/components/schemas/cost_center.yaml | 29 +++++++++++++++++++++++++ 4 files changed, 58 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 7cbc743e6..61791108e 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -15503,6 +15503,16 @@ components: admin_cost_center_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - is_enabled + - code + - description + - restricted_spender_user_ids properties: id: $ref: '#/components/schemas/id_integer' diff --git a/reference/approver.yaml b/reference/approver.yaml index 5bfb6498d..bbf63139a 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -8571,6 +8571,16 @@ components: approver_cost_center_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - is_enabled + - code + - description + - restricted_spender_user_ids properties: id: $ref: '#/components/schemas/id_integer' diff --git a/reference/spender.yaml b/reference/spender.yaml index bef2f3f9e..f08fe44e0 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -7808,6 +7808,15 @@ components: cost_center_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - is_enabled + - code + - description properties: id: $ref: '#/components/schemas/id_integer' diff --git a/src/components/schemas/cost_center.yaml b/src/components/schemas/cost_center.yaml index 353e8bc66..b77017725 100644 --- a/src/components/schemas/cost_center.yaml +++ b/src/components/schemas/cost_center.yaml @@ -1,6 +1,15 @@ cost_center_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - name + - is_enabled + - code + - description properties: id: $ref: './fields.yaml#/id_integer' @@ -98,6 +107,16 @@ cost_center_in: admin_cost_center_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - name + - is_enabled + - code + - description + - restricted_spender_user_ids properties: id: $ref: './fields.yaml#/id_integer' @@ -125,6 +144,16 @@ admin_cost_center_out: approver_cost_center_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - name + - is_enabled + - code + - description + - restricted_spender_user_ids properties: id: $ref: './fields.yaml#/id_integer' From e3244fcfdcce1cd6bfe8cc5306ec0d4b95231e8c Mon Sep 17 00:00:00 2001 From: Aniruddha Shriwant Date: Mon, 20 Jul 2026 11:31:40 +0530 Subject: [PATCH 073/107] fix: correct mileage rate POST request schema (#838) --- reference/admin.yaml | 6 +++--- src/components/schemas/mileage_rate.yaml | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 61791108e..cf9d79895 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -16545,10 +16545,12 @@ components: rate: type: number example: 10 - nullable: true + minimum: 0 + exclusiveMinimum: true description: Amount (in Home currency) per unit. slab_rates: type: array + maxItems: 1 items: type: object required: @@ -16557,10 +16559,8 @@ components: properties: rate: type: number - nullable: true limit: type: number - nullable: true is_enabled: $ref: '#/components/schemas/is_enabled' code: diff --git a/src/components/schemas/mileage_rate.yaml b/src/components/schemas/mileage_rate.yaml index 0a31d355e..5739cba1f 100644 --- a/src/components/schemas/mileage_rate.yaml +++ b/src/components/schemas/mileage_rate.yaml @@ -113,10 +113,12 @@ mileage_rate_in: rate: type: number example: 10.0 - nullable: true + minimum: 0 + exclusiveMinimum: true description: Amount (in Home currency) per unit. slab_rates: type: array + maxItems: 1 items: type: object required: @@ -125,11 +127,9 @@ mileage_rate_in: properties: rate: type: number - nullable: true limit: type: number - nullable: true is_enabled: $ref: ./fields.yaml#/is_enabled code: - $ref: ./fields.yaml#/code \ No newline at end of file + $ref: ./fields.yaml#/code From bcfcc49908f5fabd42f44548232145c04deba81b Mon Sep 17 00:00:00 2001 From: Aniruddha Shriwant Date: Mon, 20 Jul 2026 12:08:12 +0530 Subject: [PATCH 074/107] feat: add mileage rates bulk API contracts (#839) --- reference/admin.yaml | 231 ++++++++++++++++++ src/admin/openapi.yaml | 6 + src/admin/paths/admin@mileage_rates@bulk.yaml | 62 +++++ .../admin@mileage_rates@delete@bulk.yaml | 75 ++++++ ...min@mileage_rates@delete_summary@bulk.yaml | 61 +++++ src/components/schemas/mileage_rate.yaml | 29 +++ 6 files changed, 464 insertions(+) create mode 100644 src/admin/paths/admin@mileage_rates@bulk.yaml create mode 100644 src/admin/paths/admin@mileage_rates@delete@bulk.yaml create mode 100644 src/admin/paths/admin@mileage_rates@delete_summary@bulk.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index cf9d79895..c997bff43 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -1855,6 +1855,210 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/mileage_rates/bulk: + post: + operationId: mileage_rates_bulk_post + tags: + - Mileage Rates + security: + - oauth2: + - '*' + summary: Create or update mileage rates in bulk + description: | + Create or update mileage rates in bulk. The response is an empty object; re-fetch + `GET /admin/mileage_rates` after a successful request when the saved rows are needed. + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/mileage_rate_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '#/components/schemas/bulk_error' + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + /admin/mileage_rates/delete/bulk: + post: + tags: + - Mileage Rates + security: + - oauth2: + - '*' + summary: Delete mileage rates + description: | + Deletes unused mileage rates. If any supplied mileage rate is used by an expense, + the request fails without deleting any rates. A maximum of 200 unique mileage rate + IDs can be processed. Repeated IDs are deduplicated in first-seen order before the + limit is enforced. + operationId: mileage_rates_delete_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/mileage_rate_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + examples: + limit_exceeded: + summary: More than 200 unique mileage rate IDs supplied + value: + message: Cannot perform action for more than 200 mileage rates at once. + data: null + error: InvalidUsage + dependency_blocked: + summary: A mileage rate is used by an expense + value: + message: Can not delete mileage rate(s) used in other resources like expense. + data: null + error: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + /admin/mileage_rates/delete_summary/bulk: + post: + tags: + - Mileage Rates + security: + - oauth2: + - '*' + summary: Create delete summary for mileage rates + description: | + Returns how many of the supplied mileage rates can be deleted and lists those rates. + A maximum of 200 unique mileage rate IDs can be processed. Repeated IDs are + deduplicated in first-seen order before the limit is enforced. + operationId: mileage_rates_delete_summary_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/mileage_rate_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/mileage_rate_delete_summary_out' + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + example: Cannot perform action for more than 200 mileage rates at once. + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /admin/levels: get: tags: @@ -16565,6 +16769,33 @@ components: $ref: '#/components/schemas/is_enabled' code: $ref: '#/components/schemas/code' + mileage_rate_in_only_id: + type: object + required: + - id + additionalProperties: false + properties: + id: + $ref: '#/components/schemas/id_integer' + mileage_rate_delete_summary_out: + type: object + additionalProperties: false + properties: + data: + type: object + properties: + delete_count: + type: integer + description: Count of mileage rates that could be deleted from input mileage rates. + example: 2 + mileage_rates: + type: array + description: Mileage rates that could be deleted. + example: + - id: 9080 + - id: 9081 + items: + $ref: '#/components/schemas/mileage_rate_in_only_id' level_out: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 578720bb0..826738fcc 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -195,6 +195,12 @@ paths: $ref: paths/admin@departments.yaml /admin/mileage_rates: $ref: paths/admin@mileage_rates.yaml + /admin/mileage_rates/bulk: + $ref: paths/admin@mileage_rates@bulk.yaml + /admin/mileage_rates/delete/bulk: + $ref: paths/admin@mileage_rates@delete@bulk.yaml + /admin/mileage_rates/delete_summary/bulk: + $ref: paths/admin@mileage_rates@delete_summary@bulk.yaml /admin/levels: $ref: paths/admin@levels.yaml /admin/employees: diff --git a/src/admin/paths/admin@mileage_rates@bulk.yaml b/src/admin/paths/admin@mileage_rates@bulk.yaml new file mode 100644 index 000000000..63dc555fd --- /dev/null +++ b/src/admin/paths/admin@mileage_rates@bulk.yaml @@ -0,0 +1,62 @@ +post: + operationId: mileage_rates_bulk_post + tags: + - Mileage Rates + security: + - oauth2: ['*'] + summary: Create or update mileage rates in bulk + description: | + Create or update mileage rates in bulk. The response is an empty object; re-fetch + `GET /admin/mileage_rates` after a successful request when the saved rows are needed. + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: ../../components/schemas/mileage_rate.yaml#/mileage_rate_in + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: ../../components/schemas/bulk_error.yaml + - type: object + properties: + error: + type: string + nullable: true + message: + type: string + nullable: true + data: + type: object + nullable: true + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: ../../components/schemas/401.yaml + '403': + description: Forbidden + content: + application/json: + schema: + $ref: ../../components/schemas/403.yaml diff --git a/src/admin/paths/admin@mileage_rates@delete@bulk.yaml b/src/admin/paths/admin@mileage_rates@delete@bulk.yaml new file mode 100644 index 000000000..9b692c129 --- /dev/null +++ b/src/admin/paths/admin@mileage_rates@delete@bulk.yaml @@ -0,0 +1,75 @@ +post: + tags: + - Mileage Rates + security: + - oauth2: ['*'] + summary: Delete mileage rates + description: | + Deletes unused mileage rates. If any supplied mileage rate is used by an expense, + the request fails without deleting any rates. A maximum of 200 unique mileage rate + IDs can be processed. Repeated IDs are deduplicated in first-seen order before the + limit is enforced. + operationId: mileage_rates_delete_bulk_post + requestBody: + required: True + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: '../../components/schemas/mileage_rate.yaml#/mileage_rate_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + examples: + limit_exceeded: + summary: More than 200 unique mileage rate IDs supplied + value: + message: Cannot perform action for more than 200 mileage rates at once. + data: null + error: InvalidUsage + dependency_blocked: + summary: A mileage rate is used by an expense + value: + message: Can not delete mileage rate(s) used in other resources like expense. + data: null + error: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: "../../components/schemas/401.yaml" + '403': + description: Forbidden + content: + application/json: + schema: + $ref: "../../components/schemas/403.yaml" diff --git a/src/admin/paths/admin@mileage_rates@delete_summary@bulk.yaml b/src/admin/paths/admin@mileage_rates@delete_summary@bulk.yaml new file mode 100644 index 000000000..87c2540a0 --- /dev/null +++ b/src/admin/paths/admin@mileage_rates@delete_summary@bulk.yaml @@ -0,0 +1,61 @@ +post: + tags: + - Mileage Rates + security: + - oauth2: ['*'] + summary: Create delete summary for mileage rates + description: | + Returns how many of the supplied mileage rates can be deleted and lists those rates. + A maximum of 200 unique mileage rate IDs can be processed. Repeated IDs are + deduplicated in first-seen order before the limit is enforced. + operationId: mileage_rates_delete_summary_bulk_post + requestBody: + required: True + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: '../../components/schemas/mileage_rate.yaml#/mileage_rate_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '../../components/schemas/mileage_rate.yaml#/mileage_rate_delete_summary_out' + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + example: Cannot perform action for more than 200 mileage rates at once. + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: "../../components/schemas/401.yaml" + '403': + description: Forbidden + content: + application/json: + schema: + $ref: "../../components/schemas/403.yaml" diff --git a/src/components/schemas/mileage_rate.yaml b/src/components/schemas/mileage_rate.yaml index 5739cba1f..94236a01c 100644 --- a/src/components/schemas/mileage_rate.yaml +++ b/src/components/schemas/mileage_rate.yaml @@ -133,3 +133,32 @@ mileage_rate_in: $ref: ./fields.yaml#/is_enabled code: $ref: ./fields.yaml#/code + +mileage_rate_in_only_id: + type: object + required: + - id + additionalProperties: False + properties: + id: + $ref: './fields.yaml#/id_integer' + +mileage_rate_delete_summary_out: + type: object + additionalProperties: False + properties: + data: + type: object + properties: + delete_count: + type: integer + description: Count of mileage rates that could be deleted from input mileage rates. + example: 2 + mileage_rates: + type: array + description: Mileage rates that could be deleted. + example: + - id: 9080 + - id: 9081 + items: + $ref: './mileage_rate.yaml#/mileage_rate_in_only_id' From 06995da33cf0716cadbd680389efc1964dcc5129 Mon Sep 17 00:00:00 2001 From: Sumit Kumar Date: Tue, 21 Jul 2026 18:49:14 +0530 Subject: [PATCH 075/107] Added fix for failing test case by including null in contains_from_list_operator (#845) --- reference/admin.yaml | 1 + reference/spender.yaml | 1 + src/components/schemas/fields.yaml | 1 + 3 files changed, 3 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index c997bff43..f81bc7c76 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -29516,6 +29516,7 @@ components: enum: - CONTAINS_ANY_FROM_LIST - CONTAINS_NONE_FROM_LIST + - null description: | Value signifying the operator for matching values from a list field. example: CONTAINS_ANY_FROM_LIST diff --git a/reference/spender.yaml b/reference/spender.yaml index f08fe44e0..2d03c8e0f 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -16353,6 +16353,7 @@ components: enum: - CONTAINS_ANY_FROM_LIST - CONTAINS_NONE_FROM_LIST + - null description: | Value signifying the operator for matching values from a list field. example: CONTAINS_ANY_FROM_LIST diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index 9098ffd82..246ff043c 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -352,6 +352,7 @@ contains_from_list_operator: enum: - CONTAINS_ANY_FROM_LIST - CONTAINS_NONE_FROM_LIST + - null description: > Value signifying the operator for matching values from a list field. example: CONTAINS_ANY_FROM_LIST From 1030c7432e83500307555e83ebde1d0fc48701cb Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 22 Jul 2026 16:07:33 +0530 Subject: [PATCH 076/107] fix: Fix required OpenAPI drift for Exports (#818) * Fix required OpenAPI drift for Exports * Auto generate API docs * code comment fixes * Auto generate API docs * fix tests * Auto generate API docs * wip * Auto generate API docs * fix tests * Auto generate API docs * fix inconsitency tests * Auto generate API docs * fix failing tests * Auto generate API docs * fix failing tests * Auto generate API docs --- reference/admin.yaml | 158 +++++++++++++++++- reference/approver.yaml | 62 ++++++- reference/spender.yaml | 62 ++++++- src/components/schemas/accounting_export.yaml | 11 ++ .../schemas/accounting_export_lineitem.yaml | 9 + ...rd_transactions_export_configurations.yaml | 30 +++- .../corporate_card_transactions_exports.yaml | 13 ++ .../employees_export_configurations.yaml | 28 +++- src/components/schemas/employees_exports.yaml | 5 + .../expenses_export_configurations.yaml | 19 ++- src/components/schemas/expenses_exports.yaml | 3 + .../reports_export_configurations.yaml | 17 +- src/components/schemas/reports_exports.yaml | 23 +++ 13 files changed, 424 insertions(+), 16 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index f81bc7c76..87e16eb32 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -17622,6 +17622,9 @@ components: $ref: '#/components/schemas/expense_duplicate_sets_out' employees_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -17671,6 +17674,8 @@ components: default: true separate_line_items_entry: type: object + required: + - enabled properties: enabled: type: boolean @@ -18265,6 +18270,8 @@ components: Total liability payable to the employee. employees_export_configuration_separate_line_items_entry: type: object + required: + - is_enabled properties: is_enabled: type: boolean @@ -18286,6 +18293,10 @@ components: Configure which columns to show for credit entries only. example: [] employees_export_configuration_column: + required: + - name + - formula + - is_custom type: object properties: name: @@ -18323,6 +18334,10 @@ components: example: GET(department, name) employees_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -18344,6 +18359,11 @@ components: example: desc employees_export_configuration_config: type: object + required: + - is_header_visible + - separate_line_items_entry + - columns + - date_format additionalProperties: true properties: is_header_visible: @@ -18377,6 +18397,17 @@ components: employees_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: @@ -18473,9 +18504,9 @@ components: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature employees_export_configuration_in_only_id: type: object required: @@ -18742,6 +18773,17 @@ components: accounting_export_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - file_ids + - exported_at + - description + - url + - client_id properties: id: allOf: @@ -18816,6 +18858,15 @@ components: accounting_export_lineitem_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - object_id + - object_type + - reference + - accounting_export_id properties: id: $ref: '#/components/schemas/id_string' @@ -21057,6 +21108,9 @@ components: example: state=eq.PAID expenses_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -21269,6 +21323,10 @@ components: example: GET(merchant) expenses_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -21292,7 +21350,7 @@ components: type: object additionalProperties: true properties: - is_column_header_included: + is_header_visible: type: boolean description: | Whether to include column headers in the export file. Required for CSV and EXCEL export types. @@ -21328,6 +21386,17 @@ components: expenses_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: @@ -21426,9 +21495,9 @@ components: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature expenses_export_configuration_in_only_id: type: object required: @@ -23824,6 +23893,9 @@ components: $ref: '#/components/schemas/id_string' reports_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -23849,6 +23921,8 @@ components: reports_export_config: type: object additionalProperties: true + required: + - type properties: type: type: string @@ -23871,6 +23945,10 @@ components: example: true separate_line_items_entry: type: object + required: + - enabled + - debit_entries_only + - credit_entries_only properties: enabled: type: boolean @@ -23899,6 +23977,9 @@ components: type: array items: type: object + required: + - name + - formula properties: name: type: string @@ -23915,6 +23996,17 @@ components: reports_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - file_id + - state + - query_params + - notify_emails + - config properties: created_at: $ref: '#/components/schemas/created_at' @@ -24042,6 +24134,10 @@ components: example: GET(employee, user, full_name) reports_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -24096,6 +24192,17 @@ components: reports_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: @@ -24194,9 +24301,9 @@ components: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature reports_export_configuration_in_only_id: type: object required: @@ -27682,6 +27789,9 @@ components: - metadata corporate_card_transactions_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -27707,6 +27817,11 @@ components: corporate_card_transactions_export_config: type: object additionalProperties: true + required: + - type + - is_header_visible + - columns + - separate_line_items_entry properties: type: type: string @@ -27723,6 +27838,8 @@ components: example: true separate_line_items_entry: type: object + required: + - enabled properties: enabled: type: boolean @@ -27751,6 +27868,9 @@ components: type: array items: type: object + required: + - name + - formula properties: name: type: string @@ -34811,6 +34931,8 @@ components: example: false corporate_card_transactions_export_configuration_separate_line_items_entry: type: object + required: + - is_enabled properties: is_enabled: type: boolean @@ -34833,6 +34955,12 @@ components: example: [] corporate_card_transactions_export_configuration_column: type: object + required: + - name + - formula + - is_custom + - field_name + - formula_text properties: name: type: string @@ -34868,6 +34996,10 @@ components: example: GET(merchant) corporate_card_transactions_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -34889,6 +35021,11 @@ components: example: desc corporate_card_transactions_export_configuration_config: type: object + required: + - is_header_visible + - separate_line_items_entry + - columns + - date_format additionalProperties: true properties: is_header_visible: @@ -34923,6 +35060,17 @@ components: corporate_card_transactions_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: @@ -35009,9 +35157,9 @@ components: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature corporate_card_transactions_export_configuration_in_only_id: type: object required: diff --git a/reference/approver.yaml b/reference/approver.yaml index bbf63139a..bc9823a38 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -5010,6 +5010,9 @@ components: example: state=eq.PAID reports_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -5035,6 +5038,8 @@ components: reports_export_config: type: object additionalProperties: true + required: + - type properties: type: type: string @@ -5057,6 +5062,10 @@ components: example: true separate_line_items_entry: type: object + required: + - enabled + - debit_entries_only + - credit_entries_only properties: enabled: type: boolean @@ -5085,6 +5094,9 @@ components: type: array items: type: object + required: + - name + - formula properties: name: type: string @@ -5101,6 +5113,17 @@ components: reports_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - file_id + - state + - query_params + - notify_emails + - config properties: created_at: $ref: '#/components/schemas/created_at' @@ -9607,6 +9630,9 @@ components: example: exfilumWHrlPf7K expenses_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -11231,6 +11257,10 @@ components: example: GET(merchant) expenses_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -11254,7 +11284,7 @@ components: type: object additionalProperties: true properties: - is_column_header_included: + is_header_visible: type: boolean description: | Whether to include column headers in the export file. Required for CSV and EXCEL export types. @@ -11290,6 +11320,17 @@ components: expenses_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: @@ -11388,9 +11429,9 @@ components: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature expenses_export_configuration_in_only_id: type: object required: @@ -11458,6 +11499,10 @@ components: example: GET(employee, user, full_name) reports_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -11512,6 +11557,17 @@ components: reports_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: @@ -11610,9 +11666,9 @@ components: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature reports_export_configuration_in_only_id: type: object required: diff --git a/reference/spender.yaml b/reference/spender.yaml index 2d03c8e0f..27f452215 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -11953,6 +11953,9 @@ components: example: state=eq.PAID reports_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -11978,6 +11981,8 @@ components: reports_export_config: type: object additionalProperties: true + required: + - type properties: type: type: string @@ -12000,6 +12005,10 @@ components: example: true separate_line_items_entry: type: object + required: + - enabled + - debit_entries_only + - credit_entries_only properties: enabled: type: boolean @@ -12028,6 +12037,9 @@ components: type: array items: type: object + required: + - name + - formula properties: name: type: string @@ -12044,6 +12056,17 @@ components: reports_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - file_id + - state + - query_params + - notify_emails + - config properties: created_at: $ref: '#/components/schemas/created_at' @@ -18145,6 +18168,9 @@ components: example: exfilumWHrlPf7K expenses_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -19769,6 +19795,10 @@ components: example: GET(merchant) expenses_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -19792,7 +19822,7 @@ components: type: object additionalProperties: true properties: - is_column_header_included: + is_header_visible: type: boolean description: | Whether to include column headers in the export file. Required for CSV and EXCEL export types. @@ -19828,6 +19858,17 @@ components: expenses_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: @@ -19926,9 +19967,9 @@ components: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature expenses_export_configuration_in_only_id: type: object required: @@ -19996,6 +20037,10 @@ components: example: GET(employee, user, full_name) reports_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -20050,6 +20095,17 @@ components: reports_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: @@ -20148,9 +20204,9 @@ components: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature reports_export_configuration_in_only_id: type: object required: diff --git a/src/components/schemas/accounting_export.yaml b/src/components/schemas/accounting_export.yaml index 88f59fd72..2d5af49f3 100644 --- a/src/components/schemas/accounting_export.yaml +++ b/src/components/schemas/accounting_export.yaml @@ -1,6 +1,17 @@ accounting_export_out: type: object additionalProperties: False + required: + - created_at + - updated_at + - id + - org_id + - name + - file_ids + - exported_at + - description + - url + - client_id properties: id: allOf: diff --git a/src/components/schemas/accounting_export_lineitem.yaml b/src/components/schemas/accounting_export_lineitem.yaml index 72b43a549..ffb232950 100644 --- a/src/components/schemas/accounting_export_lineitem.yaml +++ b/src/components/schemas/accounting_export_lineitem.yaml @@ -1,6 +1,15 @@ accounting_export_lineitem_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - object_id + - object_type + - reference + - accounting_export_id properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/corporate_card_transactions_export_configurations.yaml b/src/components/schemas/corporate_card_transactions_export_configurations.yaml index 74a884d12..e08966f4d 100644 --- a/src/components/schemas/corporate_card_transactions_export_configurations.yaml +++ b/src/components/schemas/corporate_card_transactions_export_configurations.yaml @@ -1,5 +1,11 @@ corporate_card_transactions_export_configuration_column: type: object + required: + - name + - formula + - is_custom + - field_name + - formula_text properties: name: type: string @@ -37,6 +43,10 @@ corporate_card_transactions_export_configuration_column: corporate_card_transactions_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -60,6 +70,8 @@ corporate_card_transactions_export_configuration_sort_column: corporate_card_transactions_export_configuration_separate_line_items_entry: type: object + required: + - is_enabled properties: is_enabled: type: boolean @@ -84,6 +96,11 @@ corporate_card_transactions_export_configuration_separate_line_items_entry: corporate_card_transactions_export_configuration_config: type: object + required: + - is_header_visible + - separate_line_items_entry + - columns + - date_format additionalProperties: true properties: is_header_visible: @@ -159,9 +176,9 @@ corporate_card_transactions_export_configuration_in: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature corporate_card_transactions_export_configuration_in_only_id: @@ -177,6 +194,17 @@ corporate_card_transactions_export_configuration_in_only_id: corporate_card_transactions_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: diff --git a/src/components/schemas/corporate_card_transactions_exports.yaml b/src/components/schemas/corporate_card_transactions_exports.yaml index 72cd7ea49..8bdb03fb5 100644 --- a/src/components/schemas/corporate_card_transactions_exports.yaml +++ b/src/components/schemas/corporate_card_transactions_exports.yaml @@ -1,5 +1,8 @@ corporate_card_transactions_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -26,6 +29,11 @@ corporate_card_transactions_export_config_column_formula: corporate_card_transactions_export_config: type: object additionalProperties: true + required: + - type + - is_header_visible + - columns + - separate_line_items_entry properties: type: type: string @@ -42,6 +50,8 @@ corporate_card_transactions_export_config: example: true separate_line_items_entry: type: object + required: + - enabled properties: enabled: type: boolean @@ -68,6 +78,9 @@ corporate_card_transactions_export_config: type: array items: type: object + required: + - name + - formula properties: name: type: string diff --git a/src/components/schemas/employees_export_configurations.yaml b/src/components/schemas/employees_export_configurations.yaml index 99bd28463..cbf4e6bd3 100644 --- a/src/components/schemas/employees_export_configurations.yaml +++ b/src/components/schemas/employees_export_configurations.yaml @@ -1,4 +1,8 @@ employees_export_configuration_column: + required: + - name + - formula + - is_custom type: object properties: name: @@ -38,6 +42,10 @@ employees_export_configuration_column: employees_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -61,6 +69,8 @@ employees_export_configuration_sort_column: employees_export_configuration_separate_line_items_entry: type: object + required: + - is_enabled properties: is_enabled: type: boolean @@ -85,6 +95,11 @@ employees_export_configuration_separate_line_items_entry: employees_export_configuration_config: type: object + required: + - is_header_visible + - separate_line_items_entry + - columns + - date_format additionalProperties: true properties: is_header_visible: @@ -159,9 +174,9 @@ employees_export_configuration_in: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature employees_export_configuration_in_only_id: @@ -177,6 +192,17 @@ employees_export_configuration_in_only_id: employees_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: diff --git a/src/components/schemas/employees_exports.yaml b/src/components/schemas/employees_exports.yaml index 5e9c24369..a5327c6cb 100644 --- a/src/components/schemas/employees_exports.yaml +++ b/src/components/schemas/employees_exports.yaml @@ -1,5 +1,8 @@ employees_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -49,6 +52,8 @@ employees_export_config: default: true separate_line_items_entry: type: object + required: + - enabled properties: enabled: type: boolean diff --git a/src/components/schemas/expenses_export_configurations.yaml b/src/components/schemas/expenses_export_configurations.yaml index 1a9ccec3a..2a5912f49 100644 --- a/src/components/schemas/expenses_export_configurations.yaml +++ b/src/components/schemas/expenses_export_configurations.yaml @@ -69,6 +69,10 @@ expenses_export_pdf_configuration_column: expenses_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -118,7 +122,7 @@ expenses_export_configuration_config: type: object additionalProperties: true properties: - is_column_header_included: + is_header_visible: type: boolean description: | Whether to include column headers in the export file. Required for CSV and EXCEL export types. @@ -223,9 +227,9 @@ expenses_export_configuration_in: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature expenses_export_configuration_in_only_id: @@ -241,6 +245,17 @@ expenses_export_configuration_in_only_id: expenses_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: diff --git a/src/components/schemas/expenses_exports.yaml b/src/components/schemas/expenses_exports.yaml index 562138553..58ddd91e7 100644 --- a/src/components/schemas/expenses_exports.yaml +++ b/src/components/schemas/expenses_exports.yaml @@ -1,5 +1,8 @@ expenses_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string diff --git a/src/components/schemas/reports_export_configurations.yaml b/src/components/schemas/reports_export_configurations.yaml index 08d5ad76a..5b82e72d0 100644 --- a/src/components/schemas/reports_export_configurations.yaml +++ b/src/components/schemas/reports_export_configurations.yaml @@ -37,6 +37,10 @@ reports_export_configuration_column: reports_export_configuration_sort_column: type: object + required: + - display_name + - field_name + - direction properties: display_name: type: string @@ -159,9 +163,9 @@ reports_export_configuration_in: Configuration details for the export including columns, sorting, and formatting options. required: - name - - query_string - type - config + - sub_feature reports_export_configuration_in_only_id: @@ -177,6 +181,17 @@ reports_export_configuration_in_only_id: reports_export_configuration_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - name + - query_string + - sub_feature + - config + - type + - org_id + - user_id properties: id: allOf: diff --git a/src/components/schemas/reports_exports.yaml b/src/components/schemas/reports_exports.yaml index 593542788..7c6145a6b 100644 --- a/src/components/schemas/reports_exports.yaml +++ b/src/components/schemas/reports_exports.yaml @@ -1,5 +1,8 @@ reports_export_config_column_formula: type: object + required: + - function + - parameters properties: function: type: string @@ -26,6 +29,8 @@ reports_export_config_column_formula: reports_export_config: type: object additionalProperties: true + required: + - type properties: type: type: string @@ -48,6 +53,10 @@ reports_export_config: example: true separate_line_items_entry: type: object + required: + - enabled + - debit_entries_only + - credit_entries_only properties: enabled: type: boolean @@ -74,6 +83,9 @@ reports_export_config: type: array items: type: object + required: + - name + - formula properties: name: type: string @@ -119,6 +131,17 @@ reports_exports_in: reports_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - file_id + - state + - query_params + - notify_emails + - config properties: created_at: $ref: './fields.yaml#/created_at' From 9fe3702ad106174575036677219437d2f860cb3b Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 22 Jul 2026 16:16:32 +0530 Subject: [PATCH 077/107] fix:Fix required OpenAPI drift for Reimbursement (#829) * Fix required OpenAPI drift for Reimbursement * Auto generate API docs --- reference/admin.yaml | 20 ++++++++++++++++++++ src/components/schemas/reimbursement.yaml | 20 ++++++++++++++++++++ 2 files changed, 40 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 87e16eb32..a8dc74734 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -28467,6 +28467,24 @@ components: reimbursement_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - creator_user_id + - user_id + - org_id + - reimbursement_number + - amount + - currency + - purpose + - mode + - is_paid + - paid_at + - is_exported + - code + - employee_id + - employee properties: id: type: string @@ -28528,6 +28546,8 @@ components: $ref: '#/components/schemas/employee_out_embed' reimbursement_in_minimal: type: object + required: + - id properties: id: type: string diff --git a/src/components/schemas/reimbursement.yaml b/src/components/schemas/reimbursement.yaml index 91eba1bba..c46df8912 100644 --- a/src/components/schemas/reimbursement.yaml +++ b/src/components/schemas/reimbursement.yaml @@ -1,6 +1,24 @@ reimbursement_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - creator_user_id + - user_id + - org_id + - reimbursement_number + - amount + - currency + - purpose + - mode + - is_paid + - paid_at + - is_exported + - code + - employee_id + - employee properties: id: type: string @@ -90,6 +108,8 @@ reimbursement_in: reimbursement_in_minimal: type: object + required: + - id properties: id: type: string From b47d87be90af8b23d4555a72165fe1e9d61c2d13 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 22 Jul 2026 16:55:33 +0530 Subject: [PATCH 078/107] fix: Fix required OpenAPI drift for Advances (#811) * Fix required OpenAPI drift for Advances * Auto generate API docs * code review changes * Auto generate API docs * code comments fixes * wip * Auto generate API docs --- reference/admin.yaml | 130 +++++++++++++++++- reference/approver.yaml | 58 +++++++- reference/spender.yaml | 102 +++++++++++++- src/admin/paths/admin@advance_requests.yaml | 2 +- .../paths/admin@advance_requests@submit.yaml | 4 +- .../approver@advance_requests@submit.yaml | 4 +- src/components/schemas/advance.yaml | 38 +++++ src/components/schemas/advance_refund.yaml | 20 +++ src/components/schemas/advance_request.yaml | 76 +++++++++- src/components/schemas/advance_wallet.yaml | 8 ++ .../paths/spender@advance_requests.yaml | 2 +- .../spender@advance_requests@submit.yaml | 4 +- 12 files changed, 426 insertions(+), 22 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index a8dc74734..fd89d933e 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -4930,7 +4930,7 @@ paths: - data properties: data: - $ref: '#/components/schemas/advance_request_in' + $ref: '#/components/schemas/admin_advance_request_in' responses: '200': description: OK @@ -14794,7 +14794,7 @@ paths: - data properties: data: - $ref: '#/components/schemas/advance_request_in' + $ref: '#/components/schemas/advance_request_submit_in' responses: '200': description: OK @@ -21737,6 +21737,11 @@ components: type: object description: | Advance request custom field + required: + - id + - name + - type + - value properties: name: type: string @@ -21870,6 +21875,34 @@ components: advance_request_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - user_id + - org_id + - project_id + - advance_id + - seq_num + - currency + - amount + - last_approved_at + - notes + - purpose + - source + - state + - custom_fields + - user + - project + - advance + - approvals + - is_exported + - employee_id + - employee + - code + - comments + - file_ids + - files properties: id: allOf: @@ -21981,7 +22014,7 @@ components: type: array items: $ref: '#/components/schemas/file_out_embed' - advance_request_in: + advance_request_in_base: type: object properties: id: @@ -22019,6 +22052,12 @@ components: $ref: '#/components/schemas/fk_integer' custom_fields: $ref: '#/components/schemas/advance_request_custom_fields' + admin_advance_request_in: + allOf: + - $ref: '#/components/schemas/advance_request_in_base' + - type: object + required: + - id advance_requests_stats_in: properties: query_params: @@ -22217,6 +22256,36 @@ components: advance_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - advance_request_id + - user_id + - org_id + - project_id + - seq_num + - amount + - issued_at + - card_number + - currency + - custom_fields + - foreign_amount + - foreign_currency + - payment_mode + - purpose + - code + - source + - advance_account_id + - advance_wallet_id + - is_exported + - last_exported_at + - user + - project + - employee_id + - employee + - creator_user + - advance_request properties: id: allOf: @@ -22329,6 +22398,14 @@ components: - currency - amount - payment_mode + - advance_request_id + - project_id + - card_number + - custom_fields + - foreign_amount + - foreign_currency + - purpose + - code properties: user_id: type: string @@ -22418,6 +22495,14 @@ components: advance_wallet_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - currency + - balance_amount properties: id: allOf: @@ -22448,6 +22533,26 @@ components: advance_refund_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - collector_user_id + - refunded_at + - currency + - amount + - foreign_currency + - foreign_amount + - payment_mode + - code + - notes + - source + - card_number + - advance_wallet_id + - employee_id + - employee properties: created_at: $ref: '#/components/schemas/created_at' @@ -34581,7 +34686,6 @@ components: required: - id - approver_email - - comment properties: id: $ref: '#/components/schemas/id_string' @@ -34625,9 +34729,27 @@ components: type: string description: Reason for sending the advance request back to the spender example: Please provide additional documentation + advance_request_submit_in: + allOf: + - $ref: '#/components/schemas/advance_request_in_base' + - type: object + required: + - currency + - amount advance_request_custom_field_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - type + - options + - is_mandatory + - is_enabled + - placeholder properties: id: type: integer diff --git a/reference/approver.yaml b/reference/approver.yaml index bc9823a38..5897639bd 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -3258,7 +3258,7 @@ paths: - data properties: data: - $ref: '#/components/schemas/advance_request_in' + $ref: '#/components/schemas/advance_request_submit_in' responses: '200': description: OK @@ -7817,6 +7817,11 @@ components: type: object description: | Advance request custom field + required: + - id + - name + - type + - value properties: name: type: string @@ -7967,6 +7972,34 @@ components: advance_request_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - user_id + - org_id + - project_id + - advance_id + - seq_num + - currency + - amount + - last_approved_at + - notes + - purpose + - source + - state + - custom_fields + - user + - project + - advance + - approvals + - is_exported + - employee_id + - employee + - code + - comments + - file_ids + - files properties: id: allOf: @@ -8079,6 +8112,8 @@ components: items: $ref: '#/components/schemas/file_out_embed' advance_requests_approver_stats_in: + required: + - query_params properties: query_params: description: | @@ -10853,7 +10888,6 @@ components: required: - id - approver_email - - comment properties: id: $ref: '#/components/schemas/id_string' @@ -10907,7 +10941,7 @@ components: type: string description: Reason for sending the advance request back to the spender example: Please provide additional documentation - advance_request_in: + advance_request_in_base: type: object properties: id: @@ -10945,9 +10979,27 @@ components: $ref: '#/components/schemas/fk_integer' custom_fields: $ref: '#/components/schemas/advance_request_custom_fields' + advance_request_submit_in: + allOf: + - $ref: '#/components/schemas/advance_request_in_base' + - type: object + required: + - currency + - amount advance_request_custom_field_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - type + - options + - is_mandatory + - is_enabled + - placeholder properties: id: type: integer diff --git a/reference/spender.yaml b/reference/spender.yaml index 27f452215..eeb623078 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -2187,7 +2187,7 @@ paths: - data properties: data: - $ref: '#/components/schemas/advance_request_in' + $ref: '#/components/schemas/spender_advance_request_in' responses: '200': description: OK @@ -6218,7 +6218,7 @@ paths: - data properties: data: - $ref: '#/components/schemas/advance_request_in' + $ref: '#/components/schemas/advance_request_submit_in' responses: '200': description: OK @@ -12166,6 +12166,11 @@ components: type: object description: | Advance request custom field + required: + - id + - name + - type + - value properties: name: type: string @@ -12316,6 +12321,34 @@ components: advance_request_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - user_id + - org_id + - project_id + - advance_id + - seq_num + - currency + - amount + - last_approved_at + - notes + - purpose + - source + - state + - custom_fields + - user + - project + - advance + - approvals + - is_exported + - employee_id + - employee + - code + - comments + - file_ids + - files properties: id: allOf: @@ -12427,7 +12460,7 @@ components: type: array items: $ref: '#/components/schemas/file_out_embed' - advance_request_in: + advance_request_in_base: type: object properties: id: @@ -12465,6 +12498,13 @@ components: $ref: '#/components/schemas/fk_integer' custom_fields: $ref: '#/components/schemas/advance_request_custom_fields' + spender_advance_request_in: + allOf: + - $ref: '#/components/schemas/advance_request_in_base' + - type: object + required: + - currency + - amount advance_requests_stats_in: properties: query_params: @@ -12575,6 +12615,36 @@ components: advance_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - advance_request_id + - user_id + - org_id + - project_id + - seq_num + - amount + - issued_at + - card_number + - currency + - custom_fields + - foreign_amount + - foreign_currency + - payment_mode + - purpose + - code + - source + - advance_account_id + - advance_wallet_id + - is_exported + - last_exported_at + - user + - project + - employee_id + - employee + - creator_user + - advance_request properties: id: allOf: @@ -12706,6 +12776,14 @@ components: advance_wallet_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - currency + - balance_amount properties: id: allOf: @@ -19150,6 +19228,13 @@ components: type: boolean example: true description: This field contains a boolean value indicating if a bank account has been added to the organisation. + advance_request_submit_in: + allOf: + - $ref: '#/components/schemas/advance_request_in_base' + - type: object + required: + - currency + - amount advance_request_permissions_in: type: object additionalProperties: false @@ -19326,6 +19411,17 @@ components: advance_request_custom_field_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - type + - options + - is_mandatory + - is_enabled + - placeholder properties: id: type: integer diff --git a/src/admin/paths/admin@advance_requests.yaml b/src/admin/paths/admin@advance_requests.yaml index 6ec146b02..5206a515c 100644 --- a/src/admin/paths/admin@advance_requests.yaml +++ b/src/admin/paths/admin@advance_requests.yaml @@ -57,7 +57,7 @@ post: - data properties: data: - $ref: '../../components/schemas/advance_request.yaml#/advance_request_in' + $ref: '../../components/schemas/advance_request.yaml#/admin_advance_request_in' responses: '200': description: OK diff --git a/src/admin/paths/admin@advance_requests@submit.yaml b/src/admin/paths/admin@advance_requests@submit.yaml index 8abfe8cf7..f511c601e 100644 --- a/src/admin/paths/admin@advance_requests@submit.yaml +++ b/src/admin/paths/admin@advance_requests@submit.yaml @@ -16,7 +16,7 @@ post: - data properties: data: - $ref: '../../components/schemas/advance_request.yaml#/advance_request_in' + $ref: '../../components/schemas/advance_request.yaml#/advance_request_submit_in' responses: '200': description: OK @@ -61,4 +61,4 @@ post: message: type: string description: | - This error means the requested resource was not found or the requester doesn't have sufficient access. \ No newline at end of file + This error means the requested resource was not found or the requester doesn't have sufficient access. diff --git a/src/approver/paths/approver@advance_requests@submit.yaml b/src/approver/paths/approver@advance_requests@submit.yaml index 8abfe8cf7..f511c601e 100644 --- a/src/approver/paths/approver@advance_requests@submit.yaml +++ b/src/approver/paths/approver@advance_requests@submit.yaml @@ -16,7 +16,7 @@ post: - data properties: data: - $ref: '../../components/schemas/advance_request.yaml#/advance_request_in' + $ref: '../../components/schemas/advance_request.yaml#/advance_request_submit_in' responses: '200': description: OK @@ -61,4 +61,4 @@ post: message: type: string description: | - This error means the requested resource was not found or the requester doesn't have sufficient access. \ No newline at end of file + This error means the requested resource was not found or the requester doesn't have sufficient access. diff --git a/src/components/schemas/advance.yaml b/src/components/schemas/advance.yaml index 982fcd3dc..0aaf5fc55 100644 --- a/src/components/schemas/advance.yaml +++ b/src/components/schemas/advance.yaml @@ -1,6 +1,36 @@ advance_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - advance_request_id + - user_id + - org_id + - project_id + - seq_num + - amount + - issued_at + - card_number + - currency + - custom_fields + - foreign_amount + - foreign_currency + - payment_mode + - purpose + - code + - source + - advance_account_id + - advance_wallet_id + - is_exported + - last_exported_at + - user + - project + - employee_id + - employee + - creator_user + - advance_request properties: id: allOf: @@ -143,6 +173,14 @@ advance_in: - currency - amount - payment_mode + - advance_request_id + - project_id + - card_number + - custom_fields + - foreign_amount + - foreign_currency + - purpose + - code properties: user_id: type: string diff --git a/src/components/schemas/advance_refund.yaml b/src/components/schemas/advance_refund.yaml index 7dbcf1dca..5c533ba75 100644 --- a/src/components/schemas/advance_refund.yaml +++ b/src/components/schemas/advance_refund.yaml @@ -1,6 +1,26 @@ advance_refund_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - collector_user_id + - refunded_at + - currency + - amount + - foreign_currency + - foreign_amount + - payment_mode + - code + - notes + - source + - card_number + - advance_wallet_id + - employee_id + - employee properties: created_at: $ref: './fields.yaml#/created_at' diff --git a/src/components/schemas/advance_request.yaml b/src/components/schemas/advance_request.yaml index e70235364..5ca278569 100644 --- a/src/components/schemas/advance_request.yaml +++ b/src/components/schemas/advance_request.yaml @@ -1,6 +1,34 @@ advance_request_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - user_id + - org_id + - project_id + - advance_id + - seq_num + - currency + - amount + - last_approved_at + - notes + - purpose + - source + - state + - custom_fields + - user + - project + - advance + - approvals + - is_exported + - employee_id + - employee + - code + - comments + - file_ids + - files properties: id: allOf: @@ -113,7 +141,7 @@ advance_request_out: items: $ref: './file.yaml#/file_out_embed' -advance_request_in: +advance_request_in_base: type: object properties: id: @@ -125,7 +153,7 @@ advance_request_in: amount: $ref: './fields.yaml#/amount' code: - $ref: ./fields.yaml#/code + $ref: './fields.yaml#/code' notes: type: string nullable: true @@ -152,6 +180,29 @@ advance_request_in: custom_fields: $ref: '#/advance_request_custom_fields' +admin_advance_request_in: + allOf: + - $ref: '#/advance_request_in_base' + - type: object + required: + - id + +advance_request_submit_in: + allOf: + - $ref: '#/advance_request_in_base' + - type: object + required: + - currency + - amount + +spender_advance_request_in: + allOf: + - $ref: '#/advance_request_in_base' + - type: object + required: + - currency + - amount + advance_request_action_in: type: object additionalProperties: False @@ -277,6 +328,8 @@ advance_request_out_embed: example: 'AR/2020/10/T/95' advance_requests_approver_stats_in: + required: + - query_params properties: query_params: description: | @@ -497,7 +550,6 @@ advance_request_add_approver_in: required: - id - approver_email - - comment properties: id: $ref: './fields.yaml#/id_string' @@ -627,6 +679,17 @@ advance_request_custom_field_in: advance_request_custom_field_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - name + - type + - options + - is_mandatory + - is_enabled + - placeholder properties: id: type: integer @@ -688,6 +751,11 @@ advance_request_custom_field: type: object description: | Advance request custom field + required: + - id + - name + - type + - value properties: name: type: string @@ -749,4 +817,4 @@ advance_request_generate_file_urls_in: $ref: './fields.yaml#/id_string' description: List of file IDs to generate URLs for example: - - fiH717IpzaTG \ No newline at end of file + - fiH717IpzaTG diff --git a/src/components/schemas/advance_wallet.yaml b/src/components/schemas/advance_wallet.yaml index 8ac7f6865..72da46164 100644 --- a/src/components/schemas/advance_wallet.yaml +++ b/src/components/schemas/advance_wallet.yaml @@ -1,6 +1,14 @@ advance_wallet_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - currency + - balance_amount properties: id: allOf: diff --git a/src/spender/paths/spender@advance_requests.yaml b/src/spender/paths/spender@advance_requests.yaml index 5c8dff31a..d66d80cf0 100644 --- a/src/spender/paths/spender@advance_requests.yaml +++ b/src/spender/paths/spender@advance_requests.yaml @@ -57,7 +57,7 @@ post: - data properties: data: - $ref: '../../components/schemas/advance_request.yaml#/advance_request_in' + $ref: '../../components/schemas/advance_request.yaml#/spender_advance_request_in' responses: '200': description: OK diff --git a/src/spender/paths/spender@advance_requests@submit.yaml b/src/spender/paths/spender@advance_requests@submit.yaml index 8abfe8cf7..f511c601e 100644 --- a/src/spender/paths/spender@advance_requests@submit.yaml +++ b/src/spender/paths/spender@advance_requests@submit.yaml @@ -16,7 +16,7 @@ post: - data properties: data: - $ref: '../../components/schemas/advance_request.yaml#/advance_request_in' + $ref: '../../components/schemas/advance_request.yaml#/advance_request_submit_in' responses: '200': description: OK @@ -61,4 +61,4 @@ post: message: type: string description: | - This error means the requested resource was not found or the requester doesn't have sufficient access. \ No newline at end of file + This error means the requested resource was not found or the requester doesn't have sufficient access. From 26b9f5c8213dd0fcdb10262254777b6b99aeda94 Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Mon, 27 Jul 2026 12:48:30 +0530 Subject: [PATCH 079/107] feat: Add ignore_archived_cards field in create card transactions, summary, reconciliation summary and reconcile apis (#851) * feat: Add ignore_archived_cards field in create card transactions, summary, reconciliation summary and reconcile apis * Auto generate API docs * improvement * Auto generate API docs --------- Co-authored-by: Madan Gopal --- reference/admin.yaml | 175 ++++++++++++++++++++++--- src/components/schemas/statements.yaml | 147 ++++++++++++++++++++- 2 files changed, 296 insertions(+), 26 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index fd89d933e..1163ea566 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -31629,6 +31629,20 @@ components: - no_of_debit - no_of_credit - no_of_transactions + card_mapping_in: + type: array + items: + type: object + properties: + statement_card_number: + type: string + description: | + Card number from statement + example: xxx5-4543 + corporate_card_id: + allOf: + - $ref: '#/components/schemas/id_string' + example: bawownwrng summary_from_statement_in: type: object properties: @@ -31727,6 +31741,15 @@ components: This specifies list of statement line items to be ignored in the statement. example: - stlisfdfadssd + card_mapping: + $ref: '#/components/schemas/card_mapping_in' + ignore_archived_cards: + type: boolean + nullable: true + description: | + Controls how transactions associated with archived cards are handled during statement processing: + If true, transactions associated with archived cards are ignored. + If false, the archived cards are unarchived, and their associated transactions are processed. required: - id - statement_mapping @@ -31774,20 +31797,6 @@ components: If this period is created as bridging entry because of change in reconciliation type, then this field will indicate such change. example: STATEMENT_CYCLE_TO_CALENDAR_MONTH - card_mapping_in: - type: array - items: - type: object - properties: - statement_card_number: - type: string - description: | - Card number from statement - example: xxx5-4543 - corporate_card_id: - allOf: - - $ref: '#/components/schemas/id_string' - example: bawownwrng reconciliation_summary_from_statement_in: type: object properties: @@ -31905,6 +31914,13 @@ components: type: string example: - recexxxxxx + ignore_archived_cards: + type: boolean + nullable: true + description: | + Controls how transactions associated with archived cards are handled during statement processing: + If true, transactions associated with archived cards are ignored. + If false, the archived cards are unarchived, and their associated transactions are processed. required: - id - statement_mapping @@ -32057,6 +32073,13 @@ components: type: string example: - recexxxxxx + ignore_archived_cards: + type: boolean + nullable: true + description: | + Controls how transactions associated with archived cards are handled during statement processing: + If true, transactions associated with archived cards are ignored. + If false, the archived cards are unarchived, and their associated transactions are processed. required: - id - statement_mapping @@ -32181,6 +32204,14 @@ components: - stlisfdfadssd card_mapping: $ref: '#/components/schemas/card_mapping_in' + ignore_archived_cards: + type: boolean + nullable: true + description: | + Controls how transactions associated with archived cards are handled during statement processing: + If true, transactions associated with archived cards are ignored. + If false, the archived cards are unarchived, and their associated transactions are processed. + example: false required: - id - statement_mapping @@ -32527,14 +32558,118 @@ components: RTF Confidence percentage indicates what % of the transactions in last uploaded statement are already existing in Sage Exp Mgmt via RTF. example: 99.22 statement_archived_cards_in: - allOf: - - $ref: '#/components/schemas/summary_from_statement_in' - - type: object + type: object + properties: + id: + allOf: + - $ref: '#/components/schemas/id_string' + example: stmtadfdsdf + statement_mapping: + type: object properties: - card_mapping: - $ref: '#/components/schemas/card_mapping_in' + description_column: + type: string + description: | + Specifies the mapping of description column on the statement + nullable: true + example: description + transaction_date_column: + type: string + description: | + Specifies the mapping of transaction date on the statement. + example: txn date + transaction_id_column: + type: string + description: | + Specifies the mapping of transaction id / unique id on the statement. + example: reference number + nullable: true + amount_column: + type: string + description: | + Specifies the mapping of amount on the statement. + example: amount + card_number_column: + type: string + description: | + Specifies the mapping of card number on the statement. + example: account number + merchant_column: + type: string + description: | + Specifies the mapping of merchant on the statement. + example: Amazon + foreign_amount_column: + type: string + description: | + Specifies the mapping of foreign amount on the statement. + example: foreign amount + nullable: true + foreign_currency_column: + type: string + description: | + Specifies the mapping of foreign currency on the statement. + example: foreign currency + nullable: true + post_date_column: + type: string + description: | + Specifies the header name of the post date column in the statement. + example: post date + nullable: true + bank_name: + type: string + description: | + Specifies the bank name of the statement + example: American Express + is_debit_positive: + type: boolean + description: | + Specifies the representation of the the amount in the statement, if true then the amount represented by | + positive sign are debits, and if false then the amount represented by negative sign are debits. + example: true + name: + type: string + description: | + Specifies the mapping name. + example: USD + nullable: true + card_network: + type: string + description: | + Specifies the credit card network used by the card + example: VISA + nullable: true required: - - card_mapping + - transaction_date_column + - amount_column + - card_number_column + - merchant_column + - bank_name + - is_debit_positive + ignored_line_item_ids: + type: array + items: + type: string + description: | + This specifies list of statement line items to be ignored in the statement. + example: + - stlisfdfadssd + start_date: + $ref: '#/components/schemas/timestamptz_utc' + description: | + Start date of the statement period + nullable: true + end_date: + $ref: '#/components/schemas/timestamptz_utc' + description: | + End date of the statement period + nullable: true + card_mapping: + $ref: '#/components/schemas/card_mapping_in' + required: + - id + - statement_mapping statement_archived_cards_out: properties: number_of_cards: diff --git a/src/components/schemas/statements.yaml b/src/components/schemas/statements.yaml index 99426b3d6..40caae826 100644 --- a/src/components/schemas/statements.yaml +++ b/src/components/schemas/statements.yaml @@ -262,6 +262,14 @@ card_transaction_from_statement_in: - stlisfdfadssd card_mapping: $ref: '#/card_mapping_in' + ignore_archived_cards: + type: boolean + nullable: true + description: | + Controls how transactions associated with archived cards are handled during statement processing: + If true, transactions associated with archived cards are ignored. + If false, the archived cards are unarchived, and their associated transactions are processed. + example: false required: - id - statement_mapping @@ -479,6 +487,15 @@ summary_from_statement_in: This specifies list of statement line items to be ignored in the statement. example: - stlisfdfadssd + card_mapping: + $ref: '#/card_mapping_in' + ignore_archived_cards: + type: boolean + nullable: true + description: | + Controls how transactions associated with archived cards are handled during statement processing: + If true, transactions associated with archived cards are ignored. + If false, the archived cards are unarchived, and their associated transactions are processed. required: - id - statement_mapping @@ -746,6 +763,13 @@ reconciliation_summary_from_statement_in: type: string example: - recexxxxxx + ignore_archived_cards: + type: boolean + nullable: true + description: | + Controls how transactions associated with archived cards are handled during statement processing: + If true, transactions associated with archived cards are ignored. + If false, the archived cards are unarchived, and their associated transactions are processed. required: - id - statement_mapping @@ -876,6 +900,13 @@ reconcile_from_statement_in: type: string example: - recexxxxxx + ignore_archived_cards: + type: boolean + nullable: true + description: | + Controls how transactions associated with archived cards are handled during statement processing: + If true, transactions associated with archived cards are ignored. + If false, the archived cards are unarchived, and their associated transactions are processed. required: - id - statement_mapping @@ -1334,14 +1365,118 @@ statement_archived_cards_out: statement_archived_cards_in: - allOf: - - $ref: '#/summary_from_statement_in' - - type: object + type: object + properties: + id: + allOf: + - $ref: './fields.yaml#/id_string' + example: stmtadfdsdf + statement_mapping: + type: object properties: - card_mapping: - $ref: '#/card_mapping_in' + description_column: + type: string + description: | + Specifies the mapping of description column on the statement + nullable: true + example: description + transaction_date_column: + type: string + description: | + Specifies the mapping of transaction date on the statement. + example: txn date + transaction_id_column: + type: string + description: | + Specifies the mapping of transaction id / unique id on the statement. + example: reference number + nullable: true + amount_column: + type: string + description: | + Specifies the mapping of amount on the statement. + example: amount + card_number_column: + type: string + description: | + Specifies the mapping of card number on the statement. + example: account number + merchant_column: + type: string + description: | + Specifies the mapping of merchant on the statement. + example: Amazon + foreign_amount_column: + type: string + description: | + Specifies the mapping of foreign amount on the statement. + example: foreign amount + nullable: true + foreign_currency_column: + type: string + description: | + Specifies the mapping of foreign currency on the statement. + example: foreign currency + nullable: true + post_date_column: + type: string + description: | + Specifies the header name of the post date column in the statement. + example: post date + nullable: true + bank_name: + type: string + description: | + Specifies the bank name of the statement + example: American Express + is_debit_positive: + type: boolean + description: | + Specifies the representation of the the amount in the statement, if true then the amount represented by | + positive sign are debits, and if false then the amount represented by negative sign are debits. + example: true + name: + type: string + description: | + Specifies the mapping name. + example: USD + nullable: true + card_network: + type: string + description: | + Specifies the credit card network used by the card + example: VISA + nullable: true required: - - card_mapping + - transaction_date_column + - amount_column + - card_number_column + - merchant_column + - bank_name + - is_debit_positive + ignored_line_item_ids: + type: array + items: + type: string + description: > + This specifies list of statement line items to be ignored in the statement. + example: + - stlisfdfadssd + start_date: + $ref: './fields.yaml#/timestamptz_utc' + description: | + Start date of the statement period + nullable: true + end_date: + $ref: './fields.yaml#/timestamptz_utc' + description: | + End date of the statement period + nullable: true + card_mapping: + $ref: '#/card_mapping_in' + required: + - id + - statement_mapping statement_archived_cards_ignore_in: From 135354151635eb9e11144f25cc529fbd8ec6ad38 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 27 Jul 2026 13:10:19 +0530 Subject: [PATCH 080/107] chore: mark data, count and offset fields required where applicable (#847) * chore: mark data, count and offset fields required where applicable * Auto generate API docs * Apply suggestions from code review Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Auto generate API docs --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --- reference/accountant.yaml | 4 + reference/admin.yaml | 303 ++++++++++++++++++ reference/approver.yaml | 95 ++++++ reference/common.yaml | 12 + reference/hod.yaml | 4 + reference/hop.yaml | 4 + reference/manager.yaml | 22 ++ reference/spender.yaml | 179 +++++++++++ src/accountant/paths/accountant@orgs.yaml | 4 + .../admin@accounting_export_lineitems.yaml | 4 + src/admin/paths/admin@accounting_exports.yaml | 4 + src/admin/paths/admin@accounts.yaml | 4 + src/admin/paths/admin@adjustments.yaml | 4 + src/admin/paths/admin@advance_refunds.yaml | 4 + src/admin/paths/admin@advance_requests.yaml | 4 + .../admin@advance_requests@custom_fields.yaml | 2 + src/admin/paths/admin@advance_wallets.yaml | 4 + src/admin/paths/admin@advances.yaml | 4 + .../admin@automations@report_submissions.yaml | 4 + src/admin/paths/admin@budget_usages.yaml | 4 + src/admin/paths/admin@budgets.yaml | 4 + src/admin/paths/admin@categories.yaml | 4 + .../admin@categories@system_categories.yaml | 2 + .../admin@corporate_card_transactions.yaml | 4 + ...rd_transactions@export_configurations.yaml | 4 + ...n@corporate_card_transactions@filters.yaml | 2 + src/admin/paths/admin@corporate_cards.yaml | 4 + ...n@corporate_cards@archive_suggestions.yaml | 4 + .../admin@corporate_cards@bank_names.yaml | 2 + ...corporate_cards@duplicate_suggestions.yaml | 4 + ...n@corporate_cards@masked_card_numbers.yaml | 2 + src/admin/paths/admin@cost_centers.yaml | 4 + src/admin/paths/admin@departments.yaml | 4 + .../admin@dependent_expense_field_values.yaml | 4 + ...endent_expense_field_values@downloads.yaml | 4 + ...ependent_expense_field_values@preview.yaml | 4 + ...ependent_expense_field_values@uploads.yaml | 4 + src/admin/paths/admin@dwolla_customers.yaml | 2 + .../admin@employee_account_summaries.yaml | 4 + src/admin/paths/admin@employee_fields.yaml | 4 + src/admin/paths/admin@employees.yaml | 4 + .../paths/admin@employees@business_units.yaml | 2 + .../paths/admin@employees@downloads.yaml | 4 + ...admin@employees@export_configurations.yaml | 4 + src/admin/paths/admin@employees@filters.yaml | 2 + .../paths/admin@employees@locations.yaml | 2 + ...mployees@potential_duplicate_expenses.yaml | 4 + .../paths/admin@employees@summaries.yaml | 4 + src/admin/paths/admin@employees@titles.yaml | 2 + src/admin/paths/admin@employees@uploads.yaml | 4 + src/admin/paths/admin@expense_fields.yaml | 4 + src/admin/paths/admin@expense_policies.yaml | 4 + .../paths/admin@expense_policies@states.yaml | 4 + src/admin/paths/admin@expense_rules.yaml | 4 + src/admin/paths/admin@expenses.yaml | 4 + src/admin/paths/admin@expenses@comments.yaml | 4 + .../paths/admin@expenses@duplicate_sets.yaml | 2 + .../admin@expenses@duplicate_sets@stats.yaml | 2 + .../admin@expenses@export_configurations.yaml | 4 + src/admin/paths/admin@expenses@filters.yaml | 4 + src/admin/paths/admin@feature_configs.yaml | 4 + src/admin/paths/admin@levels.yaml | 4 + src/admin/paths/admin@merchants.yaml | 4 + src/admin/paths/admin@mileage_rates.yaml | 4 + src/admin/paths/admin@orgs.yaml | 4 + src/admin/paths/admin@orgs_bank_details.yaml | 4 + src/admin/paths/admin@per_diem_rates.yaml | 4 + src/admin/paths/admin@projects.yaml | 4 + .../paths/admin@reconciliation_entries.yaml | 4 + ...reconciliation_entries@eligible_cards.yaml | 4 + ...n@reconciliation_entries@transactions.yaml | 4 + src/admin/paths/admin@reimbursements.yaml | 4 + src/admin/paths/admin@reminders.yaml | 4 + src/admin/paths/admin@reports.yaml | 4 + .../admin@reports@export_configurations.yaml | 4 + src/admin/paths/admin@reports@exports.yaml | 5 + .../paths/admin@reports@save_filters.yaml | 4 + .../paths/admin@scheduled_callbacks.yaml | 4 + src/admin/paths/admin@schedules.yaml | 4 + .../admin@spend_overview@by_category.yaml | 4 + ...dmin@spend_overview@by_corporate_card.yaml | 4 + .../admin@spend_overview@by_department.yaml | 4 + .../admin@spend_overview@by_merchant.yaml | 4 + .../admin@spend_overview@by_project.yaml | 4 + .../paths/admin@spend_overview@by_user.yaml | 4 + .../paths/admin@spend_overview@summary.yaml | 2 + src/admin/paths/admin@statement_mappings.yaml | 4 + src/admin/paths/admin@statements.yaml | 4 + ...admin@statements@missing_transactions.yaml | 2 + .../paths/admin@statements@rtf_stats.yaml | 2 + src/admin/paths/admin@subscriptions.yaml | 4 + src/admin/paths/admin@tax_groups.yaml | 4 + src/admin/paths/admin@virtual_cards.yaml | 4 + src/approver/paths/approver@accounts.yaml | 4 + .../paths/approver@advance_requests.yaml | 4 + ...prover@advance_requests@custom_fields.yaml | 2 + src/approver/paths/approver@categories.yaml | 4 + .../paths/approver@corporate_cards.yaml | 4 + src/approver/paths/approver@cost_centers.yaml | 4 + .../paths/approver@employee_overview.yaml | 4 + .../approver@employee_overview@expenses.yaml | 4 + .../approver@employee_overview@hierarchy.yaml | 2 + src/approver/paths/approver@employees.yaml | 4 + .../paths/approver@expense_fields.yaml | 4 + .../approver@expense_policies@states.yaml | 4 + src/approver/paths/approver@expenses.yaml | 4 + .../paths/approver@expenses@comments.yaml | 4 + .../approver@expenses@duplicate_sets.yaml | 2 + ...prover@expenses@export_configurations.yaml | 4 + .../paths/approver@expenses@filters.yaml | 4 + src/approver/paths/approver@merchants.yaml | 4 + .../paths/approver@mileage_rates.yaml | 4 + .../paths/approver@per_diem_rates.yaml | 4 + src/approver/paths/approver@projects.yaml | 4 + src/approver/paths/approver@reports.yaml | 4 + ...pprover@reports@export_configurations.yaml | 4 + .../paths/approver@reports@exports.yaml | 5 + .../paths/approver@reports@filters.yaml | 4 + .../paths/approver@subscriptions.yaml | 4 + src/common/paths/common@currencies.yaml | 2 + .../common@currencies@exchange_rate.yaml | 2 + src/common/paths/common@places.yaml | 4 + .../paths/common@places@autocomplete.yaml | 4 + src/hod/paths/hod@budget_usages.yaml | 4 + src/hop/paths/hop@budget_usages.yaml | 4 + .../paths/manager@employee_overview.yaml | 4 + .../manager@employee_overview@employees.yaml | 4 + ...er@employee_overview@expense_comments.yaml | 4 + ...ployee_overview@expense_policy_states.yaml | 4 + .../manager@employee_overview@expenses.yaml | 4 + .../manager@employee_overview@hierarchy.yaml | 2 + src/spender/paths/spender@accounts.yaml | 4 + .../paths/spender@advance_requests.yaml | 4 + ...pender@advance_requests@custom_fields.yaml | 2 + .../paths/spender@advance_requests_stats.yaml | 2 + .../paths/spender@advance_wallets.yaml | 4 + src/spender/paths/spender@advances.yaml | 4 + ...pender@automations@recurring_expenses.yaml | 4 + src/spender/paths/spender@budgets.yaml | 4 + src/spender/paths/spender@categories.yaml | 4 + .../spender@corporate_card_transactions.yaml | 4 + .../paths/spender@corporate_cards.yaml | 4 + ...ender@corporate_cards@yodlee_accounts.yaml | 4 + src/spender/paths/spender@cost_centers.yaml | 4 + src/spender/paths/spender@departments.yaml | 4 + ...pender@dependent_expense_field_values.yaml | 4 + .../paths/spender@dwolla_customers.yaml | 2 + src/spender/paths/spender@employees.yaml | 4 + .../paths/spender@employees@current.yaml | 2 + .../paths/spender@employees@delegators.yaml | 4 + src/spender/paths/spender@exchange_rate.yaml | 2 + src/spender/paths/spender@expense_fields.yaml | 4 + .../paths/spender@expense_policies.yaml | 4 + .../spender@expense_policies@states.yaml | 4 + src/spender/paths/spender@expense_stats.yaml | 2 + src/spender/paths/spender@expenses.yaml | 4 + .../paths/spender@expenses@comments.yaml | 4 + .../spender@expenses@duplicate_sets.yaml | 2 + ...pender@expenses@export_configurations.yaml | 4 + .../paths/spender@expenses@filters.yaml | 4 + .../paths/spender@feature_configs.yaml | 4 + src/spender/paths/spender@merchants.yaml | 4 + src/spender/paths/spender@mileage_rates.yaml | 4 + .../paths/spender@mobile_app@versions.yaml | 4 + src/spender/paths/spender@my_profile.yaml | 2 + src/spender/paths/spender@orgs.yaml | 4 + .../paths/spender@orgs_bank_details.yaml | 4 + src/spender/paths/spender@per_diem_rates.yaml | 4 + .../spender@personal_card_transactions.yaml | 4 + ..._card_transactions@expense_suggestion.yaml | 2 + src/spender/paths/spender@personal_cards.yaml | 4 + src/spender/paths/spender@projects.yaml | 4 + .../paths/spender@recently_used_fields.yaml | 2 + src/spender/paths/spender@report_stats.yaml | 2 + src/spender/paths/spender@reports.yaml | 4 + ...spender@reports@export_configurations.yaml | 4 + .../paths/spender@reports@exports.yaml | 5 + .../paths/spender@reports@filters.yaml | 4 + src/spender/paths/spender@schedules.yaml | 4 + .../paths/spender@secondary_emails.yaml | 4 + src/spender/paths/spender@subscriptions.yaml | 4 + src/spender/paths/spender@tax_groups.yaml | 4 + src/spender/paths/spender@virtual_cards.yaml | 4 + 183 files changed, 1262 insertions(+) diff --git a/reference/accountant.yaml b/reference/accountant.yaml index 4e6ca6648..67e660e74 100644 --- a/reference/accountant.yaml +++ b/reference/accountant.yaml @@ -30,6 +30,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' diff --git a/reference/admin.yaml b/reference/admin.yaml index 1163ea566..9cf3ae7eb 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -130,6 +130,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -377,6 +381,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -630,6 +638,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -878,6 +890,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: count: $ref: '#/components/schemas/count' @@ -912,6 +926,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1038,6 +1056,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1155,6 +1177,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1191,6 +1217,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1279,6 +1309,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1367,6 +1401,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1456,6 +1494,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1691,6 +1733,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1782,6 +1828,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2075,6 +2125,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2166,6 +2220,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2258,6 +2316,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2297,6 +2359,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -2388,6 +2452,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -2431,6 +2497,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -2628,6 +2696,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -2714,6 +2784,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2803,6 +2877,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2894,6 +2972,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2937,6 +3019,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -3548,6 +3634,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -3640,6 +3730,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -3731,6 +3825,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -3878,6 +3976,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -4172,6 +4274,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -4437,6 +4543,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -4885,6 +4995,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -5207,6 +5321,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -5413,6 +5531,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -5509,6 +5631,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -5715,6 +5841,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -5917,6 +6047,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -6104,6 +6238,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: data: type: array @@ -7185,6 +7323,11 @@ paths: content: application/json: schema: + type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -7272,6 +7415,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -7454,6 +7601,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -7597,6 +7748,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -7640,6 +7793,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -8182,6 +8337,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -8279,6 +8438,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -8376,6 +8539,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -8736,6 +8903,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -9514,6 +9683,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -9771,6 +9944,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -9814,6 +9991,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -9900,6 +10081,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -9996,6 +10181,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10080,6 +10269,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10124,6 +10317,8 @@ paths: application/json: schema: type: object + required: + - data properties: time_interval_granularity: $ref: '#/components/schemas/time_interval_granularity' @@ -10182,6 +10377,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10240,6 +10439,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10298,6 +10501,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10356,6 +10563,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10414,6 +10625,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10472,6 +10687,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10521,6 +10740,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10606,6 +10829,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10805,6 +11032,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10845,6 +11076,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -10931,6 +11166,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -11121,6 +11360,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -11326,6 +11569,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -11380,6 +11627,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -11475,6 +11726,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -12001,6 +12256,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -12080,6 +12337,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -12283,6 +12542,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -12597,6 +12860,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -12756,6 +13023,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12801,6 +13070,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expenses_duplicate_sets_stats_out' @@ -12843,6 +13114,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -13099,6 +13374,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -13141,6 +13420,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -13186,6 +13469,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -13326,6 +13613,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -13686,6 +13977,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -14855,6 +15150,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_custom_fields_out' @@ -14959,6 +15256,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: allOf: @@ -15044,6 +15343,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' diff --git a/reference/approver.yaml b/reference/approver.yaml index 5897639bd..1fa85bd52 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -66,6 +66,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -367,6 +371,11 @@ paths: content: application/json: schema: + type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -451,6 +460,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -885,6 +898,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: data: type: array @@ -1244,6 +1261,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1286,6 +1307,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1489,6 +1514,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1525,6 +1554,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1570,6 +1603,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1612,6 +1649,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1648,6 +1689,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1691,6 +1736,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1727,6 +1776,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1779,6 +1832,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1991,6 +2048,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2150,6 +2211,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -2284,6 +2347,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2821,6 +2888,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2858,6 +2929,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -3319,6 +3394,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_custom_fields_out' @@ -3424,6 +3501,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -3478,6 +3557,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: data: type: array @@ -3612,6 +3695,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -3730,6 +3817,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -3998,6 +4089,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' diff --git a/reference/common.yaml b/reference/common.yaml index e9eee6cde..7cc7339e7 100644 --- a/reference/common.yaml +++ b/reference/common.yaml @@ -78,6 +78,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -121,6 +125,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -155,6 +163,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -377,6 +387,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/exchange_rate_out' diff --git a/reference/hod.yaml b/reference/hod.yaml index b05eac38c..2b7f7d1a7 100644 --- a/reference/hod.yaml +++ b/reference/hod.yaml @@ -33,6 +33,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' diff --git a/reference/hop.yaml b/reference/hop.yaml index 0066a116e..7a0d27b23 100644 --- a/reference/hop.yaml +++ b/reference/hop.yaml @@ -33,6 +33,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' diff --git a/reference/manager.yaml b/reference/manager.yaml index ad535129e..1a85e2a87 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -31,6 +31,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -177,6 +181,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -235,6 +243,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -289,6 +299,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: data: type: array @@ -430,6 +444,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -477,6 +495,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' diff --git a/reference/spender.yaml b/reference/spender.yaml index eeb623078..5282bd1de 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -113,6 +113,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -155,6 +159,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -191,6 +199,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -233,6 +245,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -269,6 +285,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -343,6 +363,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -379,6 +403,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -413,6 +441,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/my_profile_out' @@ -441,6 +471,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/recently_used_fields_out' @@ -472,6 +504,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -509,6 +545,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -547,6 +587,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: description: | @@ -1111,6 +1155,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1154,6 +1202,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1249,6 +1301,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1345,6 +1401,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1429,6 +1489,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -1869,6 +1933,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: data: type: array @@ -2060,6 +2128,11 @@ paths: content: application/json: schema: + type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2142,6 +2215,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2293,6 +2370,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2390,6 +2471,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2432,6 +2517,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2468,6 +2557,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2504,6 +2597,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -2914,6 +3011,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -3005,6 +3106,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/spender_employee_current_out' @@ -3205,6 +3308,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -3586,6 +3693,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -3731,6 +3842,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -4220,6 +4335,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -4266,6 +4385,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -4525,6 +4648,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -4753,6 +4880,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -4912,6 +5043,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -5046,6 +5179,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -5397,6 +5534,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -5527,6 +5668,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -5772,6 +5917,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -5946,6 +6095,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -6034,6 +6185,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -6071,6 +6226,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -6560,6 +6719,10 @@ paths: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -6770,6 +6933,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_custom_fields_out' @@ -6812,6 +6977,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: allOf: @@ -6899,6 +7066,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -7167,6 +7338,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -7356,6 +7531,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: description: | diff --git a/src/accountant/paths/accountant@orgs.yaml b/src/accountant/paths/accountant@orgs.yaml index ac64ce6c8..51808c448 100644 --- a/src/accountant/paths/accountant@orgs.yaml +++ b/src/accountant/paths/accountant@orgs.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@accounting_export_lineitems.yaml b/src/admin/paths/admin@accounting_export_lineitems.yaml index 63ac40987..0e3d3c7cb 100644 --- a/src/admin/paths/admin@accounting_export_lineitems.yaml +++ b/src/admin/paths/admin@accounting_export_lineitems.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@accounting_exports.yaml b/src/admin/paths/admin@accounting_exports.yaml index f8d793701..125fbb7c4 100644 --- a/src/admin/paths/admin@accounting_exports.yaml +++ b/src/admin/paths/admin@accounting_exports.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@accounts.yaml b/src/admin/paths/admin@accounts.yaml index 616395a0e..93ef0e4b0 100644 --- a/src/admin/paths/admin@accounts.yaml +++ b/src/admin/paths/admin@accounts.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@adjustments.yaml b/src/admin/paths/admin@adjustments.yaml index 1c2c089cd..12933157f 100644 --- a/src/admin/paths/admin@adjustments.yaml +++ b/src/admin/paths/admin@adjustments.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@advance_refunds.yaml b/src/admin/paths/admin@advance_refunds.yaml index 805eeaa98..82ceaf581 100644 --- a/src/admin/paths/admin@advance_refunds.yaml +++ b/src/admin/paths/admin@advance_refunds.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@advance_requests.yaml b/src/admin/paths/admin@advance_requests.yaml index 5206a515c..8bed4709e 100644 --- a/src/admin/paths/admin@advance_requests.yaml +++ b/src/admin/paths/admin@advance_requests.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@advance_requests@custom_fields.yaml b/src/admin/paths/admin@advance_requests@custom_fields.yaml index 3dfc401ea..1f43da81b 100644 --- a/src/admin/paths/admin@advance_requests@custom_fields.yaml +++ b/src/admin/paths/admin@advance_requests@custom_fields.yaml @@ -12,6 +12,8 @@ get: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_custom_fields_out' diff --git a/src/admin/paths/admin@advance_wallets.yaml b/src/admin/paths/admin@advance_wallets.yaml index 6ab0c2d4c..99ef3be7a 100644 --- a/src/admin/paths/admin@advance_wallets.yaml +++ b/src/admin/paths/admin@advance_wallets.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@advances.yaml b/src/admin/paths/admin@advances.yaml index 1cd099375..eb7ce5a16 100644 --- a/src/admin/paths/admin@advances.yaml +++ b/src/admin/paths/admin@advances.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@automations@report_submissions.yaml b/src/admin/paths/admin@automations@report_submissions.yaml index ea115d3bf..c860d8292 100644 --- a/src/admin/paths/admin@automations@report_submissions.yaml +++ b/src/admin/paths/admin@automations@report_submissions.yaml @@ -67,6 +67,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@budget_usages.yaml b/src/admin/paths/admin@budget_usages.yaml index d05a13c0b..88e3c4117 100644 --- a/src/admin/paths/admin@budget_usages.yaml +++ b/src/admin/paths/admin@budget_usages.yaml @@ -16,6 +16,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@budgets.yaml b/src/admin/paths/admin@budgets.yaml index 269866fd7..43e606171 100644 --- a/src/admin/paths/admin@budgets.yaml +++ b/src/admin/paths/admin@budgets.yaml @@ -68,6 +68,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@categories.yaml b/src/admin/paths/admin@categories.yaml index 95fb67969..ba8839075 100644 --- a/src/admin/paths/admin@categories.yaml +++ b/src/admin/paths/admin@categories.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@categories@system_categories.yaml b/src/admin/paths/admin@categories@system_categories.yaml index 62ece4d35..cfbc62464 100644 --- a/src/admin/paths/admin@categories@system_categories.yaml +++ b/src/admin/paths/admin@categories@system_categories.yaml @@ -13,6 +13,8 @@ get: schema: type: object additionalProperties: False + required: + - data properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@corporate_card_transactions.yaml b/src/admin/paths/admin@corporate_card_transactions.yaml index 92c26a9c5..7232506a6 100644 --- a/src/admin/paths/admin@corporate_card_transactions.yaml +++ b/src/admin/paths/admin@corporate_card_transactions.yaml @@ -19,6 +19,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml b/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml index 1c36bdcdf..9386ab470 100644 --- a/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml @@ -17,6 +17,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@corporate_card_transactions@filters.yaml b/src/admin/paths/admin@corporate_card_transactions@filters.yaml index 5713f12d8..556a241ac 100644 --- a/src/admin/paths/admin@corporate_card_transactions@filters.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@filters.yaml @@ -59,6 +59,8 @@ get: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@corporate_cards.yaml b/src/admin/paths/admin@corporate_cards.yaml index 7eedd9054..86bdc40b0 100644 --- a/src/admin/paths/admin@corporate_cards.yaml +++ b/src/admin/paths/admin@corporate_cards.yaml @@ -19,6 +19,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@corporate_cards@archive_suggestions.yaml b/src/admin/paths/admin@corporate_cards@archive_suggestions.yaml index b41cbc0f4..d5d066ab3 100644 --- a/src/admin/paths/admin@corporate_cards@archive_suggestions.yaml +++ b/src/admin/paths/admin@corporate_cards@archive_suggestions.yaml @@ -19,6 +19,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@corporate_cards@bank_names.yaml b/src/admin/paths/admin@corporate_cards@bank_names.yaml index 1e5cdee35..5d09c4458 100644 --- a/src/admin/paths/admin@corporate_cards@bank_names.yaml +++ b/src/admin/paths/admin@corporate_cards@bank_names.yaml @@ -12,6 +12,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@corporate_cards@duplicate_suggestions.yaml b/src/admin/paths/admin@corporate_cards@duplicate_suggestions.yaml index c7ef84e80..fd62fb173 100644 --- a/src/admin/paths/admin@corporate_cards@duplicate_suggestions.yaml +++ b/src/admin/paths/admin@corporate_cards@duplicate_suggestions.yaml @@ -19,6 +19,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@corporate_cards@masked_card_numbers.yaml b/src/admin/paths/admin@corporate_cards@masked_card_numbers.yaml index 1327e4875..fb65a6908 100644 --- a/src/admin/paths/admin@corporate_cards@masked_card_numbers.yaml +++ b/src/admin/paths/admin@corporate_cards@masked_card_numbers.yaml @@ -15,6 +15,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@cost_centers.yaml b/src/admin/paths/admin@cost_centers.yaml index c0904af3a..8b0ec51bf 100644 --- a/src/admin/paths/admin@cost_centers.yaml +++ b/src/admin/paths/admin@cost_centers.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@departments.yaml b/src/admin/paths/admin@departments.yaml index 6f2ff0e61..21da1b722 100644 --- a/src/admin/paths/admin@departments.yaml +++ b/src/admin/paths/admin@departments.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@dependent_expense_field_values.yaml b/src/admin/paths/admin@dependent_expense_field_values.yaml index 595f62692..ecdc2f576 100644 --- a/src/admin/paths/admin@dependent_expense_field_values.yaml +++ b/src/admin/paths/admin@dependent_expense_field_values.yaml @@ -51,6 +51,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml b/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml index 6af330bd5..bf7b2f72b 100644 --- a/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml +++ b/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@dependent_expense_field_values@preview.yaml b/src/admin/paths/admin@dependent_expense_field_values@preview.yaml index 51b10c70f..061b24c5b 100644 --- a/src/admin/paths/admin@dependent_expense_field_values@preview.yaml +++ b/src/admin/paths/admin@dependent_expense_field_values@preview.yaml @@ -41,6 +41,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml b/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml index e002a5402..1fa6cacb6 100644 --- a/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml +++ b/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@dwolla_customers.yaml b/src/admin/paths/admin@dwolla_customers.yaml index 7f3a9a0cc..9512dee79 100644 --- a/src/admin/paths/admin@dwolla_customers.yaml +++ b/src/admin/paths/admin@dwolla_customers.yaml @@ -13,6 +13,8 @@ get: schema: type: object additionalProperties: False + required: + - data properties: data: allOf: diff --git a/src/admin/paths/admin@employee_account_summaries.yaml b/src/admin/paths/admin@employee_account_summaries.yaml index 537ef8bf5..c7a175bf6 100644 --- a/src/admin/paths/admin@employee_account_summaries.yaml +++ b/src/admin/paths/admin@employee_account_summaries.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@employee_fields.yaml b/src/admin/paths/admin@employee_fields.yaml index 35c488c69..4bcf4e824 100644 --- a/src/admin/paths/admin@employee_fields.yaml +++ b/src/admin/paths/admin@employee_fields.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@employees.yaml b/src/admin/paths/admin@employees.yaml index 4ec6009cd..797f8a398 100644 --- a/src/admin/paths/admin@employees.yaml +++ b/src/admin/paths/admin@employees.yaml @@ -15,6 +15,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@employees@business_units.yaml b/src/admin/paths/admin@employees@business_units.yaml index a90a3915a..2bf6ac391 100644 --- a/src/admin/paths/admin@employees@business_units.yaml +++ b/src/admin/paths/admin@employees@business_units.yaml @@ -15,6 +15,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@employees@downloads.yaml b/src/admin/paths/admin@employees@downloads.yaml index afba07f60..0f02c685f 100644 --- a/src/admin/paths/admin@employees@downloads.yaml +++ b/src/admin/paths/admin@employees@downloads.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@employees@export_configurations.yaml b/src/admin/paths/admin@employees@export_configurations.yaml index 534886b25..883dbe342 100644 --- a/src/admin/paths/admin@employees@export_configurations.yaml +++ b/src/admin/paths/admin@employees@export_configurations.yaml @@ -19,6 +19,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@employees@filters.yaml b/src/admin/paths/admin@employees@filters.yaml index a2961257a..2fd76e63e 100644 --- a/src/admin/paths/admin@employees@filters.yaml +++ b/src/admin/paths/admin@employees@filters.yaml @@ -59,6 +59,8 @@ get: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@employees@locations.yaml b/src/admin/paths/admin@employees@locations.yaml index 87681eb4b..9fb416700 100644 --- a/src/admin/paths/admin@employees@locations.yaml +++ b/src/admin/paths/admin@employees@locations.yaml @@ -15,6 +15,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@employees@potential_duplicate_expenses.yaml b/src/admin/paths/admin@employees@potential_duplicate_expenses.yaml index 53c586a15..1f1ba8186 100644 --- a/src/admin/paths/admin@employees@potential_duplicate_expenses.yaml +++ b/src/admin/paths/admin@employees@potential_duplicate_expenses.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@employees@summaries.yaml b/src/admin/paths/admin@employees@summaries.yaml index ce10ec868..d7937aafc 100644 --- a/src/admin/paths/admin@employees@summaries.yaml +++ b/src/admin/paths/admin@employees@summaries.yaml @@ -15,6 +15,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@employees@titles.yaml b/src/admin/paths/admin@employees@titles.yaml index ad7022c51..44363adc3 100644 --- a/src/admin/paths/admin@employees@titles.yaml +++ b/src/admin/paths/admin@employees@titles.yaml @@ -15,6 +15,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@employees@uploads.yaml b/src/admin/paths/admin@employees@uploads.yaml index c54a71aef..98301a851 100644 --- a/src/admin/paths/admin@employees@uploads.yaml +++ b/src/admin/paths/admin@employees@uploads.yaml @@ -13,6 +13,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@expense_fields.yaml b/src/admin/paths/admin@expense_fields.yaml index 5a5cecf4c..a5183e230 100644 --- a/src/admin/paths/admin@expense_fields.yaml +++ b/src/admin/paths/admin@expense_fields.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@expense_policies.yaml b/src/admin/paths/admin@expense_policies.yaml index 47fb80f4e..f2d99bfed 100644 --- a/src/admin/paths/admin@expense_policies.yaml +++ b/src/admin/paths/admin@expense_policies.yaml @@ -113,6 +113,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@expense_policies@states.yaml b/src/admin/paths/admin@expense_policies@states.yaml index 9316b6a4e..2bd6f130f 100644 --- a/src/admin/paths/admin@expense_policies@states.yaml +++ b/src/admin/paths/admin@expense_policies@states.yaml @@ -29,6 +29,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@expense_rules.yaml b/src/admin/paths/admin@expense_rules.yaml index 7b57056ea..b18e7098f 100644 --- a/src/admin/paths/admin@expense_rules.yaml +++ b/src/admin/paths/admin@expense_rules.yaml @@ -63,6 +63,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@expenses.yaml b/src/admin/paths/admin@expenses.yaml index b07ec19f7..8e5610fa4 100644 --- a/src/admin/paths/admin@expenses.yaml +++ b/src/admin/paths/admin@expenses.yaml @@ -14,6 +14,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@expenses@comments.yaml b/src/admin/paths/admin@expenses@comments.yaml index 3231c3d8a..ff96ac90f 100644 --- a/src/admin/paths/admin@expenses@comments.yaml +++ b/src/admin/paths/admin@expenses@comments.yaml @@ -13,6 +13,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@expenses@duplicate_sets.yaml b/src/admin/paths/admin@expenses@duplicate_sets.yaml index f8f622c84..417a4ac2d 100644 --- a/src/admin/paths/admin@expenses@duplicate_sets.yaml +++ b/src/admin/paths/admin@expenses@duplicate_sets.yaml @@ -21,6 +21,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@duplicate_sets@stats.yaml b/src/admin/paths/admin@expenses@duplicate_sets@stats.yaml index 2a9579818..89bdddbb5 100644 --- a/src/admin/paths/admin@expenses@duplicate_sets@stats.yaml +++ b/src/admin/paths/admin@expenses@duplicate_sets@stats.yaml @@ -26,6 +26,8 @@ get: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense_duplicate_set.yaml#/expenses_duplicate_sets_stats_out' diff --git a/src/admin/paths/admin@expenses@export_configurations.yaml b/src/admin/paths/admin@expenses@export_configurations.yaml index ed920ec01..3573fbac4 100644 --- a/src/admin/paths/admin@expenses@export_configurations.yaml +++ b/src/admin/paths/admin@expenses@export_configurations.yaml @@ -17,6 +17,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@expenses@filters.yaml b/src/admin/paths/admin@expenses@filters.yaml index 4320f56e9..d3ab7b27e 100644 --- a/src/admin/paths/admin@expenses@filters.yaml +++ b/src/admin/paths/admin@expenses@filters.yaml @@ -59,6 +59,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@feature_configs.yaml b/src/admin/paths/admin@feature_configs.yaml index e06443977..395c1c432 100644 --- a/src/admin/paths/admin@feature_configs.yaml +++ b/src/admin/paths/admin@feature_configs.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@levels.yaml b/src/admin/paths/admin@levels.yaml index 0500be9db..aaadf0736 100644 --- a/src/admin/paths/admin@levels.yaml +++ b/src/admin/paths/admin@levels.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@merchants.yaml b/src/admin/paths/admin@merchants.yaml index 9973180c4..6b1b7fc6d 100644 --- a/src/admin/paths/admin@merchants.yaml +++ b/src/admin/paths/admin@merchants.yaml @@ -18,6 +18,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@mileage_rates.yaml b/src/admin/paths/admin@mileage_rates.yaml index 620f9361e..b6f199e99 100644 --- a/src/admin/paths/admin@mileage_rates.yaml +++ b/src/admin/paths/admin@mileage_rates.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@orgs.yaml b/src/admin/paths/admin@orgs.yaml index 0c0e8baba..86aac67cf 100644 --- a/src/admin/paths/admin@orgs.yaml +++ b/src/admin/paths/admin@orgs.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@orgs_bank_details.yaml b/src/admin/paths/admin@orgs_bank_details.yaml index f0a779054..df86a68f8 100644 --- a/src/admin/paths/admin@orgs_bank_details.yaml +++ b/src/admin/paths/admin@orgs_bank_details.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@per_diem_rates.yaml b/src/admin/paths/admin@per_diem_rates.yaml index 818d5e921..4cb54f536 100644 --- a/src/admin/paths/admin@per_diem_rates.yaml +++ b/src/admin/paths/admin@per_diem_rates.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@projects.yaml b/src/admin/paths/admin@projects.yaml index 0584021ab..d9dbe32e5 100644 --- a/src/admin/paths/admin@projects.yaml +++ b/src/admin/paths/admin@projects.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@reconciliation_entries.yaml b/src/admin/paths/admin@reconciliation_entries.yaml index 7a50c125b..7b113f666 100644 --- a/src/admin/paths/admin@reconciliation_entries.yaml +++ b/src/admin/paths/admin@reconciliation_entries.yaml @@ -21,6 +21,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@reconciliation_entries@eligible_cards.yaml b/src/admin/paths/admin@reconciliation_entries@eligible_cards.yaml index 70edaeb24..c0730fb9c 100644 --- a/src/admin/paths/admin@reconciliation_entries@eligible_cards.yaml +++ b/src/admin/paths/admin@reconciliation_entries@eligible_cards.yaml @@ -34,6 +34,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@reconciliation_entries@transactions.yaml b/src/admin/paths/admin@reconciliation_entries@transactions.yaml index 7d364fcc9..1a5ebc2c3 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions.yaml @@ -46,6 +46,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@reimbursements.yaml b/src/admin/paths/admin@reimbursements.yaml index cd4abef70..4a0a73194 100644 --- a/src/admin/paths/admin@reimbursements.yaml +++ b/src/admin/paths/admin@reimbursements.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@reminders.yaml b/src/admin/paths/admin@reminders.yaml index cb78507fc..e7490eb72 100644 --- a/src/admin/paths/admin@reminders.yaml +++ b/src/admin/paths/admin@reminders.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@reports.yaml b/src/admin/paths/admin@reports.yaml index a4a713f57..f27685cb3 100644 --- a/src/admin/paths/admin@reports.yaml +++ b/src/admin/paths/admin@reports.yaml @@ -14,6 +14,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@reports@export_configurations.yaml b/src/admin/paths/admin@reports@export_configurations.yaml index e69a1dbb3..3f4c2f255 100644 --- a/src/admin/paths/admin@reports@export_configurations.yaml +++ b/src/admin/paths/admin@reports@export_configurations.yaml @@ -17,6 +17,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@reports@exports.yaml b/src/admin/paths/admin@reports@exports.yaml index 4ed93d118..683440fb1 100644 --- a/src/admin/paths/admin@reports@exports.yaml +++ b/src/admin/paths/admin@reports@exports.yaml @@ -11,6 +11,11 @@ get: content: application/json: schema: + type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@reports@save_filters.yaml b/src/admin/paths/admin@reports@save_filters.yaml index 06107026f..36652d425 100644 --- a/src/admin/paths/admin@reports@save_filters.yaml +++ b/src/admin/paths/admin@reports@save_filters.yaml @@ -59,6 +59,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: data: type: array diff --git a/src/admin/paths/admin@scheduled_callbacks.yaml b/src/admin/paths/admin@scheduled_callbacks.yaml index dda8e5246..8a1ad4f51 100644 --- a/src/admin/paths/admin@scheduled_callbacks.yaml +++ b/src/admin/paths/admin@scheduled_callbacks.yaml @@ -69,6 +69,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@schedules.yaml b/src/admin/paths/admin@schedules.yaml index 9101cb9a6..5ab588a35 100644 --- a/src/admin/paths/admin@schedules.yaml +++ b/src/admin/paths/admin@schedules.yaml @@ -69,6 +69,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@spend_overview@by_category.yaml b/src/admin/paths/admin@spend_overview@by_category.yaml index b5eae8982..5a2b1ff01 100644 --- a/src/admin/paths/admin@spend_overview@by_category.yaml +++ b/src/admin/paths/admin@spend_overview@by_category.yaml @@ -22,6 +22,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@spend_overview@by_corporate_card.yaml b/src/admin/paths/admin@spend_overview@by_corporate_card.yaml index 8aed50fb0..b6e39f854 100644 --- a/src/admin/paths/admin@spend_overview@by_corporate_card.yaml +++ b/src/admin/paths/admin@spend_overview@by_corporate_card.yaml @@ -22,6 +22,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@spend_overview@by_department.yaml b/src/admin/paths/admin@spend_overview@by_department.yaml index 6c2069b82..59cf186d8 100644 --- a/src/admin/paths/admin@spend_overview@by_department.yaml +++ b/src/admin/paths/admin@spend_overview@by_department.yaml @@ -22,6 +22,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@spend_overview@by_merchant.yaml b/src/admin/paths/admin@spend_overview@by_merchant.yaml index 64b851404..9469eb651 100644 --- a/src/admin/paths/admin@spend_overview@by_merchant.yaml +++ b/src/admin/paths/admin@spend_overview@by_merchant.yaml @@ -22,6 +22,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@spend_overview@by_project.yaml b/src/admin/paths/admin@spend_overview@by_project.yaml index da9283de7..3b6eb4d9a 100644 --- a/src/admin/paths/admin@spend_overview@by_project.yaml +++ b/src/admin/paths/admin@spend_overview@by_project.yaml @@ -22,6 +22,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@spend_overview@by_user.yaml b/src/admin/paths/admin@spend_overview@by_user.yaml index bfbdce23f..799e7ffa0 100644 --- a/src/admin/paths/admin@spend_overview@by_user.yaml +++ b/src/admin/paths/admin@spend_overview@by_user.yaml @@ -22,6 +22,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@spend_overview@summary.yaml b/src/admin/paths/admin@spend_overview@summary.yaml index 1dc40885e..021f4fede 100644 --- a/src/admin/paths/admin@spend_overview@summary.yaml +++ b/src/admin/paths/admin@spend_overview@summary.yaml @@ -26,6 +26,8 @@ get: application/json: schema: type: object + required: + - data properties: time_interval_granularity: $ref: ../../components/schemas/fields.yaml#/time_interval_granularity diff --git a/src/admin/paths/admin@statement_mappings.yaml b/src/admin/paths/admin@statement_mappings.yaml index 8fa4605fa..23a33d59b 100644 --- a/src/admin/paths/admin@statement_mappings.yaml +++ b/src/admin/paths/admin@statement_mappings.yaml @@ -18,6 +18,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@statements.yaml b/src/admin/paths/admin@statements.yaml index 67ae9c7a9..1614bfea1 100644 --- a/src/admin/paths/admin@statements.yaml +++ b/src/admin/paths/admin@statements.yaml @@ -18,6 +18,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@statements@missing_transactions.yaml b/src/admin/paths/admin@statements@missing_transactions.yaml index 02f97fb47..75599a535 100644 --- a/src/admin/paths/admin@statements@missing_transactions.yaml +++ b/src/admin/paths/admin@statements@missing_transactions.yaml @@ -62,6 +62,8 @@ get: schema: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@statements@rtf_stats.yaml b/src/admin/paths/admin@statements@rtf_stats.yaml index 606e1c132..27bc34c6e 100644 --- a/src/admin/paths/admin@statements@rtf_stats.yaml +++ b/src/admin/paths/admin@statements@rtf_stats.yaml @@ -13,6 +13,8 @@ get: schema: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@subscriptions.yaml b/src/admin/paths/admin@subscriptions.yaml index 77680a285..8d0b401c7 100644 --- a/src/admin/paths/admin@subscriptions.yaml +++ b/src/admin/paths/admin@subscriptions.yaml @@ -72,6 +72,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@tax_groups.yaml b/src/admin/paths/admin@tax_groups.yaml index bb82f48f3..12179977b 100644 --- a/src/admin/paths/admin@tax_groups.yaml +++ b/src/admin/paths/admin@tax_groups.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@virtual_cards.yaml b/src/admin/paths/admin@virtual_cards.yaml index e335c47e0..0975de9b8 100644 --- a/src/admin/paths/admin@virtual_cards.yaml +++ b/src/admin/paths/admin@virtual_cards.yaml @@ -18,6 +18,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@accounts.yaml b/src/approver/paths/approver@accounts.yaml index 43ad7d79c..bc902258f 100644 --- a/src/approver/paths/approver@accounts.yaml +++ b/src/approver/paths/approver@accounts.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: false + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@advance_requests.yaml b/src/approver/paths/approver@advance_requests.yaml index 22b4b80e9..53e70768a 100644 --- a/src/approver/paths/approver@advance_requests.yaml +++ b/src/approver/paths/approver@advance_requests.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@advance_requests@custom_fields.yaml b/src/approver/paths/approver@advance_requests@custom_fields.yaml index 674e1b21e..75d8b1009 100644 --- a/src/approver/paths/approver@advance_requests@custom_fields.yaml +++ b/src/approver/paths/approver@advance_requests@custom_fields.yaml @@ -12,6 +12,8 @@ get: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_custom_fields_out' diff --git a/src/approver/paths/approver@categories.yaml b/src/approver/paths/approver@categories.yaml index 382caeea9..5fea0cbb3 100644 --- a/src/approver/paths/approver@categories.yaml +++ b/src/approver/paths/approver@categories.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/approver/paths/approver@corporate_cards.yaml b/src/approver/paths/approver@corporate_cards.yaml index 76b9ba1e9..bf30b3550 100644 --- a/src/approver/paths/approver@corporate_cards.yaml +++ b/src/approver/paths/approver@corporate_cards.yaml @@ -21,6 +21,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@cost_centers.yaml b/src/approver/paths/approver@cost_centers.yaml index 48bbc25df..c3b0de09d 100644 --- a/src/approver/paths/approver@cost_centers.yaml +++ b/src/approver/paths/approver@cost_centers.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/approver/paths/approver@employee_overview.yaml b/src/approver/paths/approver@employee_overview.yaml index b1bcb6232..d5d07d60f 100644 --- a/src/approver/paths/approver@employee_overview.yaml +++ b/src/approver/paths/approver@employee_overview.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: data: type: array diff --git a/src/approver/paths/approver@employee_overview@expenses.yaml b/src/approver/paths/approver@employee_overview@expenses.yaml index a32237d62..e6f26cc27 100644 --- a/src/approver/paths/approver@employee_overview@expenses.yaml +++ b/src/approver/paths/approver@employee_overview@expenses.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@employee_overview@hierarchy.yaml b/src/approver/paths/approver@employee_overview@hierarchy.yaml index cd75505f9..36c9960c5 100644 --- a/src/approver/paths/approver@employee_overview@hierarchy.yaml +++ b/src/approver/paths/approver@employee_overview@hierarchy.yaml @@ -12,6 +12,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@employees.yaml b/src/approver/paths/approver@employees.yaml index bcee0bebf..89317e6d0 100644 --- a/src/approver/paths/approver@employees.yaml +++ b/src/approver/paths/approver@employees.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/approver/paths/approver@expense_fields.yaml b/src/approver/paths/approver@expense_fields.yaml index e64e0c2bb..fdb1a626c 100644 --- a/src/approver/paths/approver@expense_fields.yaml +++ b/src/approver/paths/approver@expense_fields.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/approver/paths/approver@expense_policies@states.yaml b/src/approver/paths/approver@expense_policies@states.yaml index 9316b6a4e..2bd6f130f 100644 --- a/src/approver/paths/approver@expense_policies@states.yaml +++ b/src/approver/paths/approver@expense_policies@states.yaml @@ -29,6 +29,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/approver/paths/approver@expenses.yaml b/src/approver/paths/approver@expenses.yaml index c30adfef7..d9780a8ac 100644 --- a/src/approver/paths/approver@expenses.yaml +++ b/src/approver/paths/approver@expenses.yaml @@ -14,6 +14,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@expenses@comments.yaml b/src/approver/paths/approver@expenses@comments.yaml index 3231c3d8a..ff96ac90f 100644 --- a/src/approver/paths/approver@expenses@comments.yaml +++ b/src/approver/paths/approver@expenses@comments.yaml @@ -13,6 +13,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@expenses@duplicate_sets.yaml b/src/approver/paths/approver@expenses@duplicate_sets.yaml index f8f622c84..417a4ac2d 100644 --- a/src/approver/paths/approver@expenses@duplicate_sets.yaml +++ b/src/approver/paths/approver@expenses@duplicate_sets.yaml @@ -21,6 +21,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@export_configurations.yaml b/src/approver/paths/approver@expenses@export_configurations.yaml index db5801239..96be32a0d 100644 --- a/src/approver/paths/approver@expenses@export_configurations.yaml +++ b/src/approver/paths/approver@expenses@export_configurations.yaml @@ -17,6 +17,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@expenses@filters.yaml b/src/approver/paths/approver@expenses@filters.yaml index b81a049cd..797810a62 100644 --- a/src/approver/paths/approver@expenses@filters.yaml +++ b/src/approver/paths/approver@expenses@filters.yaml @@ -59,6 +59,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@merchants.yaml b/src/approver/paths/approver@merchants.yaml index 6d38fdc61..cfaa7648c 100644 --- a/src/approver/paths/approver@merchants.yaml +++ b/src/approver/paths/approver@merchants.yaml @@ -19,6 +19,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/approver/paths/approver@mileage_rates.yaml b/src/approver/paths/approver@mileage_rates.yaml index 142a3d7e3..e970fe75e 100644 --- a/src/approver/paths/approver@mileage_rates.yaml +++ b/src/approver/paths/approver@mileage_rates.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/approver/paths/approver@per_diem_rates.yaml b/src/approver/paths/approver@per_diem_rates.yaml index b537c1091..f51a54996 100644 --- a/src/approver/paths/approver@per_diem_rates.yaml +++ b/src/approver/paths/approver@per_diem_rates.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/approver/paths/approver@projects.yaml b/src/approver/paths/approver@projects.yaml index ca527ce3a..3bdcf5eaf 100644 --- a/src/approver/paths/approver@projects.yaml +++ b/src/approver/paths/approver@projects.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/approver/paths/approver@reports.yaml b/src/approver/paths/approver@reports.yaml index 995ae8cff..3b9a5df34 100644 --- a/src/approver/paths/approver@reports.yaml +++ b/src/approver/paths/approver@reports.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/approver/paths/approver@reports@export_configurations.yaml b/src/approver/paths/approver@reports@export_configurations.yaml index eebf14228..d0c89edbc 100644 --- a/src/approver/paths/approver@reports@export_configurations.yaml +++ b/src/approver/paths/approver@reports@export_configurations.yaml @@ -17,6 +17,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@reports@exports.yaml b/src/approver/paths/approver@reports@exports.yaml index 4ed93d118..683440fb1 100644 --- a/src/approver/paths/approver@reports@exports.yaml +++ b/src/approver/paths/approver@reports@exports.yaml @@ -11,6 +11,11 @@ get: content: application/json: schema: + type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/approver/paths/approver@reports@filters.yaml b/src/approver/paths/approver@reports@filters.yaml index 667b4a402..6ae983d65 100644 --- a/src/approver/paths/approver@reports@filters.yaml +++ b/src/approver/paths/approver@reports@filters.yaml @@ -59,6 +59,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: data: type: array diff --git a/src/approver/paths/approver@subscriptions.yaml b/src/approver/paths/approver@subscriptions.yaml index d4810d5c1..f272d4b96 100644 --- a/src/approver/paths/approver@subscriptions.yaml +++ b/src/approver/paths/approver@subscriptions.yaml @@ -79,6 +79,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/common/paths/common@currencies.yaml b/src/common/paths/common@currencies.yaml index e2c63038e..76e8ec61c 100644 --- a/src/common/paths/common@currencies.yaml +++ b/src/common/paths/common@currencies.yaml @@ -10,6 +10,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/common/paths/common@currencies@exchange_rate.yaml b/src/common/paths/common@currencies@exchange_rate.yaml index de7901e04..bc10b883c 100644 --- a/src/common/paths/common@currencies@exchange_rate.yaml +++ b/src/common/paths/common@currencies@exchange_rate.yaml @@ -31,6 +31,8 @@ get: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/currency.yaml#/exchange_rate_out' diff --git a/src/common/paths/common@places.yaml b/src/common/paths/common@places.yaml index 35c5e8dae..181ef2ae7 100644 --- a/src/common/paths/common@places.yaml +++ b/src/common/paths/common@places.yaml @@ -19,6 +19,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/common/paths/common@places@autocomplete.yaml b/src/common/paths/common@places@autocomplete.yaml index 26e502973..0b7aa0a92 100644 --- a/src/common/paths/common@places@autocomplete.yaml +++ b/src/common/paths/common@places@autocomplete.yaml @@ -55,6 +55,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/hod/paths/hod@budget_usages.yaml b/src/hod/paths/hod@budget_usages.yaml index 3db850da9..e56fb149b 100644 --- a/src/hod/paths/hod@budget_usages.yaml +++ b/src/hod/paths/hod@budget_usages.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/hop/paths/hop@budget_usages.yaml b/src/hop/paths/hop@budget_usages.yaml index 3db850da9..e56fb149b 100644 --- a/src/hop/paths/hop@budget_usages.yaml +++ b/src/hop/paths/hop@budget_usages.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/manager/paths/manager@employee_overview.yaml b/src/manager/paths/manager@employee_overview.yaml index a5b641007..9fba0df7a 100644 --- a/src/manager/paths/manager@employee_overview.yaml +++ b/src/manager/paths/manager@employee_overview.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: data: type: array diff --git a/src/manager/paths/manager@employee_overview@employees.yaml b/src/manager/paths/manager@employee_overview@employees.yaml index 17523f2bb..3a28b53ba 100644 --- a/src/manager/paths/manager@employee_overview@employees.yaml +++ b/src/manager/paths/manager@employee_overview@employees.yaml @@ -19,6 +19,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/manager/paths/manager@employee_overview@expense_comments.yaml b/src/manager/paths/manager@employee_overview@expense_comments.yaml index 0f1f90c42..062d67cb7 100644 --- a/src/manager/paths/manager@employee_overview@expense_comments.yaml +++ b/src/manager/paths/manager@employee_overview@expense_comments.yaml @@ -14,6 +14,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/manager/paths/manager@employee_overview@expense_policy_states.yaml b/src/manager/paths/manager@employee_overview@expense_policy_states.yaml index e668e5e0b..15efb9e69 100644 --- a/src/manager/paths/manager@employee_overview@expense_policy_states.yaml +++ b/src/manager/paths/manager@employee_overview@expense_policy_states.yaml @@ -26,6 +26,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/manager/paths/manager@employee_overview@expenses.yaml b/src/manager/paths/manager@employee_overview@expenses.yaml index d8cdc76a1..949505563 100644 --- a/src/manager/paths/manager@employee_overview@expenses.yaml +++ b/src/manager/paths/manager@employee_overview@expenses.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/manager/paths/manager@employee_overview@hierarchy.yaml b/src/manager/paths/manager@employee_overview@hierarchy.yaml index 4eb8c603a..894752b9b 100644 --- a/src/manager/paths/manager@employee_overview@hierarchy.yaml +++ b/src/manager/paths/manager@employee_overview@hierarchy.yaml @@ -12,6 +12,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@accounts.yaml b/src/spender/paths/spender@accounts.yaml index 0aa914e79..90c76ab92 100644 --- a/src/spender/paths/spender@accounts.yaml +++ b/src/spender/paths/spender@accounts.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@advance_requests.yaml b/src/spender/paths/spender@advance_requests.yaml index d66d80cf0..28d9eeaa3 100644 --- a/src/spender/paths/spender@advance_requests.yaml +++ b/src/spender/paths/spender@advance_requests.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@advance_requests@custom_fields.yaml b/src/spender/paths/spender@advance_requests@custom_fields.yaml index 867e4d8cf..4077807a1 100644 --- a/src/spender/paths/spender@advance_requests@custom_fields.yaml +++ b/src/spender/paths/spender@advance_requests@custom_fields.yaml @@ -12,6 +12,8 @@ get: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_custom_fields_out' diff --git a/src/spender/paths/spender@advance_requests_stats.yaml b/src/spender/paths/spender@advance_requests_stats.yaml index bea06bca9..c72d7f559 100644 --- a/src/spender/paths/spender@advance_requests_stats.yaml +++ b/src/spender/paths/spender@advance_requests_stats.yaml @@ -27,6 +27,8 @@ get: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/spender/paths/spender@advance_wallets.yaml b/src/spender/paths/spender@advance_wallets.yaml index 60186f0f9..3aefce568 100644 --- a/src/spender/paths/spender@advance_wallets.yaml +++ b/src/spender/paths/spender@advance_wallets.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@advances.yaml b/src/spender/paths/spender@advances.yaml index 578fe3745..5ed59c28f 100644 --- a/src/spender/paths/spender@advances.yaml +++ b/src/spender/paths/spender@advances.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@automations@recurring_expenses.yaml b/src/spender/paths/spender@automations@recurring_expenses.yaml index 4f35c2281..47fb46b1b 100644 --- a/src/spender/paths/spender@automations@recurring_expenses.yaml +++ b/src/spender/paths/spender@automations@recurring_expenses.yaml @@ -70,6 +70,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@budgets.yaml b/src/spender/paths/spender@budgets.yaml index 3194783fe..2c0eefe46 100644 --- a/src/spender/paths/spender@budgets.yaml +++ b/src/spender/paths/spender@budgets.yaml @@ -16,6 +16,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@categories.yaml b/src/spender/paths/spender@categories.yaml index 7bd49c87b..1a09f6921 100644 --- a/src/spender/paths/spender@categories.yaml +++ b/src/spender/paths/spender@categories.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@corporate_card_transactions.yaml b/src/spender/paths/spender@corporate_card_transactions.yaml index d4846db35..3a3b8c4e2 100644 --- a/src/spender/paths/spender@corporate_card_transactions.yaml +++ b/src/spender/paths/spender@corporate_card_transactions.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@corporate_cards.yaml b/src/spender/paths/spender@corporate_cards.yaml index 21ad9fdb7..df2568472 100644 --- a/src/spender/paths/spender@corporate_cards.yaml +++ b/src/spender/paths/spender@corporate_cards.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@corporate_cards@yodlee_accounts.yaml b/src/spender/paths/spender@corporate_cards@yodlee_accounts.yaml index afdb02ac0..68d62b6e6 100644 --- a/src/spender/paths/spender@corporate_cards@yodlee_accounts.yaml +++ b/src/spender/paths/spender@corporate_cards@yodlee_accounts.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@cost_centers.yaml b/src/spender/paths/spender@cost_centers.yaml index 928de7eda..ef5323175 100644 --- a/src/spender/paths/spender@cost_centers.yaml +++ b/src/spender/paths/spender@cost_centers.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@departments.yaml b/src/spender/paths/spender@departments.yaml index 4f488e6c4..5e7c847f6 100644 --- a/src/spender/paths/spender@departments.yaml +++ b/src/spender/paths/spender@departments.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@dependent_expense_field_values.yaml b/src/spender/paths/spender@dependent_expense_field_values.yaml index 595f62692..ecdc2f576 100644 --- a/src/spender/paths/spender@dependent_expense_field_values.yaml +++ b/src/spender/paths/spender@dependent_expense_field_values.yaml @@ -51,6 +51,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@dwolla_customers.yaml b/src/spender/paths/spender@dwolla_customers.yaml index f21470848..df4e4b6cb 100644 --- a/src/spender/paths/spender@dwolla_customers.yaml +++ b/src/spender/paths/spender@dwolla_customers.yaml @@ -13,6 +13,8 @@ get: schema: type: object additionalProperties: False + required: + - data properties: data: allOf: diff --git a/src/spender/paths/spender@employees.yaml b/src/spender/paths/spender@employees.yaml index 8b047cd80..863407815 100644 --- a/src/spender/paths/spender@employees.yaml +++ b/src/spender/paths/spender@employees.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@employees@current.yaml b/src/spender/paths/spender@employees@current.yaml index 3a30973eb..7baadc66e 100644 --- a/src/spender/paths/spender@employees@current.yaml +++ b/src/spender/paths/spender@employees@current.yaml @@ -13,6 +13,8 @@ get: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/employee.yaml#/spender_employee_current_out diff --git a/src/spender/paths/spender@employees@delegators.yaml b/src/spender/paths/spender@employees@delegators.yaml index 8e48c86fa..40d1c9b4a 100644 --- a/src/spender/paths/spender@employees@delegators.yaml +++ b/src/spender/paths/spender@employees@delegators.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@exchange_rate.yaml b/src/spender/paths/spender@exchange_rate.yaml index 896868dd9..785da5366 100644 --- a/src/spender/paths/spender@exchange_rate.yaml +++ b/src/spender/paths/spender@exchange_rate.yaml @@ -35,6 +35,8 @@ get: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/spender/paths/spender@expense_fields.yaml b/src/spender/paths/spender@expense_fields.yaml index e64e0c2bb..fdb1a626c 100644 --- a/src/spender/paths/spender@expense_fields.yaml +++ b/src/spender/paths/spender@expense_fields.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@expense_policies.yaml b/src/spender/paths/spender@expense_policies.yaml index 0d9bd3dd9..62ae5e3b3 100644 --- a/src/spender/paths/spender@expense_policies.yaml +++ b/src/spender/paths/spender@expense_policies.yaml @@ -58,6 +58,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@expense_policies@states.yaml b/src/spender/paths/spender@expense_policies@states.yaml index 9316b6a4e..2bd6f130f 100644 --- a/src/spender/paths/spender@expense_policies@states.yaml +++ b/src/spender/paths/spender@expense_policies@states.yaml @@ -29,6 +29,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@expense_stats.yaml b/src/spender/paths/spender@expense_stats.yaml index 5ac7f36c4..24691f8b0 100644 --- a/src/spender/paths/spender@expense_stats.yaml +++ b/src/spender/paths/spender@expense_stats.yaml @@ -35,6 +35,8 @@ get: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/spender/paths/spender@expenses.yaml b/src/spender/paths/spender@expenses.yaml index 01c8aca19..e1eadd6ec 100644 --- a/src/spender/paths/spender@expenses.yaml +++ b/src/spender/paths/spender@expenses.yaml @@ -14,6 +14,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: description: | diff --git a/src/spender/paths/spender@expenses@comments.yaml b/src/spender/paths/spender@expenses@comments.yaml index 3231c3d8a..ff96ac90f 100644 --- a/src/spender/paths/spender@expenses@comments.yaml +++ b/src/spender/paths/spender@expenses@comments.yaml @@ -13,6 +13,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@expenses@duplicate_sets.yaml b/src/spender/paths/spender@expenses@duplicate_sets.yaml index f8f622c84..417a4ac2d 100644 --- a/src/spender/paths/spender@expenses@duplicate_sets.yaml +++ b/src/spender/paths/spender@expenses@duplicate_sets.yaml @@ -21,6 +21,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@export_configurations.yaml b/src/spender/paths/spender@expenses@export_configurations.yaml index 97125b24e..e819a0707 100644 --- a/src/spender/paths/spender@expenses@export_configurations.yaml +++ b/src/spender/paths/spender@expenses@export_configurations.yaml @@ -17,6 +17,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@expenses@filters.yaml b/src/spender/paths/spender@expenses@filters.yaml index c8f5df08d..eff9d7f67 100644 --- a/src/spender/paths/spender@expenses@filters.yaml +++ b/src/spender/paths/spender@expenses@filters.yaml @@ -59,6 +59,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@feature_configs.yaml b/src/spender/paths/spender@feature_configs.yaml index e06443977..395c1c432 100644 --- a/src/spender/paths/spender@feature_configs.yaml +++ b/src/spender/paths/spender@feature_configs.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@merchants.yaml b/src/spender/paths/spender@merchants.yaml index 36055f86e..457f142c6 100644 --- a/src/spender/paths/spender@merchants.yaml +++ b/src/spender/paths/spender@merchants.yaml @@ -19,6 +19,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@mileage_rates.yaml b/src/spender/paths/spender@mileage_rates.yaml index 142a3d7e3..e970fe75e 100644 --- a/src/spender/paths/spender@mileage_rates.yaml +++ b/src/spender/paths/spender@mileage_rates.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@mobile_app@versions.yaml b/src/spender/paths/spender@mobile_app@versions.yaml index cdb39888c..8bbd5f707 100644 --- a/src/spender/paths/spender@mobile_app@versions.yaml +++ b/src/spender/paths/spender@mobile_app@versions.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: description: | diff --git a/src/spender/paths/spender@my_profile.yaml b/src/spender/paths/spender@my_profile.yaml index eaf82e88d..cc2a50d41 100644 --- a/src/spender/paths/spender@my_profile.yaml +++ b/src/spender/paths/spender@my_profile.yaml @@ -10,6 +10,8 @@ get: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/my_profile.yaml#/my_profile_out' diff --git a/src/spender/paths/spender@orgs.yaml b/src/spender/paths/spender@orgs.yaml index 2068dc983..0da982cbb 100644 --- a/src/spender/paths/spender@orgs.yaml +++ b/src/spender/paths/spender@orgs.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@orgs_bank_details.yaml b/src/spender/paths/spender@orgs_bank_details.yaml index e73460a49..9a80f9c7e 100644 --- a/src/spender/paths/spender@orgs_bank_details.yaml +++ b/src/spender/paths/spender@orgs_bank_details.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@per_diem_rates.yaml b/src/spender/paths/spender@per_diem_rates.yaml index 5efb8de8e..0ff16825e 100644 --- a/src/spender/paths/spender@per_diem_rates.yaml +++ b/src/spender/paths/spender@per_diem_rates.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@personal_card_transactions.yaml b/src/spender/paths/spender@personal_card_transactions.yaml index 9fcd02ce6..af414897d 100644 --- a/src/spender/paths/spender@personal_card_transactions.yaml +++ b/src/spender/paths/spender@personal_card_transactions.yaml @@ -78,6 +78,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@personal_card_transactions@expense_suggestion.yaml b/src/spender/paths/spender@personal_card_transactions@expense_suggestion.yaml index e8b1886b4..eece62b5b 100644 --- a/src/spender/paths/spender@personal_card_transactions@expense_suggestion.yaml +++ b/src/spender/paths/spender@personal_card_transactions@expense_suggestion.yaml @@ -29,6 +29,8 @@ get: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@personal_cards.yaml b/src/spender/paths/spender@personal_cards.yaml index 278928a4b..0d9510cc1 100644 --- a/src/spender/paths/spender@personal_cards.yaml +++ b/src/spender/paths/spender@personal_cards.yaml @@ -52,6 +52,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@projects.yaml b/src/spender/paths/spender@projects.yaml index df6babed6..e3d8d743d 100644 --- a/src/spender/paths/spender@projects.yaml +++ b/src/spender/paths/spender@projects.yaml @@ -12,6 +12,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@recently_used_fields.yaml b/src/spender/paths/spender@recently_used_fields.yaml index b66ec3eed..f6e2590fa 100644 --- a/src/spender/paths/spender@recently_used_fields.yaml +++ b/src/spender/paths/spender@recently_used_fields.yaml @@ -10,6 +10,8 @@ get: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/recently_used_fields.yaml#/recently_used_fields_out' diff --git a/src/spender/paths/spender@report_stats.yaml b/src/spender/paths/spender@report_stats.yaml index 11d6b2b6c..2da1cb783 100644 --- a/src/spender/paths/spender@report_stats.yaml +++ b/src/spender/paths/spender@report_stats.yaml @@ -19,6 +19,8 @@ get: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/spender/paths/spender@reports.yaml b/src/spender/paths/spender@reports.yaml index 8f7f28331..7ebc05027 100644 --- a/src/spender/paths/spender@reports.yaml +++ b/src/spender/paths/spender@reports.yaml @@ -68,6 +68,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@reports@export_configurations.yaml b/src/spender/paths/spender@reports@export_configurations.yaml index de4806702..4f63e5a79 100644 --- a/src/spender/paths/spender@reports@export_configurations.yaml +++ b/src/spender/paths/spender@reports@export_configurations.yaml @@ -17,6 +17,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@reports@exports.yaml b/src/spender/paths/spender@reports@exports.yaml index 8ef4d0269..ae9c462cd 100644 --- a/src/spender/paths/spender@reports@exports.yaml +++ b/src/spender/paths/spender@reports@exports.yaml @@ -11,6 +11,11 @@ get: content: application/json: schema: + type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@reports@filters.yaml b/src/spender/paths/spender@reports@filters.yaml index 417e44f3e..88472399f 100644 --- a/src/spender/paths/spender@reports@filters.yaml +++ b/src/spender/paths/spender@reports@filters.yaml @@ -59,6 +59,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: data: type: array diff --git a/src/spender/paths/spender@schedules.yaml b/src/spender/paths/spender@schedules.yaml index 9a28c8975..7ed0100ad 100644 --- a/src/spender/paths/spender@schedules.yaml +++ b/src/spender/paths/spender@schedules.yaml @@ -68,6 +68,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@secondary_emails.yaml b/src/spender/paths/spender@secondary_emails.yaml index 769a49933..4d964929a 100644 --- a/src/spender/paths/spender@secondary_emails.yaml +++ b/src/spender/paths/spender@secondary_emails.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@subscriptions.yaml b/src/spender/paths/spender@subscriptions.yaml index ab79aa604..fae027bcc 100644 --- a/src/spender/paths/spender@subscriptions.yaml +++ b/src/spender/paths/spender@subscriptions.yaml @@ -72,6 +72,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/spender/paths/spender@tax_groups.yaml b/src/spender/paths/spender@tax_groups.yaml index 1a71789ce..948f9d971 100644 --- a/src/spender/paths/spender@tax_groups.yaml +++ b/src/spender/paths/spender@tax_groups.yaml @@ -13,6 +13,10 @@ get: schema: type: object additionalProperties: False + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/spender/paths/spender@virtual_cards.yaml b/src/spender/paths/spender@virtual_cards.yaml index e335c47e0..0975de9b8 100644 --- a/src/spender/paths/spender@virtual_cards.yaml +++ b/src/spender/paths/spender@virtual_cards.yaml @@ -18,6 +18,10 @@ get: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' From 7a75b46202657deeadd058b750a42595ac498aec Mon Sep 17 00:00:00 2001 From: satyamyesj Date: Tue, 28 Jul 2026 11:47:22 +0530 Subject: [PATCH 081/107] feat: Added doc for org weekly invitation usage API (#852) * feat: Added doc for org weekly invitation usage API * Auto generate API docs --- reference/admin.yaml | 72 +++++++++++++++++++ src/admin/openapi.yaml | 2 + .../admin@orgs@weekly_invitation_usage.yaml | 43 +++++++++++ src/components/schemas/org.yaml | 29 ++++++++ 4 files changed, 146 insertions(+) create mode 100644 src/admin/paths/admin@orgs@weekly_invitation_usage.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 9cf3ae7eb..fb873a98d 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -11246,6 +11246,50 @@ paths: application/json: schema: $ref: '#/components/schemas/401' + /admin/orgs/weekly_invitation_usage: + get: + tags: + - Organisations + summary: Get weekly employee invitation usage + description: | + This API returns the current week's employee invitation usage for the organisation. + It shows how many invitations have been sent this week, the configured weekly limit, + and whether the limit has been reached. + + If the organisation is still within its onboarding period, no weekly limit is enforced + and `weekly_limit` will be `null`. + operationId: orgs_get_weekly_invitation_usage + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/org_weekly_invitation_usage_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /admin/expense_policy_rules: post: tags: @@ -30022,6 +30066,34 @@ components: nullable: false description: | Determines whether this organization has been verified. + org_weekly_invitation_usage_out: + type: object + additionalProperties: false + required: + - id + - invitation_sent + - is_limit_reached + properties: + id: + $ref: '#/components/schemas/org_id' + weekly_limit: + type: integer + nullable: true + description: | + The maximum number of employee invitations allowed per week. + This is `null` when the organisation is within its onboarding period and no limit applies. + example: 50 + invitation_sent: + type: integer + description: | + The number of successful employee invitations sent during the current calendar week. + example: 12 + is_limit_reached: + type: boolean + description: | + Indicates whether the weekly invitation limit has been reached. + Always `false` when `weekly_limit` is `null`. + example: false expense_policy_limit_type: nullable: true type: string diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 826738fcc..fc3bc9791 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -504,6 +504,8 @@ paths: $ref: paths/admin@budgets@exports.yaml /admin/orgs: $ref: paths/admin@orgs.yaml + /admin/orgs/weekly_invitation_usage: + $ref: paths/admin@orgs@weekly_invitation_usage.yaml /admin/expense_policy_rules: $ref: paths/admin@expense_policies.yaml /admin/expense_policy_rules/enable: diff --git a/src/admin/paths/admin@orgs@weekly_invitation_usage.yaml b/src/admin/paths/admin@orgs@weekly_invitation_usage.yaml new file mode 100644 index 000000000..973e70b29 --- /dev/null +++ b/src/admin/paths/admin@orgs@weekly_invitation_usage.yaml @@ -0,0 +1,43 @@ +get: + tags: + - Organisations + summary: Get weekly employee invitation usage + description: | + This API returns the current week's employee invitation usage for the organisation. + It shows how many invitations have been sent this week, the configured weekly limit, + and whether the limit has been reached. + + If the organisation is still within its onboarding period, no weekly limit is enforced + and `weekly_limit` will be `null`. + operationId: orgs_get_weekly_invitation_usage + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../../components/schemas/org.yaml#/org_weekly_invitation_usage_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' diff --git a/src/components/schemas/org.yaml b/src/components/schemas/org.yaml index c57da5664..0e37dc648 100644 --- a/src/components/schemas/org.yaml +++ b/src/components/schemas/org.yaml @@ -1,3 +1,32 @@ +org_weekly_invitation_usage_out: + type: object + additionalProperties: false + required: + - id + - invitation_sent + - is_limit_reached + properties: + id: + $ref: './fields.yaml#/org_id' + weekly_limit: + type: integer + nullable: true + description: | + The maximum number of employee invitations allowed per week. + This is `null` when the organisation is within its onboarding period and no limit applies. + example: 50 + invitation_sent: + type: integer + description: | + The number of successful employee invitations sent during the current calendar week. + example: 12 + is_limit_reached: + type: boolean + description: | + Indicates whether the weekly invitation limit has been reached. + Always `false` when `weekly_limit` is `null`. + example: false + org_out_embed: type: object additionalProperties: False From 94346391793e97ba0740facdecb4d15384058d5c Mon Sep 17 00:00:00 2001 From: Devadathan M B Date: Tue, 28 Jul 2026 14:54:45 +0530 Subject: [PATCH 082/107] feat: add OpenAPI contract for custom expense field reordering (#848) --- reference/admin.yaml | 78 +++++++++++++++++++ reference/spender.yaml | 7 ++ src/admin/openapi.yaml | 2 + .../paths/admin@expense_fields@reorder.yaml | 62 +++++++++++++++ src/components/schemas/expense_field.yaml | 16 ++++ 5 files changed, 165 insertions(+) create mode 100644 src/admin/paths/admin@expense_fields@reorder.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index fb873a98d..d270dcd91 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -1003,6 +1003,69 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/expense_fields/reorder: + post: + tags: + - Expenses + summary: Reorder custom expense fields + description: | + Reorders all enabled, non-dependent custom expense fields for the + organization. Every eligible expense field must be included exactly once. + The order of the request items determines the `display_order`, starting from 1. + operationId: expense_fields_reorder + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: The complete ordered list of eligible expense field IDs. + minItems: 1 + uniqueItems: true + items: + $ref: '#/components/schemas/expense_field_reorder_in' + responses: + '200': + description: Expense fields reordered successfully. + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: The reordered expense fields. + items: + $ref: '#/components/schemas/expense_field_out' + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: '#/components/schemas/bulk_error' + - $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /admin/dependent_expense_field_values: get: tags: @@ -16409,6 +16472,13 @@ components: description: | This specifies the `id` of the parent expense field and denotes that the expense field is a dependent custom field. NOTE: `type` must be `DEPENDENT_SELECT`. example: 1234 + display_order: + type: integer + nullable: true + readOnly: true + description: | + The 1-based position of an enabled, non-dependent custom expense field in the organization's custom order. + example: 1 expense_field_in: type: object additionalProperties: false @@ -16484,6 +16554,14 @@ components: description: | This specifies the `id` of the parent expense field and denotes that the expense field is a dependent custom field. NOTE: `type` must be `DEPENDENT_SELECT`. example: 1234 + expense_field_reorder_in: + type: object + additionalProperties: false + required: + - id + properties: + id: + $ref: '#/components/schemas/id_integer' dependent_expense_field_values_out: type: object additionalProperties: false diff --git a/reference/spender.yaml b/reference/spender.yaml index 5282bd1de..414f89946 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -8158,6 +8158,13 @@ components: description: | This specifies the `id` of the parent expense field and denotes that the expense field is a dependent custom field. NOTE: `type` must be `DEPENDENT_SELECT`. example: 1234 + display_order: + type: integer + nullable: true + readOnly: true + description: | + The 1-based position of an enabled, non-dependent custom expense field in the organization's custom order. + example: 1 dependent_expense_field_values_out: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index fc3bc9791..c29a0d918 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -171,6 +171,8 @@ paths: $ref: paths/admin@categories@system_categories.yaml /admin/expense_fields: $ref: paths/admin@expense_fields.yaml + /admin/expense_fields/reorder: + $ref: paths/admin@expense_fields@reorder.yaml /admin/dependent_expense_field_values: $ref: paths/admin@dependent_expense_field_values.yaml /admin/dependent_expense_field_values/bulk: diff --git a/src/admin/paths/admin@expense_fields@reorder.yaml b/src/admin/paths/admin@expense_fields@reorder.yaml new file mode 100644 index 000000000..cfbebc86c --- /dev/null +++ b/src/admin/paths/admin@expense_fields@reorder.yaml @@ -0,0 +1,62 @@ +post: + tags: + - Expenses + summary: Reorder custom expense fields + description: | + Reorders all enabled, non-dependent custom expense fields for the + organization. Every eligible expense field must be included exactly once. + The order of the request items determines the `display_order`, starting from 1. + operationId: expense_fields_reorder + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: The complete ordered list of eligible expense field IDs. + minItems: 1 + uniqueItems: true + items: + $ref: '../../components/schemas/expense_field.yaml#/expense_field_reorder_in' + responses: + '200': + description: Expense fields reordered successfully. + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + description: The reordered expense fields. + items: + $ref: '../../components/schemas/expense_field.yaml#/expense_field_out' + '400': + description: Bad request + content: + application/json: + schema: + oneOf: + - $ref: ../../components/schemas/bulk_error.yaml + - $ref: ../../components/schemas/400.yaml + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: ../../components/schemas/401.yaml + '403': + description: Forbidden + content: + application/json: + schema: + $ref: ../../components/schemas/403.yaml diff --git a/src/components/schemas/expense_field.yaml b/src/components/schemas/expense_field.yaml index db356c5bd..84540117e 100644 --- a/src/components/schemas/expense_field.yaml +++ b/src/components/schemas/expense_field.yaml @@ -72,6 +72,13 @@ expense_field_out: description: | This specifies the `id` of the parent expense field and denotes that the expense field is a dependent custom field. NOTE: `type` must be `DEPENDENT_SELECT`. example: 1234 + display_order: + type: integer + nullable: true + readOnly: true + description: | + The 1-based position of an enabled, non-dependent custom expense field in the organization's custom order. + example: 1 expense_field_in: type: object @@ -151,3 +158,12 @@ expense_field_in: description: | This specifies the `id` of the parent expense field and denotes that the expense field is a dependent custom field. NOTE: `type` must be `DEPENDENT_SELECT`. example: 1234 + +expense_field_reorder_in: + type: object + additionalProperties: false + required: + - id + properties: + id: + $ref: './fields.yaml#/id_integer' From 762d5e14e7ea4d73dc6619ec3e6c0e8d3eabcc87 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Tue, 28 Jul 2026 17:44:14 +0530 Subject: [PATCH 083/107] feat: notify platform-types repo on reference change (#853) --- .github/workflows/notify-types-repo.yml | 36 +++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .github/workflows/notify-types-repo.yml diff --git a/.github/workflows/notify-types-repo.yml b/.github/workflows/notify-types-repo.yml new file mode 100644 index 000000000..31d734ff1 --- /dev/null +++ b/.github/workflows/notify-types-repo.yml @@ -0,0 +1,36 @@ +name: Notify types repo on spec change + +# Fires after the bundler commits regenerated specs to reference/. +# The bundler commits via a PAT, so its push re-triggers this workflow, +# and the reference/** path filter ensures we only notify on real changes. +on: + push: + branches: + - main + paths: + - 'reference/**' + +permissions: + contents: read + +jobs: + notify: + name: Dispatch to fyle-platform-types + runs-on: ubuntu-latest + steps: + - name: Generate token for fyle-platform-types + id: app-token + uses: actions/create-github-app-token@v3 + with: + app-id: ${{ secrets.GH_TYPES_DISPATCH_APP_ID }} + private-key: ${{ secrets.GH_TYPES_DISPATCH_APP_PRIVATE_KEY }} + owner: fylein + repositories: fyle-platform-types + + - name: Notify fyle-platform-types of spec change + uses: peter-evans/repository-dispatch@v3 + with: + token: ${{ steps.app-token.outputs.token }} + repository: fylein/fyle-platform-types + event-type: specs-updated + client-payload: '{"sha": "${{ github.sha }}", "ref": "${{ github.ref }}"}' From 7e13c5a5c2f81eb3e68fb096c5db43f210c0e29a Mon Sep 17 00:00:00 2001 From: Aniruddha Shriwant Date: Fri, 31 Jul 2026 14:01:31 +0530 Subject: [PATCH 084/107] feat: add departments bulk delete OpenAPI contracts (#846) --- reference/admin.yaml | 169 ++++++++++++++++++ src/admin/openapi.yaml | 4 + .../paths/admin@departments@delete@bulk.yaml | 75 ++++++++ ...admin@departments@delete_summary@bulk.yaml | 62 +++++++ src/components/schemas/department.yaml | 34 +++- 5 files changed, 343 insertions(+), 1 deletion(-) create mode 100644 src/admin/paths/admin@departments@delete@bulk.yaml create mode 100644 src/admin/paths/admin@departments@delete_summary@bulk.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index d270dcd91..cbd938dae 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -1875,6 +1875,147 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/departments/delete/bulk: + post: + tags: + - Departments + security: + - oauth2: + - '*' + summary: Delete departments + description: | + Deletes unused departments. If any supplied department is assigned to an employee or used + by a budget, expense policy, or expense rule, the request fails without deleting any + departments. A maximum of 200 unique department IDs can be processed. Repeated IDs are + deduplicated in first-seen order before the limit is enforced. + operationId: departments_delete_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/department_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + examples: + limit_exceeded: + summary: More than 200 unique department IDs supplied + value: + message: Cannot perform action for more than 200 departments at once. + data: null + error: InvalidUsage + dependency_blocked: + summary: A department is assigned or used by another resource + value: + message: Can not delete department(s) used in other resources like employee assignments, budgets, expense policy, expense rules. + data: null + error: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + /admin/departments/delete_summary/bulk: + post: + tags: + - Departments + security: + - oauth2: + - '*' + summary: Create delete summary for departments + description: | + Returns how many of the supplied departments can be deleted and lists those departments. + Departments assigned to employees or used by budgets, expense policies, or expense rules + are excluded. A maximum of 200 unique department IDs can be processed. Repeated IDs are + deduplicated in first-seen order before the limit is enforced. + operationId: departments_delete_summary_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/department_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/department_delete_summary_out' + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + example: Cannot perform action for more than 200 departments at once. + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /admin/mileage_rates: get: tags: @@ -17099,6 +17240,34 @@ components: description: | Link to an external document that would be shared with employees example: https://stoplight.io/ + department_in_only_id: + type: object + required: + - id + additionalProperties: false + properties: + id: + $ref: '#/components/schemas/id_string' + department_delete_summary_out: + type: object + additionalProperties: false + properties: + data: + type: object + additionalProperties: false + properties: + delete_count: + type: integer + description: Count of departments that can be deleted from the supplied departments. + example: 2 + departments: + type: array + description: Departments that can be deleted. + example: + - id: deptTqSvgYSlMk + - id: deptISw67iupk3 + items: + $ref: '#/components/schemas/department_in_only_id' mileage_rate_out: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index c29a0d918..495ae6b4d 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -195,6 +195,10 @@ paths: $ref: paths/admin@per_diem_rates@delete_summary@bulk.yaml /admin/departments: $ref: paths/admin@departments.yaml + /admin/departments/delete/bulk: + $ref: paths/admin@departments@delete@bulk.yaml + /admin/departments/delete_summary/bulk: + $ref: paths/admin@departments@delete_summary@bulk.yaml /admin/mileage_rates: $ref: paths/admin@mileage_rates.yaml /admin/mileage_rates/bulk: diff --git a/src/admin/paths/admin@departments@delete@bulk.yaml b/src/admin/paths/admin@departments@delete@bulk.yaml new file mode 100644 index 000000000..302a642d2 --- /dev/null +++ b/src/admin/paths/admin@departments@delete@bulk.yaml @@ -0,0 +1,75 @@ +post: + tags: + - Departments + security: + - oauth2: ['*'] + summary: Delete departments + description: | + Deletes unused departments. If any supplied department is assigned to an employee or used + by a budget, expense policy, or expense rule, the request fails without deleting any + departments. A maximum of 200 unique department IDs can be processed. Repeated IDs are + deduplicated in first-seen order before the limit is enforced. + operationId: departments_delete_bulk_post + requestBody: + required: True + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: '../../components/schemas/department.yaml#/department_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + examples: + limit_exceeded: + summary: More than 200 unique department IDs supplied + value: + message: Cannot perform action for more than 200 departments at once. + data: null + error: InvalidUsage + dependency_blocked: + summary: A department is assigned or used by another resource + value: + message: Can not delete department(s) used in other resources like employee assignments, budgets, expense policy, expense rules. + data: null + error: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' diff --git a/src/admin/paths/admin@departments@delete_summary@bulk.yaml b/src/admin/paths/admin@departments@delete_summary@bulk.yaml new file mode 100644 index 000000000..f8b63e153 --- /dev/null +++ b/src/admin/paths/admin@departments@delete_summary@bulk.yaml @@ -0,0 +1,62 @@ +post: + tags: + - Departments + security: + - oauth2: ['*'] + summary: Create delete summary for departments + description: | + Returns how many of the supplied departments can be deleted and lists those departments. + Departments assigned to employees or used by budgets, expense policies, or expense rules + are excluded. A maximum of 200 unique department IDs can be processed. Repeated IDs are + deduplicated in first-seen order before the limit is enforced. + operationId: departments_delete_summary_bulk_post + requestBody: + required: True + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: '../../components/schemas/department.yaml#/department_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '../../components/schemas/department.yaml#/department_delete_summary_out' + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + example: Cannot perform action for more than 200 departments at once. + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' diff --git a/src/components/schemas/department.yaml b/src/components/schemas/department.yaml index ac65cb43d..976a4bb0a 100644 --- a/src/components/schemas/department.yaml +++ b/src/components/schemas/department.yaml @@ -136,4 +136,36 @@ department_in: nullable: true description: | Link to an external document that would be shared with employees - example: https://stoplight.io/ \ No newline at end of file + example: https://stoplight.io/ + + +department_in_only_id: + type: object + required: + - id + additionalProperties: False + properties: + id: + $ref: './fields.yaml#/id_string' + + +department_delete_summary_out: + type: object + additionalProperties: False + properties: + data: + type: object + additionalProperties: False + properties: + delete_count: + type: integer + description: Count of departments that can be deleted from the supplied departments. + example: 2 + departments: + type: array + description: Departments that can be deleted. + example: + - id: deptTqSvgYSlMk + - id: deptISw67iupk3 + items: + $ref: './department.yaml#/department_in_only_id' From 5c17edc219bd859a5207bf22e1ee4b583d3fbe9f Mon Sep 17 00:00:00 2001 From: Aniruddha Shriwant Date: Fri, 31 Jul 2026 14:02:49 +0530 Subject: [PATCH 085/107] feat: add levels bulk delete OpenAPI contracts (#849) --- reference/admin.yaml | 168 ++++++++++++++++++ src/admin/openapi.yaml | 4 + src/admin/paths/admin@levels@delete@bulk.yaml | 75 ++++++++ .../admin@levels@delete_summary@bulk.yaml | 61 +++++++ src/components/schemas/level.yaml | 32 ++++ 5 files changed, 340 insertions(+) create mode 100644 src/admin/paths/admin@levels@delete@bulk.yaml create mode 100644 src/admin/paths/admin@levels@delete_summary@bulk.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index cbd938dae..c609fa7c3 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -2406,6 +2406,146 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/levels/delete/bulk: + post: + tags: + - Levels + security: + - oauth2: + - '*' + summary: Delete levels + description: | + Deletes unused levels. If any supplied level is assigned to an employee or used in an + expense policy, the request fails without deleting any levels. A maximum of 200 unique + level IDs can be processed. Repeated IDs are deduplicated in first-seen order before the + limit is enforced. + operationId: levels_delete_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/level_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + examples: + limit_exceeded: + summary: More than 200 unique level IDs supplied + value: + message: Cannot perform action for more than 200 levels at once. + data: null + error: InvalidUsage + dependency_blocked: + summary: A level is assigned or used by another resource + value: + message: Can not delete level(s) used in other resources like employee assignments, expense policy. + data: null + error: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + /admin/levels/delete_summary/bulk: + post: + tags: + - Levels + security: + - oauth2: + - '*' + summary: Get levels delete summary + description: | + Returns levels that can be deleted from the supplied IDs. Levels assigned to employees or + used in expense policies are excluded. A maximum of 200 unique level IDs can be processed. + Repeated IDs are deduplicated in first-seen order before the limit is enforced. + operationId: levels_delete_summary_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/level_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/level_delete_summary_out' + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + example: Cannot perform action for more than 200 levels at once. + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /admin/employees: get: tags: @@ -17462,6 +17602,34 @@ components: required: - name - is_enabled + level_in_only_id: + type: object + required: + - id + additionalProperties: false + properties: + id: + $ref: '#/components/schemas/id_string' + level_delete_summary_out: + type: object + additionalProperties: false + properties: + data: + type: object + additionalProperties: false + properties: + delete_count: + type: integer + description: Count of levels that can be deleted from the supplied levels. + example: 2 + levels: + type: array + description: Levels that can be deleted. + example: + - id: lvlTqSvgYSlMk + - id: lvlISw67iupk3 + items: + $ref: '#/components/schemas/level_in_only_id' fk_string: type: string nullable: true diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 495ae6b4d..551e928d9 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -209,6 +209,10 @@ paths: $ref: paths/admin@mileage_rates@delete_summary@bulk.yaml /admin/levels: $ref: paths/admin@levels.yaml + /admin/levels/delete/bulk: + $ref: paths/admin@levels@delete@bulk.yaml + /admin/levels/delete_summary/bulk: + $ref: paths/admin@levels@delete_summary@bulk.yaml /admin/employees: $ref: paths/admin@employees.yaml /admin/employees/stats: diff --git a/src/admin/paths/admin@levels@delete@bulk.yaml b/src/admin/paths/admin@levels@delete@bulk.yaml new file mode 100644 index 000000000..15cc18888 --- /dev/null +++ b/src/admin/paths/admin@levels@delete@bulk.yaml @@ -0,0 +1,75 @@ +post: + tags: + - Levels + security: + - oauth2: ['*'] + summary: Delete levels + description: | + Deletes unused levels. If any supplied level is assigned to an employee or used in an + expense policy, the request fails without deleting any levels. A maximum of 200 unique + level IDs can be processed. Repeated IDs are deduplicated in first-seen order before the + limit is enforced. + operationId: levels_delete_bulk_post + requestBody: + required: True + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: '../../components/schemas/level.yaml#/level_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + examples: + limit_exceeded: + summary: More than 200 unique level IDs supplied + value: + message: Cannot perform action for more than 200 levels at once. + data: null + error: InvalidUsage + dependency_blocked: + summary: A level is assigned or used by another resource + value: + message: Can not delete level(s) used in other resources like employee assignments, expense policy. + data: null + error: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' diff --git a/src/admin/paths/admin@levels@delete_summary@bulk.yaml b/src/admin/paths/admin@levels@delete_summary@bulk.yaml new file mode 100644 index 000000000..a605f38cd --- /dev/null +++ b/src/admin/paths/admin@levels@delete_summary@bulk.yaml @@ -0,0 +1,61 @@ +post: + tags: + - Levels + security: + - oauth2: ['*'] + summary: Get levels delete summary + description: | + Returns levels that can be deleted from the supplied IDs. Levels assigned to employees or + used in expense policies are excluded. A maximum of 200 unique level IDs can be processed. + Repeated IDs are deduplicated in first-seen order before the limit is enforced. + operationId: levels_delete_summary_bulk_post + requestBody: + required: True + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + type: array + items: + $ref: '../../components/schemas/level.yaml#/level_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '../../components/schemas/level.yaml#/level_delete_summary_out' + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + example: Cannot perform action for more than 200 levels at once. + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' diff --git a/src/components/schemas/level.yaml b/src/components/schemas/level.yaml index 73a07a96e..0c038bbf7 100644 --- a/src/components/schemas/level.yaml +++ b/src/components/schemas/level.yaml @@ -97,3 +97,35 @@ level_in: required: - name - is_enabled + + +level_in_only_id: + type: object + required: + - id + additionalProperties: False + properties: + id: + $ref: './fields.yaml#/id_string' + + +level_delete_summary_out: + type: object + additionalProperties: False + properties: + data: + type: object + additionalProperties: False + properties: + delete_count: + type: integer + description: Count of levels that can be deleted from the supplied levels. + example: 2 + levels: + type: array + description: Levels that can be deleted. + example: + - id: lvlTqSvgYSlMk + - id: lvlISw67iupk3 + items: + $ref: './level.yaml#/level_in_only_id' From 26b9112c02aafb13f6840ea11f3466d1ef1932cf Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 5 Aug 2026 15:56:31 +0530 Subject: [PATCH 086/107] chore: update required fields (#855) --- reference/accountant.yaml | 6 + reference/admin.yaml | 1568 ++++++++++++++--- reference/approver.yaml | 401 +++++ reference/common.yaml | 20 + reference/hod.yaml | 6 + reference/hop.yaml | 6 + reference/manager.yaml | 152 ++ reference/spender.yaml | 795 ++++++++- .../admin@accounting_export_lineitems.yaml | 2 + src/admin/paths/admin@accounting_exports.yaml | 2 + src/admin/paths/admin@accounts.yaml | 2 + src/admin/paths/admin@advance_refunds.yaml | 2 + .../paths/admin@advance_refunds@stats.yaml | 2 + src/admin/paths/admin@advance_requests.yaml | 2 + .../admin@advance_requests@add_approver.yaml | 4 + ...min@advance_requests@bulk_attach_file.yaml | 2 + .../admin@advance_requests@comments.yaml | 4 + .../admin@advance_requests@custom_fields.yaml | 2 + .../paths/admin@advance_requests@inquire.yaml | 2 + .../admin@advance_requests@permissions.yaml | 2 + .../paths/admin@advance_requests@reject.yaml | 2 + ...dmin@advance_requests@remove_approver.yaml | 4 + .../paths/admin@advance_requests@stats.yaml | 2 + .../paths/admin@advance_requests@submit.yaml | 2 + src/admin/paths/admin@advance_wallets.yaml | 2 + src/admin/paths/admin@advances.yaml | 2 + src/admin/paths/admin@advances@stats.yaml | 2 + .../admin@automations@report_submissions.yaml | 2 + ...automations@report_submissions@delete.yaml | 2 + src/admin/paths/admin@budgets.yaml | 2 + src/admin/paths/admin@budgets@exports.yaml | 2 + src/admin/paths/admin@categories.yaml | 2 + .../admin@categories@system_categories.yaml | 1 + .../admin@corporate_card_transactions.yaml | 2 + ...in@corporate_card_transactions@assign.yaml | 2 + ...in@corporate_card_transactions@delete.yaml | 2 + ...card_transactions@delete_summary@bulk.yaml | 2 + ...rd_transactions@export_configurations.yaml | 2 + ...n@corporate_card_transactions@exports.yaml | 2 + ...n@corporate_card_transactions@filters.yaml | 2 + ...rate_card_transactions@filters@delete.yaml | 2 + ...in@corporate_card_transactions@ignore.yaml | 2 + ...orate_card_transactions@mark_personal.yaml | 2 + ...min@corporate_card_transactions@match.yaml | 2 + ...min@corporate_card_transactions@stats.yaml | 2 + ...@corporate_card_transactions@unassign.yaml | 2 + ...rporate_card_transactions@undo_ignore.yaml | 2 + ...ate_card_transactions@unmark_personal.yaml | 2 + ...n@corporate_card_transactions@unmatch.yaml | 2 + src/admin/paths/admin@corporate_cards.yaml | 2 + .../paths/admin@corporate_cards@archive.yaml | 2 + ...ate_cards@archive_suggestions@dismiss.yaml | 2 + .../paths/admin@corporate_cards@assign.yaml | 2 + .../admin@corporate_cards@bank_names.yaml | 2 + .../paths/admin@corporate_cards@delete.yaml | 2 + ...e_cards@duplicate_suggestions@dismiss.yaml | 2 + .../paths/admin@corporate_cards@merge.yaml | 2 + .../paths/admin@corporate_cards@reassign.yaml | 2 + .../paths/admin@corporate_cards@stats.yaml | 2 + .../admin@corporate_cards@unarchive.yaml | 2 + .../admin@corporate_cards@unarchive@bulk.yaml | 2 + .../paths/admin@corporate_cards@unassign.yaml | 2 + src/admin/paths/admin@cost_centers.yaml | 2 + src/admin/paths/admin@departments.yaml | 2 + ...endent_expense_field_values@downloads.yaml | 2 + ...ependent_expense_field_values@uploads.yaml | 2 + src/admin/paths/admin@dwolla_customers.yaml | 2 + src/admin/paths/admin@employee_fields.yaml | 2 + .../paths/admin@employees@downloads.yaml | 2 + ...admin@employees@export_configurations.yaml | 2 + src/admin/paths/admin@employees@exports.yaml | 2 + src/admin/paths/admin@employees@filters.yaml | 2 + .../paths/admin@employees@filters@delete.yaml | 2 + src/admin/paths/admin@employees@stats.yaml | 2 + src/admin/paths/admin@employees@uploads.yaml | 2 + src/admin/paths/admin@expense_fields.yaml | 2 + src/admin/paths/admin@expense_policies.yaml | 2 + .../paths/admin@expense_policies@disable.yaml | 2 + .../paths/admin@expense_policies@enable.yaml | 2 + .../paths/admin@expense_policy_comments.yaml | 2 + src/admin/paths/admin@expenses.yaml | 4 + .../admin@expenses@attach_files@bulk.yaml | 2 + src/admin/paths/admin@expenses@bulk.yaml | 4 + .../admin@expenses@check_policies_bulk.yaml | 2 + .../paths/admin@expenses@comments@bulk.yaml | 4 + .../admin@expenses@export_configurations.yaml | 2 + src/admin/paths/admin@expenses@exports.yaml | 2 + src/admin/paths/admin@expenses@filters.yaml | 2 + .../paths/admin@expenses@filters@delete.yaml | 2 + src/admin/paths/admin@expenses@merge.yaml | 4 + .../paths/admin@expenses@permissions.yaml | 2 + .../admin@expenses@permissions@bulk.yaml | 2 + src/admin/paths/admin@expenses@split.yaml | 4 + ...expenses@split@check_mandatory_fields.yaml | 4 + .../admin@expenses@split@check_policies.yaml | 4 + src/admin/paths/admin@expenses@stats.yaml | 2 + src/admin/paths/admin@files.yaml | 2 + src/admin/paths/admin@files@bulk.yaml | 2 + .../paths/admin@files@generate_urls@bulk.yaml | 2 + src/admin/paths/admin@levels.yaml | 2 + src/admin/paths/admin@mileage_rates.yaml | 2 + src/admin/paths/admin@per_diem_rates.yaml | 2 + src/admin/paths/admin@projects.yaml | 2 + .../admin@reconciliation_entries@close.yaml | 2 + ...iation_entries@eligible_cards@exports.yaml | 2 + ...iliation_entries@eligible_cards@stats.yaml | 2 + ...tion_entries@transactions@delete@bulk.yaml | 2 + ...iliation_entries@transactions@exports.yaml | 2 + ...ation_entries@transactions@find_match.yaml | 2 + ...transactions@match_and_reconcile@bulk.yaml | 2 + ...transactions@move_to_next_period@bulk.yaml | 2 + ...n_entries@transactions@reconcile@bulk.yaml | 2 + ...es@transactions@resolve_multi_matches.yaml | 2 + ...nciliation_entries@transactions@stats.yaml | 2 + ...ion_entries@transactions@unmatch@bulk.yaml | 2 + .../admin@reimbursements@mark_complete.yaml | 2 + src/admin/paths/admin@reminders.yaml | 2 + src/admin/paths/admin@reminders@delete.yaml | 2 + src/admin/paths/admin@reminders@stats.yaml | 2 + .../paths/admin@reports@add_approver.yaml | 2 + .../admin@reports@apply_advance_wallets.yaml | 2 + src/admin/paths/admin@reports@comments.yaml | 2 + .../paths/admin@reports@delete_filter.yaml | 2 + .../paths/admin@reports@eject_expenses.yaml | 2 + .../admin@reports@export_configurations.yaml | 2 + src/admin/paths/admin@reports@exports.yaml | 2 + .../paths/admin@reports@permissions.yaml | 2 + .../admin@reports@process_summary@bulk.yaml | 2 + .../admin@reports@remove_advance_wallets.yaml | 2 + .../paths/admin@reports@remove_approver.yaml | 2 + .../admin@reports@revert_to_approved.yaml | 2 + .../admin@reports@revert_to_processing.yaml | 2 + .../paths/admin@reports@round_off_amount.yaml | 2 + .../paths/admin@reports@save_filters.yaml | 2 + src/admin/paths/admin@reports@send_back.yaml | 2 + src/admin/paths/admin@reports@stats.yaml | 2 + .../paths/admin@scheduled_callbacks.yaml | 2 + src/admin/paths/admin@schedules.yaml | 2 + .../admin@statements@archived_cards.yaml | 2 + ...dmin@statements@archived_cards@ignore.yaml | 2 + .../paths/admin@statements@card_stats.yaml | 2 + .../admin@statements@matching_cards.yaml | 2 + src/admin/paths/admin@statements@preview.yaml | 2 + .../paths/admin@statements@reconcile.yaml | 2 + ...min@statements@reconciliation_summary.yaml | 2 + .../admin@statements@suggest_mappings.yaml | 4 + src/admin/paths/admin@statements@summary.yaml | 2 + .../admin@statements@unassigned_cards.yaml | 2 + src/admin/paths/admin@statements@upload.yaml | 2 + src/admin/paths/admin@subscriptions.yaml | 4 + src/admin/paths/admin@tax_groups.yaml | 2 + .../paths/admin@virtual_cards@delete.yaml | 2 + ...dmin@virtual_cards@get_current_amount.yaml | 2 + ...admin@virtual_cards@show_card_details.yaml | 2 + ...pprover@advance_requests@add_approver.yaml | 4 + ...ver@advance_requests@bulk_attach_file.yaml | 2 + .../approver@advance_requests@comments.yaml | 4 + ...ance_requests@generate_file_urls@bulk.yaml | 2 + .../approver@advance_requests@inquire.yaml | 2 + ...er@advance_requests@partially_approve.yaml | 2 + ...approver@advance_requests@permissions.yaml | 2 + .../approver@advance_requests@reject.yaml | 2 + .../approver@advance_requests@stats.yaml | 2 + .../approver@advance_requests@submit.yaml | 2 + ...ver@corporate_card_transactions@match.yaml | 2 + ...r@corporate_card_transactions@unmatch.yaml | 2 + ...over@employee_overview@expenses@stats.yaml | 2 + .../approver@employee_overview@stats.yaml | 2 + src/approver/paths/approver@expenses.yaml | 4 + .../approver@expenses@attach_files@bulk.yaml | 2 + .../paths/approver@expenses@bulk.yaml | 4 + ...approver@expenses@check_policies_bulk.yaml | 2 + .../approver@expenses@comments@bulk.yaml | 4 + ...prover@expenses@export_configurations.yaml | 2 + .../paths/approver@expenses@exports.yaml | 2 + .../paths/approver@expenses@filters.yaml | 2 + .../approver@expenses@filters@delete.yaml | 2 + .../paths/approver@expenses@permissions.yaml | 2 + .../approver@expenses@permissions@bulk.yaml | 2 + .../paths/approver@expenses@split.yaml | 4 + ...expenses@split@check_mandatory_fields.yaml | 4 + ...pprover@expenses@split@check_policies.yaml | 4 + .../paths/approver@expenses@stats.yaml | 2 + src/approver/paths/approver@files@bulk.yaml | 2 + .../approver@files@generate_urls@bulk.yaml | 2 + .../paths/approver@reports@add_approver.yaml | 2 + .../paths/approver@reports@add_expenses.yaml | 2 + .../paths/approver@reports@comments.yaml | 2 + .../approver@reports@eject_expenses.yaml | 2 + ...pprover@reports@export_configurations.yaml | 2 + .../paths/approver@reports@exports.yaml | 2 + .../paths/approver@reports@filters.yaml | 2 + .../approver@reports@filters@delete.yaml | 2 + .../approver@reports@partially_approve.yaml | 2 + .../paths/approver@reports@permissions.yaml | 2 + .../approver@reports@round_off_amount.yaml | 2 + .../paths/approver@reports@send_back.yaml | 2 + .../paths/approver@reports@stats.yaml | 2 + .../paths/approver@subscriptions.yaml | 4 + ...g_logo_settings@generate_download_url.yaml | 2 + src/components/schemas/account.yaml | 24 + src/components/schemas/advance.yaml | 11 + src/components/schemas/advance_refund.yaml | 5 + src/components/schemas/advance_request.yaml | 30 + .../schemas/advance_request_approval.yaml | 4 + src/components/schemas/advance_wallet.yaml | 3 + src/components/schemas/automation.yaml | 3 + src/components/schemas/budget.yaml | 7 + src/components/schemas/budget_exports.yaml | 9 + src/components/schemas/category.yaml | 12 + src/components/schemas/corporate_card.yaml | 29 + .../schemas/corporate_card_transaction.yaml | 35 + .../corporate_card_transactions_exports.yaml | 14 + .../corporate_credit_card_expense.yaml | 4 + src/components/schemas/cost_center.yaml | 6 + src/components/schemas/currency.yaml | 2 + src/components/schemas/department.yaml | 13 + .../dependent_expense_field_values.yaml | 36 + src/components/schemas/dwolla_customer.yaml | 46 + src/components/schemas/employee.yaml | 175 +- .../schemas/employee_account_summary.yaml | 18 + src/components/schemas/employee_settings.yaml | 23 + .../employees_export_configurations.yaml | 2 + src/components/schemas/employees_exports.yaml | 14 + src/components/schemas/expense.yaml | 46 + .../schemas/expense_duplicate_set.yaml | 5 + src/components/schemas/expense_field.yaml | 19 + src/components/schemas/expense_policies.yaml | 3 + src/components/schemas/expense_rules.yaml | 16 + .../expenses_export_configurations.yaml | 2 + src/components/schemas/expenses_exports.yaml | 11 + src/components/schemas/feature_configs.yaml | 11 + src/components/schemas/fields.yaml | 6 + src/components/schemas/file.yaml | 27 + src/components/schemas/level.yaml | 2 + src/components/schemas/merchant.yaml | 11 + src/components/schemas/mileage_rate.yaml | 14 + .../schemas/mobile_app_version.yaml | 7 + src/components/schemas/my_profile.yaml | 6 + src/components/schemas/org.yaml | 26 + src/components/schemas/org_settings.yaml | 5 + src/components/schemas/per_diem_rate.yaml | 6 + src/components/schemas/personal_card.yaml | 21 + .../schemas/personal_card_transaction.yaml | 34 + src/components/schemas/place.yaml | 11 + src/components/schemas/policy.yaml | 3 + src/components/schemas/project.yaml | 11 + .../reconciliation_eligible_cards.yaml | 15 + .../schemas/reconciliation_exports.yaml | 9 + .../schemas/reconciliation_transactions.yaml | 26 + src/components/schemas/recurring_expense.yaml | 6 +- src/components/schemas/reimbursement.yaml | 8 + src/components/schemas/reminder.yaml | 12 + src/components/schemas/report.yaml | 36 + src/components/schemas/report_approval.yaml | 6 + .../reports_export_configurations.yaml | 2 + src/components/schemas/schedule.yaml | 8 + .../schemas/scheduled_callback.yaml | 14 + src/components/schemas/secondary_email.yaml | 8 + src/components/schemas/spend_overview.yaml | 42 + src/components/schemas/statements.yaml | 40 + src/components/schemas/subscriptions.yaml | 22 + src/components/schemas/user.yaml | 19 + ...ager@employee_overview@expenses@stats.yaml | 2 + ...yee_overview@files@generate_urls@bulk.yaml | 2 + .../manager@employee_overview@stats.yaml | 2 + src/spender/openapi.yaml | 2 +- .../paths/spender@advance_request_files.yaml | 2 + .../paths/spender@advance_requests.yaml | 2 + ...der@advance_requests@bulk_attach_file.yaml | 2 + .../spender@advance_requests@comments.yaml | 4 + .../spender@advance_requests@permissions.yaml | 2 + .../spender@advance_requests@pull_back.yaml | 2 + .../paths/spender@advance_requests@stats.yaml | 2 + .../spender@advance_requests@submit.yaml | 2 + src/spender/paths/spender@advances@stats.yaml | 2 + ...pender@automations@recurring_expenses.yaml | 2 + ...utomations@recurring_expenses@disable.yaml | 2 + ...rate_card_transactions@expenses@stats.yaml | 2 + ...er@corporate_card_transactions@ignore.yaml | 2 + ...orate_card_transactions@mark_personal.yaml | 2 + ...der@corporate_card_transactions@match.yaml | 2 + ...rporate_card_transactions@undo_ignore.yaml | 2 + ...ate_card_transactions@unmark_personal.yaml | 2 + ...r@corporate_card_transactions@unmatch.yaml | 2 + src/spender/paths/spender@email_files.yaml | 2 + src/spender/paths/spender@employees.yaml | 2 + src/spender/paths/spender@expense_files.yaml | 2 + .../spender@expense_policy_comments.yaml | 2 + .../spender@expenses@attach_files@bulk.yaml | 2 + .../spender@expenses@attach_receipt.yaml | 2 + src/spender/paths/spender@expenses@bulk.yaml | 4 + .../spender@expenses@check_policies.yaml | 2 + .../spender@expenses@check_policies_bulk.yaml | 2 + .../paths/spender@expenses@comments@bulk.yaml | 4 + ...pender@expenses@create_from_file@bulk.yaml | 2 + .../spender@expenses@create_from_receipt.yaml | 2 + ...pender@expenses@export_configurations.yaml | 2 + .../paths/spender@expenses@exports.yaml | 2 + .../paths/spender@expenses@filters.yaml | 2 + .../spender@expenses@filters@delete.yaml | 2 + src/spender/paths/spender@expenses@merge.yaml | 4 + .../paths/spender@expenses@permissions.yaml | 2 + .../spender@expenses@permissions@bulk.yaml | 2 + .../paths/spender@expenses@policy_test.yaml | 4 + src/spender/paths/spender@expenses@split.yaml | 4 + ...expenses@split@check_mandatory_fields.yaml | 4 + ...spender@expenses@split@check_policies.yaml | 4 + src/spender/paths/spender@expenses@stats.yaml | 2 + src/spender/paths/spender@files.yaml | 2 + src/spender/paths/spender@files@bulk.yaml | 2 + .../paths/spender@files@generate_urls.yaml | 2 + .../spender@files@generate_urls@bulk.yaml | 2 + .../paths/spender@files@upload_html.yaml | 2 + ...nder@personal_card_transactions@stats.yaml | 2 + src/spender/paths/spender@personal_cards.yaml | 2 + .../paths/spender@reports@add_expenses.yaml | 2 + .../paths/spender@reports@comments.yaml | 2 + .../paths/spender@reports@eject_expenses.yaml | 2 + ...spender@reports@export_configurations.yaml | 2 + .../paths/spender@reports@exports.yaml | 2 + .../paths/spender@reports@filters.yaml | 2 + .../paths/spender@reports@filters@delete.yaml | 2 + .../paths/spender@reports@permissions.yaml | 2 + .../paths/spender@reports@resubmit.yaml | 2 + src/spender/paths/spender@reports@stats.yaml | 2 + src/spender/paths/spender@reports@submit.yaml | 2 + .../spender@reports@suggest_purpose.yaml | 2 + src/spender/paths/spender@schedules.yaml | 2 + .../paths/spender@secondary_emails.yaml | 2 + .../paths/spender@secondary_emails@check.yaml | 2 + .../spender@secondary_emails@delete.yaml | 2 + src/spender/paths/spender@subscriptions.yaml | 4 + ...nder@virtual_cards@get_current_amount.yaml | 2 + ...ender@virtual_cards@show_card_details.yaml | 2 + 335 files changed, 4389 insertions(+), 253 deletions(-) diff --git a/reference/accountant.yaml b/reference/accountant.yaml index 67e660e74..4d6485071 100644 --- a/reference/accountant.yaml +++ b/reference/accountant.yaml @@ -190,6 +190,12 @@ components: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/admin.yaml b/reference/admin.yaml index c609fa7c3..678ec673e 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -182,6 +182,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_approver_project_out' @@ -439,6 +441,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_cost_center_out' @@ -690,6 +694,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_approver_category_out' @@ -892,6 +898,7 @@ paths: additionalProperties: false required: - data + - count properties: count: $ref: '#/components/schemas/count' @@ -974,6 +981,8 @@ paths: application/json: schema: type: object + required: + - data properties: url: type: string @@ -1330,6 +1339,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/dependent_expense_field_values_upload_out' @@ -1422,6 +1433,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/dependent_expense_field_values_download_out' @@ -1512,6 +1525,8 @@ paths: application/json: schema: type: object + required: + - data properties: url: type: string @@ -1609,6 +1624,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/per_diem_rate_out' @@ -1848,6 +1865,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/department_out' @@ -2082,6 +2101,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/mileage_rate_out' @@ -2379,247 +2400,251 @@ paths: application/json: schema: type: object - properties: - data: - $ref: '#/components/schemas/level_out' - '400': - description: Bad request - content: - application/json: - schema: - $ref: '#/components/schemas/400' - '401': - description: Unauthorized request - content: - application/json: - schema: - $ref: '#/components/schemas/401' - '403': - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/403' - '404': - description: Not Found - content: - application/json: - schema: - $ref: '#/components/schemas/404' - /admin/levels/delete/bulk: - post: - tags: - - Levels - security: - - oauth2: - - '*' - summary: Delete levels - description: | - Deletes unused levels. If any supplied level is assigned to an employee or used in an - expense policy, the request fails without deleting any levels. A maximum of 200 unique - level IDs can be processed. Repeated IDs are deduplicated in first-seen order before the - limit is enforced. - operationId: levels_delete_bulk_post - requestBody: - required: true - content: - application/json: - schema: - type: object - additionalProperties: false - required: - - data - properties: - data: - type: array - items: - $ref: '#/components/schemas/level_in_only_id' - responses: - '200': - description: OK - content: - application/json: - schema: - type: object - additionalProperties: false - '400': - description: Bad request - content: - application/json: - schema: - type: object - properties: - message: - type: string - data: - type: object - nullable: true - example: null - error: - type: string - example: InvalidUsage - examples: - limit_exceeded: - summary: More than 200 unique level IDs supplied - value: - message: Cannot perform action for more than 200 levels at once. - data: null - error: InvalidUsage - dependency_blocked: - summary: A level is assigned or used by another resource - value: - message: Can not delete level(s) used in other resources like employee assignments, expense policy. - data: null - error: InvalidUsage - '401': - description: Unauthorised request - content: - application/json: - schema: - $ref: '#/components/schemas/401' - '403': - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/403' - /admin/levels/delete_summary/bulk: - post: - tags: - - Levels - security: - - oauth2: - - '*' - summary: Get levels delete summary - description: | - Returns levels that can be deleted from the supplied IDs. Levels assigned to employees or - used in expense policies are excluded. A maximum of 200 unique level IDs can be processed. - Repeated IDs are deduplicated in first-seen order before the limit is enforced. - operationId: levels_delete_summary_bulk_post - requestBody: - required: true - content: - application/json: - schema: - type: object - additionalProperties: false - required: - - data - properties: - data: - type: array - items: - $ref: '#/components/schemas/level_in_only_id' - responses: - '200': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/level_delete_summary_out' - '400': - description: Bad request - content: - application/json: - schema: - type: object - properties: - message: - type: string - example: Cannot perform action for more than 200 levels at once. - data: - type: object - nullable: true - example: null - error: - type: string - example: InvalidUsage - '401': - description: Unauthorised request - content: - application/json: - schema: - $ref: '#/components/schemas/401' - '403': - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/403' - /admin/employees: - get: - tags: - - Employees - summary: List employees - operationId: employees_list - description: | - This API supports very rich filtering on all response fields and pagination via query parameters. To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) - parameters: - - $ref: '#/components/parameters/q' - responses: - '200': - description: OK - content: - application/json: - schema: - type: object - additionalProperties: false required: - data - - count - - offset - properties: - count: - $ref: '#/components/schemas/count' - offset: - $ref: '#/components/schemas/offset' - data: - type: array - items: - $ref: '#/components/schemas/employee_out' - '400': - description: Bad request - content: - application/json: - schema: - $ref: '#/components/schemas/400' - '401': - description: Unauthorized request - content: - application/json: - schema: - $ref: '#/components/schemas/401' - /admin/employees/stats: - post: - tags: - - Employees - summary: Employees Stats - description: | - Employees Stats - operationId: employees_stats - requestBody: - required: true - content: - application/json: - schema: - type: object - additionalProperties: false - required: - - data - properties: - data: - $ref: '#/components/schemas/employees_stats_in' - responses: - '200': - description: OK - content: - application/json: - schema: - type: object - additionalProperties: false properties: data: - $ref: '#/components/schemas/employees_stats_out' + $ref: '#/components/schemas/level_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/levels/delete/bulk: + post: + tags: + - Levels + security: + - oauth2: + - '*' + summary: Delete levels + description: | + Deletes unused levels. If any supplied level is assigned to an employee or used in an + expense policy, the request fails without deleting any levels. A maximum of 200 unique + level IDs can be processed. Repeated IDs are deduplicated in first-seen order before the + limit is enforced. + operationId: levels_delete_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/level_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + examples: + limit_exceeded: + summary: More than 200 unique level IDs supplied + value: + message: Cannot perform action for more than 200 levels at once. + data: null + error: InvalidUsage + dependency_blocked: + summary: A level is assigned or used by another resource + value: + message: Can not delete level(s) used in other resources like employee assignments, expense policy. + data: null + error: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + /admin/levels/delete_summary/bulk: + post: + tags: + - Levels + security: + - oauth2: + - '*' + summary: Get levels delete summary + description: | + Returns levels that can be deleted from the supplied IDs. Levels assigned to employees or + used in expense policies are excluded. A maximum of 200 unique level IDs can be processed. + Repeated IDs are deduplicated in first-seen order before the limit is enforced. + operationId: levels_delete_summary_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/level_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/level_delete_summary_out' + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + example: Cannot perform action for more than 200 levels at once. + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + /admin/employees: + get: + tags: + - Employees + summary: List employees + operationId: employees_list + description: | + This API supports very rich filtering on all response fields and pagination via query parameters. To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + parameters: + - $ref: '#/components/parameters/q' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + - count + - offset + properties: + count: + $ref: '#/components/schemas/count' + offset: + $ref: '#/components/schemas/offset' + data: + type: array + items: + $ref: '#/components/schemas/employee_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + /admin/employees/stats: + post: + tags: + - Employees + summary: Employees Stats + description: | + Employees Stats + operationId: employees_stats + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/employees_stats_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/employees_stats_out' '400': description: Bad request content: @@ -2757,6 +2782,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employees_exports_out' @@ -3004,6 +3031,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employee_filters_out' @@ -3085,6 +3114,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employee_filters_out' @@ -3178,6 +3209,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employees_upload_out' @@ -3271,6 +3304,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employees_download_out' @@ -3507,6 +3542,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employees_export_configuration_out' @@ -3646,6 +3683,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/file_out' @@ -3703,6 +3742,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -3779,6 +3820,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -3937,6 +3980,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/automate_report_submission_out' @@ -4031,6 +4076,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/automate_report_submission_out' @@ -4126,6 +4173,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/accounting_export_out' @@ -4221,6 +4270,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/accounting_export_lineitem_out' @@ -4358,6 +4409,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_expense_in' @@ -4368,6 +4421,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -4409,6 +4464,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_expenses_bulk_in' @@ -4419,6 +4476,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -4478,6 +4537,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -4582,6 +4643,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -4669,6 +4732,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -4793,6 +4858,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expenses_stats_out' @@ -4846,6 +4913,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_exports_out' @@ -5017,6 +5086,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_export_configuration_out' @@ -5158,6 +5229,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_out' @@ -5221,6 +5294,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_bulk_out' @@ -5287,6 +5362,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_merge_in' @@ -5297,6 +5374,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -5397,6 +5476,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -5452,6 +5533,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_requests_stats_out' @@ -5507,6 +5590,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_permissions_out' @@ -5548,6 +5633,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_in' @@ -5558,6 +5645,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_out' @@ -5599,6 +5688,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_remove_approver_in' @@ -5613,6 +5704,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -5723,6 +5816,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_out' @@ -5833,6 +5928,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advances_stats_out' @@ -5933,6 +6030,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_wallet_out' @@ -6033,6 +6132,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_refund_out' @@ -6142,6 +6243,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -6237,6 +6340,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reminder_out' @@ -6291,6 +6396,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -6346,6 +6453,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -6499,6 +6608,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -6546,6 +6657,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -6633,6 +6746,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -6687,6 +6802,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_comments_out' @@ -6736,6 +6853,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -6789,6 +6908,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -6899,6 +7020,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -6954,6 +7077,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7014,6 +7139,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7258,6 +7385,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -7387,6 +7516,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reports_stats_out' @@ -7482,6 +7613,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_permissions_out' @@ -7536,6 +7669,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7585,6 +7720,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7632,6 +7769,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7718,6 +7857,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_exports_out' @@ -7812,6 +7953,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_export_configuration_out' @@ -7995,6 +8138,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8097,6 +8242,8 @@ paths: properties: data: type: object + required: + - bank_names properties: bank_names: type: array @@ -8191,6 +8338,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_stats_out' @@ -8245,6 +8394,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8299,6 +8450,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_unassign_out' @@ -8353,6 +8506,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8407,6 +8562,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8461,6 +8618,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8515,6 +8674,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8569,6 +8730,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8624,6 +8787,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -8733,6 +8898,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_duplicate_suggestion_out' @@ -8834,6 +9001,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_archive_suggestion_out' @@ -8933,6 +9102,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_post_out' @@ -9041,6 +9212,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -9098,6 +9271,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -9155,6 +9330,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -9211,6 +9388,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_filters_out' @@ -9292,6 +9471,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_filters_out' @@ -9345,6 +9526,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_assign_out' @@ -9506,6 +9689,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unassign_out' @@ -9559,6 +9744,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_mark_personal_out' @@ -9666,6 +9853,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmark_personal_out' @@ -9719,6 +9908,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_ignore_out' @@ -9826,6 +10017,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_undo_ignore_out' @@ -9879,6 +10072,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_match_out' @@ -9932,6 +10127,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmatch_out' @@ -9985,6 +10182,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transactions_exports_out' @@ -10079,6 +10278,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/virtual_cards_get_current_balance_out' @@ -10133,6 +10334,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/virtual_cards_show_card_details_out' @@ -10187,6 +10390,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/virtual_card_out' @@ -10228,6 +10433,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_subscriptions_in' @@ -10239,6 +10446,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_subscriptions_out' @@ -10484,6 +10693,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/schedule_out' @@ -10572,6 +10783,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/scheduled_callback_out' @@ -11136,6 +11349,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/account_out' @@ -11225,6 +11440,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/tax_group_out' @@ -11335,6 +11552,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/budget_post_out' @@ -11473,6 +11692,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/budget_exports_out' @@ -11668,6 +11889,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_policy_out' @@ -11795,6 +12018,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_policy_out' @@ -11850,6 +12075,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_policy_out' @@ -12066,6 +12293,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/statements_out' @@ -12173,6 +12402,10 @@ paths: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '#/components/schemas/count' @@ -12226,6 +12459,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/preview_out' @@ -12279,6 +12514,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12334,6 +12571,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12389,6 +12628,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -12444,6 +12685,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12499,6 +12742,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/card_stats_out' @@ -12552,6 +12797,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12782,6 +13029,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12837,6 +13086,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -13211,6 +13462,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_check_policies_bulk_out' @@ -13295,6 +13548,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_comments_bulk_in' @@ -13305,6 +13560,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -13596,6 +13853,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -13606,6 +13865,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -13651,6 +13912,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -13661,6 +13924,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -13707,6 +13972,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -13717,6 +13984,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -14074,6 +14343,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -14164,6 +14435,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -14240,6 +14513,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -14300,6 +14575,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -14431,6 +14708,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -14489,6 +14768,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reconciliation_export_out' @@ -14558,6 +14839,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -14641,6 +14924,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -14716,6 +15001,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -14785,6 +15072,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -14844,6 +15133,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reconciliation_export_out' @@ -14907,6 +15198,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -15075,6 +15368,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -15214,6 +15509,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -15274,6 +15571,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_add_approver_in' @@ -15289,6 +15588,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15358,6 +15659,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15421,6 +15724,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15486,6 +15791,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15591,6 +15898,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_custom_field_out' @@ -15690,6 +15999,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/dwolla_customer_out' @@ -15875,6 +16186,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transactions_export_configuration_out' @@ -16158,6 +16471,10 @@ components: user_out_embed: type: object additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -16378,10 +16695,15 @@ components: $ref: '#/components/schemas/id_integer' project_delete_summary_out: type: object + required: + - data additionalProperties: false properties: data: type: object + required: + - delete_count + - projects properties: delete_count: type: integer @@ -16499,6 +16821,8 @@ components: cost_center_delete_summary_out: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -16645,10 +16969,15 @@ components: $ref: '#/components/schemas/id_integer' category_delete_summary_out: type: object + required: + - data additionalProperties: false properties: data: type: object + required: + - delete_count + - categories properties: delete_count: type: integer @@ -16683,6 +17012,25 @@ components: expense_field_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - seq + - field_name + - column_name + - type + - options + - default_value + - placeholder + - category_ids + - is_enabled + - is_custom + - is_mandatory + - code + - parent_field_id + - display_order properties: id: $ref: '#/components/schemas/id_integer' @@ -16846,6 +17194,16 @@ components: dependent_expense_field_values_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - parent_expense_field_value + - expense_field_value + - is_enabled properties: id: $ref: '#/components/schemas/id_integer' @@ -16919,6 +17277,13 @@ components: dependent_expense_field_values_preview_out: type: object additionalProperties: false + required: + - org_id + - parent_expense_field_id + - expense_field_id + - parent_expense_field_value + - expense_field_values + - is_enabled properties: org_id: $ref: '#/components/schemas/org_id' @@ -16953,6 +17318,16 @@ components: dependent_expense_field_values_upload_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - file_id + - error_file_id + - state properties: id: $ref: '#/components/schemas/id_integer' @@ -17019,6 +17394,15 @@ components: dependent_expense_field_values_download_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - file_id + - state properties: id: $ref: '#/components/schemas/id_integer' @@ -17259,6 +17643,8 @@ components: per_diem_rate_delete_summary_out: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -17391,6 +17777,8 @@ components: department_delete_summary_out: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -17513,10 +17901,15 @@ components: $ref: '#/components/schemas/id_integer' mileage_rate_delete_summary_out: type: object + required: + - data additionalProperties: false properties: data: type: object + required: + - delete_count + - mileage_rates properties: delete_count: type: integer @@ -17613,6 +18006,8 @@ components: level_delete_summary_out: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -17641,6 +18036,11 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -17811,6 +18211,12 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - sub_project + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -17837,6 +18243,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -17852,6 +18262,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -17865,6 +18279,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -18018,6 +18436,13 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - system_category + - name + - sub_category + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -18367,6 +18792,7 @@ components: - user_id - email - full_name + - potential_duplicate_expenses properties: user_id: $ref: '#/components/schemas/user_id' @@ -18509,6 +18935,20 @@ components: Configuration for the export. employees_exports_out: type: object + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state + - processed_at + - completed_at + - failed_at properties: created_at: type: string @@ -18945,6 +19385,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -19170,6 +19614,8 @@ components: - type - org_id - user_id + - created_by + - updated_by properties: id: allOf: @@ -19317,6 +19763,17 @@ components: file_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - created_at + - updated_at + - name + - type + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -19364,6 +19821,12 @@ components: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -19515,6 +19978,9 @@ components: $ref: '#/components/schemas/user_out_embed' automate_report_submission_in: type: object + required: + - description + - schedule_config properties: id: $ref: '#/components/schemas/id_string' @@ -19714,6 +20180,9 @@ components: example: 1234 account_out_embed: type: object + required: + - id + - type properties: id: allOf: @@ -19733,6 +20202,11 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code + - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -19813,6 +20287,12 @@ components: report_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_type + - approver_user + - state + - approver_order properties: approver_user_id: allOf: @@ -19865,6 +20345,9 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num + - amount + - last_verified_at + - approvals properties: id: anyOf: @@ -19953,6 +20436,11 @@ components: List of report_approval objects file_out_embed: type: object + required: + - id + - name + - type + - content_type properties: id: allOf: @@ -19998,6 +20486,9 @@ components: expense_verification_out_embed: type: object additionalProperties: false + required: + - verifier_user_id + - verifier_user properties: verifier_user_id: allOf: @@ -20020,6 +20511,12 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department + - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -20042,6 +20539,25 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - location + - title + - business_unit + - custom_fields + - flattened_custom_field + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -20143,6 +20659,24 @@ components: - id - corporate_card_id - corporate_card_number + - corporate_card_nickname + - corporate_card_cardholder_name + - capitalone_virtual_card_last_four + - masked_corporate_card_number + - bank_name + - corporate_card_user_full_name + - is_corporate_card_archived + - amount + - currency + - spent_at + - posted_at + - status + - description + - foreign_currency + - foreign_amount + - merchant + - category + - matched_by properties: id: allOf: @@ -20627,6 +21161,12 @@ components: example: 77.594566 commute_details: type: object + required: + - id + - distance + - distance_unit + - home_location + - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -20748,6 +21288,26 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments + - custom_fields_flattened + - approvals + - verifications + - employee_id + - split_group_amount + - expense_rule_id + - expense_rule_data + - is_split + - tax_group + - approver_comments + - verifier_comments + - policy_checks + - accounting_export_summary + - report_last_paid_at + - report_last_approved_at + - commute_deduction + - commute_details_id + - commute_details + - is_reconciled + - report_auto_approval_state properties: id: allOf: @@ -21780,6 +22340,8 @@ components: Expense ID of the expense to be verified. example: tx0agOdICdbV expenses_stats_in: + required: + - query_params properties: query_params: nullable: false @@ -21983,6 +22545,17 @@ components: expenses_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -22159,6 +22732,8 @@ components: - type - org_id - user_id + - created_by + - updated_by properties: id: allOf: @@ -22471,6 +23046,12 @@ components: advance_out_embed: type: object nullable: true + required: + - id + - currency + - amount + - advance_request_id + - seq_num properties: id: type: string @@ -22551,6 +23132,10 @@ components: advance_request_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: @@ -22570,6 +23155,14 @@ components: employee_out_embed: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department properties: id: $ref: '#/components/schemas/id_string' @@ -22603,6 +23196,17 @@ components: advance_request_comments_out: type: object additionalProperties: false + required: + - id + - comment + - action + - advance_request_id + - creator_type + - creator_user_id + - creator_user + - created_at + - updated_at + - org_id properties: id: $ref: '#/components/schemas/id_string' @@ -22821,6 +23425,8 @@ components: required: - id advance_requests_stats_in: + required: + - query_params properties: query_params: description: | @@ -22916,6 +23522,18 @@ components: advance_request_permissions_out: type: object additionalProperties: false + required: + - can_save + - can_submit + - can_edit + - can_add_approver + - can_disable_approver + - can_reject + - can_approve + - can_inquire + - can_pull_back + - can_pay + - can_delete properties: can_save: type: boolean @@ -22994,6 +23612,10 @@ components: advance_request_out_embed: type: object nullable: true + required: + - id + - last_approved_at + - seq_num properties: id: type: string @@ -23232,6 +23854,8 @@ components: custom_fields: $ref: '#/components/schemas/custom_fields' advances_stats_in: + required: + - query_params properties: query_params: type: string @@ -23241,6 +23865,9 @@ components: example: id=in.('adv1263', 'adv1569') advances_stats_out: type: object + required: + - count + - total_amount properties: count: type: integer @@ -23445,6 +24072,8 @@ components: - $ref: '#/components/schemas/id_string' example: awfgRr8YA6KK advance_refunds_stats_in: + required: + - query_params properties: query_params: type: string @@ -23454,6 +24083,9 @@ components: example: id=in.('adr1263', 'adr1569') advance_refunds_stats_out: type: object + required: + - count + - total_amount properties: count: type: integer @@ -23635,6 +24267,13 @@ components: reminder_in: type: object additionalProperties: false + required: + - type + - message + - schedule_config + - add_to_calendar + - send_mobile_notification + - receiver_user_ids properties: id: type: string @@ -23679,6 +24318,8 @@ components: ID of the reminder that needs to be deleted. example: remindNZgN7V5pft reminders_stats_in: + required: + - query_params properties: query_params: type: string @@ -23688,6 +24329,9 @@ components: example: id=in.('remind123','remind1234') reminders_stats_out: type: array + required: + - last_reminded_at + - type items: type: object properties: @@ -23702,6 +24346,24 @@ components: employee_out_embed_for_report: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - ach_account + - business_unit + - location + - title + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -23845,6 +24507,12 @@ components: reimbursement_out_minimal: type: object nullable: true + required: + - id + - currency + - amount + - mode + - ach_transfer properties: id: type: string @@ -23897,6 +24565,9 @@ components: advance_wallet_report_out: type: object additionalProperties: false + required: + - id + - amount properties: id: allOf: @@ -23937,6 +24608,14 @@ components: - applied_advance_wallets - can_apply_advances - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -24414,6 +25093,20 @@ components: - id process_summary_out: type: object + required: + - selected_reimbursable_amount + - selected_count + - unverified_count + - unverified_amount + - missing_bank_details_count + - missing_bank_details_amount + - missing_bank_details_employee_count + - missing_bank_details_employee_ids + - payment_initiated_amount + - payment_initiated_count + - reimbursable_amount + - reimbursable_report_ids + - closable_report_ids additionalProperties: true properties: selected_reimbursable_amount: @@ -24506,6 +25199,8 @@ components: id: $ref: '#/components/schemas/id_string' reports_stats_in: + required: + - query_params properties: query_params: type: string @@ -25070,6 +25765,8 @@ components: - type - org_id - user_id + - created_by + - updated_by properties: id: allOf: @@ -25441,6 +26138,8 @@ components: - bank_name - card_number corporate_card_stats_in: + required: + - query_params properties: query_params: nullable: false @@ -25450,6 +26149,10 @@ components: example: user_id=eq.null corporate_card_stats_out: type: object + required: + - count + - total_transactions_count + - transactions_count properties: count: type: integer @@ -25491,6 +26194,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -25770,6 +26477,16 @@ components: duplicate_suggestion_corporate_card_out_embed: type: object additionalProperties: false + required: + - id + - bank_name + - card_number + - nickname + - total_transactions_count + - is_visa_enrolled + - is_mastercard_enrolled + - data_feed_source + - feed_display_name properties: id: allOf: @@ -25984,6 +26701,16 @@ components: corporate_card_out_embed: type: object additionalProperties: false + required: + - id + - bank_name + - card_number + - nickname + - cardholder_name + - masked_number + - user_full_name + - user_email + - is_archived properties: id: allOf: @@ -26742,7 +27469,11 @@ components: - last_user_matched_at - is_exported - metadata + - mcc corporate_card_transactions_stats_in: + type: object + required: + - query_params properties: query_params: nullable: false @@ -26752,6 +27483,10 @@ components: example: amount=gt.0&amount=lt.1000&created_at=gt.2021-01-01T00:00:00.000Z&created_at=lt.2021-12-31T23:59:59.999Z corporate_card_transactions_stats_out: type: object + required: + - count + - debit_amount + - credit_amount properties: count: type: integer @@ -26782,6 +27517,9 @@ components: - id corporate_card_transactions_delete_summary_out: type: object + required: + - delete_count + - delete_amount properties: delete_count: type: integer @@ -27083,6 +27821,7 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc corporate_card_transaction_reassign_in: type: object properties: @@ -27322,6 +28061,8 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_mark_personal_out: type: object properties: @@ -27529,6 +28270,8 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_unmark_personal_out: type: object properties: @@ -27737,6 +28480,8 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_ignore_out: type: object properties: @@ -27951,6 +28696,9 @@ components: - matched_expenses - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_undo_ignore_out: type: object additionalProperties: false @@ -28180,6 +28928,10 @@ components: - matched_expenses - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number corporate_card_transaction_match_in: type: object properties: @@ -28411,6 +29163,9 @@ components: - matched_expenses - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_unmatch_in: type: object properties: @@ -28654,6 +29409,11 @@ components: - matched_expenses - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number + - is_exported corporate_card_transactions_export_config_column_formula: type: object required: @@ -28800,6 +29560,20 @@ components: corporate_card_transactions_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state + - processed_at + - completed_at + - failed_at properties: created_at: $ref: '#/components/schemas/created_at' @@ -29023,6 +29797,14 @@ components: admin_subscriptions_out: type: object additionalProperties: false + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - org_id + - subscribed_resources properties: id: $ref: '#/components/schemas/id_string' @@ -29083,6 +29865,15 @@ components: - reimbursement - comments - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - applied_advance_wallets + - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -29445,6 +30236,24 @@ components: example: 100 employee_account_summary_out: type: object + required: + - id + - created_at + - updated_at + - org_id + - org_currency + - user_email + - user_full_name + - cash_account_id + - cash_account + - cash_account_balance + - ccc_account_id + - ccc_account + - ccc_account_balance + - advance_account_ids + - advance_accounts + - advance_accounts_balance + - is_settleable properties: id: $ref: '#/components/schemas/id_integer' @@ -29502,6 +30311,14 @@ components: schedule_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - config + - org_id + - user_id + - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -29559,6 +30376,15 @@ components: scheduled_callback_out: type: object additionalProperties: false + required: + - id + - url + - payload + - schedule_config + - is_enabled + - created_at + - updated_at + - org_id properties: id: $ref: '#/components/schemas/id_string' @@ -29578,6 +30404,11 @@ components: $ref: '#/components/schemas/org_id' scheduled_callback_in: type: object + required: + - url + - payload + - schedule_config + - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -29620,6 +30451,9 @@ components: spend_overview_summary_data_out: type: object nullable: false + required: + - amount + - time_interval_marker properties: amount: $ref: '#/components/schemas/amount' @@ -29638,6 +30472,11 @@ components: spend_overview_by_merchant_data_out: type: object nullable: false + required: + - merchant_name + - amount + - percentage + - change_percentage properties: merchant_name: $ref: '#/components/schemas/merchant' @@ -29656,6 +30495,12 @@ components: spend_overview_by_project_data_out: type: object nullable: false + required: + - project_id + - project_display_name + - amount + - percentage + - change_percentage properties: project_id: $ref: '#/components/schemas/id_integer' @@ -29676,6 +30521,12 @@ components: spend_overview_by_category_data_out: type: object nullable: false + required: + - category_id + - category_display_name + - amount + - percentage + - change_percentage properties: category_id: $ref: '#/components/schemas/id_integer' @@ -29696,6 +30547,12 @@ components: spend_overview_by_department_data_out: type: object nullable: false + required: + - department_id + - department_display_name + - amount + - percentage + - change_percentage properties: department_id: $ref: '#/components/schemas/id_string' @@ -29710,6 +30567,13 @@ components: spend_overview_by_user_data_out: type: object nullable: false + required: + - user_id + - user_full_name + - user_email + - amount + - percentage + - change_percentage properties: user_id: $ref: '#/components/schemas/id_string' @@ -29726,6 +30590,15 @@ components: spend_overview_by_corporate_card_data_out: type: object nullable: false + required: + - card_id + - card_number + - card_holder_name + - card_nickname + - user_id + - amount + - percentage + - change_percentage properties: card_id: $ref: '#/components/schemas/id_string' @@ -29761,6 +30634,17 @@ components: account_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - user_id + - type + - currency + - current_balance_amount + - tentative_balance_amount + - org_id + - category_id properties: id: allOf: @@ -29805,6 +30689,11 @@ components: account_in: type: object additionalProperties: false + required: + - user_id + - type + - currency + - category_id properties: user_id: type: string @@ -29960,6 +30849,7 @@ components: - visibility - status - user_ids + - fiscal_year_start_month properties: id: $ref: '#/components/schemas/id_string' @@ -30272,6 +31162,12 @@ components: budget_out_embed: type: object additionalProperties: false + required: + - id + - name + - type + - amount_limit + - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -30377,6 +31273,15 @@ components: budget_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - file_id + - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -30421,6 +31326,8 @@ components: - currency - created_at - updated_at + - is_current + - is_primary properties: id: $ref: '#/components/schemas/org_id' @@ -30488,6 +31395,7 @@ components: - id - invitation_sent - is_limit_reached + - weekly_limit properties: id: $ref: '#/components/schemas/org_id' @@ -30638,6 +31546,9 @@ components: - action_add_department_head_approver - action_add_approver_user_ids - action_override_distance_slab_rate + - expense_merchants + - expense_merchants_op + - policy_violation_reason_required properties: id: allOf: @@ -31981,6 +32892,7 @@ components: - file_id - is_processed - statement_mappings_id + - creator_user statements_in: type: object properties: @@ -32544,6 +33456,16 @@ components: - id - statement_mapping summary_out: + type: object + required: + - id + - status + - period_start + - period_end + - statement_transaction_count + - statement_total + - total_cards + - bridging_entry_change_type properties: id: allOf: @@ -32716,6 +33638,12 @@ components: - statement_mapping - reconciliation_entry_ids _reconciliation_summary_object: + type: object + required: + - expense_count + - is_recommended + - reconciliation_method + - statement_transaction_count properties: expense_count: description: Number of expense matches found @@ -32733,6 +33661,9 @@ components: type: number example: 12 reconciliation_summary_out: + type: object + required: + - reconciliation_summary properties: reconciliation_summary: type: array @@ -33056,7 +33987,13 @@ components: required: - missing_transactions_count - is_rtf_statement + - rtf_card_network + - missing_corporate_card_details matching_cards_out: + type: object + required: + - statement_card_number + - matching_cards properties: statement_card_number: type: string @@ -33095,6 +34032,13 @@ components: $ref: '#/components/schemas/user_out_embed_nullable' rtf_missing_transaction_from_statement_out: type: object + required: + - error + - missing_rtf_transactions + - rtf_confidence + - rtf_count + - total_count + - status properties: error: type: string @@ -33337,6 +34281,9 @@ components: - reconciliation_method rtf_stats_out: type: object + required: + - last_uploaded_at + - rtf_confidence properties: last_uploaded_at: $ref: '#/components/schemas/timestamptz_utc' @@ -33461,6 +34408,10 @@ components: - id - statement_mapping statement_archived_cards_out: + required: + - number_of_cards + - number_of_archived_cards + - archived_cards properties: number_of_cards: type: integer @@ -33522,6 +34473,8 @@ components: additionalProperties: false required: - merchant_contains + - department_ids + - departments properties: merchant_contains: type: string @@ -33550,6 +34503,18 @@ components: nullable: false additionalProperties: false minProperties: 1 + required: + - merchant + - is_billable + - purpose + - category_id + - category + - project_id + - project + - cost_center_id + - cost_center + - custom_fields + - dependent_fields properties: merchant: type: string @@ -33620,6 +34585,8 @@ components: - creator_user - if - set + - is_suggested + - is_suggestion_dismissed properties: id: allOf: @@ -34178,6 +35145,9 @@ components: description: | List of expense IDs that needs to be dismissed as a duplicate from the target expense expenses_duplicate_sets_stats_in: + type: object + required: + - query_params properties: query_params: nullable: false @@ -34188,6 +35158,8 @@ components: example: '' expenses_duplicate_sets_stats_out: type: object + required: + - count properties: count: type: integer @@ -34208,6 +35180,17 @@ components: feature_config_out: type: object additionalProperties: false + required: + - org_id + - user_id + - created_at + - updated_at + - target_client + - feature + - sub_feature + - key + - value + - is_shared properties: org_id: $ref: '#/components/schemas/org_id' @@ -34477,6 +35460,9 @@ components: expense_check_policies_out: type: object additionalProperties: false + required: + - individual_desired_states + - final_desired_state properties: individual_desired_states: type: array @@ -34487,6 +35473,12 @@ components: org_bank_details_out: type: object additionalProperties: false + required: + - org_id + - bank_account_number + - bank_branch_ifsc + - dwolla_customers_metadata_id + - is_bank_account_added properties: org_id: $ref: '#/components/schemas/org_id' @@ -34515,6 +35507,11 @@ components: merchant_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -34656,6 +35653,14 @@ components: - amount - state - purpose + - currency + - merchant + - spent_at + - file_ids + - category + - project + - matched_corporate_card_transaction + - files properties: id: allOf: @@ -34758,6 +35763,9 @@ components: - project - purpose - splits + - currency + - matched_corporate_card_transaction + - files properties: id: allOf: @@ -34867,6 +35875,12 @@ components: - matched_expenses_count - is_reconciled - expenses + - statement_line_item_id + - expense_ids + - statement_transaction_date + - statement_post_date + - created_at + - updated_at properties: id: $ref: '#/components/schemas/id_string' @@ -34953,6 +35967,15 @@ components: example: corporate_card_id=eq.bawownwrng reconciliation_transactions_stats_out: type: object + required: + - period_start + - period_end + - statement_transaction_count + - expense_count + - statement_total + - expense_total + - difference + - matching_issue_count additionalProperties: false description: | Reconciliation transactions statistics for the selected filter period. @@ -35091,6 +36114,21 @@ components: example: reconciliation_entry_id=eq.receabc12345 reconciliation_eligible_cards_stats_out: type: object + required: + - period_start + - period_end + - statement_transaction_count + - expense_count + - statement_total + - expense_total + - difference + - matching_issue_count + - total_cards + - card_without_statement_count + - card_with_matching_issue_count + - card_with_no_issues_found_count + - card_with_no_transactions_count + - reconciled_card_count additionalProperties: false properties: period_start: @@ -35251,6 +36289,15 @@ components: reconciliation_export_out: type: object additionalProperties: false + required: + - id + - org_id + - file_id + - state + - query_params + - notify_emails + - created_at + - updated_at properties: id: allOf: @@ -35304,6 +36351,29 @@ components: spender_employee_settings_out: type: object additionalProperties: false + required: + - id + - employee_id + - org_id + - created_at + - updated_at + - category_ids + - cost_center_ids + - project_ids + - per_diem_rate_ids + - mileage_rate_ids + - insta_fyle_settings + - notification_settings + - mileage_settings + - expense_form_autofills + - data_extractor_settings + - in_app_chat_settings + - payment_mode_settings + - locale + - is_personal_cards_enabled + - default_project_id + - default_payment_mode + - default_vehicle_type properties: id: $ref: '#/components/schemas/id_string' @@ -35785,6 +36855,27 @@ components: dwolla_customer_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - customer_id + - customer_email + - customer_added_by + - is_customer_verified + - is_beneficial_owner_added + - is_beneficial_owner_verified + - is_bank_account_added + - is_bank_account_verified + - bank_account_added_by + - is_customer_document_needed + - is_beneficial_owner_document_needed + - is_customer_retry + - is_customer_suspended + - micro_deposit_verification_status + - micro_deposit_verification_attempts + - is_beneficial_owner_retry properties: id: allOf: @@ -35897,6 +36988,9 @@ components: dwolla_customer_in: type: object additionalProperties: false + required: + - customer_id + - customer_added_by properties: customer_id: type: string diff --git a/reference/approver.yaml b/reference/approver.yaml index 1fa85bd52..a9e2078f5 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -169,6 +169,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -225,6 +227,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -330,6 +334,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -422,6 +428,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_exports_out' @@ -498,6 +506,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/approver_expense_in' @@ -508,6 +518,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -549,6 +561,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/approver_expenses_bulk_in' @@ -559,6 +573,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -618,6 +634,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -671,6 +689,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_out' @@ -734,6 +754,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_bulk_out' @@ -815,6 +837,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -862,6 +886,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -949,6 +975,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -1004,6 +1032,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reports_stats_out' @@ -1058,6 +1088,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_comments_out' @@ -1107,6 +1139,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_permissions_out' @@ -1160,6 +1194,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -1195,6 +1231,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/subscriptions_in' @@ -1206,6 +1244,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/approver_subscriptions_out' @@ -1366,6 +1406,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_requests_approver_stats_out' @@ -1421,6 +1463,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_permissions_out' @@ -1462,6 +1506,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_in' @@ -1472,6 +1518,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_out' @@ -2011,6 +2059,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_check_policies_bulk_out' @@ -2095,6 +2145,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_comments_bulk_in' @@ -2105,6 +2157,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -2258,6 +2312,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expenses_stats_out' @@ -2311,6 +2367,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -2398,6 +2456,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -2451,6 +2511,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_exports_out' @@ -2486,6 +2548,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -2496,6 +2560,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -2542,6 +2608,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -2552,6 +2620,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -2597,6 +2667,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -2607,6 +2679,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -2666,6 +2740,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -2742,6 +2818,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -3038,6 +3116,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -3081,6 +3161,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_add_approver_in' @@ -3096,6 +3178,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3165,6 +3249,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3277,6 +3363,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3342,6 +3430,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3457,6 +3547,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -3639,6 +3731,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/employee_overview_stats_out' @@ -3770,6 +3864,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/employee_overview_expense_stats_out' @@ -3958,6 +4054,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_export_configuration_out' @@ -4155,6 +4253,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_export_configuration_out' @@ -4361,6 +4461,10 @@ components: user_out_embed: type: object additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -4388,6 +4492,12 @@ components: report_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_type + - approver_user + - state + - approver_order properties: approver_user_id: allOf: @@ -4467,6 +4577,12 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department + - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -4543,6 +4659,24 @@ components: employee_out_embed_for_report: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - ach_account + - business_unit + - location + - title + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -4686,6 +4820,12 @@ components: reimbursement_out_minimal: type: object nullable: true + required: + - id + - currency + - amount + - mode + - ach_transfer properties: id: type: string @@ -4712,6 +4852,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -4755,6 +4899,9 @@ components: advance_wallet_report_out: type: object additionalProperties: false + required: + - id + - amount properties: id: allOf: @@ -4793,6 +4940,15 @@ components: - reimbursement - comments - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - applied_advance_wallets + - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -5314,6 +5470,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -5329,6 +5489,13 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - system_category + - name + - sub_category + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -5360,6 +5527,12 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - sub_project + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -5391,6 +5564,9 @@ components: example: sdfd2391 account_out_embed: type: object + required: + - id + - type properties: id: allOf: @@ -5410,6 +5586,11 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code + - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -5427,6 +5608,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -5570,6 +5755,9 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num + - amount + - last_verified_at + - approvals properties: id: anyOf: @@ -5658,6 +5846,11 @@ components: List of report_approval objects file_out_embed: type: object + required: + - id + - name + - type + - content_type properties: id: allOf: @@ -5703,6 +5896,9 @@ components: expense_verification_out_embed: type: object additionalProperties: false + required: + - verifier_user_id + - verifier_user properties: verifier_user_id: allOf: @@ -5743,6 +5939,25 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - location + - title + - business_unit + - custom_fields + - flattened_custom_field + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -5857,6 +6072,24 @@ components: - id - corporate_card_id - corporate_card_number + - corporate_card_nickname + - corporate_card_cardholder_name + - capitalone_virtual_card_last_four + - masked_corporate_card_number + - bank_name + - corporate_card_user_full_name + - is_corporate_card_archived + - amount + - currency + - spent_at + - posted_at + - status + - description + - foreign_currency + - foreign_amount + - merchant + - category + - matched_by properties: id: allOf: @@ -6341,6 +6574,12 @@ components: example: 77.594566 commute_details: type: object + required: + - id + - distance + - distance_unit + - home_location + - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -6462,6 +6701,26 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments + - custom_fields_flattened + - approvals + - verifications + - employee_id + - split_group_amount + - expense_rule_id + - expense_rule_data + - is_split + - tax_group + - approver_comments + - verifier_comments + - policy_checks + - accounting_export_summary + - report_last_paid_at + - report_last_approved_at + - commute_deduction + - commute_details_id + - commute_details + - is_reconciled + - report_auto_approval_state properties: id: allOf: @@ -7555,6 +7814,8 @@ components: - $ref: '#/components/schemas/id_string' example: rpfilumWHrlPf7K reports_stats_in: + required: + - query_params properties: query_params: type: string @@ -7828,6 +8089,13 @@ components: approver_subscriptions_out: type: object additionalProperties: false + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - approver_user_id properties: id: $ref: '#/components/schemas/id_string' @@ -7884,6 +8152,12 @@ components: advance_out_embed: type: object nullable: true + required: + - id + - currency + - amount + - advance_request_id + - seq_num properties: id: type: string @@ -7964,6 +8238,10 @@ components: advance_request_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: @@ -7984,6 +8262,11 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -8000,6 +8283,14 @@ components: employee_out_embed: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department properties: id: $ref: '#/components/schemas/id_string' @@ -8033,6 +8324,17 @@ components: advance_request_comments_out: type: object additionalProperties: false + required: + - id + - comment + - action + - advance_request_id + - creator_type + - creator_user_id + - creator_user + - created_at + - updated_at + - org_id properties: id: $ref: '#/components/schemas/id_string' @@ -8276,6 +8578,18 @@ components: advance_request_permissions_out: type: object additionalProperties: false + required: + - can_save + - can_submit + - can_edit + - can_add_approver + - can_disable_approver + - can_reject + - can_approve + - can_inquire + - can_pull_back + - can_pay + - can_delete properties: can_save: type: boolean @@ -8802,6 +9116,12 @@ components: approver_merchant_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -9616,6 +9936,8 @@ components: description: | List of expense IDs that are part of the duplicate set expenses_stats_in: + required: + - query_params properties: query_params: nullable: false @@ -9873,6 +10195,17 @@ components: expenses_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -10082,6 +10415,9 @@ components: expense_check_policies_out: type: object additionalProperties: false + required: + - individual_desired_states + - final_desired_state properties: individual_desired_states: type: array @@ -10134,6 +10470,17 @@ components: file_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - created_at + - updated_at + - name + - type + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -10181,6 +10528,12 @@ components: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -10232,6 +10585,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -10642,6 +10999,17 @@ components: account_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - user_id + - type + - currency + - current_balance_amount + - tentative_balance_amount + - org_id + - category_id properties: id: allOf: @@ -10686,6 +11054,29 @@ components: spender_employee_settings_out: type: object additionalProperties: false + required: + - id + - employee_id + - org_id + - created_at + - updated_at + - category_ids + - cost_center_ids + - project_ids + - per_diem_rate_ids + - mileage_rate_ids + - insta_fyle_settings + - notification_settings + - mileage_settings + - expense_form_autofills + - data_extractor_settings + - in_app_chat_settings + - payment_mode_settings + - locale + - is_personal_cards_enabled + - default_project_id + - default_payment_mode + - default_vehicle_type properties: id: $ref: '#/components/schemas/id_string' @@ -11324,6 +11715,9 @@ components: employee_overview_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer @@ -11336,6 +11730,9 @@ components: employee_overview_expense_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer @@ -11478,6 +11875,8 @@ components: - type - org_id - user_id + - created_by + - updated_by properties: id: allOf: @@ -11715,6 +12114,8 @@ components: - type - org_id - user_id + - created_by + - updated_by properties: id: allOf: diff --git a/reference/common.yaml b/reference/common.yaml index 7cc7339e7..e4ca01c8b 100644 --- a/reference/common.yaml +++ b/reference/common.yaml @@ -419,6 +419,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/logo_file_generate_download_url_action_out' @@ -493,6 +495,9 @@ components: example: 10 place_out_minimal: type: object + required: + - id + - formatted_address properties: id: type: string @@ -505,6 +510,14 @@ components: place_out: type: object additionalProperties: false + required: + - id + - city + - state + - country + - formatted_address + - latitude + - longitude properties: id: type: string @@ -531,6 +544,8 @@ components: example: 77.594566 exchange_rate_out: type: object + required: + - exchange_rate additionalProperties: false properties: exchange_rate: @@ -544,6 +559,11 @@ components: example: sdfd2391 logo_file_generate_download_url_action_out: type: object + required: + - id + - name + - content_type + - download_url additionalProperties: false properties: id: diff --git a/reference/hod.yaml b/reference/hod.yaml index 2b7f7d1a7..d2371946e 100644 --- a/reference/hod.yaml +++ b/reference/hod.yaml @@ -155,6 +155,12 @@ components: budget_out_embed: type: object additionalProperties: false + required: + - id + - name + - type + - amount_limit + - is_enabled properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/hop.yaml b/reference/hop.yaml index 7a0d27b23..0403992ce 100644 --- a/reference/hop.yaml +++ b/reference/hop.yaml @@ -155,6 +155,12 @@ components: budget_out_embed: type: object additionalProperties: false + required: + - id + - name + - type + - amount_limit + - is_enabled properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/manager.yaml b/reference/manager.yaml index 1a85e2a87..2a2723ce3 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -114,6 +114,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -381,6 +383,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/employee_overview_stats_out' @@ -570,6 +574,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/employee_overview_expense_stats_out' @@ -711,6 +717,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -822,6 +832,12 @@ components: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -1287,6 +1303,9 @@ components: employee_overview_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer @@ -1306,6 +1325,10 @@ components: user_out_embed: type: object additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -1336,6 +1359,11 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -1508,6 +1536,12 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - sub_project + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -1534,6 +1568,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -1549,6 +1587,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -1562,6 +1604,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -1704,6 +1750,13 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - system_category + - name + - sub_category + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -2033,6 +2086,9 @@ components: example: 1234 account_out_embed: type: object + required: + - id + - type properties: id: allOf: @@ -2052,6 +2108,11 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code + - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -2127,6 +2188,12 @@ components: report_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_type + - approver_user + - state + - approver_order properties: approver_user_id: allOf: @@ -2179,6 +2246,9 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num + - amount + - last_verified_at + - approvals properties: id: anyOf: @@ -2267,6 +2337,11 @@ components: List of report_approval objects file_out_embed: type: object + required: + - id + - name + - type + - content_type properties: id: allOf: @@ -2312,6 +2387,9 @@ components: expense_verification_out_embed: type: object additionalProperties: false + required: + - verifier_user_id + - verifier_user properties: verifier_user_id: allOf: @@ -2335,6 +2413,12 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department + - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -2357,6 +2441,25 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - location + - title + - business_unit + - custom_fields + - flattened_custom_field + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -2471,6 +2574,24 @@ components: - id - corporate_card_id - corporate_card_number + - corporate_card_nickname + - corporate_card_cardholder_name + - capitalone_virtual_card_last_four + - masked_corporate_card_number + - bank_name + - corporate_card_user_full_name + - is_corporate_card_archived + - amount + - currency + - spent_at + - posted_at + - status + - description + - foreign_currency + - foreign_amount + - merchant + - category + - matched_by properties: id: allOf: @@ -2955,6 +3076,12 @@ components: example: 77.594566 commute_details: type: object + required: + - id + - distance + - distance_unit + - home_location + - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -3076,6 +3203,26 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments + - custom_fields_flattened + - approvals + - verifications + - employee_id + - split_group_amount + - expense_rule_id + - expense_rule_data + - is_split + - tax_group + - approver_comments + - verifier_comments + - policy_checks + - accounting_export_summary + - report_last_paid_at + - report_last_approved_at + - commute_deduction + - commute_details_id + - commute_details + - is_reconciled + - report_auto_approval_state properties: id: allOf: @@ -3622,6 +3769,8 @@ components: - AUTO_APPROVED - null expenses_stats_in: + required: + - query_params properties: query_params: nullable: false @@ -3632,6 +3781,9 @@ components: employee_overview_expense_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer diff --git a/reference/spender.yaml b/reference/spender.yaml index 414f89946..253190550 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -685,6 +685,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/spender_expenses_bulk_in' @@ -695,6 +697,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -806,6 +810,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -855,6 +861,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -906,6 +914,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -971,6 +981,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -1024,6 +1036,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_out' @@ -1087,6 +1101,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_bulk_out' @@ -1241,6 +1257,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/subscriptions_in' @@ -1252,6 +1270,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/spender_subscriptions_out' @@ -1360,6 +1380,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/schedule_out' @@ -1601,6 +1623,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -1651,6 +1675,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -1699,6 +1725,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -1747,6 +1775,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -1796,6 +1826,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reports_stats_out' @@ -1850,6 +1882,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_purpose_out' @@ -1897,6 +1931,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -1958,7 +1994,7 @@ paths: application/json: schema: $ref: '#/components/schemas/401' - /spender/reports/filters/delte: + /spender/reports/filters/delete: post: tags: - Reports @@ -1984,6 +2020,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -2038,6 +2076,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_comments_out' @@ -2087,6 +2127,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_permissions_out' @@ -2179,6 +2221,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_exports_out' @@ -2273,6 +2317,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -2328,6 +2374,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_requests_stats_out' @@ -2429,6 +2477,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advances_stats_out' @@ -2649,6 +2699,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -2703,6 +2755,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_mark_personal_out' @@ -2756,6 +2810,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmark_personal_out' @@ -2809,6 +2865,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_ignore_out' @@ -2862,6 +2920,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_undo_ignore_out' @@ -2915,6 +2975,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_match_out' @@ -2968,6 +3030,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmatch_out' @@ -3063,6 +3127,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/spender_employee_out' @@ -3745,6 +3811,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/virtual_cards_get_current_balance_out' @@ -3799,6 +3867,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/virtual_cards_show_card_details_out' @@ -3895,6 +3965,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/file_out' @@ -3952,6 +4024,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -4023,6 +4097,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/file_generate_urls_action_out' @@ -4079,6 +4155,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -4248,6 +4326,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/file_out_download_url' @@ -4454,6 +4534,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_check_policies_out' @@ -4505,6 +4587,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_check_policies_bulk_out' @@ -4604,6 +4688,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/recurring_expense_out' @@ -4707,6 +4793,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/recurring_expense_out' @@ -4927,6 +5015,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_comments_bulk_in' @@ -4937,6 +5027,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -5090,6 +5182,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expenses_stats_out' @@ -5143,6 +5237,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -5230,6 +5326,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -5283,6 +5381,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_exports_out' @@ -5318,6 +5418,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/spender_split_expense_in' @@ -5328,6 +5430,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -5374,6 +5478,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/spender_split_expense_in' @@ -5384,6 +5490,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -5429,6 +5537,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/spender_split_expense_in' @@ -5439,6 +5549,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -5482,6 +5594,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_merge_in' @@ -5492,6 +5606,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -5636,6 +5752,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -6141,6 +6259,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -6312,6 +6432,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -6386,6 +6508,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -6451,6 +6575,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_permissions_out' @@ -6509,6 +6635,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -6571,6 +6699,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -6614,6 +6744,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_in' @@ -6624,6 +6756,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_out' @@ -6771,6 +6905,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/secondary_email_out' @@ -6830,6 +6966,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -6893,6 +7031,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -7207,6 +7347,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_export_configuration_out' @@ -7404,6 +7546,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_export_configuration_out' @@ -8088,6 +8232,25 @@ components: expense_field_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - seq + - field_name + - column_name + - type + - options + - default_value + - placeholder + - category_ids + - is_enabled + - is_custom + - is_mandatory + - code + - parent_field_id + - display_order properties: id: $ref: '#/components/schemas/id_integer' @@ -8168,6 +8331,16 @@ components: dependent_expense_field_values_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - parent_expense_field_value + - expense_field_value + - is_enabled properties: id: $ref: '#/components/schemas/id_integer' @@ -8268,6 +8441,11 @@ components: org_out_embed: type: object additionalProperties: false + required: + - id + - name + - domain + - currency properties: id: $ref: '#/components/schemas/org_id' @@ -8293,6 +8471,10 @@ components: user_out_embed: type: object additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -8328,6 +8510,12 @@ components: my_profile_out: type: object additionalProperties: false + required: + - user_id + - org_id + - org + - user + - roles properties: user_id: $ref: '#/components/schemas/user_id' @@ -8427,6 +8615,17 @@ components: account_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - user_id + - type + - currency + - current_balance_amount + - tentative_balance_amount + - org_id + - category_id properties: id: allOf: @@ -8571,6 +8770,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -8586,6 +8789,13 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - system_category + - name + - sub_category + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -8617,6 +8827,12 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - sub_project + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -8648,6 +8864,9 @@ components: example: sdfd2391 account_out_embed: type: object + required: + - id + - type properties: id: allOf: @@ -8667,6 +8886,11 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code + - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -8684,6 +8908,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -8819,6 +9047,12 @@ components: report_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_type + - approver_user + - state + - approver_order properties: approver_user_id: allOf: @@ -8871,6 +9105,9 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num + - amount + - last_verified_at + - approvals properties: id: anyOf: @@ -8959,6 +9196,11 @@ components: List of report_approval objects file_out_embed: type: object + required: + - id + - name + - type + - content_type properties: id: allOf: @@ -9004,6 +9246,9 @@ components: expense_verification_out_embed: type: object additionalProperties: false + required: + - verifier_user_id + - verifier_user properties: verifier_user_id: allOf: @@ -9033,6 +9278,12 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department + - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -9125,6 +9376,25 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - location + - title + - business_unit + - custom_fields + - flattened_custom_field + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -9239,6 +9509,24 @@ components: - id - corporate_card_id - corporate_card_number + - corporate_card_nickname + - corporate_card_cardholder_name + - capitalone_virtual_card_last_four + - masked_corporate_card_number + - bank_name + - corporate_card_user_full_name + - is_corporate_card_archived + - amount + - currency + - spent_at + - posted_at + - status + - description + - foreign_currency + - foreign_amount + - merchant + - category + - matched_by properties: id: allOf: @@ -9723,6 +10011,12 @@ components: example: 77.594566 commute_details: type: object + required: + - id + - distance + - distance_unit + - home_location + - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -9844,6 +10138,26 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments + - custom_fields_flattened + - approvals + - verifications + - employee_id + - split_group_amount + - expense_rule_id + - expense_rule_data + - is_split + - tax_group + - approver_comments + - verifier_comments + - policy_checks + - accounting_export_summary + - report_last_paid_at + - report_last_approved_at + - commute_deduction + - commute_details_id + - commute_details + - is_reconciled + - report_auto_approval_state properties: id: allOf: @@ -10974,6 +11288,11 @@ components: merchant_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -10994,6 +11313,13 @@ components: spender_subscriptions_out: type: object additionalProperties: false + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - user_id properties: id: $ref: '#/components/schemas/id_string' @@ -11021,6 +11347,24 @@ components: employee_out_embed_for_report: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - ach_account + - business_unit + - location + - title + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -11164,6 +11508,12 @@ components: reimbursement_out_minimal: type: object nullable: true + required: + - id + - currency + - amount + - mode + - ach_transfer properties: id: type: string @@ -11190,6 +11540,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -11233,6 +11587,9 @@ components: advance_wallet_report_out: type: object additionalProperties: false + required: + - id + - amount properties: id: allOf: @@ -11271,6 +11628,15 @@ components: - reimbursement - comments - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - applied_advance_wallets + - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -11616,6 +11982,14 @@ components: schedule_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - config + - org_id + - user_id + - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -11763,6 +12137,8 @@ components: id of report, which needs to be resubmitted example: rpa21A2rdj2 reports_stats_in: + required: + - query_params properties: query_params: type: string @@ -12324,6 +12700,12 @@ components: advance_out_embed: type: object nullable: true + required: + - id + - currency + - amount + - advance_request_id + - seq_num properties: id: type: string @@ -12404,6 +12786,10 @@ components: advance_request_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: @@ -12424,6 +12810,11 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -12440,6 +12831,14 @@ components: employee_out_embed: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department properties: id: $ref: '#/components/schemas/id_string' @@ -12473,6 +12872,17 @@ components: advance_request_comments_out: type: object additionalProperties: false + required: + - id + - comment + - action + - advance_request_id + - creator_type + - creator_user_id + - creator_user + - created_at + - updated_at + - org_id properties: id: $ref: '#/components/schemas/id_string' @@ -12692,6 +13102,8 @@ components: - currency - amount advance_requests_stats_in: + required: + - query_params properties: query_params: description: | @@ -12777,6 +13189,10 @@ components: advance_request_out_embed: type: object nullable: true + required: + - id + - last_approved_at + - seq_num properties: id: type: string @@ -12937,6 +13353,8 @@ components: creator_user: $ref: '#/components/schemas/user_out_embed_nullable' advances_stats_in: + required: + - query_params properties: query_params: type: string @@ -12946,6 +13364,9 @@ components: example: id=in.('adv1263', 'adv1569') advances_stats_out: type: object + required: + - count + - total_amount properties: count: type: integer @@ -13272,6 +13693,9 @@ components: - yodlee_fastlink_params - created_at - updated_at + - org_id + - user_id + - corporate_card_id string_detail: type: string description: Additional string details of the card transaction. Can hold details upto 256 characters in length. @@ -13280,6 +13704,16 @@ components: corporate_card_out_embed: type: object additionalProperties: false + required: + - id + - bank_name + - card_number + - nickname + - cardholder_name + - masked_number + - user_full_name + - user_email + - is_archived properties: id: allOf: @@ -13753,6 +14187,8 @@ components: - capitalone_virtual_card_last_four corporate_card_transactions_expenses_stats_in: type: object + required: + - query_params properties: query_params: type: string @@ -14045,6 +14481,8 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_unmark_personal_out: type: object properties: @@ -14253,6 +14691,8 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_ignore_out: type: object properties: @@ -14467,6 +14907,9 @@ components: - matched_expenses - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_undo_ignore_out: type: object additionalProperties: false @@ -14696,6 +15139,10 @@ components: - matched_expenses - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number corporate_card_transaction_match_in: type: object properties: @@ -14927,6 +15374,9 @@ components: - matched_expenses - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_unmatch_in: type: object properties: @@ -15170,6 +15620,11 @@ components: - matched_expenses - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number + - is_exported user_full_name: type: string maxLength: 255 @@ -15238,6 +15693,19 @@ components: spender_employee_out: type: object additionalProperties: false + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: '#/components/schemas/id_string' @@ -15362,6 +15830,44 @@ components: spender_employee_current_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - created_at + - updated_at + - user + - code + - joined_at + - title + - business_unit + - special_email + - roles + - location + - is_enabled + - has_accepted_invite + - branch_account + - branch_ifsc + - department_id + - department + - level_id + - level + - mobile + - is_mobile_verified + - mobile_verification_attempts_left + - mobile_verification_attempted_at + - org_name + - currency + - approver_user_ids + - approver_users + - locale + - delegatees + - mileage_settings + - custom_fields + - flattened_custom_field + - commute_details_id + - commute_details + - is_primary properties: id: $ref: '#/components/schemas/id_string' @@ -15589,6 +16095,19 @@ components: spender_commute_details_out: type: object additionalProperties: false + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: '#/components/schemas/id_string' @@ -15646,6 +16165,11 @@ components: spender_delegatees_post_in: type: object additionalProperties: false + required: + - delegatee_user_id + - start_at + - end_at + - scopes properties: delegatee_user_id: $ref: '#/components/schemas/fk_string' @@ -15668,6 +16192,19 @@ components: spender_delegatees_post_out: type: object additionalProperties: false + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: '#/components/schemas/id_string' @@ -15725,6 +16262,10 @@ components: spender_delegators_out: type: object additionalProperties: false + required: + - user_id + - email + - full_name properties: user_id: $ref: '#/components/schemas/user_id' @@ -15739,6 +16280,13 @@ components: spender_delegatees_delete_out: type: object additionalProperties: false + required: + - id + - org_id + - delegator_user_id + - delegatee_user_id + - start_date + - end_date properties: id: $ref: '#/components/schemas/id_integer' @@ -15762,6 +16310,12 @@ components: $ref: '#/components/schemas/timestamptz_utc' employees_send_mobile_verification_code_post_out: type: object + required: + - to + - channel + - status + - date_created + - attempts_left additionalProperties: false properties: to: @@ -15779,11 +16333,6 @@ components: description: | Current status of the verification attempt example: pending - valid: - type: boolean - description: | - Whether the verification is valid - example: false date_created: type: string format: date-time @@ -15816,6 +16365,29 @@ components: spender_employee_settings_out: type: object additionalProperties: false + required: + - id + - employee_id + - org_id + - created_at + - updated_at + - category_ids + - cost_center_ids + - project_ids + - per_diem_rate_ids + - mileage_rate_ids + - insta_fyle_settings + - notification_settings + - mileage_settings + - expense_form_autofills + - data_extractor_settings + - in_app_chat_settings + - payment_mode_settings + - locale + - is_personal_cards_enabled + - default_project_id + - default_payment_mode + - default_vehicle_type properties: id: $ref: '#/components/schemas/id_string' @@ -16505,6 +17077,17 @@ components: file_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - created_at + - updated_at + - name + - type + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -16552,6 +17135,12 @@ components: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -16583,6 +17172,11 @@ components: file_out_download_url: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url properties: id: $ref: '#/components/schemas/id_string' @@ -16727,6 +17321,9 @@ components: - action_add_department_head_approver - action_add_approver_user_ids - action_override_distance_slab_rate + - expense_merchants + - expense_merchants_op + - policy_violation_reason_required properties: id: allOf: @@ -17738,6 +18335,9 @@ components: expense_check_policies_out: type: object additionalProperties: false + required: + - individual_desired_states + - final_desired_state properties: individual_desired_states: type: array @@ -17887,6 +18487,8 @@ components: - expense_details - schedule_config - is_enabled + - created_at + - updated_at properties: id: allOf: @@ -17909,8 +18511,8 @@ components: - MILEAGE: Mileage-based expense type example: EXPENSE expense_details: - type: object - nullable: false + allOf: + - $ref: '#/components/schemas/spender_expense_in' description: | Expense template details used for creating recurring expenses. Contains all the expense fields that will be applied to each generated expense. @@ -18288,6 +18890,8 @@ components: description: | List of expense IDs that are part of the duplicate set expenses_stats_in: + required: + - query_params properties: query_params: nullable: false @@ -18545,6 +19149,17 @@ components: expenses_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -18888,6 +19503,17 @@ components: feature_config_out: type: object additionalProperties: false + required: + - org_id + - user_id + - created_at + - updated_at + - target_client + - feature + - sub_feature + - key + - value + - is_shared properties: org_id: $ref: '#/components/schemas/org_id' @@ -19092,6 +19718,23 @@ components: personal_card_delete_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - currency + - bank_name + - card_number + - account_type + - yodlee_account_id + - yodlee_fastlink_params + - yodlee_is_credential_update_required + - yodlee_is_mfa_required + - yodlee_last_synced_at + - yodlee_login_id + - yodlee_provider_account_id + - created_at + - updated_at properties: id: $ref: '#/components/schemas/id_string' @@ -19156,6 +19799,8 @@ components: $ref: '#/components/schemas/updated_at' personal_card_access_token_out: type: object + required: + - access_token properties: access_token: type: string @@ -19174,6 +19819,8 @@ components: example: baccymJEDziL9Y personal_card_mfa_out: type: object + required: + - is_mfa_enabled properties: is_mfa_enabled: type: boolean @@ -19183,6 +19830,25 @@ components: description: Determines wether the user card has MFA enabled or not personal_card_transaction_out: type: object + required: + - id + - org_id + - user_id + - personal_card_id + - amount + - currency + - spent_at + - category + - merchant + - state + - description + - external_transaction_id + - matched_expense_ids + - created_at + - updated_at + - foreign_amount + - foreign_currency + - matched_expenses additionalProperties: false properties: id: @@ -19266,6 +19932,25 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - location + - title + - business_unit + - custom_fields + - flattened_custom_field + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -19357,6 +20042,10 @@ components: example: personal_card_id=eq.bacctW9DfNhwOt&state=eq.HIDDEN personal_card_transactions_stats_out: type: object + required: + - count + - debit_amount + - credit_amount properties: count: type: integer @@ -19379,6 +20068,15 @@ components: get_spender_orgs_out: type: object additionalProperties: false + required: + - id + - name + - domain + - currency + - created_at + - updated_at + - is_current + - is_primary properties: id: $ref: '#/components/schemas/org_id' @@ -19407,6 +20105,9 @@ components: spender_org_bank_details_out: type: object additionalProperties: false + required: + - org_id + - is_bank_account_added properties: org_id: $ref: '#/components/schemas/org_id' @@ -19434,6 +20135,18 @@ components: advance_request_permissions_out: type: object additionalProperties: false + required: + - can_save + - can_submit + - can_edit + - can_add_approver + - can_disable_approver + - can_reject + - can_approve + - can_inquire + - can_pull_back + - can_pay + - can_delete properties: can_save: type: boolean @@ -19496,6 +20209,7 @@ components: description: | Comment explaining the reason for pulling back the advance request example: sending back + nullable: true attach_files_to_advance_request_in: type: object required: @@ -19539,6 +20253,14 @@ components: example: adrkvnwrnpwi secondary_email_out: type: object + required: + - id + - email + - is_verified + - org_id + - user_id + - created_at + - updated_at additionalProperties: false properties: id: @@ -19666,6 +20388,28 @@ components: spender_dwolla_customer_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - customer_id + - customer_email + - customer_added_by + - is_customer_verified + - is_beneficial_owner_added + - is_beneficial_owner_verified + - is_bank_account_added + - is_bank_account_verified + - bank_account_added_by + - is_customer_document_needed + - is_beneficial_owner_document_needed + - is_customer_retry + - is_customer_suspended + - micro_deposit_verification_status + - micro_deposit_verification_attempts + - is_beneficial_owner_retry + - is_org_customer_verified properties: id: type: string @@ -19807,6 +20551,9 @@ components: dwolla_customer_in: type: object additionalProperties: false + required: + - customer_id + - customer_added_by properties: customer_id: type: string @@ -19909,6 +20656,27 @@ components: dwolla_customer_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - customer_id + - customer_email + - customer_added_by + - is_customer_verified + - is_beneficial_owner_added + - is_beneficial_owner_verified + - is_bank_account_added + - is_bank_account_verified + - bank_account_added_by + - is_customer_document_needed + - is_beneficial_owner_document_needed + - is_customer_retry + - is_customer_suspended + - micro_deposit_verification_status + - micro_deposit_verification_attempts + - is_beneficial_owner_retry properties: id: allOf: @@ -20151,6 +20919,8 @@ components: - type - org_id - user_id + - created_by + - updated_by properties: id: allOf: @@ -20388,6 +21158,8 @@ components: - type - org_id - user_id + - created_by + - updated_by properties: id: allOf: @@ -20515,6 +21287,13 @@ components: mobile_app_version_out: type: object additionalProperties: false + required: + - id + - user_id + - version + - os + - created_at + - updated_at properties: id: type: string diff --git a/src/admin/paths/admin@accounting_export_lineitems.yaml b/src/admin/paths/admin@accounting_export_lineitems.yaml index 0e3d3c7cb..dfb06f7d5 100644 --- a/src/admin/paths/admin@accounting_export_lineitems.yaml +++ b/src/admin/paths/admin@accounting_export_lineitems.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/accounting_export_lineitem.yaml#/accounting_export_lineitem_out diff --git a/src/admin/paths/admin@accounting_exports.yaml b/src/admin/paths/admin@accounting_exports.yaml index 125fbb7c4..b65f01698 100644 --- a/src/admin/paths/admin@accounting_exports.yaml +++ b/src/admin/paths/admin@accounting_exports.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/accounting_export.yaml#/accounting_export_out diff --git a/src/admin/paths/admin@accounts.yaml b/src/admin/paths/admin@accounts.yaml index 93ef0e4b0..39ddc6b8e 100644 --- a/src/admin/paths/admin@accounts.yaml +++ b/src/admin/paths/admin@accounts.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/account.yaml#/account_out' diff --git a/src/admin/paths/admin@advance_refunds.yaml b/src/admin/paths/admin@advance_refunds.yaml index 82ceaf581..f1508b5b8 100644 --- a/src/admin/paths/admin@advance_refunds.yaml +++ b/src/admin/paths/admin@advance_refunds.yaml @@ -70,6 +70,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_refund.yaml#/advance_refund_out' diff --git a/src/admin/paths/admin@advance_refunds@stats.yaml b/src/admin/paths/admin@advance_refunds@stats.yaml index 7c0f8062c..be42f477c 100644 --- a/src/admin/paths/admin@advance_refunds@stats.yaml +++ b/src/admin/paths/admin@advance_refunds@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@advance_requests.yaml b/src/admin/paths/admin@advance_requests.yaml index 8bed4709e..6b447d513 100644 --- a/src/admin/paths/admin@advance_requests.yaml +++ b/src/admin/paths/admin@advance_requests.yaml @@ -70,6 +70,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@add_approver.yaml b/src/admin/paths/admin@advance_requests@add_approver.yaml index 56de6b4b5..1128508d7 100644 --- a/src/admin/paths/admin@advance_requests@add_approver.yaml +++ b/src/admin/paths/admin@advance_requests@add_approver.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_add_approver_in' @@ -26,6 +28,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml b/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml index 14065e4b1..8da910c34 100644 --- a/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml +++ b/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@advance_requests@comments.yaml b/src/admin/paths/admin@advance_requests@comments.yaml index 4bac5d7f9..c4d14ca36 100644 --- a/src/admin/paths/admin@advance_requests@comments.yaml +++ b/src/admin/paths/admin@advance_requests@comments.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_out' diff --git a/src/admin/paths/admin@advance_requests@custom_fields.yaml b/src/admin/paths/admin@advance_requests@custom_fields.yaml index 1f43da81b..cac7f388f 100644 --- a/src/admin/paths/admin@advance_requests@custom_fields.yaml +++ b/src/admin/paths/admin@advance_requests@custom_fields.yaml @@ -66,6 +66,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_custom_field_out' diff --git a/src/admin/paths/admin@advance_requests@inquire.yaml b/src/admin/paths/admin@advance_requests@inquire.yaml index 7edb2e29b..939704db3 100644 --- a/src/admin/paths/admin@advance_requests@inquire.yaml +++ b/src/admin/paths/admin@advance_requests@inquire.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@permissions.yaml b/src/admin/paths/admin@advance_requests@permissions.yaml index 744da3b9f..8f5d4031b 100644 --- a/src/admin/paths/admin@advance_requests@permissions.yaml +++ b/src/admin/paths/admin@advance_requests@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_permissions_out' diff --git a/src/admin/paths/admin@advance_requests@reject.yaml b/src/admin/paths/admin@advance_requests@reject.yaml index b3e8c6577..4ef47efba 100644 --- a/src/admin/paths/admin@advance_requests@reject.yaml +++ b/src/admin/paths/admin@advance_requests@reject.yaml @@ -29,6 +29,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@remove_approver.yaml b/src/admin/paths/admin@advance_requests@remove_approver.yaml index 916bb571e..749d58844 100644 --- a/src/admin/paths/admin@advance_requests@remove_approver.yaml +++ b/src/admin/paths/admin@advance_requests@remove_approver.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_remove_approver_in' @@ -25,6 +27,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@stats.yaml b/src/admin/paths/admin@advance_requests@stats.yaml index f8899cb51..34b7bc4fe 100644 --- a/src/admin/paths/admin@advance_requests@stats.yaml +++ b/src/admin/paths/admin@advance_requests@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_requests_stats_out' diff --git a/src/admin/paths/admin@advance_requests@submit.yaml b/src/admin/paths/admin@advance_requests@submit.yaml index f511c601e..287fae1b2 100644 --- a/src/admin/paths/admin@advance_requests@submit.yaml +++ b/src/admin/paths/admin@advance_requests@submit.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_wallets.yaml b/src/admin/paths/admin@advance_wallets.yaml index 99ef3be7a..9dd1379ea 100644 --- a/src/admin/paths/admin@advance_wallets.yaml +++ b/src/admin/paths/admin@advance_wallets.yaml @@ -70,6 +70,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_wallet.yaml#/advance_wallet_out' diff --git a/src/admin/paths/admin@advances.yaml b/src/admin/paths/admin@advances.yaml index eb7ce5a16..b9d19a5b7 100644 --- a/src/admin/paths/admin@advances.yaml +++ b/src/admin/paths/admin@advances.yaml @@ -70,6 +70,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance.yaml#/advance_out' diff --git a/src/admin/paths/admin@advances@stats.yaml b/src/admin/paths/admin@advances@stats.yaml index 54003447c..2e99a08d2 100644 --- a/src/admin/paths/admin@advances@stats.yaml +++ b/src/admin/paths/admin@advances@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance.yaml#/advances_stats_out' diff --git a/src/admin/paths/admin@automations@report_submissions.yaml b/src/admin/paths/admin@automations@report_submissions.yaml index c860d8292..20d28a5d3 100644 --- a/src/admin/paths/admin@automations@report_submissions.yaml +++ b/src/admin/paths/admin@automations@report_submissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/automation.yaml#/automate_report_submission_out diff --git a/src/admin/paths/admin@automations@report_submissions@delete.yaml b/src/admin/paths/admin@automations@report_submissions@delete.yaml index 6f363fe20..6e4787d82 100644 --- a/src/admin/paths/admin@automations@report_submissions@delete.yaml +++ b/src/admin/paths/admin@automations@report_submissions@delete.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/automation.yaml#/automate_report_submission_out diff --git a/src/admin/paths/admin@budgets.yaml b/src/admin/paths/admin@budgets.yaml index 43e606171..25c99f06b 100644 --- a/src/admin/paths/admin@budgets.yaml +++ b/src/admin/paths/admin@budgets.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/budget.yaml#/budget_post_out diff --git a/src/admin/paths/admin@budgets@exports.yaml b/src/admin/paths/admin@budgets@exports.yaml index a130c8ba3..771917194 100644 --- a/src/admin/paths/admin@budgets@exports.yaml +++ b/src/admin/paths/admin@budgets@exports.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/budget_exports.yaml#/budget_exports_out' diff --git a/src/admin/paths/admin@categories.yaml b/src/admin/paths/admin@categories.yaml index ba8839075..b83f6e782 100644 --- a/src/admin/paths/admin@categories.yaml +++ b/src/admin/paths/admin@categories.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/category.yaml#/admin_approver_category_out diff --git a/src/admin/paths/admin@categories@system_categories.yaml b/src/admin/paths/admin@categories@system_categories.yaml index cfbc62464..701ced45b 100644 --- a/src/admin/paths/admin@categories@system_categories.yaml +++ b/src/admin/paths/admin@categories@system_categories.yaml @@ -15,6 +15,7 @@ get: additionalProperties: False required: - data + - count properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@corporate_card_transactions.yaml b/src/admin/paths/admin@corporate_card_transactions.yaml index 7232506a6..3c075f769 100644 --- a/src/admin/paths/admin@corporate_card_transactions.yaml +++ b/src/admin/paths/admin@corporate_card_transactions.yaml @@ -69,6 +69,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_post_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@assign.yaml b/src/admin/paths/admin@corporate_card_transactions@assign.yaml index a4c225645..164cf9037 100644 --- a/src/admin/paths/admin@corporate_card_transactions@assign.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@assign.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_assign_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@delete.yaml b/src/admin/paths/admin@corporate_card_transactions@delete.yaml index 61b423a22..07939d246 100644 --- a/src/admin/paths/admin@corporate_card_transactions@delete.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@delete.yaml @@ -26,6 +26,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml b/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml index 8f4c16436..7bfa398ce 100644 --- a/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml @@ -26,6 +26,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml b/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml index 9386ab470..7213a20b8 100644 --- a/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml @@ -161,6 +161,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transactions_export_configurations.yaml#/corporate_card_transactions_export_configuration_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@exports.yaml b/src/admin/paths/admin@corporate_card_transactions@exports.yaml index a0600ae9b..1adce438e 100644 --- a/src/admin/paths/admin@corporate_card_transactions@exports.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@exports.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transactions_exports.yaml#/corporate_card_transactions_exports_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@filters.yaml b/src/admin/paths/admin@corporate_card_transactions@filters.yaml index 556a241ac..8034539b3 100644 --- a/src/admin/paths/admin@corporate_card_transactions@filters.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction_filters.yaml#/corporate_card_transaction_filters_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml b/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml index b3e617efb..2666a271b 100644 --- a/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction_filters.yaml#/corporate_card_transaction_filters_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@ignore.yaml b/src/admin/paths/admin@corporate_card_transactions@ignore.yaml index af8d658dd..2a34f0ea2 100644 --- a/src/admin/paths/admin@corporate_card_transactions@ignore.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@ignore.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_ignore_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml b/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml index 8105cd9de..a689b154c 100644 --- a/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_mark_personal_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@match.yaml b/src/admin/paths/admin@corporate_card_transactions@match.yaml index 4c60ece64..7cbe00818 100644 --- a/src/admin/paths/admin@corporate_card_transactions@match.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@match.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_match_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@stats.yaml b/src/admin/paths/admin@corporate_card_transactions@stats.yaml index fc87585f1..3c19e125e 100644 --- a/src/admin/paths/admin@corporate_card_transactions@stats.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@corporate_card_transactions@unassign.yaml b/src/admin/paths/admin@corporate_card_transactions@unassign.yaml index 3bab0bb07..bc01a9857 100644 --- a/src/admin/paths/admin@corporate_card_transactions@unassign.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@unassign.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unassign_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml b/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml index fec689502..5f28cd2e5 100644 --- a/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_undo_ignore_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml b/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml index b68b9b0a8..91bebf4fe 100644 --- a/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmark_personal_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml b/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml index a5f3244d4..7677284cd 100644 --- a/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmatch_out' diff --git a/src/admin/paths/admin@corporate_cards.yaml b/src/admin/paths/admin@corporate_cards.yaml index 86bdc40b0..7544044b4 100644 --- a/src/admin/paths/admin@corporate_cards.yaml +++ b/src/admin/paths/admin@corporate_cards.yaml @@ -69,6 +69,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@archive.yaml b/src/admin/paths/admin@corporate_cards@archive.yaml index 704fde701..63b51ae9f 100644 --- a/src/admin/paths/admin@corporate_cards@archive.yaml +++ b/src/admin/paths/admin@corporate_cards@archive.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml b/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml index e52b39b20..67621dd1d 100644 --- a/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml +++ b/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_archive_suggestion_out' diff --git a/src/admin/paths/admin@corporate_cards@assign.yaml b/src/admin/paths/admin@corporate_cards@assign.yaml index ff739e803..36a0d7256 100644 --- a/src/admin/paths/admin@corporate_cards@assign.yaml +++ b/src/admin/paths/admin@corporate_cards@assign.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@bank_names.yaml b/src/admin/paths/admin@corporate_cards@bank_names.yaml index 5d09c4458..feed534db 100644 --- a/src/admin/paths/admin@corporate_cards@bank_names.yaml +++ b/src/admin/paths/admin@corporate_cards@bank_names.yaml @@ -17,6 +17,8 @@ get: properties: data: type: object + required: + - bank_names properties: bank_names: type: array diff --git a/src/admin/paths/admin@corporate_cards@delete.yaml b/src/admin/paths/admin@corporate_cards@delete.yaml index aad46e8e8..e562ea251 100644 --- a/src/admin/paths/admin@corporate_cards@delete.yaml +++ b/src/admin/paths/admin@corporate_cards@delete.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml b/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml index 88ed5f0b2..e53b58c97 100644 --- a/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml +++ b/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_duplicate_suggestion_out' diff --git a/src/admin/paths/admin@corporate_cards@merge.yaml b/src/admin/paths/admin@corporate_cards@merge.yaml index e2850c21d..452aeeeb0 100644 --- a/src/admin/paths/admin@corporate_cards@merge.yaml +++ b/src/admin/paths/admin@corporate_cards@merge.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@reassign.yaml b/src/admin/paths/admin@corporate_cards@reassign.yaml index 6c609bdc1..bd454839e 100644 --- a/src/admin/paths/admin@corporate_cards@reassign.yaml +++ b/src/admin/paths/admin@corporate_cards@reassign.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@stats.yaml b/src/admin/paths/admin@corporate_cards@stats.yaml index f994b78a8..bfec761b7 100644 --- a/src/admin/paths/admin@corporate_cards@stats.yaml +++ b/src/admin/paths/admin@corporate_cards@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_stats_out' diff --git a/src/admin/paths/admin@corporate_cards@unarchive.yaml b/src/admin/paths/admin@corporate_cards@unarchive.yaml index 3e21aabdf..ad5809880 100644 --- a/src/admin/paths/admin@corporate_cards@unarchive.yaml +++ b/src/admin/paths/admin@corporate_cards@unarchive.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml b/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml index bce9c0ae3..9e95f516e 100644 --- a/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml +++ b/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@corporate_cards@unassign.yaml b/src/admin/paths/admin@corporate_cards@unassign.yaml index 24bba1d9d..8798ff037 100644 --- a/src/admin/paths/admin@corporate_cards@unassign.yaml +++ b/src/admin/paths/admin@corporate_cards@unassign.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_unassign_out' diff --git a/src/admin/paths/admin@cost_centers.yaml b/src/admin/paths/admin@cost_centers.yaml index 8b0ec51bf..18b840621 100644 --- a/src/admin/paths/admin@cost_centers.yaml +++ b/src/admin/paths/admin@cost_centers.yaml @@ -71,6 +71,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/cost_center.yaml#/admin_cost_center_out diff --git a/src/admin/paths/admin@departments.yaml b/src/admin/paths/admin@departments.yaml index 21da1b722..39511bd9b 100644 --- a/src/admin/paths/admin@departments.yaml +++ b/src/admin/paths/admin@departments.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/department.yaml#/department_out diff --git a/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml b/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml index bf7b2f72b..d3875747b 100644 --- a/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml +++ b/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/dependent_expense_field_values.yaml#/dependent_expense_field_values_download_out' diff --git a/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml b/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml index 1fa6cacb6..ea2bc809e 100644 --- a/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml +++ b/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/dependent_expense_field_values.yaml#/dependent_expense_field_values_upload_out' diff --git a/src/admin/paths/admin@dwolla_customers.yaml b/src/admin/paths/admin@dwolla_customers.yaml index 9512dee79..a944eb6bb 100644 --- a/src/admin/paths/admin@dwolla_customers.yaml +++ b/src/admin/paths/admin@dwolla_customers.yaml @@ -60,6 +60,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/dwolla_customer.yaml#/dwolla_customer_out' diff --git a/src/admin/paths/admin@employee_fields.yaml b/src/admin/paths/admin@employee_fields.yaml index 4bcf4e824..fa8537f02 100644 --- a/src/admin/paths/admin@employee_fields.yaml +++ b/src/admin/paths/admin@employee_fields.yaml @@ -60,6 +60,8 @@ post: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/admin/paths/admin@employees@downloads.yaml b/src/admin/paths/admin@employees@downloads.yaml index 0f02c685f..a6522340a 100644 --- a/src/admin/paths/admin@employees@downloads.yaml +++ b/src/admin/paths/admin@employees@downloads.yaml @@ -65,6 +65,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employee.yaml#/employees_download_out' diff --git a/src/admin/paths/admin@employees@export_configurations.yaml b/src/admin/paths/admin@employees@export_configurations.yaml index 883dbe342..1ebea4124 100644 --- a/src/admin/paths/admin@employees@export_configurations.yaml +++ b/src/admin/paths/admin@employees@export_configurations.yaml @@ -163,6 +163,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employees_export_configurations.yaml#/employees_export_configuration_out' diff --git a/src/admin/paths/admin@employees@exports.yaml b/src/admin/paths/admin@employees@exports.yaml index e9e34ca4e..142c571e6 100644 --- a/src/admin/paths/admin@employees@exports.yaml +++ b/src/admin/paths/admin@employees@exports.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employees_exports.yaml#/employees_exports_out' diff --git a/src/admin/paths/admin@employees@filters.yaml b/src/admin/paths/admin@employees@filters.yaml index 2fd76e63e..f5832b22a 100644 --- a/src/admin/paths/admin@employees@filters.yaml +++ b/src/admin/paths/admin@employees@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employee_filters.yaml#/employee_filters_out' diff --git a/src/admin/paths/admin@employees@filters@delete.yaml b/src/admin/paths/admin@employees@filters@delete.yaml index 9a485e223..4c3ec7877 100644 --- a/src/admin/paths/admin@employees@filters@delete.yaml +++ b/src/admin/paths/admin@employees@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employee_filters.yaml#/employee_filters_out' diff --git a/src/admin/paths/admin@employees@stats.yaml b/src/admin/paths/admin@employees@stats.yaml index bebfd19ae..aab808494 100644 --- a/src/admin/paths/admin@employees@stats.yaml +++ b/src/admin/paths/admin@employees@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/employee.yaml#/employees_stats_out' diff --git a/src/admin/paths/admin@employees@uploads.yaml b/src/admin/paths/admin@employees@uploads.yaml index 98301a851..289929f91 100644 --- a/src/admin/paths/admin@employees@uploads.yaml +++ b/src/admin/paths/admin@employees@uploads.yaml @@ -65,6 +65,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employee.yaml#/employees_upload_out' diff --git a/src/admin/paths/admin@expense_fields.yaml b/src/admin/paths/admin@expense_fields.yaml index a5183e230..2efd1d8f6 100644 --- a/src/admin/paths/admin@expense_fields.yaml +++ b/src/admin/paths/admin@expense_fields.yaml @@ -60,6 +60,8 @@ post: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/admin/paths/admin@expense_policies.yaml b/src/admin/paths/admin@expense_policies.yaml index f2d99bfed..3a0dc57b5 100644 --- a/src/admin/paths/admin@expense_policies.yaml +++ b/src/admin/paths/admin@expense_policies.yaml @@ -31,6 +31,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense_policies.yaml#/expense_policy_out diff --git a/src/admin/paths/admin@expense_policies@disable.yaml b/src/admin/paths/admin@expense_policies@disable.yaml index 9e804fcb6..80784a21d 100644 --- a/src/admin/paths/admin@expense_policies@disable.yaml +++ b/src/admin/paths/admin@expense_policies@disable.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense_policies.yaml#/expense_policy_out diff --git a/src/admin/paths/admin@expense_policies@enable.yaml b/src/admin/paths/admin@expense_policies@enable.yaml index d2268e290..d23e1c5c8 100644 --- a/src/admin/paths/admin@expense_policies@enable.yaml +++ b/src/admin/paths/admin@expense_policies@enable.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense_policies.yaml#/expense_policy_out diff --git a/src/admin/paths/admin@expense_policy_comments.yaml b/src/admin/paths/admin@expense_policy_comments.yaml index 32672860a..5c3668172 100644 --- a/src/admin/paths/admin@expense_policy_comments.yaml +++ b/src/admin/paths/admin@expense_policy_comments.yaml @@ -58,6 +58,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@expenses.yaml b/src/admin/paths/admin@expenses.yaml index 8e5610fa4..5c9213e25 100644 --- a/src/admin/paths/admin@expenses.yaml +++ b/src/admin/paths/admin@expenses.yaml @@ -52,6 +52,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_expense_in' @@ -62,6 +64,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/admin/paths/admin@expenses@attach_files@bulk.yaml b/src/admin/paths/admin@expenses@attach_files@bulk.yaml index 697d8e58d..10a43e46a 100644 --- a/src/admin/paths/admin@expenses@attach_files@bulk.yaml +++ b/src/admin/paths/admin@expenses@attach_files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@bulk.yaml b/src/admin/paths/admin@expenses@bulk.yaml index 7d4a8e59e..07ec4dae0 100644 --- a/src/admin/paths/admin@expenses@bulk.yaml +++ b/src/admin/paths/admin@expenses@bulk.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_expenses_bulk_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@check_policies_bulk.yaml b/src/admin/paths/admin@expenses@check_policies_bulk.yaml index 89319cc95..5a4e15542 100644 --- a/src/admin/paths/admin@expenses@check_policies_bulk.yaml +++ b/src/admin/paths/admin@expenses@check_policies_bulk.yaml @@ -28,6 +28,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out diff --git a/src/admin/paths/admin@expenses@comments@bulk.yaml b/src/admin/paths/admin@expenses@comments@bulk.yaml index a48fa6c05..4d597c219 100644 --- a/src/admin/paths/admin@expenses@comments@bulk.yaml +++ b/src/admin/paths/admin@expenses@comments@bulk.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_comments_bulk_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@export_configurations.yaml b/src/admin/paths/admin@expenses@export_configurations.yaml index 3573fbac4..837605ec1 100644 --- a/src/admin/paths/admin@expenses@export_configurations.yaml +++ b/src/admin/paths/admin@expenses@export_configurations.yaml @@ -147,6 +147,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_export_configurations.yaml#/expenses_export_configuration_out' diff --git a/src/admin/paths/admin@expenses@exports.yaml b/src/admin/paths/admin@expenses@exports.yaml index 0736bd382..1e0d8906e 100644 --- a/src/admin/paths/admin@expenses@exports.yaml +++ b/src/admin/paths/admin@expenses@exports.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_exports.yaml#/expenses_exports_out' diff --git a/src/admin/paths/admin@expenses@filters.yaml b/src/admin/paths/admin@expenses@filters.yaml index d3ab7b27e..10e5f6f1c 100644 --- a/src/admin/paths/admin@expenses@filters.yaml +++ b/src/admin/paths/admin@expenses@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/admin/paths/admin@expenses@filters@delete.yaml b/src/admin/paths/admin@expenses@filters@delete.yaml index 144f8b063..0acdb816f 100644 --- a/src/admin/paths/admin@expenses@filters@delete.yaml +++ b/src/admin/paths/admin@expenses@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/admin/paths/admin@expenses@merge.yaml b/src/admin/paths/admin@expenses@merge.yaml index 9684a9e75..1f7c77091 100644 --- a/src/admin/paths/admin@expenses@merge.yaml +++ b/src/admin/paths/admin@expenses@merge.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_merge_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/admin/paths/admin@expenses@permissions.yaml b/src/admin/paths/admin@expenses@permissions.yaml index d6001df6f..3364da543 100644 --- a/src/admin/paths/admin@expenses@permissions.yaml +++ b/src/admin/paths/admin@expenses@permissions.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_out' diff --git a/src/admin/paths/admin@expenses@permissions@bulk.yaml b/src/admin/paths/admin@expenses@permissions@bulk.yaml index 0c0719457..8664840e7 100644 --- a/src/admin/paths/admin@expenses@permissions@bulk.yaml +++ b/src/admin/paths/admin@expenses@permissions@bulk.yaml @@ -33,6 +33,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' diff --git a/src/admin/paths/admin@expenses@split.yaml b/src/admin/paths/admin@expenses@split.yaml index d0754dc82..b07231780 100644 --- a/src/admin/paths/admin@expenses@split.yaml +++ b/src/admin/paths/admin@expenses@split.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml b/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml index 9a9988de2..57c713302 100644 --- a/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml +++ b/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@split@check_policies.yaml b/src/admin/paths/admin@expenses@split@check_policies.yaml index e8a60dddd..0c9410c0b 100644 --- a/src/admin/paths/admin@expenses@split@check_policies.yaml +++ b/src/admin/paths/admin@expenses@split@check_policies.yaml @@ -14,6 +14,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -24,6 +26,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@stats.yaml b/src/admin/paths/admin@expenses@stats.yaml index ee129cee4..0bf898b7c 100644 --- a/src/admin/paths/admin@expenses@stats.yaml +++ b/src/admin/paths/admin@expenses@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_stats_out' diff --git a/src/admin/paths/admin@files.yaml b/src/admin/paths/admin@files.yaml index 02998c601..65603ab8e 100644 --- a/src/admin/paths/admin@files.yaml +++ b/src/admin/paths/admin@files.yaml @@ -59,6 +59,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/file.yaml#/file_out diff --git a/src/admin/paths/admin@files@bulk.yaml b/src/admin/paths/admin@files@bulk.yaml index d48b10505..ffd179f21 100644 --- a/src/admin/paths/admin@files@bulk.yaml +++ b/src/admin/paths/admin@files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@files@generate_urls@bulk.yaml b/src/admin/paths/admin@files@generate_urls@bulk.yaml index a29425341..f28de9259 100644 --- a/src/admin/paths/admin@files@generate_urls@bulk.yaml +++ b/src/admin/paths/admin@files@generate_urls@bulk.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@levels.yaml b/src/admin/paths/admin@levels.yaml index aaadf0736..fc01a971d 100644 --- a/src/admin/paths/admin@levels.yaml +++ b/src/admin/paths/admin@levels.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: ../../components/schemas/level.yaml#/level_out diff --git a/src/admin/paths/admin@mileage_rates.yaml b/src/admin/paths/admin@mileage_rates.yaml index b6f199e99..7f3e8559c 100644 --- a/src/admin/paths/admin@mileage_rates.yaml +++ b/src/admin/paths/admin@mileage_rates.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: ../../components/schemas/mileage_rate.yaml#/mileage_rate_out diff --git a/src/admin/paths/admin@per_diem_rates.yaml b/src/admin/paths/admin@per_diem_rates.yaml index 4cb54f536..f363a51a8 100644 --- a/src/admin/paths/admin@per_diem_rates.yaml +++ b/src/admin/paths/admin@per_diem_rates.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/per_diem_rate.yaml#/per_diem_rate_out diff --git a/src/admin/paths/admin@projects.yaml b/src/admin/paths/admin@projects.yaml index d9dbe32e5..d311d685d 100644 --- a/src/admin/paths/admin@projects.yaml +++ b/src/admin/paths/admin@projects.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/project.yaml#/admin_approver_project_out diff --git a/src/admin/paths/admin@reconciliation_entries@close.yaml b/src/admin/paths/admin@reconciliation_entries@close.yaml index 5e8b56b7d..f491c1fdb 100644 --- a/src/admin/paths/admin@reconciliation_entries@close.yaml +++ b/src/admin/paths/admin@reconciliation_entries@close.yaml @@ -33,6 +33,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml b/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml index 3755c345e..04c6923c2 100644 --- a/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml +++ b/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/reconciliation_exports.yaml#/reconciliation_export_out' diff --git a/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml b/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml index d36857e54..c7c16dcf5 100644 --- a/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml +++ b/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml @@ -26,6 +26,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml index 698c0e4be..c2f5a66c2 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml @@ -39,6 +39,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml index 0d4f54b96..d1b11f39c 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/reconciliation_exports.yaml#/reconciliation_export_out' diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml index 40c7ee40e..149cac5f6 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml @@ -32,6 +32,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml index 70600a3d6..08ba7772c 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml @@ -46,6 +46,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml index e9b88c92c..a21847a8d 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml @@ -31,6 +31,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml index 92b38f5be..b93a11236 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml @@ -39,6 +39,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml index d54070960..246efefd8 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml @@ -38,6 +38,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml index 4a291f7f5..60d0a3581 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml @@ -26,6 +26,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml index fbd004c12..0af2981f0 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml @@ -39,6 +39,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reimbursements@mark_complete.yaml b/src/admin/paths/admin@reimbursements@mark_complete.yaml index 5dce2ef6e..5f29952d4 100644 --- a/src/admin/paths/admin@reimbursements@mark_complete.yaml +++ b/src/admin/paths/admin@reimbursements@mark_complete.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/reimbursement.yaml#/reimbursement_out' diff --git a/src/admin/paths/admin@reminders.yaml b/src/admin/paths/admin@reminders.yaml index e7490eb72..7aa19a6bf 100644 --- a/src/admin/paths/admin@reminders.yaml +++ b/src/admin/paths/admin@reminders.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/reminder.yaml#/reminder_out diff --git a/src/admin/paths/admin@reminders@delete.yaml b/src/admin/paths/admin@reminders@delete.yaml index 95ec9b7e0..3e060b578 100644 --- a/src/admin/paths/admin@reminders@delete.yaml +++ b/src/admin/paths/admin@reminders@delete.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reminders@stats.yaml b/src/admin/paths/admin@reminders@stats.yaml index 3cca816f3..e22926d51 100644 --- a/src/admin/paths/admin@reminders@stats.yaml +++ b/src/admin/paths/admin@reminders@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reports@add_approver.yaml b/src/admin/paths/admin@reports@add_approver.yaml index 226ad05bd..19a0e87f0 100644 --- a/src/admin/paths/admin@reports@add_approver.yaml +++ b/src/admin/paths/admin@reports@add_approver.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@apply_advance_wallets.yaml b/src/admin/paths/admin@reports@apply_advance_wallets.yaml index fceba0263..c5fee00fa 100644 --- a/src/admin/paths/admin@reports@apply_advance_wallets.yaml +++ b/src/admin/paths/admin@reports@apply_advance_wallets.yaml @@ -24,6 +24,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@comments.yaml b/src/admin/paths/admin@reports@comments.yaml index 9b48e93b2..ffdef235d 100644 --- a/src/admin/paths/admin@reports@comments.yaml +++ b/src/admin/paths/admin@reports@comments.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_comments_out' diff --git a/src/admin/paths/admin@reports@delete_filter.yaml b/src/admin/paths/admin@reports@delete_filter.yaml index 50d56712a..63bceca83 100644 --- a/src/admin/paths/admin@reports@delete_filter.yaml +++ b/src/admin/paths/admin@reports@delete_filter.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/admin/paths/admin@reports@eject_expenses.yaml b/src/admin/paths/admin@reports@eject_expenses.yaml index d293caddb..3a9717f45 100644 --- a/src/admin/paths/admin@reports@eject_expenses.yaml +++ b/src/admin/paths/admin@reports@eject_expenses.yaml @@ -30,6 +30,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@export_configurations.yaml b/src/admin/paths/admin@reports@export_configurations.yaml index 3f4c2f255..d544fa796 100644 --- a/src/admin/paths/admin@reports@export_configurations.yaml +++ b/src/admin/paths/admin@reports@export_configurations.yaml @@ -70,6 +70,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_export_configurations.yaml#/reports_export_configuration_out' diff --git a/src/admin/paths/admin@reports@exports.yaml b/src/admin/paths/admin@reports@exports.yaml index 683440fb1..248ff4d59 100644 --- a/src/admin/paths/admin@reports@exports.yaml +++ b/src/admin/paths/admin@reports@exports.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_exports.yaml#/reports_exports_out' diff --git a/src/admin/paths/admin@reports@permissions.yaml b/src/admin/paths/admin@reports@permissions.yaml index 00c0674d9..71ca3ad25 100644 --- a/src/admin/paths/admin@reports@permissions.yaml +++ b/src/admin/paths/admin@reports@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report_permissions.yaml#/report_permissions_out' diff --git a/src/admin/paths/admin@reports@process_summary@bulk.yaml b/src/admin/paths/admin@reports@process_summary@bulk.yaml index 7ca2d35c9..84f8a99f4 100644 --- a/src/admin/paths/admin@reports@process_summary@bulk.yaml +++ b/src/admin/paths/admin@reports@process_summary@bulk.yaml @@ -26,6 +26,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reports@remove_advance_wallets.yaml b/src/admin/paths/admin@reports@remove_advance_wallets.yaml index ebc30e859..f4675ef0a 100644 --- a/src/admin/paths/admin@reports@remove_advance_wallets.yaml +++ b/src/admin/paths/admin@reports@remove_advance_wallets.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@remove_approver.yaml b/src/admin/paths/admin@reports@remove_approver.yaml index a305e8946..cf117eacd 100644 --- a/src/admin/paths/admin@reports@remove_approver.yaml +++ b/src/admin/paths/admin@reports@remove_approver.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@revert_to_approved.yaml b/src/admin/paths/admin@reports@revert_to_approved.yaml index 7c411b0ba..51e3af78d 100644 --- a/src/admin/paths/admin@reports@revert_to_approved.yaml +++ b/src/admin/paths/admin@reports@revert_to_approved.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@revert_to_processing.yaml b/src/admin/paths/admin@reports@revert_to_processing.yaml index 6d00142dd..22ab342dc 100644 --- a/src/admin/paths/admin@reports@revert_to_processing.yaml +++ b/src/admin/paths/admin@reports@revert_to_processing.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@round_off_amount.yaml b/src/admin/paths/admin@reports@round_off_amount.yaml index 06614451f..f99731a3a 100644 --- a/src/admin/paths/admin@reports@round_off_amount.yaml +++ b/src/admin/paths/admin@reports@round_off_amount.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@save_filters.yaml b/src/admin/paths/admin@reports@save_filters.yaml index 36652d425..2da3220ee 100644 --- a/src/admin/paths/admin@reports@save_filters.yaml +++ b/src/admin/paths/admin@reports@save_filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/admin/paths/admin@reports@send_back.yaml b/src/admin/paths/admin@reports@send_back.yaml index acd3ca98d..3cc52c0aa 100644 --- a/src/admin/paths/admin@reports@send_back.yaml +++ b/src/admin/paths/admin@reports@send_back.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@stats.yaml b/src/admin/paths/admin@reports@stats.yaml index bd00c4e13..029c82d13 100644 --- a/src/admin/paths/admin@reports@stats.yaml +++ b/src/admin/paths/admin@reports@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/reports_stats_out' diff --git a/src/admin/paths/admin@scheduled_callbacks.yaml b/src/admin/paths/admin@scheduled_callbacks.yaml index 8a1ad4f51..d6b9f008f 100644 --- a/src/admin/paths/admin@scheduled_callbacks.yaml +++ b/src/admin/paths/admin@scheduled_callbacks.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/scheduled_callback.yaml#/scheduled_callback_out diff --git a/src/admin/paths/admin@schedules.yaml b/src/admin/paths/admin@schedules.yaml index 5ab588a35..c6e4eb8ca 100644 --- a/src/admin/paths/admin@schedules.yaml +++ b/src/admin/paths/admin@schedules.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/schedule.yaml#/schedule_out diff --git a/src/admin/paths/admin@statements@archived_cards.yaml b/src/admin/paths/admin@statements@archived_cards.yaml index 60b5d27b6..09083e129 100644 --- a/src/admin/paths/admin@statements@archived_cards.yaml +++ b/src/admin/paths/admin@statements@archived_cards.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@archived_cards@ignore.yaml b/src/admin/paths/admin@statements@archived_cards@ignore.yaml index e3a06ac61..575dc0970 100644 --- a/src/admin/paths/admin@statements@archived_cards@ignore.yaml +++ b/src/admin/paths/admin@statements@archived_cards@ignore.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@statements@card_stats.yaml b/src/admin/paths/admin@statements@card_stats.yaml index 5906f74f6..3a9d20431 100644 --- a/src/admin/paths/admin@statements@card_stats.yaml +++ b/src/admin/paths/admin@statements@card_stats.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/statements.yaml#/card_stats_out' diff --git a/src/admin/paths/admin@statements@matching_cards.yaml b/src/admin/paths/admin@statements@matching_cards.yaml index 05cf558fa..68b4b9aa6 100644 --- a/src/admin/paths/admin@statements@matching_cards.yaml +++ b/src/admin/paths/admin@statements@matching_cards.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@preview.yaml b/src/admin/paths/admin@statements@preview.yaml index 5a21fb962..f57f87bb3 100644 --- a/src/admin/paths/admin@statements@preview.yaml +++ b/src/admin/paths/admin@statements@preview.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/statements.yaml#/preview_out' diff --git a/src/admin/paths/admin@statements@reconcile.yaml b/src/admin/paths/admin@statements@reconcile.yaml index d35298686..1669a3032 100644 --- a/src/admin/paths/admin@statements@reconcile.yaml +++ b/src/admin/paths/admin@statements@reconcile.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@statements@reconciliation_summary.yaml b/src/admin/paths/admin@statements@reconciliation_summary.yaml index e752af7ef..f6b325be4 100644 --- a/src/admin/paths/admin@statements@reconciliation_summary.yaml +++ b/src/admin/paths/admin@statements@reconciliation_summary.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@suggest_mappings.yaml b/src/admin/paths/admin@statements@suggest_mappings.yaml index 9343af7e8..7612be13b 100644 --- a/src/admin/paths/admin@statements@suggest_mappings.yaml +++ b/src/admin/paths/admin@statements@suggest_mappings.yaml @@ -31,6 +31,10 @@ post: application/json: schema: type: object + required: + - data + - count + - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@statements@summary.yaml b/src/admin/paths/admin@statements@summary.yaml index f0e6aca4c..6da4d23c5 100644 --- a/src/admin/paths/admin@statements@summary.yaml +++ b/src/admin/paths/admin@statements@summary.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@unassigned_cards.yaml b/src/admin/paths/admin@statements@unassigned_cards.yaml index 515510f52..18fc4f299 100644 --- a/src/admin/paths/admin@statements@unassigned_cards.yaml +++ b/src/admin/paths/admin@statements@unassigned_cards.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@upload.yaml b/src/admin/paths/admin@statements@upload.yaml index c14faeba1..704d3c069 100644 --- a/src/admin/paths/admin@statements@upload.yaml +++ b/src/admin/paths/admin@statements@upload.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/statements.yaml#/statements_out' diff --git a/src/admin/paths/admin@subscriptions.yaml b/src/admin/paths/admin@subscriptions.yaml index 8d0b401c7..dc8b04e6e 100644 --- a/src/admin/paths/admin@subscriptions.yaml +++ b/src/admin/paths/admin@subscriptions.yaml @@ -11,6 +11,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/admin_subscriptions_in' @@ -22,6 +24,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/admin_subscriptions_out' diff --git a/src/admin/paths/admin@tax_groups.yaml b/src/admin/paths/admin@tax_groups.yaml index 12179977b..f0551647f 100644 --- a/src/admin/paths/admin@tax_groups.yaml +++ b/src/admin/paths/admin@tax_groups.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/tax_group.yaml#/tax_group_out' diff --git a/src/admin/paths/admin@virtual_cards@delete.yaml b/src/admin/paths/admin@virtual_cards@delete.yaml index 065ae1e09..7ca783e98 100644 --- a/src/admin/paths/admin@virtual_cards@delete.yaml +++ b/src/admin/paths/admin@virtual_cards@delete.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_card_out' diff --git a/src/admin/paths/admin@virtual_cards@get_current_amount.yaml b/src/admin/paths/admin@virtual_cards@get_current_amount.yaml index b326a885c..4e422c72f 100644 --- a/src/admin/paths/admin@virtual_cards@get_current_amount.yaml +++ b/src/admin/paths/admin@virtual_cards@get_current_amount.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_get_current_balance_out' diff --git a/src/admin/paths/admin@virtual_cards@show_card_details.yaml b/src/admin/paths/admin@virtual_cards@show_card_details.yaml index e1b3bcc92..ac9d647f2 100644 --- a/src/admin/paths/admin@virtual_cards@show_card_details.yaml +++ b/src/admin/paths/admin@virtual_cards@show_card_details.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_show_card_details_out' diff --git a/src/approver/paths/approver@advance_requests@add_approver.yaml b/src/approver/paths/approver@advance_requests@add_approver.yaml index 81c08199f..7685fd3e4 100644 --- a/src/approver/paths/approver@advance_requests@add_approver.yaml +++ b/src/approver/paths/approver@advance_requests@add_approver.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_add_approver_in' @@ -26,6 +28,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml b/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml index 14065e4b1..8da910c34 100644 --- a/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml +++ b/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@advance_requests@comments.yaml b/src/approver/paths/approver@advance_requests@comments.yaml index 81f9ea81d..2ce3237c2 100644 --- a/src/approver/paths/approver@advance_requests@comments.yaml +++ b/src/approver/paths/approver@advance_requests@comments.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_out' diff --git a/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml b/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml index 66b6174f8..3b633a735 100644 --- a/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml +++ b/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@advance_requests@inquire.yaml b/src/approver/paths/approver@advance_requests@inquire.yaml index 806a56798..da8dd2440 100644 --- a/src/approver/paths/approver@advance_requests@inquire.yaml +++ b/src/approver/paths/approver@advance_requests@inquire.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@partially_approve.yaml b/src/approver/paths/approver@advance_requests@partially_approve.yaml index 0068c6c50..13bbc1386 100644 --- a/src/approver/paths/approver@advance_requests@partially_approve.yaml +++ b/src/approver/paths/approver@advance_requests@partially_approve.yaml @@ -26,6 +26,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@permissions.yaml b/src/approver/paths/approver@advance_requests@permissions.yaml index 744da3b9f..8f5d4031b 100644 --- a/src/approver/paths/approver@advance_requests@permissions.yaml +++ b/src/approver/paths/approver@advance_requests@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_permissions_out' diff --git a/src/approver/paths/approver@advance_requests@reject.yaml b/src/approver/paths/approver@advance_requests@reject.yaml index 0930de8e2..c2df92a74 100644 --- a/src/approver/paths/approver@advance_requests@reject.yaml +++ b/src/approver/paths/approver@advance_requests@reject.yaml @@ -29,6 +29,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@stats.yaml b/src/approver/paths/approver@advance_requests@stats.yaml index 9e16193ec..d778f6fac 100644 --- a/src/approver/paths/approver@advance_requests@stats.yaml +++ b/src/approver/paths/approver@advance_requests@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_requests_approver_stats_out' diff --git a/src/approver/paths/approver@advance_requests@submit.yaml b/src/approver/paths/approver@advance_requests@submit.yaml index f511c601e..287fae1b2 100644 --- a/src/approver/paths/approver@advance_requests@submit.yaml +++ b/src/approver/paths/approver@advance_requests@submit.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@corporate_card_transactions@match.yaml b/src/approver/paths/approver@corporate_card_transactions@match.yaml index 4c60ece64..7cbe00818 100644 --- a/src/approver/paths/approver@corporate_card_transactions@match.yaml +++ b/src/approver/paths/approver@corporate_card_transactions@match.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_match_out' diff --git a/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml b/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml index 561fa70a1..01c7bdec8 100644 --- a/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml +++ b/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmatch_out' diff --git a/src/approver/paths/approver@employee_overview@expenses@stats.yaml b/src/approver/paths/approver@employee_overview@expenses@stats.yaml index b9f4a4e48..cee6c869e 100644 --- a/src/approver/paths/approver@employee_overview@expenses@stats.yaml +++ b/src/approver/paths/approver@employee_overview@expenses@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_expense_stats_out diff --git a/src/approver/paths/approver@employee_overview@stats.yaml b/src/approver/paths/approver@employee_overview@stats.yaml index b133e3fc7..441c9a55d 100644 --- a/src/approver/paths/approver@employee_overview@stats.yaml +++ b/src/approver/paths/approver@employee_overview@stats.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_stats_out diff --git a/src/approver/paths/approver@expenses.yaml b/src/approver/paths/approver@expenses.yaml index d9780a8ac..2537789d4 100644 --- a/src/approver/paths/approver@expenses.yaml +++ b/src/approver/paths/approver@expenses.yaml @@ -53,6 +53,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/approver_expense_in' @@ -63,6 +65,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/approver/paths/approver@expenses@attach_files@bulk.yaml b/src/approver/paths/approver@expenses@attach_files@bulk.yaml index 697d8e58d..10a43e46a 100644 --- a/src/approver/paths/approver@expenses@attach_files@bulk.yaml +++ b/src/approver/paths/approver@expenses@attach_files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@bulk.yaml b/src/approver/paths/approver@expenses@bulk.yaml index 1e777f6e0..d9f30d26d 100644 --- a/src/approver/paths/approver@expenses@bulk.yaml +++ b/src/approver/paths/approver@expenses@bulk.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/approver_expenses_bulk_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@check_policies_bulk.yaml b/src/approver/paths/approver@expenses@check_policies_bulk.yaml index 99296b6ba..9d66fc8ab 100644 --- a/src/approver/paths/approver@expenses@check_policies_bulk.yaml +++ b/src/approver/paths/approver@expenses@check_policies_bulk.yaml @@ -28,6 +28,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out diff --git a/src/approver/paths/approver@expenses@comments@bulk.yaml b/src/approver/paths/approver@expenses@comments@bulk.yaml index 2fb188a45..8ba2a5104 100644 --- a/src/approver/paths/approver@expenses@comments@bulk.yaml +++ b/src/approver/paths/approver@expenses@comments@bulk.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_comments_bulk_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@export_configurations.yaml b/src/approver/paths/approver@expenses@export_configurations.yaml index 96be32a0d..4d56b4cab 100644 --- a/src/approver/paths/approver@expenses@export_configurations.yaml +++ b/src/approver/paths/approver@expenses@export_configurations.yaml @@ -158,6 +158,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_export_configurations.yaml#/expenses_export_configuration_out' diff --git a/src/approver/paths/approver@expenses@exports.yaml b/src/approver/paths/approver@expenses@exports.yaml index 0736bd382..1e0d8906e 100644 --- a/src/approver/paths/approver@expenses@exports.yaml +++ b/src/approver/paths/approver@expenses@exports.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_exports.yaml#/expenses_exports_out' diff --git a/src/approver/paths/approver@expenses@filters.yaml b/src/approver/paths/approver@expenses@filters.yaml index 797810a62..38291520a 100644 --- a/src/approver/paths/approver@expenses@filters.yaml +++ b/src/approver/paths/approver@expenses@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/approver/paths/approver@expenses@filters@delete.yaml b/src/approver/paths/approver@expenses@filters@delete.yaml index 144f8b063..0acdb816f 100644 --- a/src/approver/paths/approver@expenses@filters@delete.yaml +++ b/src/approver/paths/approver@expenses@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/approver/paths/approver@expenses@permissions.yaml b/src/approver/paths/approver@expenses@permissions.yaml index 00ba5862c..e291a4a40 100644 --- a/src/approver/paths/approver@expenses@permissions.yaml +++ b/src/approver/paths/approver@expenses@permissions.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_out' diff --git a/src/approver/paths/approver@expenses@permissions@bulk.yaml b/src/approver/paths/approver@expenses@permissions@bulk.yaml index 2ffce10c5..938f1be3c 100644 --- a/src/approver/paths/approver@expenses@permissions@bulk.yaml +++ b/src/approver/paths/approver@expenses@permissions@bulk.yaml @@ -33,6 +33,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' diff --git a/src/approver/paths/approver@expenses@split.yaml b/src/approver/paths/approver@expenses@split.yaml index 6c18eb6ec..e8a734bc7 100644 --- a/src/approver/paths/approver@expenses@split.yaml +++ b/src/approver/paths/approver@expenses@split.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml b/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml index 9a9988de2..57c713302 100644 --- a/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml +++ b/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@split@check_policies.yaml b/src/approver/paths/approver@expenses@split@check_policies.yaml index 402c93873..f75995482 100644 --- a/src/approver/paths/approver@expenses@split@check_policies.yaml +++ b/src/approver/paths/approver@expenses@split@check_policies.yaml @@ -14,6 +14,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -24,6 +26,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@stats.yaml b/src/approver/paths/approver@expenses@stats.yaml index ee129cee4..0bf898b7c 100644 --- a/src/approver/paths/approver@expenses@stats.yaml +++ b/src/approver/paths/approver@expenses@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_stats_out' diff --git a/src/approver/paths/approver@files@bulk.yaml b/src/approver/paths/approver@files@bulk.yaml index 11b97415d..942bbd084 100644 --- a/src/approver/paths/approver@files@bulk.yaml +++ b/src/approver/paths/approver@files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@files@generate_urls@bulk.yaml b/src/approver/paths/approver@files@generate_urls@bulk.yaml index a29425341..f28de9259 100644 --- a/src/approver/paths/approver@files@generate_urls@bulk.yaml +++ b/src/approver/paths/approver@files@generate_urls@bulk.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@reports@add_approver.yaml b/src/approver/paths/approver@reports@add_approver.yaml index 2d728ead7..c2451a2f6 100644 --- a/src/approver/paths/approver@reports@add_approver.yaml +++ b/src/approver/paths/approver@reports@add_approver.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@add_expenses.yaml b/src/approver/paths/approver@reports@add_expenses.yaml index d78c9af28..3aca97649 100644 --- a/src/approver/paths/approver@reports@add_expenses.yaml +++ b/src/approver/paths/approver@reports@add_expenses.yaml @@ -26,6 +26,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@comments.yaml b/src/approver/paths/approver@reports@comments.yaml index 883b28497..7e3628021 100644 --- a/src/approver/paths/approver@reports@comments.yaml +++ b/src/approver/paths/approver@reports@comments.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_comments_out' diff --git a/src/approver/paths/approver@reports@eject_expenses.yaml b/src/approver/paths/approver@reports@eject_expenses.yaml index f948a3806..4e90d7e8b 100644 --- a/src/approver/paths/approver@reports@eject_expenses.yaml +++ b/src/approver/paths/approver@reports@eject_expenses.yaml @@ -26,6 +26,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@export_configurations.yaml b/src/approver/paths/approver@reports@export_configurations.yaml index d0c89edbc..0eaf70cac 100644 --- a/src/approver/paths/approver@reports@export_configurations.yaml +++ b/src/approver/paths/approver@reports@export_configurations.yaml @@ -83,6 +83,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_export_configurations.yaml#/reports_export_configuration_out' diff --git a/src/approver/paths/approver@reports@exports.yaml b/src/approver/paths/approver@reports@exports.yaml index 683440fb1..248ff4d59 100644 --- a/src/approver/paths/approver@reports@exports.yaml +++ b/src/approver/paths/approver@reports@exports.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_exports.yaml#/reports_exports_out' diff --git a/src/approver/paths/approver@reports@filters.yaml b/src/approver/paths/approver@reports@filters.yaml index 6ae983d65..3793210ec 100644 --- a/src/approver/paths/approver@reports@filters.yaml +++ b/src/approver/paths/approver@reports@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/approver/paths/approver@reports@filters@delete.yaml b/src/approver/paths/approver@reports@filters@delete.yaml index 50d56712a..63bceca83 100644 --- a/src/approver/paths/approver@reports@filters@delete.yaml +++ b/src/approver/paths/approver@reports@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/approver/paths/approver@reports@partially_approve.yaml b/src/approver/paths/approver@reports@partially_approve.yaml index d4992f6b4..63e0f396e 100644 --- a/src/approver/paths/approver@reports@partially_approve.yaml +++ b/src/approver/paths/approver@reports@partially_approve.yaml @@ -26,6 +26,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@permissions.yaml b/src/approver/paths/approver@reports@permissions.yaml index 00c0674d9..71ca3ad25 100644 --- a/src/approver/paths/approver@reports@permissions.yaml +++ b/src/approver/paths/approver@reports@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report_permissions.yaml#/report_permissions_out' diff --git a/src/approver/paths/approver@reports@round_off_amount.yaml b/src/approver/paths/approver@reports@round_off_amount.yaml index 97134cb22..67b43e94c 100644 --- a/src/approver/paths/approver@reports@round_off_amount.yaml +++ b/src/approver/paths/approver@reports@round_off_amount.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@send_back.yaml b/src/approver/paths/approver@reports@send_back.yaml index 097602105..8502b3c9b 100644 --- a/src/approver/paths/approver@reports@send_back.yaml +++ b/src/approver/paths/approver@reports@send_back.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@stats.yaml b/src/approver/paths/approver@reports@stats.yaml index bd00c4e13..029c82d13 100644 --- a/src/approver/paths/approver@reports@stats.yaml +++ b/src/approver/paths/approver@reports@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/reports_stats_out' diff --git a/src/approver/paths/approver@subscriptions.yaml b/src/approver/paths/approver@subscriptions.yaml index f272d4b96..1cece38ec 100644 --- a/src/approver/paths/approver@subscriptions.yaml +++ b/src/approver/paths/approver@subscriptions.yaml @@ -11,6 +11,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/subscriptions_in' @@ -22,6 +24,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/approver_subscriptions_out' diff --git a/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml b/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml index ef3d14d3d..476aea906 100644 --- a/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml +++ b/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml @@ -12,6 +12,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: ../../components/schemas/org_settings.yaml#/logo_file_generate_download_url_action_out diff --git a/src/components/schemas/account.yaml b/src/components/schemas/account.yaml index 8673451d1..094319b9e 100644 --- a/src/components/schemas/account.yaml +++ b/src/components/schemas/account.yaml @@ -1,6 +1,17 @@ account_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - user_id + - type + - currency + - current_balance_amount + - tentative_balance_amount + - org_id + - category_id properties: id: allOf: @@ -45,6 +56,9 @@ account_out: account_out_embed: type: object + required: + - id + - type properties: id: allOf: @@ -63,6 +77,11 @@ account_out_embed: account_snapshot_out_embed: type: object + required: + - account_id + - type + - currency + - balance properties: account_id: allOf: @@ -87,6 +106,11 @@ account_snapshot_out_embed: account_in: type: object additionalProperties: false + required: + - user_id + - type + - currency + - category_id properties: user_id: type: string diff --git a/src/components/schemas/advance.yaml b/src/components/schemas/advance.yaml index 0aaf5fc55..0daadea92 100644 --- a/src/components/schemas/advance.yaml +++ b/src/components/schemas/advance.yaml @@ -141,6 +141,12 @@ advance_out: advance_out_embed: type: object nullable: true + required: + - id + - currency + - amount + - advance_request_id + - seq_num properties: id: type: string @@ -246,6 +252,8 @@ advance_in: $ref: './fields.yaml#/custom_fields' advances_stats_in: + required: + - query_params properties: query_params: type: string @@ -256,6 +264,9 @@ advances_stats_in: advances_stats_out: type: object + required: + - count + - total_amount properties: count: type: integer diff --git a/src/components/schemas/advance_refund.yaml b/src/components/schemas/advance_refund.yaml index 5c533ba75..849939512 100644 --- a/src/components/schemas/advance_refund.yaml +++ b/src/components/schemas/advance_refund.yaml @@ -153,6 +153,8 @@ advance_refund_in: example: 'awfgRr8YA6KK' advance_refunds_stats_in: + required: + - query_params properties: query_params: type: string @@ -163,6 +165,9 @@ advance_refunds_stats_in: advance_refunds_stats_out: type: object + required: + - count + - total_amount properties: count: type: integer diff --git a/src/components/schemas/advance_request.yaml b/src/components/schemas/advance_request.yaml index 5ca278569..8be5ea210 100644 --- a/src/components/schemas/advance_request.yaml +++ b/src/components/schemas/advance_request.yaml @@ -216,6 +216,8 @@ advance_request_action_in: example: 'rpa21A2rdj2' advance_requests_stats_in: + required: + - query_params properties: query_params: description: | @@ -305,6 +307,10 @@ advance_requests_stats_out: advance_request_out_embed: type: object nullable: true + required: + - id + - last_approved_at + - seq_num properties: id: type: string @@ -406,6 +412,17 @@ advance_request_comments_in: advance_request_comments_out: type: object additionalProperties: false + required: + - id + - comment + - action + - advance_request_id + - creator_type + - creator_user_id + - creator_user + - created_at + - updated_at + - org_id properties: id: $ref: './fields.yaml#/id_string' @@ -470,6 +487,18 @@ advance_request_permissions_in: advance_request_permissions_out: type: object additionalProperties: false + required: + - can_save + - can_submit + - can_edit + - can_add_approver + - can_disable_approver + - can_reject + - can_approve + - can_inquire + - can_pull_back + - can_pay + - can_delete properties: can_save: type: boolean @@ -533,6 +562,7 @@ advance_request_action_pull_back_in: description: | Comment explaining the reason for pulling back the advance request example: 'sending back' + nullable: true advance_request_delete_in: type: object diff --git a/src/components/schemas/advance_request_approval.yaml b/src/components/schemas/advance_request_approval.yaml index d4e5b3d1c..d773cf1ea 100644 --- a/src/components/schemas/advance_request_approval.yaml +++ b/src/components/schemas/advance_request_approval.yaml @@ -1,6 +1,10 @@ advance_request_approval_out_embed: type: object additionalProperties: False + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: diff --git a/src/components/schemas/advance_wallet.yaml b/src/components/schemas/advance_wallet.yaml index 72da46164..30ed9452d 100644 --- a/src/components/schemas/advance_wallet.yaml +++ b/src/components/schemas/advance_wallet.yaml @@ -41,6 +41,9 @@ advance_wallet_in: advance_wallet_report_out: type: object additionalProperties: false + required: + - id + - amount properties: id: allOf: diff --git a/src/components/schemas/automation.yaml b/src/components/schemas/automation.yaml index 08cc75a6f..8b49828a5 100644 --- a/src/components/schemas/automation.yaml +++ b/src/components/schemas/automation.yaml @@ -13,6 +13,9 @@ spender_automate_report_submission_next_at_out: automate_report_submission_in: type: object + required: + - description + - schedule_config properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/budget.yaml b/src/components/schemas/budget.yaml index 71199ca3d..8b7e04cb0 100644 --- a/src/components/schemas/budget.yaml +++ b/src/components/schemas/budget.yaml @@ -183,6 +183,7 @@ budget_out: - visibility - status - user_ids + - fiscal_year_start_month properties: id: $ref: './fields.yaml#/id_string' @@ -302,6 +303,12 @@ budget_out: budget_out_embed: type: object additionalProperties: False + required: + - id + - name + - type + - amount_limit + - is_enabled properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/budget_exports.yaml b/src/components/schemas/budget_exports.yaml index d00f343c9..4e2f0cca2 100644 --- a/src/components/schemas/budget_exports.yaml +++ b/src/components/schemas/budget_exports.yaml @@ -16,6 +16,15 @@ budget_exports_in: budget_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - file_id + - state properties: created_at: $ref: './fields.yaml#/created_at' diff --git a/src/components/schemas/category.yaml b/src/components/schemas/category.yaml index e82a28f13..9fa66ad8c 100644 --- a/src/components/schemas/category.yaml +++ b/src/components/schemas/category.yaml @@ -65,6 +65,13 @@ category_out_embed: type: object nullable: true additionalProperties: False + required: + - id + - system_category + - name + - sub_category + - code + - display_name properties: id: $ref: './fields.yaml#/id_integer' @@ -236,10 +243,15 @@ admin_approver_category_out: category_delete_summary_out: type: object + required: + - data additionalProperties: False properties: data: type: object + required: + - delete_count + - categories properties: delete_count: type: integer diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index ad233810a..a39c7d41d 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -500,6 +500,16 @@ corporate_card_unassign_out: corporate_card_out_embed: type: object additionalProperties: false + required: + - id + - bank_name + - card_number + - nickname + - cardholder_name + - masked_number + - user_full_name + - user_email + - is_archived properties: id: allOf: @@ -559,6 +569,16 @@ corporate_card_out_embed: duplicate_suggestion_corporate_card_out_embed: type: object additionalProperties: false + required: + - id + - bank_name + - card_number + - nickname + - total_transactions_count + - is_visa_enrolled + - is_mastercard_enrolled + - data_feed_source + - feed_display_name properties: id: allOf: @@ -612,6 +632,8 @@ duplicate_suggestion_corporate_card_out_embed: corporate_card_stats_in: + required: + - query_params properties: query_params: nullable: False @@ -622,6 +644,10 @@ corporate_card_stats_in: corporate_card_stats_out: type: object + required: + - count + - total_transactions_count + - transactions_count properties: count: type: integer @@ -734,6 +760,9 @@ yodlee_accounts_out: - updated_at + - org_id + - user_id + - corporate_card_id corporate_card_merge_in: type: object properties: diff --git a/src/components/schemas/corporate_card_transaction.yaml b/src/components/schemas/corporate_card_transaction.yaml index 9146aaa5d..c0144790a 100644 --- a/src/components/schemas/corporate_card_transaction.yaml +++ b/src/components/schemas/corporate_card_transaction.yaml @@ -603,6 +603,7 @@ corporate_card_transaction_post_out: - is_exported - metadata + - mcc corporate_card_transaction_assign_in: type: object properties: @@ -830,6 +831,7 @@ corporate_card_transaction_assign_out: - last_user_matched_at - metadata + - mcc corporate_card_transaction_unassign_out: type: object properties: @@ -1046,6 +1048,8 @@ corporate_card_transaction_unassign_out: - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_match_in: type: object properties: @@ -1279,6 +1283,9 @@ corporate_card_transaction_match_out: - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_unmatch_in: type: object properties: @@ -1524,6 +1531,11 @@ corporate_card_transaction_unmatch_out: - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number + - is_exported corporate_card_transaction_id_in: type: object properties: @@ -1742,6 +1754,8 @@ corporate_card_transaction_mark_personal_out: - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_unmark_personal_out: type: object properties: @@ -1951,6 +1965,8 @@ corporate_card_transaction_unmark_personal_out: - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_ignore_out: type: object properties: @@ -2166,6 +2182,9 @@ corporate_card_transaction_ignore_out: - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_undo_ignore_out: type: object additionalProperties: false @@ -2396,7 +2415,14 @@ corporate_card_transaction_undo_ignore_out: - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number corporate_card_transactions_stats_in: + type: object + required: + - query_params properties: query_params: nullable: false @@ -2407,6 +2433,10 @@ corporate_card_transactions_stats_in: corporate_card_transactions_stats_out: type: object + required: + - count + - debit_amount + - credit_amount properties: count: type: integer @@ -2439,6 +2469,9 @@ corporate_card_transactions_delete_summary_in: corporate_card_transactions_delete_summary_out: type: object + required: + - delete_count + - delete_amount properties: delete_count: type: integer @@ -2481,6 +2514,8 @@ corporate_card_transaction_reassign_in: corporate_card_transactions_expenses_stats_in: type: object + required: + - query_params properties: query_params: type: string diff --git a/src/components/schemas/corporate_card_transactions_exports.yaml b/src/components/schemas/corporate_card_transactions_exports.yaml index 8bdb03fb5..430b52a24 100644 --- a/src/components/schemas/corporate_card_transactions_exports.yaml +++ b/src/components/schemas/corporate_card_transactions_exports.yaml @@ -126,6 +126,20 @@ corporate_card_transactions_exports_in: corporate_card_transactions_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state + - processed_at + - completed_at + - failed_at properties: created_at: $ref: './fields.yaml#/created_at' diff --git a/src/components/schemas/corporate_credit_card_expense.yaml b/src/components/schemas/corporate_credit_card_expense.yaml index fe5669f3b..d1d152ea3 100644 --- a/src/components/schemas/corporate_credit_card_expense.yaml +++ b/src/components/schemas/corporate_credit_card_expense.yaml @@ -1,5 +1,9 @@ corporate_credit_card_expense_out_embed: type: object + required: + - id + - currency + - amount properties: id: type: string diff --git a/src/components/schemas/cost_center.yaml b/src/components/schemas/cost_center.yaml index b77017725..bf9086733 100644 --- a/src/components/schemas/cost_center.yaml +++ b/src/components/schemas/cost_center.yaml @@ -36,6 +36,10 @@ cost_center_out_embed: type: object nullable: true additionalProperties: False + required: + - id + - name + - code properties: id: $ref: './fields.yaml#/id_integer' @@ -190,6 +194,8 @@ cost_center_in_only_id: cost_center_delete_summary_out: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/components/schemas/currency.yaml b/src/components/schemas/currency.yaml index 365cba351..748254464 100644 --- a/src/components/schemas/currency.yaml +++ b/src/components/schemas/currency.yaml @@ -1,5 +1,7 @@ exchange_rate_out: type: object + required: + - exchange_rate additionalProperties: false properties: exchange_rate: diff --git a/src/components/schemas/department.yaml b/src/components/schemas/department.yaml index 976a4bb0a..186d566ee 100644 --- a/src/components/schemas/department.yaml +++ b/src/components/schemas/department.yaml @@ -66,6 +66,12 @@ department_out_embed: type: object additionalProperties: False nullable: true + required: + - id + - code + - name + - sub_department + - display_name properties: id: $ref: './fields.yaml#/id_string' @@ -92,6 +98,11 @@ department_out_employee_embed: type: object additionalProperties: False nullable: true + required: + - id + - code + - name + - sub_department properties: id: $ref: './fields.yaml#/id_string' @@ -152,6 +163,8 @@ department_in_only_id: department_delete_summary_out: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/components/schemas/dependent_expense_field_values.yaml b/src/components/schemas/dependent_expense_field_values.yaml index 3aa27fef8..c1da6481c 100644 --- a/src/components/schemas/dependent_expense_field_values.yaml +++ b/src/components/schemas/dependent_expense_field_values.yaml @@ -1,6 +1,16 @@ dependent_expense_field_values_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - parent_expense_field_value + - expense_field_value + - is_enabled properties: id: $ref: './fields.yaml#/id_integer' @@ -76,6 +86,16 @@ dependent_expense_field_values_in: dependent_expense_field_values_upload_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - file_id + - error_file_id + - state properties: id: $ref: './fields.yaml#/id_integer' @@ -144,6 +164,13 @@ dependent_expense_field_values_upload_in: dependent_expense_field_values_preview_out: type: object additionalProperties: false + required: + - org_id + - parent_expense_field_id + - expense_field_id + - parent_expense_field_value + - expense_field_values + - is_enabled properties: org_id: $ref: ./fields.yaml#/org_id @@ -179,6 +206,15 @@ dependent_expense_field_values_preview_out: dependent_expense_field_values_download_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - file_id + - state properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/dwolla_customer.yaml b/src/components/schemas/dwolla_customer.yaml index 7fe9d386d..393950a68 100644 --- a/src/components/schemas/dwolla_customer.yaml +++ b/src/components/schemas/dwolla_customer.yaml @@ -1,6 +1,27 @@ dwolla_customer_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - customer_id + - customer_email + - customer_added_by + - is_customer_verified + - is_beneficial_owner_added + - is_beneficial_owner_verified + - is_bank_account_added + - is_bank_account_verified + - bank_account_added_by + - is_customer_document_needed + - is_beneficial_owner_document_needed + - is_customer_retry + - is_customer_suspended + - micro_deposit_verification_status + - micro_deposit_verification_attempts + - is_beneficial_owner_retry properties: id: allOf: @@ -114,6 +135,28 @@ dwolla_customer_out: spender_dwolla_customer_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - customer_id + - customer_email + - customer_added_by + - is_customer_verified + - is_beneficial_owner_added + - is_beneficial_owner_verified + - is_bank_account_added + - is_bank_account_verified + - bank_account_added_by + - is_customer_document_needed + - is_beneficial_owner_document_needed + - is_customer_retry + - is_customer_suspended + - micro_deposit_verification_status + - micro_deposit_verification_attempts + - is_beneficial_owner_retry + - is_org_customer_verified properties: id: type: string @@ -256,6 +299,9 @@ spender_dwolla_customer_out: dwolla_customer_in: type: object additionalProperties: false + required: + - customer_id + - customer_added_by properties: customer_id: type: string diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index ff2a7e622..39b3e47eb 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -274,6 +274,14 @@ employee_out: employee_out_embed: type: object additionalProperties: False + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department properties: id: $ref: ./fields.yaml#/id_string @@ -325,6 +333,7 @@ employee_out_potential_duplicate_expenses: - user_id - email - full_name + - potential_duplicate_expenses properties: user_id: $ref: './fields.yaml#/user_id' @@ -345,6 +354,25 @@ employee_out_embed_for_expense: type: object additionalProperties: False nullable: True + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - location + - title + - business_unit + - custom_fields + - flattened_custom_field + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: ./fields.yaml#/id_string @@ -424,6 +452,25 @@ employee_out_embed_for_expense_with_department_name: type: object additionalProperties: False nullable: True + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - location + - title + - business_unit + - custom_fields + - flattened_custom_field + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: ./fields.yaml#/id_string @@ -502,6 +549,24 @@ employee_out_embed_for_expense_with_department_name: employee_out_embed_for_report: type: object additionalProperties: False + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - ach_account + - business_unit + - location + - title + - has_accepted_invite + - is_enabled + - mobile + - joined_at properties: id: $ref: ./fields.yaml#/id_string @@ -675,6 +740,19 @@ employee_in: spender_employee_out: type: object additionalProperties: False + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: './fields.yaml#/id_string' @@ -828,6 +906,19 @@ employees_download_out: spender_commute_details_out: type: object additionalProperties: False + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: './fields.yaml#/id_string' @@ -886,6 +977,10 @@ spender_commute_details_out: spender_delegators_out: type: object additionalProperties: False + required: + - user_id + - email + - full_name properties: user_id: $ref: './fields.yaml#/user_id' @@ -901,6 +996,13 @@ spender_delegators_out: spender_delegatees_delete_out: type: object additionalProperties: False + required: + - id + - org_id + - delegator_user_id + - delegatee_user_id + - start_date + - end_date properties: id: $ref: './fields.yaml#/id_integer' @@ -927,6 +1029,11 @@ spender_delegatees_delete_out: spender_delegatees_post_in: type: object additionalProperties: False + required: + - delegatee_user_id + - start_at + - end_at + - scopes properties: delegatee_user_id: $ref: ./fields.yaml#/fk_string @@ -950,6 +1057,19 @@ spender_delegatees_post_in: spender_delegatees_post_out: type: object additionalProperties: False + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: './fields.yaml#/id_string' @@ -1088,6 +1208,12 @@ employee_change_owner_in: employees_send_mobile_verification_code_post_out: type: object + required: + - to + - channel + - status + - date_created + - attempts_left additionalProperties: False properties: to: @@ -1105,11 +1231,6 @@ employees_send_mobile_verification_code_post_out: description: | Current status of the verification attempt example: "pending" - valid: - type: boolean - description: | - Whether the verification is valid - example: false date_created: type: string format: date-time @@ -1196,6 +1317,44 @@ employee_hierarchy_out: spender_employee_current_out: type: object additionalProperties: False + required: + - id + - org_id + - user_id + - created_at + - updated_at + - user + - code + - joined_at + - title + - business_unit + - special_email + - roles + - location + - is_enabled + - has_accepted_invite + - branch_account + - branch_ifsc + - department_id + - department + - level_id + - level + - mobile + - is_mobile_verified + - mobile_verification_attempts_left + - mobile_verification_attempted_at + - org_name + - currency + - approver_user_ids + - approver_users + - locale + - delegatees + - mileage_settings + - custom_fields + - flattened_custom_field + - commute_details_id + - commute_details + - is_primary properties: id: $ref: './fields.yaml#/id_string' @@ -1463,6 +1622,9 @@ employee_overview_out: employee_overview_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer @@ -1476,6 +1638,9 @@ employee_overview_stats_out: employee_overview_expense_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer diff --git a/src/components/schemas/employee_account_summary.yaml b/src/components/schemas/employee_account_summary.yaml index a6dfee00f..c994c450a 100644 --- a/src/components/schemas/employee_account_summary.yaml +++ b/src/components/schemas/employee_account_summary.yaml @@ -1,5 +1,23 @@ employee_account_summary_out: type: object + required: + - id + - created_at + - updated_at + - org_id + - org_currency + - user_email + - user_full_name + - cash_account_id + - cash_account + - cash_account_balance + - ccc_account_id + - ccc_account + - ccc_account_balance + - advance_account_ids + - advance_accounts + - advance_accounts_balance + - is_settleable properties: id: diff --git a/src/components/schemas/employee_settings.yaml b/src/components/schemas/employee_settings.yaml index 1902e4b44..faa5ac749 100644 --- a/src/components/schemas/employee_settings.yaml +++ b/src/components/schemas/employee_settings.yaml @@ -1,6 +1,29 @@ spender_employee_settings_out: type: object additionalProperties: false + required: + - id + - employee_id + - org_id + - created_at + - updated_at + - category_ids + - cost_center_ids + - project_ids + - per_diem_rate_ids + - mileage_rate_ids + - insta_fyle_settings + - notification_settings + - mileage_settings + - expense_form_autofills + - data_extractor_settings + - in_app_chat_settings + - payment_mode_settings + - locale + - is_personal_cards_enabled + - default_project_id + - default_payment_mode + - default_vehicle_type properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/employees_export_configurations.yaml b/src/components/schemas/employees_export_configurations.yaml index cbf4e6bd3..432a05148 100644 --- a/src/components/schemas/employees_export_configurations.yaml +++ b/src/components/schemas/employees_export_configurations.yaml @@ -203,6 +203,8 @@ employees_export_configuration_out: - type - org_id - user_id + - created_by + - updated_by properties: id: allOf: diff --git a/src/components/schemas/employees_exports.yaml b/src/components/schemas/employees_exports.yaml index a5327c6cb..b348fad55 100644 --- a/src/components/schemas/employees_exports.yaml +++ b/src/components/schemas/employees_exports.yaml @@ -123,6 +123,20 @@ employees_exports_in: employees_exports_out: type: object + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state + - processed_at + - completed_at + - failed_at properties: created_at: type: string diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 32bd291b3..5978c1120 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -83,6 +83,26 @@ expense_out: - invoice_number - is_duplicate_present - expense_policy_comments + - custom_fields_flattened + - approvals + - verifications + - employee_id + - split_group_amount + - expense_rule_id + - expense_rule_data + - is_split + - tax_group + - approver_comments + - verifier_comments + - policy_checks + - accounting_export_summary + - report_last_paid_at + - report_last_approved_at + - commute_deduction + - commute_details_id + - commute_details + - is_reconciled + - report_auto_approval_state properties: id: allOf: @@ -1573,6 +1593,24 @@ matched_corporate_card_transaction_out_embed: - id - corporate_card_id - corporate_card_number + - corporate_card_nickname + - corporate_card_cardholder_name + - capitalone_virtual_card_last_four + - masked_corporate_card_number + - bank_name + - corporate_card_user_full_name + - is_corporate_card_archived + - amount + - currency + - spent_at + - posted_at + - status + - description + - foreign_currency + - foreign_amount + - merchant + - category + - matched_by properties: id: allOf: @@ -2030,6 +2068,9 @@ expense_check_policies_in: expense_check_policies_out: type: object additionalProperties: False + required: + - individual_desired_states + - final_desired_state properties: individual_desired_states: type: array @@ -2065,6 +2106,8 @@ expense_delete_in: expenses_stats_in: + required: + - query_params properties: query_params: nullable: False @@ -2512,6 +2555,9 @@ expense_duplicate_sets_out: expense_verification_out_embed: type: object additionalProperties: false + required: + - verifier_user_id + - verifier_user properties: verifier_user_id: allOf: diff --git a/src/components/schemas/expense_duplicate_set.yaml b/src/components/schemas/expense_duplicate_set.yaml index 65307d2e1..391fa97bc 100644 --- a/src/components/schemas/expense_duplicate_set.yaml +++ b/src/components/schemas/expense_duplicate_set.yaml @@ -1,4 +1,7 @@ expenses_duplicate_sets_stats_in: + type: object + required: + - query_params properties: query_params: nullable: False @@ -10,6 +13,8 @@ expenses_duplicate_sets_stats_in: expenses_duplicate_sets_stats_out: type: object + required: + - count properties: count: type: integer diff --git a/src/components/schemas/expense_field.yaml b/src/components/schemas/expense_field.yaml index 84540117e..de2034c68 100644 --- a/src/components/schemas/expense_field.yaml +++ b/src/components/schemas/expense_field.yaml @@ -1,6 +1,25 @@ expense_field_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - seq + - field_name + - column_name + - type + - options + - default_value + - placeholder + - category_ids + - is_enabled + - is_custom + - is_mandatory + - code + - parent_field_id + - display_order properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/expense_policies.yaml b/src/components/schemas/expense_policies.yaml index df806737b..8f1415fa8 100644 --- a/src/components/schemas/expense_policies.yaml +++ b/src/components/schemas/expense_policies.yaml @@ -533,6 +533,9 @@ expense_policy_out: - action_add_department_head_approver - action_add_approver_user_ids - action_override_distance_slab_rate + - expense_merchants + - expense_merchants_op + - policy_violation_reason_required properties: id: allOf: diff --git a/src/components/schemas/expense_rules.yaml b/src/components/schemas/expense_rules.yaml index ebc4fa6e2..6897cec28 100644 --- a/src/components/schemas/expense_rules.yaml +++ b/src/components/schemas/expense_rules.yaml @@ -26,6 +26,8 @@ expense_rule_if_out: additionalProperties: false required: - merchant_contains + - department_ids + - departments properties: merchant_contains: type: string @@ -100,6 +102,18 @@ expense_rule_data_out: nullable: false additionalProperties: false minProperties: 1 + required: + - merchant + - is_billable + - purpose + - category_id + - category + - project_id + - project + - cost_center_id + - cost_center + - custom_fields + - dependent_fields properties: merchant: type: string @@ -181,6 +195,8 @@ expense_rule_out: - creator_user - if - set + - is_suggested + - is_suggestion_dismissed properties: id: allOf: diff --git a/src/components/schemas/expenses_export_configurations.yaml b/src/components/schemas/expenses_export_configurations.yaml index 2a5912f49..c8e721e6f 100644 --- a/src/components/schemas/expenses_export_configurations.yaml +++ b/src/components/schemas/expenses_export_configurations.yaml @@ -256,6 +256,8 @@ expenses_export_configuration_out: - type - org_id - user_id + - created_by + - updated_by properties: id: allOf: diff --git a/src/components/schemas/expenses_exports.yaml b/src/components/schemas/expenses_exports.yaml index 58ddd91e7..de5d94e8f 100644 --- a/src/components/schemas/expenses_exports.yaml +++ b/src/components/schemas/expenses_exports.yaml @@ -116,6 +116,17 @@ expenses_exports_in: expenses_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state properties: created_at: $ref: './fields.yaml#/created_at' diff --git a/src/components/schemas/feature_configs.yaml b/src/components/schemas/feature_configs.yaml index e8c954a00..2bb85dcca 100644 --- a/src/components/schemas/feature_configs.yaml +++ b/src/components/schemas/feature_configs.yaml @@ -1,6 +1,17 @@ feature_config_out: type: object additionalProperties: false + required: + - org_id + - user_id + - created_at + - updated_at + - target_client + - feature + - sub_feature + - key + - value + - is_shared properties: org_id: $ref: ./fields.yaml#/org_id diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index 246ff043c..85e8fa24a 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1876,6 +1876,12 @@ commute_location: commute_details: type: object + required: + - id + - distance + - distance_unit + - home_location + - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. diff --git a/src/components/schemas/file.yaml b/src/components/schemas/file.yaml index ebcb48815..54e666f06 100644 --- a/src/components/schemas/file.yaml +++ b/src/components/schemas/file.yaml @@ -1,6 +1,17 @@ file_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - created_at + - updated_at + - name + - type + - content_type + - download_url + - upload_url properties: id: $ref: './fields.yaml#/id_string' @@ -53,6 +64,12 @@ file_generate_urls_action_in: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: './fields.yaml#/id_string' @@ -78,6 +95,11 @@ file_generate_urls_action_out: file_out_embed: type: object + required: + - id + - name + - type + - content_type properties: id: allOf: @@ -164,6 +186,11 @@ file_delete_action_in: file_out_download_url: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/level.yaml b/src/components/schemas/level.yaml index 0c038bbf7..4d38ba007 100644 --- a/src/components/schemas/level.yaml +++ b/src/components/schemas/level.yaml @@ -112,6 +112,8 @@ level_in_only_id: level_delete_summary_out: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/components/schemas/merchant.yaml b/src/components/schemas/merchant.yaml index ba4ba3e48..dd90ece22 100644 --- a/src/components/schemas/merchant.yaml +++ b/src/components/schemas/merchant.yaml @@ -1,6 +1,11 @@ merchant_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - display_name properties: id: $ref: './fields.yaml#/id_integer' @@ -17,6 +22,12 @@ merchant_out: approver_merchant_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - display_name properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/mileage_rate.yaml b/src/components/schemas/mileage_rate.yaml index 94236a01c..230bc3276 100644 --- a/src/components/schemas/mileage_rate.yaml +++ b/src/components/schemas/mileage_rate.yaml @@ -61,6 +61,10 @@ mileage_rate_out_embed: type: object nullable: true additionalProperties: False + required: + - id + - vehicle_type + - code properties: id: $ref: './fields.yaml#/id_integer' @@ -74,6 +78,11 @@ mileage_rate_out_embed_for_expense: type: object nullable: true additionalProperties: False + required: + - id + - vehicle_type + - code + - rate properties: id: $ref: './fields.yaml#/id_integer' @@ -145,10 +154,15 @@ mileage_rate_in_only_id: mileage_rate_delete_summary_out: type: object + required: + - data additionalProperties: False properties: data: type: object + required: + - delete_count + - mileage_rates properties: delete_count: type: integer diff --git a/src/components/schemas/mobile_app_version.yaml b/src/components/schemas/mobile_app_version.yaml index e4960648a..41e2a6511 100644 --- a/src/components/schemas/mobile_app_version.yaml +++ b/src/components/schemas/mobile_app_version.yaml @@ -1,6 +1,13 @@ mobile_app_version_out: type: object additionalProperties: false + required: + - id + - user_id + - version + - os + - created_at + - updated_at properties: id: type: string diff --git a/src/components/schemas/my_profile.yaml b/src/components/schemas/my_profile.yaml index 79d292e1e..a5880739a 100644 --- a/src/components/schemas/my_profile.yaml +++ b/src/components/schemas/my_profile.yaml @@ -1,6 +1,12 @@ my_profile_out: type: object additionalProperties: false + required: + - user_id + - org_id + - org + - user + - roles properties: user_id: $ref: '../../components/schemas/fields.yaml#/user_id' diff --git a/src/components/schemas/org.yaml b/src/components/schemas/org.yaml index 0e37dc648..aabc8bcff 100644 --- a/src/components/schemas/org.yaml +++ b/src/components/schemas/org.yaml @@ -5,6 +5,7 @@ org_weekly_invitation_usage_out: - id - invitation_sent - is_limit_reached + - weekly_limit properties: id: $ref: './fields.yaml#/org_id' @@ -30,6 +31,11 @@ org_weekly_invitation_usage_out: org_out_embed: type: object additionalProperties: False + required: + - id + - name + - domain + - currency properties: id: $ref: './fields.yaml#/org_id' @@ -55,6 +61,8 @@ org_out: - currency - created_at - updated_at + - is_current + - is_primary properties: id: $ref: './fields.yaml#/org_id' @@ -174,6 +182,15 @@ org_reset_delete_in: get_spender_orgs_out: type: object additionalProperties: False + required: + - id + - name + - domain + - currency + - created_at + - updated_at + - is_current + - is_primary properties: id: $ref: './fields.yaml#/org_id' @@ -202,6 +219,12 @@ get_spender_orgs_out: org_bank_details_out: type: object additionalProperties: false + required: + - org_id + - bank_account_number + - bank_branch_ifsc + - dwolla_customers_metadata_id + - is_bank_account_added properties: org_id: $ref: './fields.yaml#/org_id' @@ -230,6 +253,9 @@ org_bank_details_out: spender_org_bank_details_out: type: object additionalProperties: false + required: + - org_id + - is_bank_account_added properties: org_id: $ref: './fields.yaml#/org_id' diff --git a/src/components/schemas/org_settings.yaml b/src/components/schemas/org_settings.yaml index f1f8cfa54..8af0054f7 100644 --- a/src/components/schemas/org_settings.yaml +++ b/src/components/schemas/org_settings.yaml @@ -1,5 +1,10 @@ logo_file_generate_download_url_action_out: type: object + required: + - id + - name + - content_type + - download_url additionalProperties: false properties: id: diff --git a/src/components/schemas/per_diem_rate.yaml b/src/components/schemas/per_diem_rate.yaml index 43d01f8ed..01f4b54c1 100644 --- a/src/components/schemas/per_diem_rate.yaml +++ b/src/components/schemas/per_diem_rate.yaml @@ -46,6 +46,10 @@ per_diem_rate_out_embed: type: object nullable: true additionalProperties: False + required: + - id + - name + - code properties: id: $ref: './fields.yaml#/id_integer' @@ -98,6 +102,8 @@ per_diem_rate_in_only_id: per_diem_rate_delete_summary_out: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/components/schemas/personal_card.yaml b/src/components/schemas/personal_card.yaml index 5319ea146..9c92956be 100644 --- a/src/components/schemas/personal_card.yaml +++ b/src/components/schemas/personal_card.yaml @@ -1,5 +1,7 @@ personal_card_access_token_out: type: object + required: + - access_token properties: access_token: type: string @@ -20,6 +22,8 @@ personal_card_mfa_in: personal_card_mfa_out: type: object + required: + - is_mfa_enabled properties: is_mfa_enabled: type: boolean @@ -138,6 +142,23 @@ personal_card_out: personal_card_delete_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - currency + - bank_name + - card_number + - account_type + - yodlee_account_id + - yodlee_fastlink_params + - yodlee_is_credential_update_required + - yodlee_is_mfa_required + - yodlee_last_synced_at + - yodlee_login_id + - yodlee_provider_account_id + - created_at + - updated_at properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/personal_card_transaction.yaml b/src/components/schemas/personal_card_transaction.yaml index a074c296a..db941b98a 100644 --- a/src/components/schemas/personal_card_transaction.yaml +++ b/src/components/schemas/personal_card_transaction.yaml @@ -1,5 +1,24 @@ personal_card_transaction_out: type: object + required: + - id + - org_id + - user_id + - personal_card_id + - amount + - currency + - spent_at + - category + - merchant + - state + - description + - external_transaction_id + - matched_expense_ids + - created_at + - updated_at + - foreign_amount + - foreign_currency + - matched_expenses additionalProperties: False properties: id: @@ -76,6 +95,17 @@ matched_expense_out_embed: type: object nullable: true additionalProperties: false + required: + - amount + - category_display_name + - currency + - seq_num + - id + - no_of_files + - purpose + - state + - spent_at + - merchant properties: amount: $ref: './fields.yaml#/amount' @@ -156,6 +186,10 @@ personal_card_transactions_stats_in: personal_card_transactions_stats_out: type: object + required: + - count + - debit_amount + - credit_amount properties: count: type: integer diff --git a/src/components/schemas/place.yaml b/src/components/schemas/place.yaml index d62bfd837..8ade16b2d 100644 --- a/src/components/schemas/place.yaml +++ b/src/components/schemas/place.yaml @@ -1,6 +1,14 @@ place_out: type: object additionalProperties: false + required: + - id + - city + - state + - country + - formatted_address + - latitude + - longitude properties: id: type: string @@ -28,6 +36,9 @@ place_out: place_out_minimal: type: object + required: + - id + - formatted_address properties: id: type: string diff --git a/src/components/schemas/policy.yaml b/src/components/schemas/policy.yaml index 9893061f8..796ea059a 100644 --- a/src/components/schemas/policy.yaml +++ b/src/components/schemas/policy.yaml @@ -1,6 +1,9 @@ policy_test_out: type: object additionalProperties: false + required: + - policy_violation_summary + - policy_violations properties: policy_violation_summary: type: object diff --git a/src/components/schemas/project.yaml b/src/components/schemas/project.yaml index 3e779062f..a1723bcfb 100644 --- a/src/components/schemas/project.yaml +++ b/src/components/schemas/project.yaml @@ -67,6 +67,12 @@ project_out_embed: type: object nullable: true additionalProperties: False + required: + - id + - name + - sub_project + - code + - display_name properties: id: $ref: './fields.yaml#/id_integer' @@ -268,10 +274,15 @@ admin_approver_project_out: project_delete_summary_out: type: object + required: + - data additionalProperties: False properties: data: type: object + required: + - delete_count + - projects properties: delete_count: type: integer diff --git a/src/components/schemas/reconciliation_eligible_cards.yaml b/src/components/schemas/reconciliation_eligible_cards.yaml index 572089e49..584c27a41 100644 --- a/src/components/schemas/reconciliation_eligible_cards.yaml +++ b/src/components/schemas/reconciliation_eligible_cards.yaml @@ -97,6 +97,21 @@ reconciliation_eligible_cards_stats_in: reconciliation_eligible_cards_stats_out: type: object + required: + - period_start + - period_end + - statement_transaction_count + - expense_count + - statement_total + - expense_total + - difference + - matching_issue_count + - total_cards + - card_without_statement_count + - card_with_matching_issue_count + - card_with_no_issues_found_count + - card_with_no_transactions_count + - reconciled_card_count additionalProperties: False properties: period_start: diff --git a/src/components/schemas/reconciliation_exports.yaml b/src/components/schemas/reconciliation_exports.yaml index 2b13a5630..fd9d42fb0 100644 --- a/src/components/schemas/reconciliation_exports.yaml +++ b/src/components/schemas/reconciliation_exports.yaml @@ -99,6 +99,15 @@ reconciliation_export_in: reconciliation_export_out: type: object additionalProperties: false + required: + - id + - org_id + - file_id + - state + - query_params + - notify_emails + - created_at + - updated_at properties: id: allOf: diff --git a/src/components/schemas/reconciliation_transactions.yaml b/src/components/schemas/reconciliation_transactions.yaml index 218cc460e..fb4f4c09e 100644 --- a/src/components/schemas/reconciliation_transactions.yaml +++ b/src/components/schemas/reconciliation_transactions.yaml @@ -11,6 +11,12 @@ reconciliation_transaction_out: - matched_expenses_count - is_reconciled - expenses + - statement_line_item_id + - expense_ids + - statement_transaction_date + - statement_post_date + - created_at + - updated_at properties: id: $ref: './fields.yaml#/id_string' @@ -86,6 +92,14 @@ reconciliation_expense_split_out_embed: - amount - state - purpose + - currency + - merchant + - spent_at + - file_ids + - category + - project + - matched_corporate_card_transaction + - files properties: id: allOf: @@ -187,6 +201,9 @@ reconciliation_matched_expense_out_embed: - project - purpose - splits + - currency + - matched_corporate_card_transaction + - files properties: id: allOf: @@ -301,6 +318,15 @@ reconciliation_transactions_stats_in: reconciliation_transactions_stats_out: type: object + required: + - period_start + - period_end + - statement_transaction_count + - expense_count + - statement_total + - expense_total + - difference + - matching_issue_count additionalProperties: False description: | Reconciliation transactions statistics for the selected filter period. diff --git a/src/components/schemas/recurring_expense.yaml b/src/components/schemas/recurring_expense.yaml index 9f1a8c742..7821dd546 100644 --- a/src/components/schemas/recurring_expense.yaml +++ b/src/components/schemas/recurring_expense.yaml @@ -49,6 +49,8 @@ recurring_expense_out: - expense_details - schedule_config - is_enabled + - created_at + - updated_at properties: id: allOf: @@ -71,8 +73,8 @@ recurring_expense_out: - MILEAGE: Mileage-based expense type example: EXPENSE expense_details: - type: object - nullable: false + allOf: + - $ref: './expense.yaml#/spender_expense_in' description: | Expense template details used for creating recurring expenses. Contains all the expense fields that will be applied to each generated expense. diff --git a/src/components/schemas/reimbursement.yaml b/src/components/schemas/reimbursement.yaml index c46df8912..27b9471b8 100644 --- a/src/components/schemas/reimbursement.yaml +++ b/src/components/schemas/reimbursement.yaml @@ -102,6 +102,8 @@ reimbursement_out: reimbursement_in: type: object + required: + - amount properties: amount: $ref: './fields.yaml#/amount' @@ -124,6 +126,12 @@ reimbursement_in_minimal: reimbursement_out_minimal: type: object nullable: true + required: + - id + - currency + - amount + - mode + - ach_transfer properties: id: type: string diff --git a/src/components/schemas/reminder.yaml b/src/components/schemas/reminder.yaml index f9bb5e011..c28b7a7ce 100644 --- a/src/components/schemas/reminder.yaml +++ b/src/components/schemas/reminder.yaml @@ -72,6 +72,13 @@ reminder_out: reminder_in: type: object additionalProperties: False + required: + - type + - message + - schedule_config + - add_to_calendar + - send_mobile_notification + - receiver_user_ids properties: id: type: string @@ -118,6 +125,8 @@ reminder_delete_in: example: 'remindNZgN7V5pft' reminders_stats_in: + required: + - query_params properties: query_params: type: string @@ -128,6 +137,9 @@ reminders_stats_in: reminders_stats_out: type: array + required: + - last_reminded_at + - type items: type: object properties: diff --git a/src/components/schemas/report.yaml b/src/components/schemas/report.yaml index 7114ecd27..b62a118f9 100644 --- a/src/components/schemas/report.yaml +++ b/src/components/schemas/report.yaml @@ -29,6 +29,15 @@ report_out: - reimbursement - comments - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - applied_advance_wallets + - auto_approval_state properties: id: $ref: ./fields.yaml#/id_string @@ -279,6 +288,14 @@ admin_report_out: - applied_advance_wallets - can_apply_advances - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - auto_approval_state properties: id: $ref: ./fields.yaml#/id_string @@ -561,6 +578,9 @@ report_out_embed: - last_paid_at - reimbursement_id - reimbursement_seq_num + - amount + - last_verified_at + - approvals properties: id: anyOf: @@ -998,6 +1018,20 @@ process_summary_in: process_summary_out: type: object + required: + - selected_reimbursable_amount + - selected_count + - unverified_count + - unverified_amount + - missing_bank_details_count + - missing_bank_details_amount + - missing_bank_details_employee_count + - missing_bank_details_employee_ids + - payment_initiated_amount + - payment_initiated_count + - reimbursable_amount + - reimbursable_report_ids + - closable_report_ids additionalProperties: True properties: selected_reimbursable_amount: @@ -1082,6 +1116,8 @@ process_summary_out: reports_stats_in: + required: + - query_params properties: query_params: type: string diff --git a/src/components/schemas/report_approval.yaml b/src/components/schemas/report_approval.yaml index d56c9e4a1..5fa83251c 100644 --- a/src/components/schemas/report_approval.yaml +++ b/src/components/schemas/report_approval.yaml @@ -1,6 +1,12 @@ report_approval_out_embed: type: object additionalProperties: False + required: + - approver_user_id + - approver_type + - approver_user + - state + - approver_order properties: approver_user_id: allOf: diff --git a/src/components/schemas/reports_export_configurations.yaml b/src/components/schemas/reports_export_configurations.yaml index 5b82e72d0..372873ec2 100644 --- a/src/components/schemas/reports_export_configurations.yaml +++ b/src/components/schemas/reports_export_configurations.yaml @@ -192,6 +192,8 @@ reports_export_configuration_out: - type - org_id - user_id + - created_by + - updated_by properties: id: allOf: diff --git a/src/components/schemas/schedule.yaml b/src/components/schemas/schedule.yaml index d8e8726ea..db32e249a 100644 --- a/src/components/schemas/schedule.yaml +++ b/src/components/schemas/schedule.yaml @@ -20,6 +20,14 @@ schedule_in: schedule_out: type: object additionalProperties: False + required: + - id + - created_at + - updated_at + - config + - org_id + - user_id + - is_enabled properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/scheduled_callback.yaml b/src/components/schemas/scheduled_callback.yaml index b34a70971..770ba6ff2 100644 --- a/src/components/schemas/scheduled_callback.yaml +++ b/src/components/schemas/scheduled_callback.yaml @@ -1,5 +1,10 @@ scheduled_callback_in: type: object + required: + - url + - payload + - schedule_config + - is_enabled properties: id: $ref: './fields.yaml#/id_string' @@ -16,6 +21,15 @@ scheduled_callback_in: scheduled_callback_out: type: object additionalProperties: False + required: + - id + - url + - payload + - schedule_config + - is_enabled + - created_at + - updated_at + - org_id properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/secondary_email.yaml b/src/components/schemas/secondary_email.yaml index 24fec25ef..1fd908373 100644 --- a/src/components/schemas/secondary_email.yaml +++ b/src/components/schemas/secondary_email.yaml @@ -13,6 +13,14 @@ secondary_email_in: secondary_email_out: type: object + required: + - id + - email + - is_verified + - org_id + - user_id + - created_at + - updated_at additionalProperties: False properties: id: diff --git a/src/components/schemas/spend_overview.yaml b/src/components/schemas/spend_overview.yaml index 04e186478..163a1798a 100644 --- a/src/components/schemas/spend_overview.yaml +++ b/src/components/schemas/spend_overview.yaml @@ -2,6 +2,9 @@ spend_overview_summary_data_out: type: object nullable: False + required: + - amount + - time_interval_marker properties: amount: $ref: './fields.yaml#/amount' @@ -12,6 +15,11 @@ spend_overview_summary_data_out: spend_overview_by_merchant_data_out: type: object nullable: False + required: + - merchant_name + - amount + - percentage + - change_percentage properties: merchant_name: $ref: './fields.yaml#/merchant' @@ -26,6 +34,12 @@ spend_overview_by_merchant_data_out: spend_overview_by_project_data_out: type: object nullable: False + required: + - project_id + - project_display_name + - amount + - percentage + - change_percentage properties: project_id: $ref: './fields.yaml#/id_integer' @@ -42,6 +56,12 @@ spend_overview_by_project_data_out: spend_overview_by_category_data_out: type: object nullable: False + required: + - category_id + - category_display_name + - amount + - percentage + - change_percentage properties: category_id: $ref: './fields.yaml#/id_integer' @@ -58,6 +78,12 @@ spend_overview_by_category_data_out: spend_overview_by_department_data_out: type: object nullable: False + required: + - department_id + - department_display_name + - amount + - percentage + - change_percentage properties: department_id: $ref: './fields.yaml#/id_string' @@ -74,6 +100,13 @@ spend_overview_by_department_data_out: spend_overview_by_user_data_out: type: object nullable: False + required: + - user_id + - user_full_name + - user_email + - amount + - percentage + - change_percentage properties: user_id: $ref: './fields.yaml#/id_string' @@ -92,6 +125,15 @@ spend_overview_by_user_data_out: spend_overview_by_corporate_card_data_out: type: object nullable: False + required: + - card_id + - card_number + - card_holder_name + - card_nickname + - user_id + - amount + - percentage + - change_percentage properties: card_id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/statements.yaml b/src/components/schemas/statements.yaml index 40caae826..0097ada0f 100644 --- a/src/components/schemas/statements.yaml +++ b/src/components/schemas/statements.yaml @@ -154,6 +154,7 @@ statements_out: - is_processed - statement_mappings_id + - creator_user card_transaction_from_statement_in: type: object properties: @@ -915,6 +916,13 @@ reconcile_from_statement_in: rtf_missing_transaction_from_statement_out: type: object + required: + - error + - missing_rtf_transactions + - rtf_confidence + - rtf_count + - total_count + - status properties: error: type: string @@ -1028,6 +1036,9 @@ rtf_missing_transaction_from_statement_out: rtf_stats_out: type: object + required: + - last_uploaded_at + - rtf_confidence properties: last_uploaded_at: $ref: './fields.yaml#/timestamptz_utc' @@ -1145,6 +1156,16 @@ preview_out: - no_of_transactions summary_out: + type: object + required: + - id + - status + - period_start + - period_end + - statement_transaction_count + - statement_total + - total_cards + - bridging_entry_change_type properties: id: allOf: @@ -1191,6 +1212,12 @@ summary_out: _reconciliation_summary_object: + type: object + required: + - expense_count + - is_recommended + - reconciliation_method + - statement_transaction_count properties: expense_count: description: Number of expense matches found @@ -1210,6 +1237,9 @@ _reconciliation_summary_object: reconciliation_summary_out: + type: object + required: + - reconciliation_summary properties: reconciliation_summary: type: array @@ -1269,7 +1299,13 @@ card_stats_out: - is_rtf_statement + - rtf_card_network + - missing_corporate_card_details matching_cards_out: + type: object + required: + - statement_card_number + - matching_cards properties: statement_card_number: type: string @@ -1321,6 +1357,10 @@ unassigned_cards_from_statement_in: - statement_id statement_archived_cards_out: + required: + - number_of_cards + - number_of_archived_cards + - archived_cards properties: number_of_cards: type: integer diff --git a/src/components/schemas/subscriptions.yaml b/src/components/schemas/subscriptions.yaml index e61b5627c..4db7ff318 100644 --- a/src/components/schemas/subscriptions.yaml +++ b/src/components/schemas/subscriptions.yaml @@ -1,6 +1,13 @@ spender_subscriptions_out: type: object additionalProperties: False + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - user_id properties: id: $ref: ./fields.yaml#/id_string @@ -18,6 +25,13 @@ spender_subscriptions_out: approver_subscriptions_out: type: object additionalProperties: False + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - approver_user_id properties: id: $ref: ./fields.yaml#/id_string @@ -35,6 +49,14 @@ approver_subscriptions_out: admin_subscriptions_out: type: object additionalProperties: False + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - org_id + - subscribed_resources properties: id: $ref: ./fields.yaml#/id_string diff --git a/src/components/schemas/user.yaml b/src/components/schemas/user.yaml index 8fd2e6646..1062e0d01 100644 --- a/src/components/schemas/user.yaml +++ b/src/components/schemas/user.yaml @@ -1,6 +1,13 @@ user_out: type: object additionalProperties: False + required: + - id + - created_at + - updated_at + - email + - full_name + - email_verified_at properties: id: $ref: './fields.yaml#/id_string' @@ -22,6 +29,10 @@ user_out: user_out_embed: type: object additionalProperties: False + required: + - id + - email + - full_name properties: id: allOf: @@ -42,6 +53,10 @@ user_out_embed_nullable: type: object nullable: true additionalProperties: False + required: + - id + - email + - full_name properties: id: allOf: @@ -61,6 +76,10 @@ user_out_nullable_example_null: type: object nullable: true additionalProperties: False + required: + - id + - email + - full_name properties: id: allOf: diff --git a/src/manager/paths/manager@employee_overview@expenses@stats.yaml b/src/manager/paths/manager@employee_overview@expenses@stats.yaml index 99481ae3e..b4e9be6b4 100644 --- a/src/manager/paths/manager@employee_overview@expenses@stats.yaml +++ b/src/manager/paths/manager@employee_overview@expenses@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_expense_stats_out diff --git a/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml b/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml index aacf96bcc..91523915e 100644 --- a/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml +++ b/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml @@ -33,6 +33,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/manager/paths/manager@employee_overview@stats.yaml b/src/manager/paths/manager@employee_overview@stats.yaml index 7eb46a92a..0b90e52b4 100644 --- a/src/manager/paths/manager@employee_overview@stats.yaml +++ b/src/manager/paths/manager@employee_overview@stats.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_stats_out diff --git a/src/spender/openapi.yaml b/src/spender/openapi.yaml index 42d044303..ed6b41066 100644 --- a/src/spender/openapi.yaml +++ b/src/spender/openapi.yaml @@ -181,7 +181,7 @@ paths: $ref: 'paths/spender@reports@suggest_purpose.yaml' /spender/reports/filters: $ref: 'paths/spender@reports@filters.yaml' - /spender/reports/filters/delte: + /spender/reports/filters/delete: $ref: 'paths/spender@reports@filters@delete.yaml' /spender/reports/comments: $ref: 'paths/spender@reports@comments.yaml' diff --git a/src/spender/paths/spender@advance_request_files.yaml b/src/spender/paths/spender@advance_request_files.yaml index fbce63cf7..167d26a8b 100644 --- a/src/spender/paths/spender@advance_request_files.yaml +++ b/src/spender/paths/spender@advance_request_files.yaml @@ -40,6 +40,8 @@ post: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/spender/paths/spender@advance_requests.yaml b/src/spender/paths/spender@advance_requests.yaml index 28d9eeaa3..1e735f2ca 100644 --- a/src/spender/paths/spender@advance_requests.yaml +++ b/src/spender/paths/spender@advance_requests.yaml @@ -70,6 +70,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml b/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml index 14065e4b1..8da910c34 100644 --- a/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml +++ b/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@advance_requests@comments.yaml b/src/spender/paths/spender@advance_requests@comments.yaml index 8f9b06917..f095c09d4 100644 --- a/src/spender/paths/spender@advance_requests@comments.yaml +++ b/src/spender/paths/spender@advance_requests@comments.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_out' diff --git a/src/spender/paths/spender@advance_requests@permissions.yaml b/src/spender/paths/spender@advance_requests@permissions.yaml index 744da3b9f..8f5d4031b 100644 --- a/src/spender/paths/spender@advance_requests@permissions.yaml +++ b/src/spender/paths/spender@advance_requests@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_permissions_out' diff --git a/src/spender/paths/spender@advance_requests@pull_back.yaml b/src/spender/paths/spender@advance_requests@pull_back.yaml index 3c718f32a..db7ceba87 100644 --- a/src/spender/paths/spender@advance_requests@pull_back.yaml +++ b/src/spender/paths/spender@advance_requests@pull_back.yaml @@ -28,6 +28,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/spender/paths/spender@advance_requests@stats.yaml b/src/spender/paths/spender@advance_requests@stats.yaml index 79f6aa154..456f09cd8 100644 --- a/src/spender/paths/spender@advance_requests@stats.yaml +++ b/src/spender/paths/spender@advance_requests@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_requests_stats_out' diff --git a/src/spender/paths/spender@advance_requests@submit.yaml b/src/spender/paths/spender@advance_requests@submit.yaml index f511c601e..287fae1b2 100644 --- a/src/spender/paths/spender@advance_requests@submit.yaml +++ b/src/spender/paths/spender@advance_requests@submit.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/spender/paths/spender@advances@stats.yaml b/src/spender/paths/spender@advances@stats.yaml index 54003447c..2e99a08d2 100644 --- a/src/spender/paths/spender@advances@stats.yaml +++ b/src/spender/paths/spender@advances@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance.yaml#/advances_stats_out' diff --git a/src/spender/paths/spender@automations@recurring_expenses.yaml b/src/spender/paths/spender@automations@recurring_expenses.yaml index 47fb46b1b..d3872e9e3 100644 --- a/src/spender/paths/spender@automations@recurring_expenses.yaml +++ b/src/spender/paths/spender@automations@recurring_expenses.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/recurring_expense.yaml#/recurring_expense_out' diff --git a/src/spender/paths/spender@automations@recurring_expenses@disable.yaml b/src/spender/paths/spender@automations@recurring_expenses@disable.yaml index d42056ac1..3b61eea04 100644 --- a/src/spender/paths/spender@automations@recurring_expenses@disable.yaml +++ b/src/spender/paths/spender@automations@recurring_expenses@disable.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/recurring_expense.yaml#/recurring_expense_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml b/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml index 7d6e7c526..5e3202893 100644 --- a/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/spender/paths/spender@corporate_card_transactions@ignore.yaml b/src/spender/paths/spender@corporate_card_transactions@ignore.yaml index af8d658dd..2a34f0ea2 100644 --- a/src/spender/paths/spender@corporate_card_transactions@ignore.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@ignore.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_ignore_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml b/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml index 446cbb7a1..17e2e040a 100644 --- a/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_mark_personal_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@match.yaml b/src/spender/paths/spender@corporate_card_transactions@match.yaml index 20d943d2b..7fd39f0fd 100644 --- a/src/spender/paths/spender@corporate_card_transactions@match.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@match.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_match_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml b/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml index b31f1e80a..5da053028 100644 --- a/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_undo_ignore_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml b/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml index 9a9971a12..49b7338fd 100644 --- a/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmark_personal_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml b/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml index d6225e595..59edc33a2 100644 --- a/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmatch_out' diff --git a/src/spender/paths/spender@email_files.yaml b/src/spender/paths/spender@email_files.yaml index ee331cce0..33cf8a983 100644 --- a/src/spender/paths/spender@email_files.yaml +++ b/src/spender/paths/spender@email_files.yaml @@ -34,6 +34,8 @@ post: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/spender/paths/spender@employees.yaml b/src/spender/paths/spender@employees.yaml index 863407815..811db855e 100644 --- a/src/spender/paths/spender@employees.yaml +++ b/src/spender/paths/spender@employees.yaml @@ -66,6 +66,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/employee.yaml#/spender_employee_out' diff --git a/src/spender/paths/spender@expense_files.yaml b/src/spender/paths/spender@expense_files.yaml index dddcb5c0a..19a113422 100644 --- a/src/spender/paths/spender@expense_files.yaml +++ b/src/spender/paths/spender@expense_files.yaml @@ -39,6 +39,8 @@ post: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/spender/paths/spender@expense_policy_comments.yaml b/src/spender/paths/spender@expense_policy_comments.yaml index 32672860a..5c3668172 100644 --- a/src/spender/paths/spender@expense_policy_comments.yaml +++ b/src/spender/paths/spender@expense_policy_comments.yaml @@ -58,6 +58,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/spender/paths/spender@expenses@attach_files@bulk.yaml b/src/spender/paths/spender@expenses@attach_files@bulk.yaml index 697d8e58d..10a43e46a 100644 --- a/src/spender/paths/spender@expenses@attach_files@bulk.yaml +++ b/src/spender/paths/spender@expenses@attach_files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@attach_receipt.yaml b/src/spender/paths/spender@expenses@attach_receipt.yaml index 7f9b03b94..a2a2a0b57 100644 --- a/src/spender/paths/spender@expenses@attach_receipt.yaml +++ b/src/spender/paths/spender@expenses@attach_receipt.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/spender/paths/spender@expenses@bulk.yaml b/src/spender/paths/spender@expenses@bulk.yaml index dc552913d..45a44b83d 100644 --- a/src/spender/paths/spender@expenses@bulk.yaml +++ b/src/spender/paths/spender@expenses@bulk.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_expenses_bulk_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@check_policies.yaml b/src/spender/paths/spender@expenses@check_policies.yaml index 7127e4f80..6de6fd159 100644 --- a/src/spender/paths/spender@expenses@check_policies.yaml +++ b/src/spender/paths/spender@expenses@check_policies.yaml @@ -29,6 +29,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_out diff --git a/src/spender/paths/spender@expenses@check_policies_bulk.yaml b/src/spender/paths/spender@expenses@check_policies_bulk.yaml index 46a8d4cad..c72a9c70f 100644 --- a/src/spender/paths/spender@expenses@check_policies_bulk.yaml +++ b/src/spender/paths/spender@expenses@check_policies_bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out diff --git a/src/spender/paths/spender@expenses@comments@bulk.yaml b/src/spender/paths/spender@expenses@comments@bulk.yaml index 9411f87fc..60bf39510 100644 --- a/src/spender/paths/spender@expenses@comments@bulk.yaml +++ b/src/spender/paths/spender@expenses@comments@bulk.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_comments_bulk_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@create_from_file@bulk.yaml b/src/spender/paths/spender@expenses@create_from_file@bulk.yaml index 6b74fb2a7..593289c15 100644 --- a/src/spender/paths/spender@expenses@create_from_file@bulk.yaml +++ b/src/spender/paths/spender@expenses@create_from_file@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@create_from_receipt.yaml b/src/spender/paths/spender@expenses@create_from_receipt.yaml index ffd0a8bdd..642668b1f 100644 --- a/src/spender/paths/spender@expenses@create_from_receipt.yaml +++ b/src/spender/paths/spender@expenses@create_from_receipt.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/spender/paths/spender@expenses@export_configurations.yaml b/src/spender/paths/spender@expenses@export_configurations.yaml index e819a0707..c5b29e88e 100644 --- a/src/spender/paths/spender@expenses@export_configurations.yaml +++ b/src/spender/paths/spender@expenses@export_configurations.yaml @@ -158,6 +158,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_export_configurations.yaml#/expenses_export_configuration_out' diff --git a/src/spender/paths/spender@expenses@exports.yaml b/src/spender/paths/spender@expenses@exports.yaml index 0736bd382..1e0d8906e 100644 --- a/src/spender/paths/spender@expenses@exports.yaml +++ b/src/spender/paths/spender@expenses@exports.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_exports.yaml#/expenses_exports_out' diff --git a/src/spender/paths/spender@expenses@filters.yaml b/src/spender/paths/spender@expenses@filters.yaml index eff9d7f67..ff4e69e9a 100644 --- a/src/spender/paths/spender@expenses@filters.yaml +++ b/src/spender/paths/spender@expenses@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/spender/paths/spender@expenses@filters@delete.yaml b/src/spender/paths/spender@expenses@filters@delete.yaml index 144f8b063..0acdb816f 100644 --- a/src/spender/paths/spender@expenses@filters@delete.yaml +++ b/src/spender/paths/spender@expenses@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/spender/paths/spender@expenses@merge.yaml b/src/spender/paths/spender@expenses@merge.yaml index 9684a9e75..1f7c77091 100644 --- a/src/spender/paths/spender@expenses@merge.yaml +++ b/src/spender/paths/spender@expenses@merge.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_merge_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/spender/paths/spender@expenses@permissions.yaml b/src/spender/paths/spender@expenses@permissions.yaml index d6001df6f..3364da543 100644 --- a/src/spender/paths/spender@expenses@permissions.yaml +++ b/src/spender/paths/spender@expenses@permissions.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_out' diff --git a/src/spender/paths/spender@expenses@permissions@bulk.yaml b/src/spender/paths/spender@expenses@permissions@bulk.yaml index e6c19225c..8cfe9e758 100644 --- a/src/spender/paths/spender@expenses@permissions@bulk.yaml +++ b/src/spender/paths/spender@expenses@permissions@bulk.yaml @@ -33,6 +33,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' diff --git a/src/spender/paths/spender@expenses@policy_test.yaml b/src/spender/paths/spender@expenses@policy_test.yaml index a28d0d139..07c740338 100644 --- a/src/spender/paths/spender@expenses@policy_test.yaml +++ b/src/spender/paths/spender@expenses@policy_test.yaml @@ -14,6 +14,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_expense_in' @@ -24,6 +26,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/policy.yaml#/policy_test_out' diff --git a/src/spender/paths/spender@expenses@split.yaml b/src/spender/paths/spender@expenses@split.yaml index 207118e4d..be727a4b8 100644 --- a/src/spender/paths/spender@expenses@split.yaml +++ b/src/spender/paths/spender@expenses@split.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_split_expense_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml b/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml index 2037b253e..3285f9d30 100644 --- a/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml +++ b/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_split_expense_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@split@check_policies.yaml b/src/spender/paths/spender@expenses@split@check_policies.yaml index deeaf5fe1..583c809e9 100644 --- a/src/spender/paths/spender@expenses@split@check_policies.yaml +++ b/src/spender/paths/spender@expenses@split@check_policies.yaml @@ -14,6 +14,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_split_expense_in' @@ -24,6 +26,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@stats.yaml b/src/spender/paths/spender@expenses@stats.yaml index ee129cee4..0bf898b7c 100644 --- a/src/spender/paths/spender@expenses@stats.yaml +++ b/src/spender/paths/spender@expenses@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_stats_out' diff --git a/src/spender/paths/spender@files.yaml b/src/spender/paths/spender@files.yaml index eed5916ba..053d51b3f 100644 --- a/src/spender/paths/spender@files.yaml +++ b/src/spender/paths/spender@files.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/file.yaml#/file_out diff --git a/src/spender/paths/spender@files@bulk.yaml b/src/spender/paths/spender@files@bulk.yaml index 0e90578db..ae24251cd 100644 --- a/src/spender/paths/spender@files@bulk.yaml +++ b/src/spender/paths/spender@files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@files@generate_urls.yaml b/src/spender/paths/spender@files@generate_urls.yaml index 4a7180a10..8a3c6233b 100644 --- a/src/spender/paths/spender@files@generate_urls.yaml +++ b/src/spender/paths/spender@files@generate_urls.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/file.yaml#/file_generate_urls_action_out diff --git a/src/spender/paths/spender@files@generate_urls@bulk.yaml b/src/spender/paths/spender@files@generate_urls@bulk.yaml index e132a077e..13432b189 100644 --- a/src/spender/paths/spender@files@generate_urls@bulk.yaml +++ b/src/spender/paths/spender@files@generate_urls@bulk.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@files@upload_html.yaml b/src/spender/paths/spender@files@upload_html.yaml index dfacbc82d..b2f0c49b9 100644 --- a/src/spender/paths/spender@files@upload_html.yaml +++ b/src/spender/paths/spender@files@upload_html.yaml @@ -37,6 +37,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/file.yaml#/file_out_download_url diff --git a/src/spender/paths/spender@personal_card_transactions@stats.yaml b/src/spender/paths/spender@personal_card_transactions@stats.yaml index 9b2c4a2a5..d15303184 100644 --- a/src/spender/paths/spender@personal_card_transactions@stats.yaml +++ b/src/spender/paths/spender@personal_card_transactions@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/spender/paths/spender@personal_cards.yaml b/src/spender/paths/spender@personal_cards.yaml index 0d9510cc1..6a16a44c8 100644 --- a/src/spender/paths/spender@personal_cards.yaml +++ b/src/spender/paths/spender@personal_cards.yaml @@ -19,6 +19,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@reports@add_expenses.yaml b/src/spender/paths/spender@reports@add_expenses.yaml index d84f51bf9..762ca0bca 100644 --- a/src/spender/paths/spender@reports@add_expenses.yaml +++ b/src/spender/paths/spender@reports@add_expenses.yaml @@ -24,6 +24,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@comments.yaml b/src/spender/paths/spender@reports@comments.yaml index 883b28497..7e3628021 100644 --- a/src/spender/paths/spender@reports@comments.yaml +++ b/src/spender/paths/spender@reports@comments.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_comments_out' diff --git a/src/spender/paths/spender@reports@eject_expenses.yaml b/src/spender/paths/spender@reports@eject_expenses.yaml index ceeb17152..76358806b 100644 --- a/src/spender/paths/spender@reports@eject_expenses.yaml +++ b/src/spender/paths/spender@reports@eject_expenses.yaml @@ -26,6 +26,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@export_configurations.yaml b/src/spender/paths/spender@reports@export_configurations.yaml index 4f63e5a79..e19fcb464 100644 --- a/src/spender/paths/spender@reports@export_configurations.yaml +++ b/src/spender/paths/spender@reports@export_configurations.yaml @@ -83,6 +83,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_export_configurations.yaml#/reports_export_configuration_out' diff --git a/src/spender/paths/spender@reports@exports.yaml b/src/spender/paths/spender@reports@exports.yaml index ae9c462cd..9d98a5198 100644 --- a/src/spender/paths/spender@reports@exports.yaml +++ b/src/spender/paths/spender@reports@exports.yaml @@ -64,6 +64,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_exports.yaml#/reports_exports_out' diff --git a/src/spender/paths/spender@reports@filters.yaml b/src/spender/paths/spender@reports@filters.yaml index 88472399f..4b06a8705 100644 --- a/src/spender/paths/spender@reports@filters.yaml +++ b/src/spender/paths/spender@reports@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/spender/paths/spender@reports@filters@delete.yaml b/src/spender/paths/spender@reports@filters@delete.yaml index 50d56712a..63bceca83 100644 --- a/src/spender/paths/spender@reports@filters@delete.yaml +++ b/src/spender/paths/spender@reports@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/spender/paths/spender@reports@permissions.yaml b/src/spender/paths/spender@reports@permissions.yaml index 00c0674d9..71ca3ad25 100644 --- a/src/spender/paths/spender@reports@permissions.yaml +++ b/src/spender/paths/spender@reports@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report_permissions.yaml#/report_permissions_out' diff --git a/src/spender/paths/spender@reports@resubmit.yaml b/src/spender/paths/spender@reports@resubmit.yaml index d031ff6b6..55b68d276 100644 --- a/src/spender/paths/spender@reports@resubmit.yaml +++ b/src/spender/paths/spender@reports@resubmit.yaml @@ -24,6 +24,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@stats.yaml b/src/spender/paths/spender@reports@stats.yaml index bd00c4e13..029c82d13 100644 --- a/src/spender/paths/spender@reports@stats.yaml +++ b/src/spender/paths/spender@reports@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/reports_stats_out' diff --git a/src/spender/paths/spender@reports@submit.yaml b/src/spender/paths/spender@reports@submit.yaml index c655c82df..3b521a248 100644 --- a/src/spender/paths/spender@reports@submit.yaml +++ b/src/spender/paths/spender@reports@submit.yaml @@ -24,6 +24,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@suggest_purpose.yaml b/src/spender/paths/spender@reports@suggest_purpose.yaml index 62e20eac5..3079e4f37 100644 --- a/src/spender/paths/spender@reports@suggest_purpose.yaml +++ b/src/spender/paths/spender@reports@suggest_purpose.yaml @@ -24,6 +24,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_purpose_out' diff --git a/src/spender/paths/spender@schedules.yaml b/src/spender/paths/spender@schedules.yaml index 7ed0100ad..13cf2a8f6 100644 --- a/src/spender/paths/spender@schedules.yaml +++ b/src/spender/paths/spender@schedules.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/schedule.yaml#/schedule_out diff --git a/src/spender/paths/spender@secondary_emails.yaml b/src/spender/paths/spender@secondary_emails.yaml index 4d964929a..d5f554748 100644 --- a/src/spender/paths/spender@secondary_emails.yaml +++ b/src/spender/paths/spender@secondary_emails.yaml @@ -66,6 +66,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/secondary_email.yaml#/secondary_email_out diff --git a/src/spender/paths/spender@secondary_emails@check.yaml b/src/spender/paths/spender@secondary_emails@check.yaml index 20eb49ab5..4f316949c 100644 --- a/src/spender/paths/spender@secondary_emails@check.yaml +++ b/src/spender/paths/spender@secondary_emails@check.yaml @@ -35,6 +35,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/spender/paths/spender@secondary_emails@delete.yaml b/src/spender/paths/spender@secondary_emails@delete.yaml index 2def9c992..273910199 100644 --- a/src/spender/paths/spender@secondary_emails@delete.yaml +++ b/src/spender/paths/spender@secondary_emails@delete.yaml @@ -35,6 +35,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/spender/paths/spender@subscriptions.yaml b/src/spender/paths/spender@subscriptions.yaml index fae027bcc..d9ab5b93a 100644 --- a/src/spender/paths/spender@subscriptions.yaml +++ b/src/spender/paths/spender@subscriptions.yaml @@ -11,6 +11,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/subscriptions_in' @@ -22,6 +24,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/spender_subscriptions_out' diff --git a/src/spender/paths/spender@virtual_cards@get_current_amount.yaml b/src/spender/paths/spender@virtual_cards@get_current_amount.yaml index 7de87d1e4..c241f2727 100644 --- a/src/spender/paths/spender@virtual_cards@get_current_amount.yaml +++ b/src/spender/paths/spender@virtual_cards@get_current_amount.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_get_current_balance_out' diff --git a/src/spender/paths/spender@virtual_cards@show_card_details.yaml b/src/spender/paths/spender@virtual_cards@show_card_details.yaml index 49e8b924f..017381b29 100644 --- a/src/spender/paths/spender@virtual_cards@show_card_details.yaml +++ b/src/spender/paths/spender@virtual_cards@show_card_details.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_show_card_details_out' From ec3692d40fc82fea2a9578599cc34a51b0929504 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Thu, 6 Aug 2026 10:56:00 +0530 Subject: [PATCH 087/107] Revert "chore: update required fields (#855)" (#856) This reverts commit 26b9112c02aafb13f6840ea11f3466d1ef1932cf. --- reference/accountant.yaml | 6 - reference/admin.yaml | 1568 +++-------------- reference/approver.yaml | 401 ----- reference/common.yaml | 20 - reference/hod.yaml | 6 - reference/hop.yaml | 6 - reference/manager.yaml | 152 -- reference/spender.yaml | 795 +-------- .../admin@accounting_export_lineitems.yaml | 2 - src/admin/paths/admin@accounting_exports.yaml | 2 - src/admin/paths/admin@accounts.yaml | 2 - src/admin/paths/admin@advance_refunds.yaml | 2 - .../paths/admin@advance_refunds@stats.yaml | 2 - src/admin/paths/admin@advance_requests.yaml | 2 - .../admin@advance_requests@add_approver.yaml | 4 - ...min@advance_requests@bulk_attach_file.yaml | 2 - .../admin@advance_requests@comments.yaml | 4 - .../admin@advance_requests@custom_fields.yaml | 2 - .../paths/admin@advance_requests@inquire.yaml | 2 - .../admin@advance_requests@permissions.yaml | 2 - .../paths/admin@advance_requests@reject.yaml | 2 - ...dmin@advance_requests@remove_approver.yaml | 4 - .../paths/admin@advance_requests@stats.yaml | 2 - .../paths/admin@advance_requests@submit.yaml | 2 - src/admin/paths/admin@advance_wallets.yaml | 2 - src/admin/paths/admin@advances.yaml | 2 - src/admin/paths/admin@advances@stats.yaml | 2 - .../admin@automations@report_submissions.yaml | 2 - ...automations@report_submissions@delete.yaml | 2 - src/admin/paths/admin@budgets.yaml | 2 - src/admin/paths/admin@budgets@exports.yaml | 2 - src/admin/paths/admin@categories.yaml | 2 - .../admin@categories@system_categories.yaml | 1 - .../admin@corporate_card_transactions.yaml | 2 - ...in@corporate_card_transactions@assign.yaml | 2 - ...in@corporate_card_transactions@delete.yaml | 2 - ...card_transactions@delete_summary@bulk.yaml | 2 - ...rd_transactions@export_configurations.yaml | 2 - ...n@corporate_card_transactions@exports.yaml | 2 - ...n@corporate_card_transactions@filters.yaml | 2 - ...rate_card_transactions@filters@delete.yaml | 2 - ...in@corporate_card_transactions@ignore.yaml | 2 - ...orate_card_transactions@mark_personal.yaml | 2 - ...min@corporate_card_transactions@match.yaml | 2 - ...min@corporate_card_transactions@stats.yaml | 2 - ...@corporate_card_transactions@unassign.yaml | 2 - ...rporate_card_transactions@undo_ignore.yaml | 2 - ...ate_card_transactions@unmark_personal.yaml | 2 - ...n@corporate_card_transactions@unmatch.yaml | 2 - src/admin/paths/admin@corporate_cards.yaml | 2 - .../paths/admin@corporate_cards@archive.yaml | 2 - ...ate_cards@archive_suggestions@dismiss.yaml | 2 - .../paths/admin@corporate_cards@assign.yaml | 2 - .../admin@corporate_cards@bank_names.yaml | 2 - .../paths/admin@corporate_cards@delete.yaml | 2 - ...e_cards@duplicate_suggestions@dismiss.yaml | 2 - .../paths/admin@corporate_cards@merge.yaml | 2 - .../paths/admin@corporate_cards@reassign.yaml | 2 - .../paths/admin@corporate_cards@stats.yaml | 2 - .../admin@corporate_cards@unarchive.yaml | 2 - .../admin@corporate_cards@unarchive@bulk.yaml | 2 - .../paths/admin@corporate_cards@unassign.yaml | 2 - src/admin/paths/admin@cost_centers.yaml | 2 - src/admin/paths/admin@departments.yaml | 2 - ...endent_expense_field_values@downloads.yaml | 2 - ...ependent_expense_field_values@uploads.yaml | 2 - src/admin/paths/admin@dwolla_customers.yaml | 2 - src/admin/paths/admin@employee_fields.yaml | 2 - .../paths/admin@employees@downloads.yaml | 2 - ...admin@employees@export_configurations.yaml | 2 - src/admin/paths/admin@employees@exports.yaml | 2 - src/admin/paths/admin@employees@filters.yaml | 2 - .../paths/admin@employees@filters@delete.yaml | 2 - src/admin/paths/admin@employees@stats.yaml | 2 - src/admin/paths/admin@employees@uploads.yaml | 2 - src/admin/paths/admin@expense_fields.yaml | 2 - src/admin/paths/admin@expense_policies.yaml | 2 - .../paths/admin@expense_policies@disable.yaml | 2 - .../paths/admin@expense_policies@enable.yaml | 2 - .../paths/admin@expense_policy_comments.yaml | 2 - src/admin/paths/admin@expenses.yaml | 4 - .../admin@expenses@attach_files@bulk.yaml | 2 - src/admin/paths/admin@expenses@bulk.yaml | 4 - .../admin@expenses@check_policies_bulk.yaml | 2 - .../paths/admin@expenses@comments@bulk.yaml | 4 - .../admin@expenses@export_configurations.yaml | 2 - src/admin/paths/admin@expenses@exports.yaml | 2 - src/admin/paths/admin@expenses@filters.yaml | 2 - .../paths/admin@expenses@filters@delete.yaml | 2 - src/admin/paths/admin@expenses@merge.yaml | 4 - .../paths/admin@expenses@permissions.yaml | 2 - .../admin@expenses@permissions@bulk.yaml | 2 - src/admin/paths/admin@expenses@split.yaml | 4 - ...expenses@split@check_mandatory_fields.yaml | 4 - .../admin@expenses@split@check_policies.yaml | 4 - src/admin/paths/admin@expenses@stats.yaml | 2 - src/admin/paths/admin@files.yaml | 2 - src/admin/paths/admin@files@bulk.yaml | 2 - .../paths/admin@files@generate_urls@bulk.yaml | 2 - src/admin/paths/admin@levels.yaml | 2 - src/admin/paths/admin@mileage_rates.yaml | 2 - src/admin/paths/admin@per_diem_rates.yaml | 2 - src/admin/paths/admin@projects.yaml | 2 - .../admin@reconciliation_entries@close.yaml | 2 - ...iation_entries@eligible_cards@exports.yaml | 2 - ...iliation_entries@eligible_cards@stats.yaml | 2 - ...tion_entries@transactions@delete@bulk.yaml | 2 - ...iliation_entries@transactions@exports.yaml | 2 - ...ation_entries@transactions@find_match.yaml | 2 - ...transactions@match_and_reconcile@bulk.yaml | 2 - ...transactions@move_to_next_period@bulk.yaml | 2 - ...n_entries@transactions@reconcile@bulk.yaml | 2 - ...es@transactions@resolve_multi_matches.yaml | 2 - ...nciliation_entries@transactions@stats.yaml | 2 - ...ion_entries@transactions@unmatch@bulk.yaml | 2 - .../admin@reimbursements@mark_complete.yaml | 2 - src/admin/paths/admin@reminders.yaml | 2 - src/admin/paths/admin@reminders@delete.yaml | 2 - src/admin/paths/admin@reminders@stats.yaml | 2 - .../paths/admin@reports@add_approver.yaml | 2 - .../admin@reports@apply_advance_wallets.yaml | 2 - src/admin/paths/admin@reports@comments.yaml | 2 - .../paths/admin@reports@delete_filter.yaml | 2 - .../paths/admin@reports@eject_expenses.yaml | 2 - .../admin@reports@export_configurations.yaml | 2 - src/admin/paths/admin@reports@exports.yaml | 2 - .../paths/admin@reports@permissions.yaml | 2 - .../admin@reports@process_summary@bulk.yaml | 2 - .../admin@reports@remove_advance_wallets.yaml | 2 - .../paths/admin@reports@remove_approver.yaml | 2 - .../admin@reports@revert_to_approved.yaml | 2 - .../admin@reports@revert_to_processing.yaml | 2 - .../paths/admin@reports@round_off_amount.yaml | 2 - .../paths/admin@reports@save_filters.yaml | 2 - src/admin/paths/admin@reports@send_back.yaml | 2 - src/admin/paths/admin@reports@stats.yaml | 2 - .../paths/admin@scheduled_callbacks.yaml | 2 - src/admin/paths/admin@schedules.yaml | 2 - .../admin@statements@archived_cards.yaml | 2 - ...dmin@statements@archived_cards@ignore.yaml | 2 - .../paths/admin@statements@card_stats.yaml | 2 - .../admin@statements@matching_cards.yaml | 2 - src/admin/paths/admin@statements@preview.yaml | 2 - .../paths/admin@statements@reconcile.yaml | 2 - ...min@statements@reconciliation_summary.yaml | 2 - .../admin@statements@suggest_mappings.yaml | 4 - src/admin/paths/admin@statements@summary.yaml | 2 - .../admin@statements@unassigned_cards.yaml | 2 - src/admin/paths/admin@statements@upload.yaml | 2 - src/admin/paths/admin@subscriptions.yaml | 4 - src/admin/paths/admin@tax_groups.yaml | 2 - .../paths/admin@virtual_cards@delete.yaml | 2 - ...dmin@virtual_cards@get_current_amount.yaml | 2 - ...admin@virtual_cards@show_card_details.yaml | 2 - ...pprover@advance_requests@add_approver.yaml | 4 - ...ver@advance_requests@bulk_attach_file.yaml | 2 - .../approver@advance_requests@comments.yaml | 4 - ...ance_requests@generate_file_urls@bulk.yaml | 2 - .../approver@advance_requests@inquire.yaml | 2 - ...er@advance_requests@partially_approve.yaml | 2 - ...approver@advance_requests@permissions.yaml | 2 - .../approver@advance_requests@reject.yaml | 2 - .../approver@advance_requests@stats.yaml | 2 - .../approver@advance_requests@submit.yaml | 2 - ...ver@corporate_card_transactions@match.yaml | 2 - ...r@corporate_card_transactions@unmatch.yaml | 2 - ...over@employee_overview@expenses@stats.yaml | 2 - .../approver@employee_overview@stats.yaml | 2 - src/approver/paths/approver@expenses.yaml | 4 - .../approver@expenses@attach_files@bulk.yaml | 2 - .../paths/approver@expenses@bulk.yaml | 4 - ...approver@expenses@check_policies_bulk.yaml | 2 - .../approver@expenses@comments@bulk.yaml | 4 - ...prover@expenses@export_configurations.yaml | 2 - .../paths/approver@expenses@exports.yaml | 2 - .../paths/approver@expenses@filters.yaml | 2 - .../approver@expenses@filters@delete.yaml | 2 - .../paths/approver@expenses@permissions.yaml | 2 - .../approver@expenses@permissions@bulk.yaml | 2 - .../paths/approver@expenses@split.yaml | 4 - ...expenses@split@check_mandatory_fields.yaml | 4 - ...pprover@expenses@split@check_policies.yaml | 4 - .../paths/approver@expenses@stats.yaml | 2 - src/approver/paths/approver@files@bulk.yaml | 2 - .../approver@files@generate_urls@bulk.yaml | 2 - .../paths/approver@reports@add_approver.yaml | 2 - .../paths/approver@reports@add_expenses.yaml | 2 - .../paths/approver@reports@comments.yaml | 2 - .../approver@reports@eject_expenses.yaml | 2 - ...pprover@reports@export_configurations.yaml | 2 - .../paths/approver@reports@exports.yaml | 2 - .../paths/approver@reports@filters.yaml | 2 - .../approver@reports@filters@delete.yaml | 2 - .../approver@reports@partially_approve.yaml | 2 - .../paths/approver@reports@permissions.yaml | 2 - .../approver@reports@round_off_amount.yaml | 2 - .../paths/approver@reports@send_back.yaml | 2 - .../paths/approver@reports@stats.yaml | 2 - .../paths/approver@subscriptions.yaml | 4 - ...g_logo_settings@generate_download_url.yaml | 2 - src/components/schemas/account.yaml | 24 - src/components/schemas/advance.yaml | 11 - src/components/schemas/advance_refund.yaml | 5 - src/components/schemas/advance_request.yaml | 30 - .../schemas/advance_request_approval.yaml | 4 - src/components/schemas/advance_wallet.yaml | 3 - src/components/schemas/automation.yaml | 3 - src/components/schemas/budget.yaml | 7 - src/components/schemas/budget_exports.yaml | 9 - src/components/schemas/category.yaml | 12 - src/components/schemas/corporate_card.yaml | 29 - .../schemas/corporate_card_transaction.yaml | 35 - .../corporate_card_transactions_exports.yaml | 14 - .../corporate_credit_card_expense.yaml | 4 - src/components/schemas/cost_center.yaml | 6 - src/components/schemas/currency.yaml | 2 - src/components/schemas/department.yaml | 13 - .../dependent_expense_field_values.yaml | 36 - src/components/schemas/dwolla_customer.yaml | 46 - src/components/schemas/employee.yaml | 175 +- .../schemas/employee_account_summary.yaml | 18 - src/components/schemas/employee_settings.yaml | 23 - .../employees_export_configurations.yaml | 2 - src/components/schemas/employees_exports.yaml | 14 - src/components/schemas/expense.yaml | 46 - .../schemas/expense_duplicate_set.yaml | 5 - src/components/schemas/expense_field.yaml | 19 - src/components/schemas/expense_policies.yaml | 3 - src/components/schemas/expense_rules.yaml | 16 - .../expenses_export_configurations.yaml | 2 - src/components/schemas/expenses_exports.yaml | 11 - src/components/schemas/feature_configs.yaml | 11 - src/components/schemas/fields.yaml | 6 - src/components/schemas/file.yaml | 27 - src/components/schemas/level.yaml | 2 - src/components/schemas/merchant.yaml | 11 - src/components/schemas/mileage_rate.yaml | 14 - .../schemas/mobile_app_version.yaml | 7 - src/components/schemas/my_profile.yaml | 6 - src/components/schemas/org.yaml | 26 - src/components/schemas/org_settings.yaml | 5 - src/components/schemas/per_diem_rate.yaml | 6 - src/components/schemas/personal_card.yaml | 21 - .../schemas/personal_card_transaction.yaml | 34 - src/components/schemas/place.yaml | 11 - src/components/schemas/policy.yaml | 3 - src/components/schemas/project.yaml | 11 - .../reconciliation_eligible_cards.yaml | 15 - .../schemas/reconciliation_exports.yaml | 9 - .../schemas/reconciliation_transactions.yaml | 26 - src/components/schemas/recurring_expense.yaml | 6 +- src/components/schemas/reimbursement.yaml | 8 - src/components/schemas/reminder.yaml | 12 - src/components/schemas/report.yaml | 36 - src/components/schemas/report_approval.yaml | 6 - .../reports_export_configurations.yaml | 2 - src/components/schemas/schedule.yaml | 8 - .../schemas/scheduled_callback.yaml | 14 - src/components/schemas/secondary_email.yaml | 8 - src/components/schemas/spend_overview.yaml | 42 - src/components/schemas/statements.yaml | 40 - src/components/schemas/subscriptions.yaml | 22 - src/components/schemas/user.yaml | 19 - ...ager@employee_overview@expenses@stats.yaml | 2 - ...yee_overview@files@generate_urls@bulk.yaml | 2 - .../manager@employee_overview@stats.yaml | 2 - src/spender/openapi.yaml | 2 +- .../paths/spender@advance_request_files.yaml | 2 - .../paths/spender@advance_requests.yaml | 2 - ...der@advance_requests@bulk_attach_file.yaml | 2 - .../spender@advance_requests@comments.yaml | 4 - .../spender@advance_requests@permissions.yaml | 2 - .../spender@advance_requests@pull_back.yaml | 2 - .../paths/spender@advance_requests@stats.yaml | 2 - .../spender@advance_requests@submit.yaml | 2 - src/spender/paths/spender@advances@stats.yaml | 2 - ...pender@automations@recurring_expenses.yaml | 2 - ...utomations@recurring_expenses@disable.yaml | 2 - ...rate_card_transactions@expenses@stats.yaml | 2 - ...er@corporate_card_transactions@ignore.yaml | 2 - ...orate_card_transactions@mark_personal.yaml | 2 - ...der@corporate_card_transactions@match.yaml | 2 - ...rporate_card_transactions@undo_ignore.yaml | 2 - ...ate_card_transactions@unmark_personal.yaml | 2 - ...r@corporate_card_transactions@unmatch.yaml | 2 - src/spender/paths/spender@email_files.yaml | 2 - src/spender/paths/spender@employees.yaml | 2 - src/spender/paths/spender@expense_files.yaml | 2 - .../spender@expense_policy_comments.yaml | 2 - .../spender@expenses@attach_files@bulk.yaml | 2 - .../spender@expenses@attach_receipt.yaml | 2 - src/spender/paths/spender@expenses@bulk.yaml | 4 - .../spender@expenses@check_policies.yaml | 2 - .../spender@expenses@check_policies_bulk.yaml | 2 - .../paths/spender@expenses@comments@bulk.yaml | 4 - ...pender@expenses@create_from_file@bulk.yaml | 2 - .../spender@expenses@create_from_receipt.yaml | 2 - ...pender@expenses@export_configurations.yaml | 2 - .../paths/spender@expenses@exports.yaml | 2 - .../paths/spender@expenses@filters.yaml | 2 - .../spender@expenses@filters@delete.yaml | 2 - src/spender/paths/spender@expenses@merge.yaml | 4 - .../paths/spender@expenses@permissions.yaml | 2 - .../spender@expenses@permissions@bulk.yaml | 2 - .../paths/spender@expenses@policy_test.yaml | 4 - src/spender/paths/spender@expenses@split.yaml | 4 - ...expenses@split@check_mandatory_fields.yaml | 4 - ...spender@expenses@split@check_policies.yaml | 4 - src/spender/paths/spender@expenses@stats.yaml | 2 - src/spender/paths/spender@files.yaml | 2 - src/spender/paths/spender@files@bulk.yaml | 2 - .../paths/spender@files@generate_urls.yaml | 2 - .../spender@files@generate_urls@bulk.yaml | 2 - .../paths/spender@files@upload_html.yaml | 2 - ...nder@personal_card_transactions@stats.yaml | 2 - src/spender/paths/spender@personal_cards.yaml | 2 - .../paths/spender@reports@add_expenses.yaml | 2 - .../paths/spender@reports@comments.yaml | 2 - .../paths/spender@reports@eject_expenses.yaml | 2 - ...spender@reports@export_configurations.yaml | 2 - .../paths/spender@reports@exports.yaml | 2 - .../paths/spender@reports@filters.yaml | 2 - .../paths/spender@reports@filters@delete.yaml | 2 - .../paths/spender@reports@permissions.yaml | 2 - .../paths/spender@reports@resubmit.yaml | 2 - src/spender/paths/spender@reports@stats.yaml | 2 - src/spender/paths/spender@reports@submit.yaml | 2 - .../spender@reports@suggest_purpose.yaml | 2 - src/spender/paths/spender@schedules.yaml | 2 - .../paths/spender@secondary_emails.yaml | 2 - .../paths/spender@secondary_emails@check.yaml | 2 - .../spender@secondary_emails@delete.yaml | 2 - src/spender/paths/spender@subscriptions.yaml | 4 - ...nder@virtual_cards@get_current_amount.yaml | 2 - ...ender@virtual_cards@show_card_details.yaml | 2 - 335 files changed, 253 insertions(+), 4389 deletions(-) diff --git a/reference/accountant.yaml b/reference/accountant.yaml index 4d6485071..67e660e74 100644 --- a/reference/accountant.yaml +++ b/reference/accountant.yaml @@ -190,12 +190,6 @@ components: file_generate_urls_action_out: type: object additionalProperties: false - required: - - id - - name - - content_type - - download_url - - upload_url properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/admin.yaml b/reference/admin.yaml index 678ec673e..c609fa7c3 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -182,8 +182,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_approver_project_out' @@ -441,8 +439,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_cost_center_out' @@ -694,8 +690,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_approver_category_out' @@ -898,7 +892,6 @@ paths: additionalProperties: false required: - data - - count properties: count: $ref: '#/components/schemas/count' @@ -981,8 +974,6 @@ paths: application/json: schema: type: object - required: - - data properties: url: type: string @@ -1339,8 +1330,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/dependent_expense_field_values_upload_out' @@ -1433,8 +1422,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/dependent_expense_field_values_download_out' @@ -1525,8 +1512,6 @@ paths: application/json: schema: type: object - required: - - data properties: url: type: string @@ -1624,8 +1609,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/per_diem_rate_out' @@ -1865,8 +1848,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/department_out' @@ -2101,8 +2082,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/mileage_rate_out' @@ -2400,251 +2379,247 @@ paths: application/json: schema: type: object + properties: + data: + $ref: '#/components/schemas/level_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' + /admin/levels/delete/bulk: + post: + tags: + - Levels + security: + - oauth2: + - '*' + summary: Delete levels + description: | + Deletes unused levels. If any supplied level is assigned to an employee or used in an + expense policy, the request fails without deleting any levels. A maximum of 200 unique + level IDs can be processed. Repeated IDs are deduplicated in first-seen order before the + limit is enforced. + operationId: levels_delete_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/level_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + examples: + limit_exceeded: + summary: More than 200 unique level IDs supplied + value: + message: Cannot perform action for more than 200 levels at once. + data: null + error: InvalidUsage + dependency_blocked: + summary: A level is assigned or used by another resource + value: + message: Can not delete level(s) used in other resources like employee assignments, expense policy. + data: null + error: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + /admin/levels/delete_summary/bulk: + post: + tags: + - Levels + security: + - oauth2: + - '*' + summary: Get levels delete summary + description: | + Returns levels that can be deleted from the supplied IDs. Levels assigned to employees or + used in expense policies are excluded. A maximum of 200 unique level IDs can be processed. + Repeated IDs are deduplicated in first-seen order before the limit is enforced. + operationId: levels_delete_summary_bulk_post + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: array + items: + $ref: '#/components/schemas/level_in_only_id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/level_delete_summary_out' + '400': + description: Bad request + content: + application/json: + schema: + type: object + properties: + message: + type: string + example: Cannot perform action for more than 200 levels at once. + data: + type: object + nullable: true + example: null + error: + type: string + example: InvalidUsage + '401': + description: Unauthorised request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + /admin/employees: + get: + tags: + - Employees + summary: List employees + operationId: employees_list + description: | + This API supports very rich filtering on all response fields and pagination via query parameters. To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) + parameters: + - $ref: '#/components/parameters/q' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false required: - data + - count + - offset properties: + count: + $ref: '#/components/schemas/count' + offset: + $ref: '#/components/schemas/offset' data: - $ref: '#/components/schemas/level_out' - '400': - description: Bad request - content: - application/json: - schema: - $ref: '#/components/schemas/400' - '401': - description: Unauthorized request - content: - application/json: - schema: - $ref: '#/components/schemas/401' - '403': - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/403' - '404': - description: Not Found - content: - application/json: - schema: - $ref: '#/components/schemas/404' - /admin/levels/delete/bulk: - post: - tags: - - Levels - security: - - oauth2: - - '*' - summary: Delete levels - description: | - Deletes unused levels. If any supplied level is assigned to an employee or used in an - expense policy, the request fails without deleting any levels. A maximum of 200 unique - level IDs can be processed. Repeated IDs are deduplicated in first-seen order before the - limit is enforced. - operationId: levels_delete_bulk_post - requestBody: - required: true - content: - application/json: - schema: - type: object - additionalProperties: false - required: - - data - properties: - data: - type: array - items: - $ref: '#/components/schemas/level_in_only_id' - responses: - '200': - description: OK - content: - application/json: - schema: - type: object - additionalProperties: false - '400': - description: Bad request - content: - application/json: - schema: - type: object - properties: - message: - type: string - data: - type: object - nullable: true - example: null - error: - type: string - example: InvalidUsage - examples: - limit_exceeded: - summary: More than 200 unique level IDs supplied - value: - message: Cannot perform action for more than 200 levels at once. - data: null - error: InvalidUsage - dependency_blocked: - summary: A level is assigned or used by another resource - value: - message: Can not delete level(s) used in other resources like employee assignments, expense policy. - data: null - error: InvalidUsage - '401': - description: Unauthorised request - content: - application/json: - schema: - $ref: '#/components/schemas/401' - '403': - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/403' - /admin/levels/delete_summary/bulk: - post: - tags: - - Levels - security: - - oauth2: - - '*' - summary: Get levels delete summary - description: | - Returns levels that can be deleted from the supplied IDs. Levels assigned to employees or - used in expense policies are excluded. A maximum of 200 unique level IDs can be processed. - Repeated IDs are deduplicated in first-seen order before the limit is enforced. - operationId: levels_delete_summary_bulk_post - requestBody: - required: true - content: - application/json: - schema: - type: object - additionalProperties: false - required: - - data - properties: - data: - type: array - items: - $ref: '#/components/schemas/level_in_only_id' - responses: - '200': - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/level_delete_summary_out' - '400': - description: Bad request - content: - application/json: - schema: - type: object - properties: - message: - type: string - example: Cannot perform action for more than 200 levels at once. - data: - type: object - nullable: true - example: null - error: - type: string - example: InvalidUsage - '401': - description: Unauthorised request - content: - application/json: - schema: - $ref: '#/components/schemas/401' - '403': - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/403' - /admin/employees: - get: - tags: - - Employees - summary: List employees - operationId: employees_list - description: | - This API supports very rich filtering on all response fields and pagination via query parameters. To understand how to use these parameters, please see the [Guide to Data APIs](https://docs.fylehq.com/docs/fyle-platform-docs/ZG9jOjI3Mzk2NTM3-guide-to-data-ap-is#filtering) - parameters: - - $ref: '#/components/parameters/q' - responses: - '200': - description: OK - content: - application/json: - schema: - type: object - additionalProperties: false - required: - - data - - count - - offset - properties: - count: - $ref: '#/components/schemas/count' - offset: - $ref: '#/components/schemas/offset' - data: - type: array - items: - $ref: '#/components/schemas/employee_out' - '400': - description: Bad request - content: - application/json: - schema: - $ref: '#/components/schemas/400' - '401': - description: Unauthorized request - content: - application/json: - schema: - $ref: '#/components/schemas/401' - /admin/employees/stats: - post: - tags: - - Employees - summary: Employees Stats - description: | - Employees Stats - operationId: employees_stats - requestBody: - required: true - content: - application/json: - schema: - type: object - additionalProperties: false - required: - - data - properties: - data: - $ref: '#/components/schemas/employees_stats_in' - responses: - '200': - description: OK - content: - application/json: - schema: - type: object - additionalProperties: false - required: - - data - properties: - data: - $ref: '#/components/schemas/employees_stats_out' + type: array + items: + $ref: '#/components/schemas/employee_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + /admin/employees/stats: + post: + tags: + - Employees + summary: Employees Stats + description: | + Employees Stats + operationId: employees_stats + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/employees_stats_in' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + data: + $ref: '#/components/schemas/employees_stats_out' '400': description: Bad request content: @@ -2782,8 +2757,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/employees_exports_out' @@ -3031,8 +3004,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/employee_filters_out' @@ -3114,8 +3085,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/employee_filters_out' @@ -3209,8 +3178,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/employees_upload_out' @@ -3304,8 +3271,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/employees_download_out' @@ -3542,8 +3507,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/employees_export_configuration_out' @@ -3683,8 +3646,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/file_out' @@ -3742,8 +3703,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -3820,8 +3779,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -3980,8 +3937,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/automate_report_submission_out' @@ -4076,8 +4031,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/automate_report_submission_out' @@ -4173,8 +4126,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/accounting_export_out' @@ -4270,8 +4221,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/accounting_export_lineitem_out' @@ -4409,8 +4358,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/admin_expense_in' @@ -4421,8 +4368,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_out' @@ -4464,8 +4409,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/admin_expenses_bulk_in' @@ -4476,8 +4419,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -4537,8 +4478,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -4643,8 +4582,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -4732,8 +4669,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -4858,8 +4793,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expenses_stats_out' @@ -4913,8 +4846,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expenses_exports_out' @@ -5086,8 +5017,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expenses_export_configuration_out' @@ -5229,8 +5158,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_permissions_out' @@ -5294,8 +5221,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_permissions_bulk_out' @@ -5362,8 +5287,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expenses_merge_in' @@ -5374,8 +5297,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_out' @@ -5476,8 +5397,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -5533,8 +5452,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_requests_stats_out' @@ -5590,8 +5507,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_permissions_out' @@ -5633,8 +5548,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_comments_in' @@ -5645,8 +5558,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_comments_out' @@ -5688,8 +5599,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_remove_approver_in' @@ -5704,8 +5613,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -5816,8 +5723,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_out' @@ -5928,8 +5833,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advances_stats_out' @@ -6030,8 +5933,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_wallet_out' @@ -6132,8 +6033,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_refund_out' @@ -6243,8 +6142,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -6340,8 +6237,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/reminder_out' @@ -6396,8 +6291,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -6453,8 +6346,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -6608,8 +6499,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -6657,8 +6546,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -6746,8 +6633,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -6802,8 +6687,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_comments_out' @@ -6853,8 +6736,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -6908,8 +6789,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7020,8 +6899,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7077,8 +6954,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7139,8 +7014,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7385,8 +7258,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -7516,8 +7387,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/reports_stats_out' @@ -7613,8 +7482,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_permissions_out' @@ -7669,8 +7536,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7720,8 +7585,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7769,8 +7632,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7857,8 +7718,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/reports_exports_out' @@ -7953,8 +7812,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/reports_export_configuration_out' @@ -8138,8 +7995,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8242,8 +8097,6 @@ paths: properties: data: type: object - required: - - bank_names properties: bank_names: type: array @@ -8338,8 +8191,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_stats_out' @@ -8394,8 +8245,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8450,8 +8299,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_unassign_out' @@ -8506,8 +8353,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8562,8 +8407,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8618,8 +8461,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8674,8 +8515,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8730,8 +8569,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8787,8 +8624,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -8898,8 +8733,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_duplicate_suggestion_out' @@ -9001,8 +8834,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_archive_suggestion_out' @@ -9102,8 +8933,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_post_out' @@ -9212,8 +9041,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -9271,8 +9098,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -9330,8 +9155,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -9388,8 +9211,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_filters_out' @@ -9471,8 +9292,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_filters_out' @@ -9526,8 +9345,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_assign_out' @@ -9689,8 +9506,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unassign_out' @@ -9744,8 +9559,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_mark_personal_out' @@ -9853,8 +9666,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmark_personal_out' @@ -9908,8 +9719,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_ignore_out' @@ -10017,8 +9826,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_undo_ignore_out' @@ -10072,8 +9879,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_match_out' @@ -10127,8 +9932,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmatch_out' @@ -10182,8 +9985,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transactions_exports_out' @@ -10278,8 +10079,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/virtual_cards_get_current_balance_out' @@ -10334,8 +10133,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/virtual_cards_show_card_details_out' @@ -10390,8 +10187,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/virtual_card_out' @@ -10433,8 +10228,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_subscriptions_in' @@ -10446,8 +10239,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/admin_subscriptions_out' @@ -10693,8 +10484,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/schedule_out' @@ -10783,8 +10572,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/scheduled_callback_out' @@ -11349,8 +11136,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/account_out' @@ -11440,8 +11225,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/tax_group_out' @@ -11552,8 +11335,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/budget_post_out' @@ -11692,8 +11473,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/budget_exports_out' @@ -11889,8 +11668,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_policy_out' @@ -12018,8 +11795,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_policy_out' @@ -12075,8 +11850,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_policy_out' @@ -12293,8 +12066,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/statements_out' @@ -12402,10 +12173,6 @@ paths: application/json: schema: type: object - required: - - data - - count - - offset properties: count: $ref: '#/components/schemas/count' @@ -12459,8 +12226,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/preview_out' @@ -12514,8 +12279,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -12571,8 +12334,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -12628,8 +12389,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: object @@ -12685,8 +12444,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -12742,8 +12499,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/card_stats_out' @@ -12797,8 +12552,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -13029,8 +12782,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -13086,8 +12837,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: object @@ -13462,8 +13211,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_check_policies_bulk_out' @@ -13548,8 +13295,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_comments_bulk_in' @@ -13560,8 +13305,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -13853,8 +13596,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -13865,8 +13606,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -13912,8 +13651,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -13924,8 +13661,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -13972,8 +13707,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -13984,8 +13717,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -14343,8 +14074,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -14435,8 +14164,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -14513,8 +14240,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -14575,8 +14300,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -14708,8 +14431,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -14768,8 +14489,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/reconciliation_export_out' @@ -14839,8 +14558,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -14924,8 +14641,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -15001,8 +14716,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: object @@ -15072,8 +14785,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -15133,8 +14844,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/reconciliation_export_out' @@ -15198,8 +14907,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -15368,8 +15075,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -15509,8 +15214,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -15571,8 +15274,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_add_approver_in' @@ -15588,8 +15289,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15659,8 +15358,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15724,8 +15421,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15791,8 +15486,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15898,8 +15591,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_custom_field_out' @@ -15999,8 +15690,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/dwolla_customer_out' @@ -16186,8 +15875,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transactions_export_configuration_out' @@ -16471,10 +16158,6 @@ components: user_out_embed: type: object additionalProperties: false - required: - - id - - email - - full_name properties: id: allOf: @@ -16695,15 +16378,10 @@ components: $ref: '#/components/schemas/id_integer' project_delete_summary_out: type: object - required: - - data additionalProperties: false properties: data: type: object - required: - - delete_count - - projects properties: delete_count: type: integer @@ -16821,8 +16499,6 @@ components: cost_center_delete_summary_out: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -16969,15 +16645,10 @@ components: $ref: '#/components/schemas/id_integer' category_delete_summary_out: type: object - required: - - data additionalProperties: false properties: data: type: object - required: - - delete_count - - categories properties: delete_count: type: integer @@ -17012,25 +16683,6 @@ components: expense_field_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - seq - - field_name - - column_name - - type - - options - - default_value - - placeholder - - category_ids - - is_enabled - - is_custom - - is_mandatory - - code - - parent_field_id - - display_order properties: id: $ref: '#/components/schemas/id_integer' @@ -17194,16 +16846,6 @@ components: dependent_expense_field_values_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - parent_expense_field_id - - expense_field_id - - parent_expense_field_value - - expense_field_value - - is_enabled properties: id: $ref: '#/components/schemas/id_integer' @@ -17277,13 +16919,6 @@ components: dependent_expense_field_values_preview_out: type: object additionalProperties: false - required: - - org_id - - parent_expense_field_id - - expense_field_id - - parent_expense_field_value - - expense_field_values - - is_enabled properties: org_id: $ref: '#/components/schemas/org_id' @@ -17318,16 +16953,6 @@ components: dependent_expense_field_values_upload_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - parent_expense_field_id - - expense_field_id - - file_id - - error_file_id - - state properties: id: $ref: '#/components/schemas/id_integer' @@ -17394,15 +17019,6 @@ components: dependent_expense_field_values_download_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - parent_expense_field_id - - expense_field_id - - file_id - - state properties: id: $ref: '#/components/schemas/id_integer' @@ -17643,8 +17259,6 @@ components: per_diem_rate_delete_summary_out: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -17777,8 +17391,6 @@ components: department_delete_summary_out: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -17901,15 +17513,10 @@ components: $ref: '#/components/schemas/id_integer' mileage_rate_delete_summary_out: type: object - required: - - data additionalProperties: false properties: data: type: object - required: - - delete_count - - mileage_rates properties: delete_count: type: integer @@ -18006,8 +17613,6 @@ components: level_delete_summary_out: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -18036,11 +17641,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - code - - name - - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -18211,12 +17811,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - sub_project - - code - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -18243,10 +17837,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -18262,10 +17852,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -18279,10 +17865,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - vehicle_type - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -18436,13 +18018,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - system_category - - name - - sub_category - - code - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -18792,7 +18367,6 @@ components: - user_id - email - full_name - - potential_duplicate_expenses properties: user_id: $ref: '#/components/schemas/user_id' @@ -18935,20 +18509,6 @@ components: Configuration for the export. employees_exports_out: type: object - required: - - created_at - - updated_at - - id - - org_id - - user_id - - query_params - - notify_emails - - config - - file_id - - state - - processed_at - - completed_at - - failed_at properties: created_at: type: string @@ -19385,10 +18945,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - email - - full_name properties: id: allOf: @@ -19614,8 +19170,6 @@ components: - type - org_id - user_id - - created_by - - updated_by properties: id: allOf: @@ -19763,17 +19317,6 @@ components: file_out: type: object additionalProperties: false - required: - - id - - org_id - - user_id - - created_at - - updated_at - - name - - type - - content_type - - download_url - - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -19821,12 +19364,6 @@ components: file_generate_urls_action_out: type: object additionalProperties: false - required: - - id - - name - - content_type - - download_url - - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -19978,9 +19515,6 @@ components: $ref: '#/components/schemas/user_out_embed' automate_report_submission_in: type: object - required: - - description - - schedule_config properties: id: $ref: '#/components/schemas/id_string' @@ -20180,9 +19714,6 @@ components: example: 1234 account_out_embed: type: object - required: - - id - - type properties: id: allOf: @@ -20202,11 +19733,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - vehicle_type - - code - - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -20287,12 +19813,6 @@ components: report_approval_out_embed: type: object additionalProperties: false - required: - - approver_user_id - - approver_type - - approver_user - - state - - approver_order properties: approver_user_id: allOf: @@ -20345,9 +19865,6 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num - - amount - - last_verified_at - - approvals properties: id: anyOf: @@ -20436,11 +19953,6 @@ components: List of report_approval objects file_out_embed: type: object - required: - - id - - name - - type - - content_type properties: id: allOf: @@ -20486,9 +19998,6 @@ components: expense_verification_out_embed: type: object additionalProperties: false - required: - - verifier_user_id - - verifier_user properties: verifier_user_id: allOf: @@ -20511,12 +20020,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - code - - name - - sub_department - - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -20539,25 +20042,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - location - - title - - business_unit - - custom_fields - - flattened_custom_field - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -20659,24 +20143,6 @@ components: - id - corporate_card_id - corporate_card_number - - corporate_card_nickname - - corporate_card_cardholder_name - - capitalone_virtual_card_last_four - - masked_corporate_card_number - - bank_name - - corporate_card_user_full_name - - is_corporate_card_archived - - amount - - currency - - spent_at - - posted_at - - status - - description - - foreign_currency - - foreign_amount - - merchant - - category - - matched_by properties: id: allOf: @@ -21161,12 +20627,6 @@ components: example: 77.594566 commute_details: type: object - required: - - id - - distance - - distance_unit - - home_location - - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -21288,26 +20748,6 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments - - custom_fields_flattened - - approvals - - verifications - - employee_id - - split_group_amount - - expense_rule_id - - expense_rule_data - - is_split - - tax_group - - approver_comments - - verifier_comments - - policy_checks - - accounting_export_summary - - report_last_paid_at - - report_last_approved_at - - commute_deduction - - commute_details_id - - commute_details - - is_reconciled - - report_auto_approval_state properties: id: allOf: @@ -22340,8 +21780,6 @@ components: Expense ID of the expense to be verified. example: tx0agOdICdbV expenses_stats_in: - required: - - query_params properties: query_params: nullable: false @@ -22545,17 +21983,6 @@ components: expenses_exports_out: type: object additionalProperties: false - required: - - created_at - - updated_at - - id - - org_id - - user_id - - query_params - - notify_emails - - config - - file_id - - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -22732,8 +22159,6 @@ components: - type - org_id - user_id - - created_by - - updated_by properties: id: allOf: @@ -23046,12 +22471,6 @@ components: advance_out_embed: type: object nullable: true - required: - - id - - currency - - amount - - advance_request_id - - seq_num properties: id: type: string @@ -23132,10 +22551,6 @@ components: advance_request_approval_out_embed: type: object additionalProperties: false - required: - - approver_user_id - - approver_user - - state properties: approver_user_id: allOf: @@ -23155,14 +22570,6 @@ components: employee_out_embed: type: object additionalProperties: false - required: - - id - - user_id - - user - - code - - org_id - - department_id - - department properties: id: $ref: '#/components/schemas/id_string' @@ -23196,17 +22603,6 @@ components: advance_request_comments_out: type: object additionalProperties: false - required: - - id - - comment - - action - - advance_request_id - - creator_type - - creator_user_id - - creator_user - - created_at - - updated_at - - org_id properties: id: $ref: '#/components/schemas/id_string' @@ -23425,8 +22821,6 @@ components: required: - id advance_requests_stats_in: - required: - - query_params properties: query_params: description: | @@ -23522,18 +22916,6 @@ components: advance_request_permissions_out: type: object additionalProperties: false - required: - - can_save - - can_submit - - can_edit - - can_add_approver - - can_disable_approver - - can_reject - - can_approve - - can_inquire - - can_pull_back - - can_pay - - can_delete properties: can_save: type: boolean @@ -23612,10 +22994,6 @@ components: advance_request_out_embed: type: object nullable: true - required: - - id - - last_approved_at - - seq_num properties: id: type: string @@ -23854,8 +23232,6 @@ components: custom_fields: $ref: '#/components/schemas/custom_fields' advances_stats_in: - required: - - query_params properties: query_params: type: string @@ -23865,9 +23241,6 @@ components: example: id=in.('adv1263', 'adv1569') advances_stats_out: type: object - required: - - count - - total_amount properties: count: type: integer @@ -24072,8 +23445,6 @@ components: - $ref: '#/components/schemas/id_string' example: awfgRr8YA6KK advance_refunds_stats_in: - required: - - query_params properties: query_params: type: string @@ -24083,9 +23454,6 @@ components: example: id=in.('adr1263', 'adr1569') advance_refunds_stats_out: type: object - required: - - count - - total_amount properties: count: type: integer @@ -24267,13 +23635,6 @@ components: reminder_in: type: object additionalProperties: false - required: - - type - - message - - schedule_config - - add_to_calendar - - send_mobile_notification - - receiver_user_ids properties: id: type: string @@ -24318,8 +23679,6 @@ components: ID of the reminder that needs to be deleted. example: remindNZgN7V5pft reminders_stats_in: - required: - - query_params properties: query_params: type: string @@ -24329,9 +23688,6 @@ components: example: id=in.('remind123','remind1234') reminders_stats_out: type: array - required: - - last_reminded_at - - type items: type: object properties: @@ -24346,24 +23702,6 @@ components: employee_out_embed_for_report: type: object additionalProperties: false - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - ach_account - - business_unit - - location - - title - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -24507,12 +23845,6 @@ components: reimbursement_out_minimal: type: object nullable: true - required: - - id - - currency - - amount - - mode - - ach_transfer properties: id: type: string @@ -24565,9 +23897,6 @@ components: advance_wallet_report_out: type: object additionalProperties: false - required: - - id - - amount properties: id: allOf: @@ -24608,14 +23937,6 @@ components: - applied_advance_wallets - can_apply_advances - creator_type - - is_verified - - is_physical_bill_submitted - - physical_bill_submitted_at - - is_exported - - employee_id - - state_display_name - - accounting_export_summary - - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -25093,20 +24414,6 @@ components: - id process_summary_out: type: object - required: - - selected_reimbursable_amount - - selected_count - - unverified_count - - unverified_amount - - missing_bank_details_count - - missing_bank_details_amount - - missing_bank_details_employee_count - - missing_bank_details_employee_ids - - payment_initiated_amount - - payment_initiated_count - - reimbursable_amount - - reimbursable_report_ids - - closable_report_ids additionalProperties: true properties: selected_reimbursable_amount: @@ -25199,8 +24506,6 @@ components: id: $ref: '#/components/schemas/id_string' reports_stats_in: - required: - - query_params properties: query_params: type: string @@ -25765,8 +25070,6 @@ components: - type - org_id - user_id - - created_by - - updated_by properties: id: allOf: @@ -26138,8 +25441,6 @@ components: - bank_name - card_number corporate_card_stats_in: - required: - - query_params properties: query_params: nullable: false @@ -26149,10 +25450,6 @@ components: example: user_id=eq.null corporate_card_stats_out: type: object - required: - - count - - total_transactions_count - - transactions_count properties: count: type: integer @@ -26194,10 +25491,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - email - - full_name properties: id: allOf: @@ -26477,16 +25770,6 @@ components: duplicate_suggestion_corporate_card_out_embed: type: object additionalProperties: false - required: - - id - - bank_name - - card_number - - nickname - - total_transactions_count - - is_visa_enrolled - - is_mastercard_enrolled - - data_feed_source - - feed_display_name properties: id: allOf: @@ -26701,16 +25984,6 @@ components: corporate_card_out_embed: type: object additionalProperties: false - required: - - id - - bank_name - - card_number - - nickname - - cardholder_name - - masked_number - - user_full_name - - user_email - - is_archived properties: id: allOf: @@ -27469,11 +26742,7 @@ components: - last_user_matched_at - is_exported - metadata - - mcc corporate_card_transactions_stats_in: - type: object - required: - - query_params properties: query_params: nullable: false @@ -27483,10 +26752,6 @@ components: example: amount=gt.0&amount=lt.1000&created_at=gt.2021-01-01T00:00:00.000Z&created_at=lt.2021-12-31T23:59:59.999Z corporate_card_transactions_stats_out: type: object - required: - - count - - debit_amount - - credit_amount properties: count: type: integer @@ -27517,9 +26782,6 @@ components: - id corporate_card_transactions_delete_summary_out: type: object - required: - - delete_count - - delete_amount properties: delete_count: type: integer @@ -27821,7 +27083,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - mcc corporate_card_transaction_reassign_in: type: object properties: @@ -28061,8 +27322,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - mcc - - is_exported corporate_card_transaction_mark_personal_out: type: object properties: @@ -28270,8 +27529,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - mcc - - is_exported corporate_card_transaction_unmark_personal_out: type: object properties: @@ -28480,8 +27737,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - mcc - - is_exported corporate_card_transaction_ignore_out: type: object properties: @@ -28696,9 +27951,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - capitalone_virtual_card_last_four - - mcc - - is_exported corporate_card_transaction_undo_ignore_out: type: object additionalProperties: false @@ -28928,10 +28180,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - transaction_status - - capitalone_virtual_card_last_four - - mcc - - bank_transaction_number corporate_card_transaction_match_in: type: object properties: @@ -29163,9 +28411,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - capitalone_virtual_card_last_four - - mcc - - is_exported corporate_card_transaction_unmatch_in: type: object properties: @@ -29409,11 +28654,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - transaction_status - - capitalone_virtual_card_last_four - - mcc - - bank_transaction_number - - is_exported corporate_card_transactions_export_config_column_formula: type: object required: @@ -29560,20 +28800,6 @@ components: corporate_card_transactions_exports_out: type: object additionalProperties: false - required: - - created_at - - updated_at - - id - - org_id - - user_id - - query_params - - notify_emails - - config - - file_id - - state - - processed_at - - completed_at - - failed_at properties: created_at: $ref: '#/components/schemas/created_at' @@ -29797,14 +29023,6 @@ components: admin_subscriptions_out: type: object additionalProperties: false - required: - - id - - is_enabled - - webhook_url - - updated_at - - created_at - - org_id - - subscribed_resources properties: id: $ref: '#/components/schemas/id_string' @@ -29865,15 +29083,6 @@ components: - reimbursement - comments - creator_type - - is_verified - - is_physical_bill_submitted - - physical_bill_submitted_at - - is_exported - - employee_id - - state_display_name - - accounting_export_summary - - applied_advance_wallets - - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -30236,24 +29445,6 @@ components: example: 100 employee_account_summary_out: type: object - required: - - id - - created_at - - updated_at - - org_id - - org_currency - - user_email - - user_full_name - - cash_account_id - - cash_account - - cash_account_balance - - ccc_account_id - - ccc_account - - ccc_account_balance - - advance_account_ids - - advance_accounts - - advance_accounts_balance - - is_settleable properties: id: $ref: '#/components/schemas/id_integer' @@ -30311,14 +29502,6 @@ components: schedule_out: type: object additionalProperties: false - required: - - id - - created_at - - updated_at - - config - - org_id - - user_id - - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -30376,15 +29559,6 @@ components: scheduled_callback_out: type: object additionalProperties: false - required: - - id - - url - - payload - - schedule_config - - is_enabled - - created_at - - updated_at - - org_id properties: id: $ref: '#/components/schemas/id_string' @@ -30404,11 +29578,6 @@ components: $ref: '#/components/schemas/org_id' scheduled_callback_in: type: object - required: - - url - - payload - - schedule_config - - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -30451,9 +29620,6 @@ components: spend_overview_summary_data_out: type: object nullable: false - required: - - amount - - time_interval_marker properties: amount: $ref: '#/components/schemas/amount' @@ -30472,11 +29638,6 @@ components: spend_overview_by_merchant_data_out: type: object nullable: false - required: - - merchant_name - - amount - - percentage - - change_percentage properties: merchant_name: $ref: '#/components/schemas/merchant' @@ -30495,12 +29656,6 @@ components: spend_overview_by_project_data_out: type: object nullable: false - required: - - project_id - - project_display_name - - amount - - percentage - - change_percentage properties: project_id: $ref: '#/components/schemas/id_integer' @@ -30521,12 +29676,6 @@ components: spend_overview_by_category_data_out: type: object nullable: false - required: - - category_id - - category_display_name - - amount - - percentage - - change_percentage properties: category_id: $ref: '#/components/schemas/id_integer' @@ -30547,12 +29696,6 @@ components: spend_overview_by_department_data_out: type: object nullable: false - required: - - department_id - - department_display_name - - amount - - percentage - - change_percentage properties: department_id: $ref: '#/components/schemas/id_string' @@ -30567,13 +29710,6 @@ components: spend_overview_by_user_data_out: type: object nullable: false - required: - - user_id - - user_full_name - - user_email - - amount - - percentage - - change_percentage properties: user_id: $ref: '#/components/schemas/id_string' @@ -30590,15 +29726,6 @@ components: spend_overview_by_corporate_card_data_out: type: object nullable: false - required: - - card_id - - card_number - - card_holder_name - - card_nickname - - user_id - - amount - - percentage - - change_percentage properties: card_id: $ref: '#/components/schemas/id_string' @@ -30634,17 +29761,6 @@ components: account_out: type: object additionalProperties: false - required: - - id - - created_at - - updated_at - - user_id - - type - - currency - - current_balance_amount - - tentative_balance_amount - - org_id - - category_id properties: id: allOf: @@ -30689,11 +29805,6 @@ components: account_in: type: object additionalProperties: false - required: - - user_id - - type - - currency - - category_id properties: user_id: type: string @@ -30849,7 +29960,6 @@ components: - visibility - status - user_ids - - fiscal_year_start_month properties: id: $ref: '#/components/schemas/id_string' @@ -31162,12 +30272,6 @@ components: budget_out_embed: type: object additionalProperties: false - required: - - id - - name - - type - - amount_limit - - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -31273,15 +30377,6 @@ components: budget_exports_out: type: object additionalProperties: false - required: - - created_at - - updated_at - - id - - org_id - - user_id - - query_params - - file_id - - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -31326,8 +30421,6 @@ components: - currency - created_at - updated_at - - is_current - - is_primary properties: id: $ref: '#/components/schemas/org_id' @@ -31395,7 +30488,6 @@ components: - id - invitation_sent - is_limit_reached - - weekly_limit properties: id: $ref: '#/components/schemas/org_id' @@ -31546,9 +30638,6 @@ components: - action_add_department_head_approver - action_add_approver_user_ids - action_override_distance_slab_rate - - expense_merchants - - expense_merchants_op - - policy_violation_reason_required properties: id: allOf: @@ -32892,7 +31981,6 @@ components: - file_id - is_processed - statement_mappings_id - - creator_user statements_in: type: object properties: @@ -33456,16 +32544,6 @@ components: - id - statement_mapping summary_out: - type: object - required: - - id - - status - - period_start - - period_end - - statement_transaction_count - - statement_total - - total_cards - - bridging_entry_change_type properties: id: allOf: @@ -33638,12 +32716,6 @@ components: - statement_mapping - reconciliation_entry_ids _reconciliation_summary_object: - type: object - required: - - expense_count - - is_recommended - - reconciliation_method - - statement_transaction_count properties: expense_count: description: Number of expense matches found @@ -33661,9 +32733,6 @@ components: type: number example: 12 reconciliation_summary_out: - type: object - required: - - reconciliation_summary properties: reconciliation_summary: type: array @@ -33987,13 +33056,7 @@ components: required: - missing_transactions_count - is_rtf_statement - - rtf_card_network - - missing_corporate_card_details matching_cards_out: - type: object - required: - - statement_card_number - - matching_cards properties: statement_card_number: type: string @@ -34032,13 +33095,6 @@ components: $ref: '#/components/schemas/user_out_embed_nullable' rtf_missing_transaction_from_statement_out: type: object - required: - - error - - missing_rtf_transactions - - rtf_confidence - - rtf_count - - total_count - - status properties: error: type: string @@ -34281,9 +33337,6 @@ components: - reconciliation_method rtf_stats_out: type: object - required: - - last_uploaded_at - - rtf_confidence properties: last_uploaded_at: $ref: '#/components/schemas/timestamptz_utc' @@ -34408,10 +33461,6 @@ components: - id - statement_mapping statement_archived_cards_out: - required: - - number_of_cards - - number_of_archived_cards - - archived_cards properties: number_of_cards: type: integer @@ -34473,8 +33522,6 @@ components: additionalProperties: false required: - merchant_contains - - department_ids - - departments properties: merchant_contains: type: string @@ -34503,18 +33550,6 @@ components: nullable: false additionalProperties: false minProperties: 1 - required: - - merchant - - is_billable - - purpose - - category_id - - category - - project_id - - project - - cost_center_id - - cost_center - - custom_fields - - dependent_fields properties: merchant: type: string @@ -34585,8 +33620,6 @@ components: - creator_user - if - set - - is_suggested - - is_suggestion_dismissed properties: id: allOf: @@ -35145,9 +34178,6 @@ components: description: | List of expense IDs that needs to be dismissed as a duplicate from the target expense expenses_duplicate_sets_stats_in: - type: object - required: - - query_params properties: query_params: nullable: false @@ -35158,8 +34188,6 @@ components: example: '' expenses_duplicate_sets_stats_out: type: object - required: - - count properties: count: type: integer @@ -35180,17 +34208,6 @@ components: feature_config_out: type: object additionalProperties: false - required: - - org_id - - user_id - - created_at - - updated_at - - target_client - - feature - - sub_feature - - key - - value - - is_shared properties: org_id: $ref: '#/components/schemas/org_id' @@ -35460,9 +34477,6 @@ components: expense_check_policies_out: type: object additionalProperties: false - required: - - individual_desired_states - - final_desired_state properties: individual_desired_states: type: array @@ -35473,12 +34487,6 @@ components: org_bank_details_out: type: object additionalProperties: false - required: - - org_id - - bank_account_number - - bank_branch_ifsc - - dwolla_customers_metadata_id - - is_bank_account_added properties: org_id: $ref: '#/components/schemas/org_id' @@ -35507,11 +34515,6 @@ components: merchant_out: type: object additionalProperties: false - required: - - id - - created_at - - updated_at - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -35653,14 +34656,6 @@ components: - amount - state - purpose - - currency - - merchant - - spent_at - - file_ids - - category - - project - - matched_corporate_card_transaction - - files properties: id: allOf: @@ -35763,9 +34758,6 @@ components: - project - purpose - splits - - currency - - matched_corporate_card_transaction - - files properties: id: allOf: @@ -35875,12 +34867,6 @@ components: - matched_expenses_count - is_reconciled - expenses - - statement_line_item_id - - expense_ids - - statement_transaction_date - - statement_post_date - - created_at - - updated_at properties: id: $ref: '#/components/schemas/id_string' @@ -35967,15 +34953,6 @@ components: example: corporate_card_id=eq.bawownwrng reconciliation_transactions_stats_out: type: object - required: - - period_start - - period_end - - statement_transaction_count - - expense_count - - statement_total - - expense_total - - difference - - matching_issue_count additionalProperties: false description: | Reconciliation transactions statistics for the selected filter period. @@ -36114,21 +35091,6 @@ components: example: reconciliation_entry_id=eq.receabc12345 reconciliation_eligible_cards_stats_out: type: object - required: - - period_start - - period_end - - statement_transaction_count - - expense_count - - statement_total - - expense_total - - difference - - matching_issue_count - - total_cards - - card_without_statement_count - - card_with_matching_issue_count - - card_with_no_issues_found_count - - card_with_no_transactions_count - - reconciled_card_count additionalProperties: false properties: period_start: @@ -36289,15 +35251,6 @@ components: reconciliation_export_out: type: object additionalProperties: false - required: - - id - - org_id - - file_id - - state - - query_params - - notify_emails - - created_at - - updated_at properties: id: allOf: @@ -36351,29 +35304,6 @@ components: spender_employee_settings_out: type: object additionalProperties: false - required: - - id - - employee_id - - org_id - - created_at - - updated_at - - category_ids - - cost_center_ids - - project_ids - - per_diem_rate_ids - - mileage_rate_ids - - insta_fyle_settings - - notification_settings - - mileage_settings - - expense_form_autofills - - data_extractor_settings - - in_app_chat_settings - - payment_mode_settings - - locale - - is_personal_cards_enabled - - default_project_id - - default_payment_mode - - default_vehicle_type properties: id: $ref: '#/components/schemas/id_string' @@ -36855,27 +35785,6 @@ components: dwolla_customer_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - customer_id - - customer_email - - customer_added_by - - is_customer_verified - - is_beneficial_owner_added - - is_beneficial_owner_verified - - is_bank_account_added - - is_bank_account_verified - - bank_account_added_by - - is_customer_document_needed - - is_beneficial_owner_document_needed - - is_customer_retry - - is_customer_suspended - - micro_deposit_verification_status - - micro_deposit_verification_attempts - - is_beneficial_owner_retry properties: id: allOf: @@ -36988,9 +35897,6 @@ components: dwolla_customer_in: type: object additionalProperties: false - required: - - customer_id - - customer_added_by properties: customer_id: type: string diff --git a/reference/approver.yaml b/reference/approver.yaml index a9e2078f5..1fa85bd52 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -169,8 +169,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_out' @@ -227,8 +225,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_out' @@ -334,8 +330,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_out' @@ -428,8 +422,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/reports_exports_out' @@ -506,8 +498,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/approver_expense_in' @@ -518,8 +508,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_out' @@ -561,8 +549,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/approver_expenses_bulk_in' @@ -573,8 +559,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -634,8 +618,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -689,8 +671,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_permissions_out' @@ -754,8 +734,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_permissions_bulk_out' @@ -837,8 +815,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_out' @@ -886,8 +862,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -975,8 +949,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -1032,8 +1004,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/reports_stats_out' @@ -1088,8 +1058,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_comments_out' @@ -1139,8 +1107,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_permissions_out' @@ -1194,8 +1160,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/report_out' @@ -1231,8 +1195,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/subscriptions_in' @@ -1244,8 +1206,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/approver_subscriptions_out' @@ -1406,8 +1366,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_requests_approver_stats_out' @@ -1463,8 +1421,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_permissions_out' @@ -1506,8 +1462,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_comments_in' @@ -1518,8 +1472,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_comments_out' @@ -2059,8 +2011,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_check_policies_bulk_out' @@ -2145,8 +2095,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_comments_bulk_in' @@ -2157,8 +2105,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -2312,8 +2258,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expenses_stats_out' @@ -2367,8 +2311,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -2456,8 +2398,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -2511,8 +2451,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expenses_exports_out' @@ -2548,8 +2486,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -2560,8 +2496,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -2608,8 +2542,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -2620,8 +2552,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -2667,8 +2597,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -2679,8 +2607,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -2740,8 +2666,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -2818,8 +2742,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -3116,8 +3038,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -3161,8 +3081,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_add_approver_in' @@ -3178,8 +3096,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3249,8 +3165,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3363,8 +3277,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3430,8 +3342,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3547,8 +3457,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -3731,8 +3639,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/employee_overview_stats_out' @@ -3864,8 +3770,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/employee_overview_expense_stats_out' @@ -4054,8 +3958,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expenses_export_configuration_out' @@ -4253,8 +4155,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/reports_export_configuration_out' @@ -4461,10 +4361,6 @@ components: user_out_embed: type: object additionalProperties: false - required: - - id - - email - - full_name properties: id: allOf: @@ -4492,12 +4388,6 @@ components: report_approval_out_embed: type: object additionalProperties: false - required: - - approver_user_id - - approver_type - - approver_user - - state - - approver_order properties: approver_user_id: allOf: @@ -4577,12 +4467,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - code - - name - - sub_department - - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -4659,24 +4543,6 @@ components: employee_out_embed_for_report: type: object additionalProperties: false - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - ach_account - - business_unit - - location - - title - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -4820,12 +4686,6 @@ components: reimbursement_out_minimal: type: object nullable: true - required: - - id - - currency - - amount - - mode - - ach_transfer properties: id: type: string @@ -4852,10 +4712,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - email - - full_name properties: id: allOf: @@ -4899,9 +4755,6 @@ components: advance_wallet_report_out: type: object additionalProperties: false - required: - - id - - amount properties: id: allOf: @@ -4940,15 +4793,6 @@ components: - reimbursement - comments - creator_type - - is_verified - - is_physical_bill_submitted - - physical_bill_submitted_at - - is_exported - - employee_id - - state_display_name - - accounting_export_summary - - applied_advance_wallets - - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -5470,10 +5314,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -5489,13 +5329,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - system_category - - name - - sub_category - - code - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -5527,12 +5360,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - sub_project - - code - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -5564,9 +5391,6 @@ components: example: sdfd2391 account_out_embed: type: object - required: - - id - - type properties: id: allOf: @@ -5586,11 +5410,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - vehicle_type - - code - - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -5608,10 +5427,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -5755,9 +5570,6 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num - - amount - - last_verified_at - - approvals properties: id: anyOf: @@ -5846,11 +5658,6 @@ components: List of report_approval objects file_out_embed: type: object - required: - - id - - name - - type - - content_type properties: id: allOf: @@ -5896,9 +5703,6 @@ components: expense_verification_out_embed: type: object additionalProperties: false - required: - - verifier_user_id - - verifier_user properties: verifier_user_id: allOf: @@ -5939,25 +5743,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - location - - title - - business_unit - - custom_fields - - flattened_custom_field - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -6072,24 +5857,6 @@ components: - id - corporate_card_id - corporate_card_number - - corporate_card_nickname - - corporate_card_cardholder_name - - capitalone_virtual_card_last_four - - masked_corporate_card_number - - bank_name - - corporate_card_user_full_name - - is_corporate_card_archived - - amount - - currency - - spent_at - - posted_at - - status - - description - - foreign_currency - - foreign_amount - - merchant - - category - - matched_by properties: id: allOf: @@ -6574,12 +6341,6 @@ components: example: 77.594566 commute_details: type: object - required: - - id - - distance - - distance_unit - - home_location - - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -6701,26 +6462,6 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments - - custom_fields_flattened - - approvals - - verifications - - employee_id - - split_group_amount - - expense_rule_id - - expense_rule_data - - is_split - - tax_group - - approver_comments - - verifier_comments - - policy_checks - - accounting_export_summary - - report_last_paid_at - - report_last_approved_at - - commute_deduction - - commute_details_id - - commute_details - - is_reconciled - - report_auto_approval_state properties: id: allOf: @@ -7814,8 +7555,6 @@ components: - $ref: '#/components/schemas/id_string' example: rpfilumWHrlPf7K reports_stats_in: - required: - - query_params properties: query_params: type: string @@ -8089,13 +7828,6 @@ components: approver_subscriptions_out: type: object additionalProperties: false - required: - - id - - is_enabled - - webhook_url - - updated_at - - created_at - - approver_user_id properties: id: $ref: '#/components/schemas/id_string' @@ -8152,12 +7884,6 @@ components: advance_out_embed: type: object nullable: true - required: - - id - - currency - - amount - - advance_request_id - - seq_num properties: id: type: string @@ -8238,10 +7964,6 @@ components: advance_request_approval_out_embed: type: object additionalProperties: false - required: - - approver_user_id - - approver_user - - state properties: approver_user_id: allOf: @@ -8262,11 +7984,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - code - - name - - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -8283,14 +8000,6 @@ components: employee_out_embed: type: object additionalProperties: false - required: - - id - - user_id - - user - - code - - org_id - - department_id - - department properties: id: $ref: '#/components/schemas/id_string' @@ -8324,17 +8033,6 @@ components: advance_request_comments_out: type: object additionalProperties: false - required: - - id - - comment - - action - - advance_request_id - - creator_type - - creator_user_id - - creator_user - - created_at - - updated_at - - org_id properties: id: $ref: '#/components/schemas/id_string' @@ -8578,18 +8276,6 @@ components: advance_request_permissions_out: type: object additionalProperties: false - required: - - can_save - - can_submit - - can_edit - - can_add_approver - - can_disable_approver - - can_reject - - can_approve - - can_inquire - - can_pull_back - - can_pay - - can_delete properties: can_save: type: boolean @@ -9116,12 +8802,6 @@ components: approver_merchant_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -9936,8 +9616,6 @@ components: description: | List of expense IDs that are part of the duplicate set expenses_stats_in: - required: - - query_params properties: query_params: nullable: false @@ -10195,17 +9873,6 @@ components: expenses_exports_out: type: object additionalProperties: false - required: - - created_at - - updated_at - - id - - org_id - - user_id - - query_params - - notify_emails - - config - - file_id - - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -10415,9 +10082,6 @@ components: expense_check_policies_out: type: object additionalProperties: false - required: - - individual_desired_states - - final_desired_state properties: individual_desired_states: type: array @@ -10470,17 +10134,6 @@ components: file_out: type: object additionalProperties: false - required: - - id - - org_id - - user_id - - created_at - - updated_at - - name - - type - - content_type - - download_url - - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -10528,12 +10181,6 @@ components: file_generate_urls_action_out: type: object additionalProperties: false - required: - - id - - name - - content_type - - download_url - - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -10585,10 +10232,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - vehicle_type - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -10999,17 +10642,6 @@ components: account_out: type: object additionalProperties: false - required: - - id - - created_at - - updated_at - - user_id - - type - - currency - - current_balance_amount - - tentative_balance_amount - - org_id - - category_id properties: id: allOf: @@ -11054,29 +10686,6 @@ components: spender_employee_settings_out: type: object additionalProperties: false - required: - - id - - employee_id - - org_id - - created_at - - updated_at - - category_ids - - cost_center_ids - - project_ids - - per_diem_rate_ids - - mileage_rate_ids - - insta_fyle_settings - - notification_settings - - mileage_settings - - expense_form_autofills - - data_extractor_settings - - in_app_chat_settings - - payment_mode_settings - - locale - - is_personal_cards_enabled - - default_project_id - - default_payment_mode - - default_vehicle_type properties: id: $ref: '#/components/schemas/id_string' @@ -11715,9 +11324,6 @@ components: employee_overview_stats_out: type: object additionalProperties: false - required: - - count - - total_amount properties: count: type: integer @@ -11730,9 +11336,6 @@ components: employee_overview_expense_stats_out: type: object additionalProperties: false - required: - - count - - total_amount properties: count: type: integer @@ -11875,8 +11478,6 @@ components: - type - org_id - user_id - - created_by - - updated_by properties: id: allOf: @@ -12114,8 +11715,6 @@ components: - type - org_id - user_id - - created_by - - updated_by properties: id: allOf: diff --git a/reference/common.yaml b/reference/common.yaml index e4ca01c8b..7cc7339e7 100644 --- a/reference/common.yaml +++ b/reference/common.yaml @@ -419,8 +419,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/logo_file_generate_download_url_action_out' @@ -495,9 +493,6 @@ components: example: 10 place_out_minimal: type: object - required: - - id - - formatted_address properties: id: type: string @@ -510,14 +505,6 @@ components: place_out: type: object additionalProperties: false - required: - - id - - city - - state - - country - - formatted_address - - latitude - - longitude properties: id: type: string @@ -544,8 +531,6 @@ components: example: 77.594566 exchange_rate_out: type: object - required: - - exchange_rate additionalProperties: false properties: exchange_rate: @@ -559,11 +544,6 @@ components: example: sdfd2391 logo_file_generate_download_url_action_out: type: object - required: - - id - - name - - content_type - - download_url additionalProperties: false properties: id: diff --git a/reference/hod.yaml b/reference/hod.yaml index d2371946e..2b7f7d1a7 100644 --- a/reference/hod.yaml +++ b/reference/hod.yaml @@ -155,12 +155,6 @@ components: budget_out_embed: type: object additionalProperties: false - required: - - id - - name - - type - - amount_limit - - is_enabled properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/hop.yaml b/reference/hop.yaml index 0403992ce..7a0d27b23 100644 --- a/reference/hop.yaml +++ b/reference/hop.yaml @@ -155,12 +155,6 @@ components: budget_out_embed: type: object additionalProperties: false - required: - - id - - name - - type - - amount_limit - - is_enabled properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/manager.yaml b/reference/manager.yaml index 2a2723ce3..1a85e2a87 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -114,8 +114,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -383,8 +381,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/employee_overview_stats_out' @@ -574,8 +570,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/employee_overview_expense_stats_out' @@ -717,10 +711,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - email - - full_name properties: id: allOf: @@ -832,12 +822,6 @@ components: file_generate_urls_action_out: type: object additionalProperties: false - required: - - id - - name - - content_type - - download_url - - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -1303,9 +1287,6 @@ components: employee_overview_stats_out: type: object additionalProperties: false - required: - - count - - total_amount properties: count: type: integer @@ -1325,10 +1306,6 @@ components: user_out_embed: type: object additionalProperties: false - required: - - id - - email - - full_name properties: id: allOf: @@ -1359,11 +1336,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - code - - name - - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -1536,12 +1508,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - sub_project - - code - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -1568,10 +1534,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -1587,10 +1549,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -1604,10 +1562,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - vehicle_type - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -1750,13 +1704,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - system_category - - name - - sub_category - - code - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -2086,9 +2033,6 @@ components: example: 1234 account_out_embed: type: object - required: - - id - - type properties: id: allOf: @@ -2108,11 +2052,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - vehicle_type - - code - - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -2188,12 +2127,6 @@ components: report_approval_out_embed: type: object additionalProperties: false - required: - - approver_user_id - - approver_type - - approver_user - - state - - approver_order properties: approver_user_id: allOf: @@ -2246,9 +2179,6 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num - - amount - - last_verified_at - - approvals properties: id: anyOf: @@ -2337,11 +2267,6 @@ components: List of report_approval objects file_out_embed: type: object - required: - - id - - name - - type - - content_type properties: id: allOf: @@ -2387,9 +2312,6 @@ components: expense_verification_out_embed: type: object additionalProperties: false - required: - - verifier_user_id - - verifier_user properties: verifier_user_id: allOf: @@ -2413,12 +2335,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - code - - name - - sub_department - - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -2441,25 +2357,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - location - - title - - business_unit - - custom_fields - - flattened_custom_field - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -2574,24 +2471,6 @@ components: - id - corporate_card_id - corporate_card_number - - corporate_card_nickname - - corporate_card_cardholder_name - - capitalone_virtual_card_last_four - - masked_corporate_card_number - - bank_name - - corporate_card_user_full_name - - is_corporate_card_archived - - amount - - currency - - spent_at - - posted_at - - status - - description - - foreign_currency - - foreign_amount - - merchant - - category - - matched_by properties: id: allOf: @@ -3076,12 +2955,6 @@ components: example: 77.594566 commute_details: type: object - required: - - id - - distance - - distance_unit - - home_location - - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -3203,26 +3076,6 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments - - custom_fields_flattened - - approvals - - verifications - - employee_id - - split_group_amount - - expense_rule_id - - expense_rule_data - - is_split - - tax_group - - approver_comments - - verifier_comments - - policy_checks - - accounting_export_summary - - report_last_paid_at - - report_last_approved_at - - commute_deduction - - commute_details_id - - commute_details - - is_reconciled - - report_auto_approval_state properties: id: allOf: @@ -3769,8 +3622,6 @@ components: - AUTO_APPROVED - null expenses_stats_in: - required: - - query_params properties: query_params: nullable: false @@ -3781,9 +3632,6 @@ components: employee_overview_expense_stats_out: type: object additionalProperties: false - required: - - count - - total_amount properties: count: type: integer diff --git a/reference/spender.yaml b/reference/spender.yaml index 253190550..414f89946 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -685,8 +685,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/spender_expenses_bulk_in' @@ -697,8 +695,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -810,8 +806,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_out' @@ -861,8 +855,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_out' @@ -914,8 +906,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -981,8 +971,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -1036,8 +1024,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_permissions_out' @@ -1101,8 +1087,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_permissions_bulk_out' @@ -1257,8 +1241,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/subscriptions_in' @@ -1270,8 +1252,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/spender_subscriptions_out' @@ -1380,8 +1360,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/schedule_out' @@ -1623,8 +1601,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_out' @@ -1675,8 +1651,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_out' @@ -1725,8 +1699,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_out' @@ -1775,8 +1747,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_out' @@ -1826,8 +1796,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/reports_stats_out' @@ -1882,8 +1850,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_purpose_out' @@ -1931,8 +1897,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -1994,7 +1958,7 @@ paths: application/json: schema: $ref: '#/components/schemas/401' - /spender/reports/filters/delete: + /spender/reports/filters/delte: post: tags: - Reports @@ -2020,8 +1984,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -2076,8 +2038,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_comments_out' @@ -2127,8 +2087,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/report_permissions_out' @@ -2221,8 +2179,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/reports_exports_out' @@ -2317,8 +2273,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -2374,8 +2328,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_requests_stats_out' @@ -2477,8 +2429,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advances_stats_out' @@ -2699,8 +2649,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -2755,8 +2703,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_mark_personal_out' @@ -2810,8 +2756,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmark_personal_out' @@ -2865,8 +2809,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_ignore_out' @@ -2920,8 +2862,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_undo_ignore_out' @@ -2975,8 +2915,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_match_out' @@ -3030,8 +2968,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmatch_out' @@ -3127,8 +3063,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/spender_employee_out' @@ -3811,8 +3745,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/virtual_cards_get_current_balance_out' @@ -3867,8 +3799,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/virtual_cards_show_card_details_out' @@ -3965,8 +3895,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/file_out' @@ -4024,8 +3952,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -4097,8 +4023,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/file_generate_urls_action_out' @@ -4155,8 +4079,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -4326,8 +4248,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/file_out_download_url' @@ -4534,8 +4454,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_check_policies_out' @@ -4587,8 +4505,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expense_check_policies_bulk_out' @@ -4688,8 +4604,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/recurring_expense_out' @@ -4793,8 +4707,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/recurring_expense_out' @@ -5015,8 +4927,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_comments_bulk_in' @@ -5027,8 +4937,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -5182,8 +5090,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/expenses_stats_out' @@ -5237,8 +5143,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -5326,8 +5230,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -5381,8 +5283,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expenses_exports_out' @@ -5418,8 +5318,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/spender_split_expense_in' @@ -5430,8 +5328,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -5478,8 +5374,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/spender_split_expense_in' @@ -5490,8 +5384,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -5537,8 +5429,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/spender_split_expense_in' @@ -5549,8 +5439,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: type: array @@ -5594,8 +5482,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expenses_merge_in' @@ -5606,8 +5492,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expense_out' @@ -5752,8 +5636,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -6259,8 +6141,6 @@ paths: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: @@ -6432,8 +6312,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -6508,8 +6386,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -6575,8 +6451,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_permissions_out' @@ -6635,8 +6509,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -6699,8 +6571,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: array @@ -6744,8 +6614,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_comments_in' @@ -6756,8 +6624,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/advance_request_comments_out' @@ -6905,8 +6771,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '#/components/schemas/secondary_email_out' @@ -6966,8 +6830,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -7031,8 +6893,6 @@ paths: schema: type: object additionalProperties: false - required: - - data properties: data: type: object @@ -7347,8 +7207,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/expenses_export_configuration_out' @@ -7546,8 +7404,6 @@ paths: application/json: schema: type: object - required: - - data properties: data: $ref: '#/components/schemas/reports_export_configuration_out' @@ -8232,25 +8088,6 @@ components: expense_field_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - seq - - field_name - - column_name - - type - - options - - default_value - - placeholder - - category_ids - - is_enabled - - is_custom - - is_mandatory - - code - - parent_field_id - - display_order properties: id: $ref: '#/components/schemas/id_integer' @@ -8331,16 +8168,6 @@ components: dependent_expense_field_values_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - parent_expense_field_id - - expense_field_id - - parent_expense_field_value - - expense_field_value - - is_enabled properties: id: $ref: '#/components/schemas/id_integer' @@ -8441,11 +8268,6 @@ components: org_out_embed: type: object additionalProperties: false - required: - - id - - name - - domain - - currency properties: id: $ref: '#/components/schemas/org_id' @@ -8471,10 +8293,6 @@ components: user_out_embed: type: object additionalProperties: false - required: - - id - - email - - full_name properties: id: allOf: @@ -8510,12 +8328,6 @@ components: my_profile_out: type: object additionalProperties: false - required: - - user_id - - org_id - - org - - user - - roles properties: user_id: $ref: '#/components/schemas/user_id' @@ -8615,17 +8427,6 @@ components: account_out: type: object additionalProperties: false - required: - - id - - created_at - - updated_at - - user_id - - type - - currency - - current_balance_amount - - tentative_balance_amount - - org_id - - category_id properties: id: allOf: @@ -8770,10 +8571,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -8789,13 +8586,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - system_category - - name - - sub_category - - code - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -8827,12 +8617,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - sub_project - - code - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -8864,9 +8648,6 @@ components: example: sdfd2391 account_out_embed: type: object - required: - - id - - type properties: id: allOf: @@ -8886,11 +8667,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - vehicle_type - - code - - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -8908,10 +8684,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - name - - code properties: id: $ref: '#/components/schemas/id_integer' @@ -9047,12 +8819,6 @@ components: report_approval_out_embed: type: object additionalProperties: false - required: - - approver_user_id - - approver_type - - approver_user - - state - - approver_order properties: approver_user_id: allOf: @@ -9105,9 +8871,6 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num - - amount - - last_verified_at - - approvals properties: id: anyOf: @@ -9196,11 +8959,6 @@ components: List of report_approval objects file_out_embed: type: object - required: - - id - - name - - type - - content_type properties: id: allOf: @@ -9246,9 +9004,6 @@ components: expense_verification_out_embed: type: object additionalProperties: false - required: - - verifier_user_id - - verifier_user properties: verifier_user_id: allOf: @@ -9278,12 +9033,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - code - - name - - sub_department - - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -9376,25 +9125,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - location - - title - - business_unit - - custom_fields - - flattened_custom_field - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -9509,24 +9239,6 @@ components: - id - corporate_card_id - corporate_card_number - - corporate_card_nickname - - corporate_card_cardholder_name - - capitalone_virtual_card_last_four - - masked_corporate_card_number - - bank_name - - corporate_card_user_full_name - - is_corporate_card_archived - - amount - - currency - - spent_at - - posted_at - - status - - description - - foreign_currency - - foreign_amount - - merchant - - category - - matched_by properties: id: allOf: @@ -10011,12 +9723,6 @@ components: example: 77.594566 commute_details: type: object - required: - - id - - distance - - distance_unit - - home_location - - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -10138,26 +9844,6 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments - - custom_fields_flattened - - approvals - - verifications - - employee_id - - split_group_amount - - expense_rule_id - - expense_rule_data - - is_split - - tax_group - - approver_comments - - verifier_comments - - policy_checks - - accounting_export_summary - - report_last_paid_at - - report_last_approved_at - - commute_deduction - - commute_details_id - - commute_details - - is_reconciled - - report_auto_approval_state properties: id: allOf: @@ -11288,11 +10974,6 @@ components: merchant_out: type: object additionalProperties: false - required: - - id - - created_at - - updated_at - - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -11313,13 +10994,6 @@ components: spender_subscriptions_out: type: object additionalProperties: false - required: - - id - - is_enabled - - webhook_url - - updated_at - - created_at - - user_id properties: id: $ref: '#/components/schemas/id_string' @@ -11347,24 +11021,6 @@ components: employee_out_embed_for_report: type: object additionalProperties: false - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - ach_account - - business_unit - - location - - title - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -11508,12 +11164,6 @@ components: reimbursement_out_minimal: type: object nullable: true - required: - - id - - currency - - amount - - mode - - ach_transfer properties: id: type: string @@ -11540,10 +11190,6 @@ components: type: object nullable: true additionalProperties: false - required: - - id - - email - - full_name properties: id: allOf: @@ -11587,9 +11233,6 @@ components: advance_wallet_report_out: type: object additionalProperties: false - required: - - id - - amount properties: id: allOf: @@ -11628,15 +11271,6 @@ components: - reimbursement - comments - creator_type - - is_verified - - is_physical_bill_submitted - - physical_bill_submitted_at - - is_exported - - employee_id - - state_display_name - - accounting_export_summary - - applied_advance_wallets - - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -11982,14 +11616,6 @@ components: schedule_out: type: object additionalProperties: false - required: - - id - - created_at - - updated_at - - config - - org_id - - user_id - - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -12137,8 +11763,6 @@ components: id of report, which needs to be resubmitted example: rpa21A2rdj2 reports_stats_in: - required: - - query_params properties: query_params: type: string @@ -12700,12 +12324,6 @@ components: advance_out_embed: type: object nullable: true - required: - - id - - currency - - amount - - advance_request_id - - seq_num properties: id: type: string @@ -12786,10 +12404,6 @@ components: advance_request_approval_out_embed: type: object additionalProperties: false - required: - - approver_user_id - - approver_user - - state properties: approver_user_id: allOf: @@ -12810,11 +12424,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - code - - name - - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -12831,14 +12440,6 @@ components: employee_out_embed: type: object additionalProperties: false - required: - - id - - user_id - - user - - code - - org_id - - department_id - - department properties: id: $ref: '#/components/schemas/id_string' @@ -12872,17 +12473,6 @@ components: advance_request_comments_out: type: object additionalProperties: false - required: - - id - - comment - - action - - advance_request_id - - creator_type - - creator_user_id - - creator_user - - created_at - - updated_at - - org_id properties: id: $ref: '#/components/schemas/id_string' @@ -13102,8 +12692,6 @@ components: - currency - amount advance_requests_stats_in: - required: - - query_params properties: query_params: description: | @@ -13189,10 +12777,6 @@ components: advance_request_out_embed: type: object nullable: true - required: - - id - - last_approved_at - - seq_num properties: id: type: string @@ -13353,8 +12937,6 @@ components: creator_user: $ref: '#/components/schemas/user_out_embed_nullable' advances_stats_in: - required: - - query_params properties: query_params: type: string @@ -13364,9 +12946,6 @@ components: example: id=in.('adv1263', 'adv1569') advances_stats_out: type: object - required: - - count - - total_amount properties: count: type: integer @@ -13693,9 +13272,6 @@ components: - yodlee_fastlink_params - created_at - updated_at - - org_id - - user_id - - corporate_card_id string_detail: type: string description: Additional string details of the card transaction. Can hold details upto 256 characters in length. @@ -13704,16 +13280,6 @@ components: corporate_card_out_embed: type: object additionalProperties: false - required: - - id - - bank_name - - card_number - - nickname - - cardholder_name - - masked_number - - user_full_name - - user_email - - is_archived properties: id: allOf: @@ -14187,8 +13753,6 @@ components: - capitalone_virtual_card_last_four corporate_card_transactions_expenses_stats_in: type: object - required: - - query_params properties: query_params: type: string @@ -14481,8 +14045,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - mcc - - is_exported corporate_card_transaction_unmark_personal_out: type: object properties: @@ -14691,8 +14253,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - mcc - - is_exported corporate_card_transaction_ignore_out: type: object properties: @@ -14907,9 +14467,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - capitalone_virtual_card_last_four - - mcc - - is_exported corporate_card_transaction_undo_ignore_out: type: object additionalProperties: false @@ -15139,10 +14696,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - transaction_status - - capitalone_virtual_card_last_four - - mcc - - bank_transaction_number corporate_card_transaction_match_in: type: object properties: @@ -15374,9 +14927,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - capitalone_virtual_card_last_four - - mcc - - is_exported corporate_card_transaction_unmatch_in: type: object properties: @@ -15620,11 +15170,6 @@ components: - matched_expenses - last_user_matched_at - metadata - - transaction_status - - capitalone_virtual_card_last_four - - mcc - - bank_transaction_number - - is_exported user_full_name: type: string maxLength: 255 @@ -15693,19 +15238,6 @@ components: spender_employee_out: type: object additionalProperties: false - required: - - id - - user_id - - email - - full_name - - roles - - commute_details - - mobile - - is_mobile_verified - - sms_opt_out_source - - is_enabled - - has_accepted_invite - - delegatees properties: id: $ref: '#/components/schemas/id_string' @@ -15830,44 +15362,6 @@ components: spender_employee_current_out: type: object additionalProperties: false - required: - - id - - org_id - - user_id - - created_at - - updated_at - - user - - code - - joined_at - - title - - business_unit - - special_email - - roles - - location - - is_enabled - - has_accepted_invite - - branch_account - - branch_ifsc - - department_id - - department - - level_id - - level - - mobile - - is_mobile_verified - - mobile_verification_attempts_left - - mobile_verification_attempted_at - - org_name - - currency - - approver_user_ids - - approver_users - - locale - - delegatees - - mileage_settings - - custom_fields - - flattened_custom_field - - commute_details_id - - commute_details - - is_primary properties: id: $ref: '#/components/schemas/id_string' @@ -16095,19 +15589,6 @@ components: spender_commute_details_out: type: object additionalProperties: false - required: - - id - - user_id - - email - - full_name - - roles - - commute_details - - mobile - - is_mobile_verified - - sms_opt_out_source - - is_enabled - - has_accepted_invite - - delegatees properties: id: $ref: '#/components/schemas/id_string' @@ -16165,11 +15646,6 @@ components: spender_delegatees_post_in: type: object additionalProperties: false - required: - - delegatee_user_id - - start_at - - end_at - - scopes properties: delegatee_user_id: $ref: '#/components/schemas/fk_string' @@ -16192,19 +15668,6 @@ components: spender_delegatees_post_out: type: object additionalProperties: false - required: - - id - - user_id - - email - - full_name - - roles - - commute_details - - mobile - - is_mobile_verified - - sms_opt_out_source - - is_enabled - - has_accepted_invite - - delegatees properties: id: $ref: '#/components/schemas/id_string' @@ -16262,10 +15725,6 @@ components: spender_delegators_out: type: object additionalProperties: false - required: - - user_id - - email - - full_name properties: user_id: $ref: '#/components/schemas/user_id' @@ -16280,13 +15739,6 @@ components: spender_delegatees_delete_out: type: object additionalProperties: false - required: - - id - - org_id - - delegator_user_id - - delegatee_user_id - - start_date - - end_date properties: id: $ref: '#/components/schemas/id_integer' @@ -16310,12 +15762,6 @@ components: $ref: '#/components/schemas/timestamptz_utc' employees_send_mobile_verification_code_post_out: type: object - required: - - to - - channel - - status - - date_created - - attempts_left additionalProperties: false properties: to: @@ -16333,6 +15779,11 @@ components: description: | Current status of the verification attempt example: pending + valid: + type: boolean + description: | + Whether the verification is valid + example: false date_created: type: string format: date-time @@ -16365,29 +15816,6 @@ components: spender_employee_settings_out: type: object additionalProperties: false - required: - - id - - employee_id - - org_id - - created_at - - updated_at - - category_ids - - cost_center_ids - - project_ids - - per_diem_rate_ids - - mileage_rate_ids - - insta_fyle_settings - - notification_settings - - mileage_settings - - expense_form_autofills - - data_extractor_settings - - in_app_chat_settings - - payment_mode_settings - - locale - - is_personal_cards_enabled - - default_project_id - - default_payment_mode - - default_vehicle_type properties: id: $ref: '#/components/schemas/id_string' @@ -17077,17 +16505,6 @@ components: file_out: type: object additionalProperties: false - required: - - id - - org_id - - user_id - - created_at - - updated_at - - name - - type - - content_type - - download_url - - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -17135,12 +16552,6 @@ components: file_generate_urls_action_out: type: object additionalProperties: false - required: - - id - - name - - content_type - - download_url - - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -17172,11 +16583,6 @@ components: file_out_download_url: type: object additionalProperties: false - required: - - id - - name - - content_type - - download_url properties: id: $ref: '#/components/schemas/id_string' @@ -17321,9 +16727,6 @@ components: - action_add_department_head_approver - action_add_approver_user_ids - action_override_distance_slab_rate - - expense_merchants - - expense_merchants_op - - policy_violation_reason_required properties: id: allOf: @@ -18335,9 +17738,6 @@ components: expense_check_policies_out: type: object additionalProperties: false - required: - - individual_desired_states - - final_desired_state properties: individual_desired_states: type: array @@ -18487,8 +17887,6 @@ components: - expense_details - schedule_config - is_enabled - - created_at - - updated_at properties: id: allOf: @@ -18511,8 +17909,8 @@ components: - MILEAGE: Mileage-based expense type example: EXPENSE expense_details: - allOf: - - $ref: '#/components/schemas/spender_expense_in' + type: object + nullable: false description: | Expense template details used for creating recurring expenses. Contains all the expense fields that will be applied to each generated expense. @@ -18890,8 +18288,6 @@ components: description: | List of expense IDs that are part of the duplicate set expenses_stats_in: - required: - - query_params properties: query_params: nullable: false @@ -19149,17 +18545,6 @@ components: expenses_exports_out: type: object additionalProperties: false - required: - - created_at - - updated_at - - id - - org_id - - user_id - - query_params - - notify_emails - - config - - file_id - - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -19503,17 +18888,6 @@ components: feature_config_out: type: object additionalProperties: false - required: - - org_id - - user_id - - created_at - - updated_at - - target_client - - feature - - sub_feature - - key - - value - - is_shared properties: org_id: $ref: '#/components/schemas/org_id' @@ -19718,23 +19092,6 @@ components: personal_card_delete_out: type: object additionalProperties: false - required: - - id - - org_id - - user_id - - currency - - bank_name - - card_number - - account_type - - yodlee_account_id - - yodlee_fastlink_params - - yodlee_is_credential_update_required - - yodlee_is_mfa_required - - yodlee_last_synced_at - - yodlee_login_id - - yodlee_provider_account_id - - created_at - - updated_at properties: id: $ref: '#/components/schemas/id_string' @@ -19799,8 +19156,6 @@ components: $ref: '#/components/schemas/updated_at' personal_card_access_token_out: type: object - required: - - access_token properties: access_token: type: string @@ -19819,8 +19174,6 @@ components: example: baccymJEDziL9Y personal_card_mfa_out: type: object - required: - - is_mfa_enabled properties: is_mfa_enabled: type: boolean @@ -19830,25 +19183,6 @@ components: description: Determines wether the user card has MFA enabled or not personal_card_transaction_out: type: object - required: - - id - - org_id - - user_id - - personal_card_id - - amount - - currency - - spent_at - - category - - merchant - - state - - description - - external_transaction_id - - matched_expense_ids - - created_at - - updated_at - - foreign_amount - - foreign_currency - - matched_expenses additionalProperties: false properties: id: @@ -19932,25 +19266,6 @@ components: type: object additionalProperties: false nullable: true - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - location - - title - - business_unit - - custom_fields - - flattened_custom_field - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: '#/components/schemas/id_string' @@ -20042,10 +19357,6 @@ components: example: personal_card_id=eq.bacctW9DfNhwOt&state=eq.HIDDEN personal_card_transactions_stats_out: type: object - required: - - count - - debit_amount - - credit_amount properties: count: type: integer @@ -20068,15 +19379,6 @@ components: get_spender_orgs_out: type: object additionalProperties: false - required: - - id - - name - - domain - - currency - - created_at - - updated_at - - is_current - - is_primary properties: id: $ref: '#/components/schemas/org_id' @@ -20105,9 +19407,6 @@ components: spender_org_bank_details_out: type: object additionalProperties: false - required: - - org_id - - is_bank_account_added properties: org_id: $ref: '#/components/schemas/org_id' @@ -20135,18 +19434,6 @@ components: advance_request_permissions_out: type: object additionalProperties: false - required: - - can_save - - can_submit - - can_edit - - can_add_approver - - can_disable_approver - - can_reject - - can_approve - - can_inquire - - can_pull_back - - can_pay - - can_delete properties: can_save: type: boolean @@ -20209,7 +19496,6 @@ components: description: | Comment explaining the reason for pulling back the advance request example: sending back - nullable: true attach_files_to_advance_request_in: type: object required: @@ -20253,14 +19539,6 @@ components: example: adrkvnwrnpwi secondary_email_out: type: object - required: - - id - - email - - is_verified - - org_id - - user_id - - created_at - - updated_at additionalProperties: false properties: id: @@ -20388,28 +19666,6 @@ components: spender_dwolla_customer_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - customer_id - - customer_email - - customer_added_by - - is_customer_verified - - is_beneficial_owner_added - - is_beneficial_owner_verified - - is_bank_account_added - - is_bank_account_verified - - bank_account_added_by - - is_customer_document_needed - - is_beneficial_owner_document_needed - - is_customer_retry - - is_customer_suspended - - micro_deposit_verification_status - - micro_deposit_verification_attempts - - is_beneficial_owner_retry - - is_org_customer_verified properties: id: type: string @@ -20551,9 +19807,6 @@ components: dwolla_customer_in: type: object additionalProperties: false - required: - - customer_id - - customer_added_by properties: customer_id: type: string @@ -20656,27 +19909,6 @@ components: dwolla_customer_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - customer_id - - customer_email - - customer_added_by - - is_customer_verified - - is_beneficial_owner_added - - is_beneficial_owner_verified - - is_bank_account_added - - is_bank_account_verified - - bank_account_added_by - - is_customer_document_needed - - is_beneficial_owner_document_needed - - is_customer_retry - - is_customer_suspended - - micro_deposit_verification_status - - micro_deposit_verification_attempts - - is_beneficial_owner_retry properties: id: allOf: @@ -20919,8 +20151,6 @@ components: - type - org_id - user_id - - created_by - - updated_by properties: id: allOf: @@ -21158,8 +20388,6 @@ components: - type - org_id - user_id - - created_by - - updated_by properties: id: allOf: @@ -21287,13 +20515,6 @@ components: mobile_app_version_out: type: object additionalProperties: false - required: - - id - - user_id - - version - - os - - created_at - - updated_at properties: id: type: string diff --git a/src/admin/paths/admin@accounting_export_lineitems.yaml b/src/admin/paths/admin@accounting_export_lineitems.yaml index dfb06f7d5..0e3d3c7cb 100644 --- a/src/admin/paths/admin@accounting_export_lineitems.yaml +++ b/src/admin/paths/admin@accounting_export_lineitems.yaml @@ -65,8 +65,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/accounting_export_lineitem.yaml#/accounting_export_lineitem_out diff --git a/src/admin/paths/admin@accounting_exports.yaml b/src/admin/paths/admin@accounting_exports.yaml index b65f01698..125fbb7c4 100644 --- a/src/admin/paths/admin@accounting_exports.yaml +++ b/src/admin/paths/admin@accounting_exports.yaml @@ -65,8 +65,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/accounting_export.yaml#/accounting_export_out diff --git a/src/admin/paths/admin@accounts.yaml b/src/admin/paths/admin@accounts.yaml index 39ddc6b8e..93ef0e4b0 100644 --- a/src/admin/paths/admin@accounts.yaml +++ b/src/admin/paths/admin@accounts.yaml @@ -65,8 +65,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/account.yaml#/account_out' diff --git a/src/admin/paths/admin@advance_refunds.yaml b/src/admin/paths/admin@advance_refunds.yaml index f1508b5b8..82ceaf581 100644 --- a/src/admin/paths/admin@advance_refunds.yaml +++ b/src/admin/paths/admin@advance_refunds.yaml @@ -70,8 +70,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_refund.yaml#/advance_refund_out' diff --git a/src/admin/paths/admin@advance_refunds@stats.yaml b/src/admin/paths/admin@advance_refunds@stats.yaml index be42f477c..7c0f8062c 100644 --- a/src/admin/paths/admin@advance_refunds@stats.yaml +++ b/src/admin/paths/admin@advance_refunds@stats.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@advance_requests.yaml b/src/admin/paths/admin@advance_requests.yaml index 6b447d513..8bed4709e 100644 --- a/src/admin/paths/admin@advance_requests.yaml +++ b/src/admin/paths/admin@advance_requests.yaml @@ -70,8 +70,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@add_approver.yaml b/src/admin/paths/admin@advance_requests@add_approver.yaml index 1128508d7..56de6b4b5 100644 --- a/src/admin/paths/admin@advance_requests@add_approver.yaml +++ b/src/admin/paths/admin@advance_requests@add_approver.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_add_approver_in' @@ -28,8 +26,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml b/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml index 8da910c34..14065e4b1 100644 --- a/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml +++ b/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@advance_requests@comments.yaml b/src/admin/paths/admin@advance_requests@comments.yaml index c4d14ca36..4bac5d7f9 100644 --- a/src/admin/paths/admin@advance_requests@comments.yaml +++ b/src/admin/paths/admin@advance_requests@comments.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_out' diff --git a/src/admin/paths/admin@advance_requests@custom_fields.yaml b/src/admin/paths/admin@advance_requests@custom_fields.yaml index cac7f388f..1f43da81b 100644 --- a/src/admin/paths/admin@advance_requests@custom_fields.yaml +++ b/src/admin/paths/admin@advance_requests@custom_fields.yaml @@ -66,8 +66,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_custom_field_out' diff --git a/src/admin/paths/admin@advance_requests@inquire.yaml b/src/admin/paths/admin@advance_requests@inquire.yaml index 939704db3..7edb2e29b 100644 --- a/src/admin/paths/admin@advance_requests@inquire.yaml +++ b/src/admin/paths/admin@advance_requests@inquire.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@permissions.yaml b/src/admin/paths/admin@advance_requests@permissions.yaml index 8f5d4031b..744da3b9f 100644 --- a/src/admin/paths/admin@advance_requests@permissions.yaml +++ b/src/admin/paths/admin@advance_requests@permissions.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_permissions_out' diff --git a/src/admin/paths/admin@advance_requests@reject.yaml b/src/admin/paths/admin@advance_requests@reject.yaml index 4ef47efba..b3e8c6577 100644 --- a/src/admin/paths/admin@advance_requests@reject.yaml +++ b/src/admin/paths/admin@advance_requests@reject.yaml @@ -29,8 +29,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@remove_approver.yaml b/src/admin/paths/admin@advance_requests@remove_approver.yaml index 749d58844..916bb571e 100644 --- a/src/admin/paths/admin@advance_requests@remove_approver.yaml +++ b/src/admin/paths/admin@advance_requests@remove_approver.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_remove_approver_in' @@ -27,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@stats.yaml b/src/admin/paths/admin@advance_requests@stats.yaml index 34b7bc4fe..f8899cb51 100644 --- a/src/admin/paths/admin@advance_requests@stats.yaml +++ b/src/admin/paths/admin@advance_requests@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_requests_stats_out' diff --git a/src/admin/paths/admin@advance_requests@submit.yaml b/src/admin/paths/admin@advance_requests@submit.yaml index 287fae1b2..f511c601e 100644 --- a/src/admin/paths/admin@advance_requests@submit.yaml +++ b/src/admin/paths/admin@advance_requests@submit.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_wallets.yaml b/src/admin/paths/admin@advance_wallets.yaml index 9dd1379ea..99ef3be7a 100644 --- a/src/admin/paths/admin@advance_wallets.yaml +++ b/src/admin/paths/admin@advance_wallets.yaml @@ -70,8 +70,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_wallet.yaml#/advance_wallet_out' diff --git a/src/admin/paths/admin@advances.yaml b/src/admin/paths/admin@advances.yaml index b9d19a5b7..eb7ce5a16 100644 --- a/src/admin/paths/admin@advances.yaml +++ b/src/admin/paths/admin@advances.yaml @@ -70,8 +70,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance.yaml#/advance_out' diff --git a/src/admin/paths/admin@advances@stats.yaml b/src/admin/paths/admin@advances@stats.yaml index 2e99a08d2..54003447c 100644 --- a/src/admin/paths/admin@advances@stats.yaml +++ b/src/admin/paths/admin@advances@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance.yaml#/advances_stats_out' diff --git a/src/admin/paths/admin@automations@report_submissions.yaml b/src/admin/paths/admin@automations@report_submissions.yaml index 20d28a5d3..c860d8292 100644 --- a/src/admin/paths/admin@automations@report_submissions.yaml +++ b/src/admin/paths/admin@automations@report_submissions.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/automation.yaml#/automate_report_submission_out diff --git a/src/admin/paths/admin@automations@report_submissions@delete.yaml b/src/admin/paths/admin@automations@report_submissions@delete.yaml index 6e4787d82..6f363fe20 100644 --- a/src/admin/paths/admin@automations@report_submissions@delete.yaml +++ b/src/admin/paths/admin@automations@report_submissions@delete.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/automation.yaml#/automate_report_submission_out diff --git a/src/admin/paths/admin@budgets.yaml b/src/admin/paths/admin@budgets.yaml index 25c99f06b..43e606171 100644 --- a/src/admin/paths/admin@budgets.yaml +++ b/src/admin/paths/admin@budgets.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/budget.yaml#/budget_post_out diff --git a/src/admin/paths/admin@budgets@exports.yaml b/src/admin/paths/admin@budgets@exports.yaml index 771917194..a130c8ba3 100644 --- a/src/admin/paths/admin@budgets@exports.yaml +++ b/src/admin/paths/admin@budgets@exports.yaml @@ -25,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/budget_exports.yaml#/budget_exports_out' diff --git a/src/admin/paths/admin@categories.yaml b/src/admin/paths/admin@categories.yaml index b83f6e782..ba8839075 100644 --- a/src/admin/paths/admin@categories.yaml +++ b/src/admin/paths/admin@categories.yaml @@ -65,8 +65,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/category.yaml#/admin_approver_category_out diff --git a/src/admin/paths/admin@categories@system_categories.yaml b/src/admin/paths/admin@categories@system_categories.yaml index 701ced45b..cfbc62464 100644 --- a/src/admin/paths/admin@categories@system_categories.yaml +++ b/src/admin/paths/admin@categories@system_categories.yaml @@ -15,7 +15,6 @@ get: additionalProperties: False required: - data - - count properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@corporate_card_transactions.yaml b/src/admin/paths/admin@corporate_card_transactions.yaml index 3c075f769..7232506a6 100644 --- a/src/admin/paths/admin@corporate_card_transactions.yaml +++ b/src/admin/paths/admin@corporate_card_transactions.yaml @@ -69,8 +69,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_post_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@assign.yaml b/src/admin/paths/admin@corporate_card_transactions@assign.yaml index 164cf9037..a4c225645 100644 --- a/src/admin/paths/admin@corporate_card_transactions@assign.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@assign.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_assign_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@delete.yaml b/src/admin/paths/admin@corporate_card_transactions@delete.yaml index 07939d246..61b423a22 100644 --- a/src/admin/paths/admin@corporate_card_transactions@delete.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@delete.yaml @@ -26,8 +26,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml b/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml index 7bfa398ce..8f4c16436 100644 --- a/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml @@ -26,8 +26,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml b/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml index 7213a20b8..9386ab470 100644 --- a/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml @@ -161,8 +161,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transactions_export_configurations.yaml#/corporate_card_transactions_export_configuration_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@exports.yaml b/src/admin/paths/admin@corporate_card_transactions@exports.yaml index 1adce438e..a0600ae9b 100644 --- a/src/admin/paths/admin@corporate_card_transactions@exports.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@exports.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transactions_exports.yaml#/corporate_card_transactions_exports_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@filters.yaml b/src/admin/paths/admin@corporate_card_transactions@filters.yaml index 8034539b3..556a241ac 100644 --- a/src/admin/paths/admin@corporate_card_transactions@filters.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@filters.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction_filters.yaml#/corporate_card_transaction_filters_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml b/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml index 2666a271b..b3e617efb 100644 --- a/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction_filters.yaml#/corporate_card_transaction_filters_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@ignore.yaml b/src/admin/paths/admin@corporate_card_transactions@ignore.yaml index 2a34f0ea2..af8d658dd 100644 --- a/src/admin/paths/admin@corporate_card_transactions@ignore.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@ignore.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_ignore_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml b/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml index a689b154c..8105cd9de 100644 --- a/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_mark_personal_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@match.yaml b/src/admin/paths/admin@corporate_card_transactions@match.yaml index 7cbe00818..4c60ece64 100644 --- a/src/admin/paths/admin@corporate_card_transactions@match.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@match.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_match_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@stats.yaml b/src/admin/paths/admin@corporate_card_transactions@stats.yaml index 3c19e125e..fc87585f1 100644 --- a/src/admin/paths/admin@corporate_card_transactions@stats.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@stats.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@corporate_card_transactions@unassign.yaml b/src/admin/paths/admin@corporate_card_transactions@unassign.yaml index bc01a9857..3bab0bb07 100644 --- a/src/admin/paths/admin@corporate_card_transactions@unassign.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@unassign.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unassign_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml b/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml index 5f28cd2e5..fec689502 100644 --- a/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_undo_ignore_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml b/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml index 91bebf4fe..b68b9b0a8 100644 --- a/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmark_personal_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml b/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml index 7677284cd..a5f3244d4 100644 --- a/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmatch_out' diff --git a/src/admin/paths/admin@corporate_cards.yaml b/src/admin/paths/admin@corporate_cards.yaml index 7544044b4..86bdc40b0 100644 --- a/src/admin/paths/admin@corporate_cards.yaml +++ b/src/admin/paths/admin@corporate_cards.yaml @@ -69,8 +69,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@archive.yaml b/src/admin/paths/admin@corporate_cards@archive.yaml index 63b51ae9f..704fde701 100644 --- a/src/admin/paths/admin@corporate_cards@archive.yaml +++ b/src/admin/paths/admin@corporate_cards@archive.yaml @@ -25,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml b/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml index 67621dd1d..e52b39b20 100644 --- a/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml +++ b/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_archive_suggestion_out' diff --git a/src/admin/paths/admin@corporate_cards@assign.yaml b/src/admin/paths/admin@corporate_cards@assign.yaml index 36a0d7256..ff739e803 100644 --- a/src/admin/paths/admin@corporate_cards@assign.yaml +++ b/src/admin/paths/admin@corporate_cards@assign.yaml @@ -25,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@bank_names.yaml b/src/admin/paths/admin@corporate_cards@bank_names.yaml index feed534db..5d09c4458 100644 --- a/src/admin/paths/admin@corporate_cards@bank_names.yaml +++ b/src/admin/paths/admin@corporate_cards@bank_names.yaml @@ -17,8 +17,6 @@ get: properties: data: type: object - required: - - bank_names properties: bank_names: type: array diff --git a/src/admin/paths/admin@corporate_cards@delete.yaml b/src/admin/paths/admin@corporate_cards@delete.yaml index e562ea251..aad46e8e8 100644 --- a/src/admin/paths/admin@corporate_cards@delete.yaml +++ b/src/admin/paths/admin@corporate_cards@delete.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml b/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml index e53b58c97..88ed5f0b2 100644 --- a/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml +++ b/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_duplicate_suggestion_out' diff --git a/src/admin/paths/admin@corporate_cards@merge.yaml b/src/admin/paths/admin@corporate_cards@merge.yaml index 452aeeeb0..e2850c21d 100644 --- a/src/admin/paths/admin@corporate_cards@merge.yaml +++ b/src/admin/paths/admin@corporate_cards@merge.yaml @@ -25,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@reassign.yaml b/src/admin/paths/admin@corporate_cards@reassign.yaml index bd454839e..6c609bdc1 100644 --- a/src/admin/paths/admin@corporate_cards@reassign.yaml +++ b/src/admin/paths/admin@corporate_cards@reassign.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@stats.yaml b/src/admin/paths/admin@corporate_cards@stats.yaml index bfec761b7..f994b78a8 100644 --- a/src/admin/paths/admin@corporate_cards@stats.yaml +++ b/src/admin/paths/admin@corporate_cards@stats.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_stats_out' diff --git a/src/admin/paths/admin@corporate_cards@unarchive.yaml b/src/admin/paths/admin@corporate_cards@unarchive.yaml index ad5809880..3e21aabdf 100644 --- a/src/admin/paths/admin@corporate_cards@unarchive.yaml +++ b/src/admin/paths/admin@corporate_cards@unarchive.yaml @@ -25,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml b/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml index 9e95f516e..bce9c0ae3 100644 --- a/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml +++ b/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml @@ -25,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@corporate_cards@unassign.yaml b/src/admin/paths/admin@corporate_cards@unassign.yaml index 8798ff037..24bba1d9d 100644 --- a/src/admin/paths/admin@corporate_cards@unassign.yaml +++ b/src/admin/paths/admin@corporate_cards@unassign.yaml @@ -25,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_unassign_out' diff --git a/src/admin/paths/admin@cost_centers.yaml b/src/admin/paths/admin@cost_centers.yaml index 18b840621..8b0ec51bf 100644 --- a/src/admin/paths/admin@cost_centers.yaml +++ b/src/admin/paths/admin@cost_centers.yaml @@ -71,8 +71,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/cost_center.yaml#/admin_cost_center_out diff --git a/src/admin/paths/admin@departments.yaml b/src/admin/paths/admin@departments.yaml index 39511bd9b..21da1b722 100644 --- a/src/admin/paths/admin@departments.yaml +++ b/src/admin/paths/admin@departments.yaml @@ -65,8 +65,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/department.yaml#/department_out diff --git a/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml b/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml index d3875747b..bf7b2f72b 100644 --- a/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml +++ b/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml @@ -63,8 +63,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/dependent_expense_field_values.yaml#/dependent_expense_field_values_download_out' diff --git a/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml b/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml index ea2bc809e..1fa6cacb6 100644 --- a/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml +++ b/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml @@ -63,8 +63,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/dependent_expense_field_values.yaml#/dependent_expense_field_values_upload_out' diff --git a/src/admin/paths/admin@dwolla_customers.yaml b/src/admin/paths/admin@dwolla_customers.yaml index a944eb6bb..9512dee79 100644 --- a/src/admin/paths/admin@dwolla_customers.yaml +++ b/src/admin/paths/admin@dwolla_customers.yaml @@ -60,8 +60,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/dwolla_customer.yaml#/dwolla_customer_out' diff --git a/src/admin/paths/admin@employee_fields.yaml b/src/admin/paths/admin@employee_fields.yaml index fa8537f02..4bcf4e824 100644 --- a/src/admin/paths/admin@employee_fields.yaml +++ b/src/admin/paths/admin@employee_fields.yaml @@ -60,8 +60,6 @@ post: application/json: schema: type: object - required: - - data properties: url: type: string diff --git a/src/admin/paths/admin@employees@downloads.yaml b/src/admin/paths/admin@employees@downloads.yaml index a6522340a..0f02c685f 100644 --- a/src/admin/paths/admin@employees@downloads.yaml +++ b/src/admin/paths/admin@employees@downloads.yaml @@ -65,8 +65,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/employee.yaml#/employees_download_out' diff --git a/src/admin/paths/admin@employees@export_configurations.yaml b/src/admin/paths/admin@employees@export_configurations.yaml index 1ebea4124..883dbe342 100644 --- a/src/admin/paths/admin@employees@export_configurations.yaml +++ b/src/admin/paths/admin@employees@export_configurations.yaml @@ -163,8 +163,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/employees_export_configurations.yaml#/employees_export_configuration_out' diff --git a/src/admin/paths/admin@employees@exports.yaml b/src/admin/paths/admin@employees@exports.yaml index 142c571e6..e9e34ca4e 100644 --- a/src/admin/paths/admin@employees@exports.yaml +++ b/src/admin/paths/admin@employees@exports.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/employees_exports.yaml#/employees_exports_out' diff --git a/src/admin/paths/admin@employees@filters.yaml b/src/admin/paths/admin@employees@filters.yaml index f5832b22a..2fd76e63e 100644 --- a/src/admin/paths/admin@employees@filters.yaml +++ b/src/admin/paths/admin@employees@filters.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/employee_filters.yaml#/employee_filters_out' diff --git a/src/admin/paths/admin@employees@filters@delete.yaml b/src/admin/paths/admin@employees@filters@delete.yaml index 4c3ec7877..9a485e223 100644 --- a/src/admin/paths/admin@employees@filters@delete.yaml +++ b/src/admin/paths/admin@employees@filters@delete.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/employee_filters.yaml#/employee_filters_out' diff --git a/src/admin/paths/admin@employees@stats.yaml b/src/admin/paths/admin@employees@stats.yaml index aab808494..bebfd19ae 100644 --- a/src/admin/paths/admin@employees@stats.yaml +++ b/src/admin/paths/admin@employees@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/employee.yaml#/employees_stats_out' diff --git a/src/admin/paths/admin@employees@uploads.yaml b/src/admin/paths/admin@employees@uploads.yaml index 289929f91..98301a851 100644 --- a/src/admin/paths/admin@employees@uploads.yaml +++ b/src/admin/paths/admin@employees@uploads.yaml @@ -65,8 +65,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/employee.yaml#/employees_upload_out' diff --git a/src/admin/paths/admin@expense_fields.yaml b/src/admin/paths/admin@expense_fields.yaml index 2efd1d8f6..a5183e230 100644 --- a/src/admin/paths/admin@expense_fields.yaml +++ b/src/admin/paths/admin@expense_fields.yaml @@ -60,8 +60,6 @@ post: application/json: schema: type: object - required: - - data properties: url: type: string diff --git a/src/admin/paths/admin@expense_policies.yaml b/src/admin/paths/admin@expense_policies.yaml index 3a0dc57b5..f2d99bfed 100644 --- a/src/admin/paths/admin@expense_policies.yaml +++ b/src/admin/paths/admin@expense_policies.yaml @@ -31,8 +31,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/expense_policies.yaml#/expense_policy_out diff --git a/src/admin/paths/admin@expense_policies@disable.yaml b/src/admin/paths/admin@expense_policies@disable.yaml index 80784a21d..9e804fcb6 100644 --- a/src/admin/paths/admin@expense_policies@disable.yaml +++ b/src/admin/paths/admin@expense_policies@disable.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/expense_policies.yaml#/expense_policy_out diff --git a/src/admin/paths/admin@expense_policies@enable.yaml b/src/admin/paths/admin@expense_policies@enable.yaml index d23e1c5c8..d2268e290 100644 --- a/src/admin/paths/admin@expense_policies@enable.yaml +++ b/src/admin/paths/admin@expense_policies@enable.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/expense_policies.yaml#/expense_policy_out diff --git a/src/admin/paths/admin@expense_policy_comments.yaml b/src/admin/paths/admin@expense_policy_comments.yaml index 5c3668172..32672860a 100644 --- a/src/admin/paths/admin@expense_policy_comments.yaml +++ b/src/admin/paths/admin@expense_policy_comments.yaml @@ -58,8 +58,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: object diff --git a/src/admin/paths/admin@expenses.yaml b/src/admin/paths/admin@expenses.yaml index 5c9213e25..8e5610fa4 100644 --- a/src/admin/paths/admin@expenses.yaml +++ b/src/admin/paths/admin@expenses.yaml @@ -52,8 +52,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_expense_in' @@ -64,8 +62,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/admin/paths/admin@expenses@attach_files@bulk.yaml b/src/admin/paths/admin@expenses@attach_files@bulk.yaml index 10a43e46a..697d8e58d 100644 --- a/src/admin/paths/admin@expenses@attach_files@bulk.yaml +++ b/src/admin/paths/admin@expenses@attach_files@bulk.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@bulk.yaml b/src/admin/paths/admin@expenses@bulk.yaml index 07ec4dae0..7d4a8e59e 100644 --- a/src/admin/paths/admin@expenses@bulk.yaml +++ b/src/admin/paths/admin@expenses@bulk.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_expenses_bulk_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@check_policies_bulk.yaml b/src/admin/paths/admin@expenses@check_policies_bulk.yaml index 5a4e15542..89319cc95 100644 --- a/src/admin/paths/admin@expenses@check_policies_bulk.yaml +++ b/src/admin/paths/admin@expenses@check_policies_bulk.yaml @@ -28,8 +28,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out diff --git a/src/admin/paths/admin@expenses@comments@bulk.yaml b/src/admin/paths/admin@expenses@comments@bulk.yaml index 4d597c219..a48fa6c05 100644 --- a/src/admin/paths/admin@expenses@comments@bulk.yaml +++ b/src/admin/paths/admin@expenses@comments@bulk.yaml @@ -13,8 +13,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_comments_bulk_in' @@ -25,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@export_configurations.yaml b/src/admin/paths/admin@expenses@export_configurations.yaml index 837605ec1..3573fbac4 100644 --- a/src/admin/paths/admin@expenses@export_configurations.yaml +++ b/src/admin/paths/admin@expenses@export_configurations.yaml @@ -147,8 +147,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expenses_export_configurations.yaml#/expenses_export_configuration_out' diff --git a/src/admin/paths/admin@expenses@exports.yaml b/src/admin/paths/admin@expenses@exports.yaml index 1e0d8906e..0736bd382 100644 --- a/src/admin/paths/admin@expenses@exports.yaml +++ b/src/admin/paths/admin@expenses@exports.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expenses_exports.yaml#/expenses_exports_out' diff --git a/src/admin/paths/admin@expenses@filters.yaml b/src/admin/paths/admin@expenses@filters.yaml index 10e5f6f1c..d3ab7b27e 100644 --- a/src/admin/paths/admin@expenses@filters.yaml +++ b/src/admin/paths/admin@expenses@filters.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/admin/paths/admin@expenses@filters@delete.yaml b/src/admin/paths/admin@expenses@filters@delete.yaml index 0acdb816f..144f8b063 100644 --- a/src/admin/paths/admin@expenses@filters@delete.yaml +++ b/src/admin/paths/admin@expenses@filters@delete.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/admin/paths/admin@expenses@merge.yaml b/src/admin/paths/admin@expenses@merge.yaml index 1f7c77091..9684a9e75 100644 --- a/src/admin/paths/admin@expenses@merge.yaml +++ b/src/admin/paths/admin@expenses@merge.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_merge_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/admin/paths/admin@expenses@permissions.yaml b/src/admin/paths/admin@expenses@permissions.yaml index 3364da543..d6001df6f 100644 --- a/src/admin/paths/admin@expenses@permissions.yaml +++ b/src/admin/paths/admin@expenses@permissions.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_out' diff --git a/src/admin/paths/admin@expenses@permissions@bulk.yaml b/src/admin/paths/admin@expenses@permissions@bulk.yaml index 8664840e7..0c0719457 100644 --- a/src/admin/paths/admin@expenses@permissions@bulk.yaml +++ b/src/admin/paths/admin@expenses@permissions@bulk.yaml @@ -33,8 +33,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' diff --git a/src/admin/paths/admin@expenses@split.yaml b/src/admin/paths/admin@expenses@split.yaml index b07231780..d0754dc82 100644 --- a/src/admin/paths/admin@expenses@split.yaml +++ b/src/admin/paths/admin@expenses@split.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml b/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml index 57c713302..9a9988de2 100644 --- a/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml +++ b/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml @@ -13,8 +13,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -25,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@split@check_policies.yaml b/src/admin/paths/admin@expenses@split@check_policies.yaml index 0c9410c0b..e8a60dddd 100644 --- a/src/admin/paths/admin@expenses@split@check_policies.yaml +++ b/src/admin/paths/admin@expenses@split@check_policies.yaml @@ -14,8 +14,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -26,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@stats.yaml b/src/admin/paths/admin@expenses@stats.yaml index 0bf898b7c..ee129cee4 100644 --- a/src/admin/paths/admin@expenses@stats.yaml +++ b/src/admin/paths/admin@expenses@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_stats_out' diff --git a/src/admin/paths/admin@files.yaml b/src/admin/paths/admin@files.yaml index 65603ab8e..02998c601 100644 --- a/src/admin/paths/admin@files.yaml +++ b/src/admin/paths/admin@files.yaml @@ -59,8 +59,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/file.yaml#/file_out diff --git a/src/admin/paths/admin@files@bulk.yaml b/src/admin/paths/admin@files@bulk.yaml index ffd179f21..d48b10505 100644 --- a/src/admin/paths/admin@files@bulk.yaml +++ b/src/admin/paths/admin@files@bulk.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@files@generate_urls@bulk.yaml b/src/admin/paths/admin@files@generate_urls@bulk.yaml index f28de9259..a29425341 100644 --- a/src/admin/paths/admin@files@generate_urls@bulk.yaml +++ b/src/admin/paths/admin@files@generate_urls@bulk.yaml @@ -32,8 +32,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@levels.yaml b/src/admin/paths/admin@levels.yaml index fc01a971d..aaadf0736 100644 --- a/src/admin/paths/admin@levels.yaml +++ b/src/admin/paths/admin@levels.yaml @@ -63,8 +63,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: ../../components/schemas/level.yaml#/level_out diff --git a/src/admin/paths/admin@mileage_rates.yaml b/src/admin/paths/admin@mileage_rates.yaml index 7f3e8559c..b6f199e99 100644 --- a/src/admin/paths/admin@mileage_rates.yaml +++ b/src/admin/paths/admin@mileage_rates.yaml @@ -63,8 +63,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: ../../components/schemas/mileage_rate.yaml#/mileage_rate_out diff --git a/src/admin/paths/admin@per_diem_rates.yaml b/src/admin/paths/admin@per_diem_rates.yaml index f363a51a8..4cb54f536 100644 --- a/src/admin/paths/admin@per_diem_rates.yaml +++ b/src/admin/paths/admin@per_diem_rates.yaml @@ -65,8 +65,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/per_diem_rate.yaml#/per_diem_rate_out diff --git a/src/admin/paths/admin@projects.yaml b/src/admin/paths/admin@projects.yaml index d311d685d..d9dbe32e5 100644 --- a/src/admin/paths/admin@projects.yaml +++ b/src/admin/paths/admin@projects.yaml @@ -65,8 +65,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/project.yaml#/admin_approver_project_out diff --git a/src/admin/paths/admin@reconciliation_entries@close.yaml b/src/admin/paths/admin@reconciliation_entries@close.yaml index f491c1fdb..5e8b56b7d 100644 --- a/src/admin/paths/admin@reconciliation_entries@close.yaml +++ b/src/admin/paths/admin@reconciliation_entries@close.yaml @@ -33,8 +33,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml b/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml index 04c6923c2..3755c345e 100644 --- a/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml +++ b/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/reconciliation_exports.yaml#/reconciliation_export_out' diff --git a/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml b/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml index c7c16dcf5..d36857e54 100644 --- a/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml +++ b/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml @@ -26,8 +26,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml index c2f5a66c2..698c0e4be 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml @@ -39,8 +39,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml index d1b11f39c..0d4f54b96 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/reconciliation_exports.yaml#/reconciliation_export_out' diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml index 149cac5f6..40c7ee40e 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml @@ -32,8 +32,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: false properties: data: diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml index 08ba7772c..70600a3d6 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml @@ -46,8 +46,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml index a21847a8d..e9b88c92c 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml @@ -31,8 +31,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml index b93a11236..92b38f5be 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml @@ -39,8 +39,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml index 246efefd8..d54070960 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml @@ -38,8 +38,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml index 60d0a3581..4a291f7f5 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml @@ -26,8 +26,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml index 0af2981f0..fbd004c12 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml @@ -39,8 +39,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: type: object diff --git a/src/admin/paths/admin@reimbursements@mark_complete.yaml b/src/admin/paths/admin@reimbursements@mark_complete.yaml index 5f29952d4..5dce2ef6e 100644 --- a/src/admin/paths/admin@reimbursements@mark_complete.yaml +++ b/src/admin/paths/admin@reimbursements@mark_complete.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/reimbursement.yaml#/reimbursement_out' diff --git a/src/admin/paths/admin@reminders.yaml b/src/admin/paths/admin@reminders.yaml index 7aa19a6bf..e7490eb72 100644 --- a/src/admin/paths/admin@reminders.yaml +++ b/src/admin/paths/admin@reminders.yaml @@ -65,8 +65,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/reminder.yaml#/reminder_out diff --git a/src/admin/paths/admin@reminders@delete.yaml b/src/admin/paths/admin@reminders@delete.yaml index 3e060b578..95ec9b7e0 100644 --- a/src/admin/paths/admin@reminders@delete.yaml +++ b/src/admin/paths/admin@reminders@delete.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reminders@stats.yaml b/src/admin/paths/admin@reminders@stats.yaml index e22926d51..3cca816f3 100644 --- a/src/admin/paths/admin@reminders@stats.yaml +++ b/src/admin/paths/admin@reminders@stats.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reports@add_approver.yaml b/src/admin/paths/admin@reports@add_approver.yaml index 19a0e87f0..226ad05bd 100644 --- a/src/admin/paths/admin@reports@add_approver.yaml +++ b/src/admin/paths/admin@reports@add_approver.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@apply_advance_wallets.yaml b/src/admin/paths/admin@reports@apply_advance_wallets.yaml index c5fee00fa..fceba0263 100644 --- a/src/admin/paths/admin@reports@apply_advance_wallets.yaml +++ b/src/admin/paths/admin@reports@apply_advance_wallets.yaml @@ -24,8 +24,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@comments.yaml b/src/admin/paths/admin@reports@comments.yaml index ffdef235d..9b48e93b2 100644 --- a/src/admin/paths/admin@reports@comments.yaml +++ b/src/admin/paths/admin@reports@comments.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_comments_out' diff --git a/src/admin/paths/admin@reports@delete_filter.yaml b/src/admin/paths/admin@reports@delete_filter.yaml index 63bceca83..50d56712a 100644 --- a/src/admin/paths/admin@reports@delete_filter.yaml +++ b/src/admin/paths/admin@reports@delete_filter.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/admin/paths/admin@reports@eject_expenses.yaml b/src/admin/paths/admin@reports@eject_expenses.yaml index 3a9717f45..d293caddb 100644 --- a/src/admin/paths/admin@reports@eject_expenses.yaml +++ b/src/admin/paths/admin@reports@eject_expenses.yaml @@ -30,8 +30,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@export_configurations.yaml b/src/admin/paths/admin@reports@export_configurations.yaml index d544fa796..3f4c2f255 100644 --- a/src/admin/paths/admin@reports@export_configurations.yaml +++ b/src/admin/paths/admin@reports@export_configurations.yaml @@ -70,8 +70,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/reports_export_configurations.yaml#/reports_export_configuration_out' diff --git a/src/admin/paths/admin@reports@exports.yaml b/src/admin/paths/admin@reports@exports.yaml index 248ff4d59..683440fb1 100644 --- a/src/admin/paths/admin@reports@exports.yaml +++ b/src/admin/paths/admin@reports@exports.yaml @@ -63,8 +63,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/reports_exports.yaml#/reports_exports_out' diff --git a/src/admin/paths/admin@reports@permissions.yaml b/src/admin/paths/admin@reports@permissions.yaml index 71ca3ad25..00c0674d9 100644 --- a/src/admin/paths/admin@reports@permissions.yaml +++ b/src/admin/paths/admin@reports@permissions.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report_permissions.yaml#/report_permissions_out' diff --git a/src/admin/paths/admin@reports@process_summary@bulk.yaml b/src/admin/paths/admin@reports@process_summary@bulk.yaml index 84f8a99f4..7ca2d35c9 100644 --- a/src/admin/paths/admin@reports@process_summary@bulk.yaml +++ b/src/admin/paths/admin@reports@process_summary@bulk.yaml @@ -26,8 +26,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reports@remove_advance_wallets.yaml b/src/admin/paths/admin@reports@remove_advance_wallets.yaml index f4675ef0a..ebc30e859 100644 --- a/src/admin/paths/admin@reports@remove_advance_wallets.yaml +++ b/src/admin/paths/admin@reports@remove_advance_wallets.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@remove_approver.yaml b/src/admin/paths/admin@reports@remove_approver.yaml index cf117eacd..a305e8946 100644 --- a/src/admin/paths/admin@reports@remove_approver.yaml +++ b/src/admin/paths/admin@reports@remove_approver.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@revert_to_approved.yaml b/src/admin/paths/admin@reports@revert_to_approved.yaml index 51e3af78d..7c411b0ba 100644 --- a/src/admin/paths/admin@reports@revert_to_approved.yaml +++ b/src/admin/paths/admin@reports@revert_to_approved.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@revert_to_processing.yaml b/src/admin/paths/admin@reports@revert_to_processing.yaml index 22ab342dc..6d00142dd 100644 --- a/src/admin/paths/admin@reports@revert_to_processing.yaml +++ b/src/admin/paths/admin@reports@revert_to_processing.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@round_off_amount.yaml b/src/admin/paths/admin@reports@round_off_amount.yaml index f99731a3a..06614451f 100644 --- a/src/admin/paths/admin@reports@round_off_amount.yaml +++ b/src/admin/paths/admin@reports@round_off_amount.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@save_filters.yaml b/src/admin/paths/admin@reports@save_filters.yaml index 2da3220ee..36652d425 100644 --- a/src/admin/paths/admin@reports@save_filters.yaml +++ b/src/admin/paths/admin@reports@save_filters.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/admin/paths/admin@reports@send_back.yaml b/src/admin/paths/admin@reports@send_back.yaml index 3cc52c0aa..acd3ca98d 100644 --- a/src/admin/paths/admin@reports@send_back.yaml +++ b/src/admin/paths/admin@reports@send_back.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@stats.yaml b/src/admin/paths/admin@reports@stats.yaml index 029c82d13..bd00c4e13 100644 --- a/src/admin/paths/admin@reports@stats.yaml +++ b/src/admin/paths/admin@reports@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/reports_stats_out' diff --git a/src/admin/paths/admin@scheduled_callbacks.yaml b/src/admin/paths/admin@scheduled_callbacks.yaml index d6b9f008f..8a1ad4f51 100644 --- a/src/admin/paths/admin@scheduled_callbacks.yaml +++ b/src/admin/paths/admin@scheduled_callbacks.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/scheduled_callback.yaml#/scheduled_callback_out diff --git a/src/admin/paths/admin@schedules.yaml b/src/admin/paths/admin@schedules.yaml index c6e4eb8ca..5ab588a35 100644 --- a/src/admin/paths/admin@schedules.yaml +++ b/src/admin/paths/admin@schedules.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/schedule.yaml#/schedule_out diff --git a/src/admin/paths/admin@statements@archived_cards.yaml b/src/admin/paths/admin@statements@archived_cards.yaml index 09083e129..60b5d27b6 100644 --- a/src/admin/paths/admin@statements@archived_cards.yaml +++ b/src/admin/paths/admin@statements@archived_cards.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@archived_cards@ignore.yaml b/src/admin/paths/admin@statements@archived_cards@ignore.yaml index 575dc0970..e3a06ac61 100644 --- a/src/admin/paths/admin@statements@archived_cards@ignore.yaml +++ b/src/admin/paths/admin@statements@archived_cards@ignore.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: object diff --git a/src/admin/paths/admin@statements@card_stats.yaml b/src/admin/paths/admin@statements@card_stats.yaml index 3a9d20431..5906f74f6 100644 --- a/src/admin/paths/admin@statements@card_stats.yaml +++ b/src/admin/paths/admin@statements@card_stats.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/statements.yaml#/card_stats_out' diff --git a/src/admin/paths/admin@statements@matching_cards.yaml b/src/admin/paths/admin@statements@matching_cards.yaml index 68b4b9aa6..05cf558fa 100644 --- a/src/admin/paths/admin@statements@matching_cards.yaml +++ b/src/admin/paths/admin@statements@matching_cards.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@preview.yaml b/src/admin/paths/admin@statements@preview.yaml index f57f87bb3..5a21fb962 100644 --- a/src/admin/paths/admin@statements@preview.yaml +++ b/src/admin/paths/admin@statements@preview.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/statements.yaml#/preview_out' diff --git a/src/admin/paths/admin@statements@reconcile.yaml b/src/admin/paths/admin@statements@reconcile.yaml index 1669a3032..d35298686 100644 --- a/src/admin/paths/admin@statements@reconcile.yaml +++ b/src/admin/paths/admin@statements@reconcile.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: object diff --git a/src/admin/paths/admin@statements@reconciliation_summary.yaml b/src/admin/paths/admin@statements@reconciliation_summary.yaml index f6b325be4..e752af7ef 100644 --- a/src/admin/paths/admin@statements@reconciliation_summary.yaml +++ b/src/admin/paths/admin@statements@reconciliation_summary.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@suggest_mappings.yaml b/src/admin/paths/admin@statements@suggest_mappings.yaml index 7612be13b..9343af7e8 100644 --- a/src/admin/paths/admin@statements@suggest_mappings.yaml +++ b/src/admin/paths/admin@statements@suggest_mappings.yaml @@ -31,10 +31,6 @@ post: application/json: schema: type: object - required: - - data - - count - - offset properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@statements@summary.yaml b/src/admin/paths/admin@statements@summary.yaml index 6da4d23c5..f0e6aca4c 100644 --- a/src/admin/paths/admin@statements@summary.yaml +++ b/src/admin/paths/admin@statements@summary.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@unassigned_cards.yaml b/src/admin/paths/admin@statements@unassigned_cards.yaml index 18fc4f299..515510f52 100644 --- a/src/admin/paths/admin@statements@unassigned_cards.yaml +++ b/src/admin/paths/admin@statements@unassigned_cards.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@upload.yaml b/src/admin/paths/admin@statements@upload.yaml index 704d3c069..c14faeba1 100644 --- a/src/admin/paths/admin@statements@upload.yaml +++ b/src/admin/paths/admin@statements@upload.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/statements.yaml#/statements_out' diff --git a/src/admin/paths/admin@subscriptions.yaml b/src/admin/paths/admin@subscriptions.yaml index dc8b04e6e..8d0b401c7 100644 --- a/src/admin/paths/admin@subscriptions.yaml +++ b/src/admin/paths/admin@subscriptions.yaml @@ -11,8 +11,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/admin_subscriptions_in' @@ -24,8 +22,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/admin_subscriptions_out' diff --git a/src/admin/paths/admin@tax_groups.yaml b/src/admin/paths/admin@tax_groups.yaml index f0551647f..12179977b 100644 --- a/src/admin/paths/admin@tax_groups.yaml +++ b/src/admin/paths/admin@tax_groups.yaml @@ -65,8 +65,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/tax_group.yaml#/tax_group_out' diff --git a/src/admin/paths/admin@virtual_cards@delete.yaml b/src/admin/paths/admin@virtual_cards@delete.yaml index 7ca783e98..065ae1e09 100644 --- a/src/admin/paths/admin@virtual_cards@delete.yaml +++ b/src/admin/paths/admin@virtual_cards@delete.yaml @@ -25,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_card_out' diff --git a/src/admin/paths/admin@virtual_cards@get_current_amount.yaml b/src/admin/paths/admin@virtual_cards@get_current_amount.yaml index 4e422c72f..b326a885c 100644 --- a/src/admin/paths/admin@virtual_cards@get_current_amount.yaml +++ b/src/admin/paths/admin@virtual_cards@get_current_amount.yaml @@ -25,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_get_current_balance_out' diff --git a/src/admin/paths/admin@virtual_cards@show_card_details.yaml b/src/admin/paths/admin@virtual_cards@show_card_details.yaml index ac9d647f2..e1b3bcc92 100644 --- a/src/admin/paths/admin@virtual_cards@show_card_details.yaml +++ b/src/admin/paths/admin@virtual_cards@show_card_details.yaml @@ -25,8 +25,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_show_card_details_out' diff --git a/src/approver/paths/approver@advance_requests@add_approver.yaml b/src/approver/paths/approver@advance_requests@add_approver.yaml index 7685fd3e4..81c08199f 100644 --- a/src/approver/paths/approver@advance_requests@add_approver.yaml +++ b/src/approver/paths/approver@advance_requests@add_approver.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_add_approver_in' @@ -28,8 +26,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml b/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml index 8da910c34..14065e4b1 100644 --- a/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml +++ b/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/approver/paths/approver@advance_requests@comments.yaml b/src/approver/paths/approver@advance_requests@comments.yaml index 2ce3237c2..81f9ea81d 100644 --- a/src/approver/paths/approver@advance_requests@comments.yaml +++ b/src/approver/paths/approver@advance_requests@comments.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_out' diff --git a/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml b/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml index 3b633a735..66b6174f8 100644 --- a/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml +++ b/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml @@ -32,8 +32,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: type: array diff --git a/src/approver/paths/approver@advance_requests@inquire.yaml b/src/approver/paths/approver@advance_requests@inquire.yaml index da8dd2440..806a56798 100644 --- a/src/approver/paths/approver@advance_requests@inquire.yaml +++ b/src/approver/paths/approver@advance_requests@inquire.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@partially_approve.yaml b/src/approver/paths/approver@advance_requests@partially_approve.yaml index 13bbc1386..0068c6c50 100644 --- a/src/approver/paths/approver@advance_requests@partially_approve.yaml +++ b/src/approver/paths/approver@advance_requests@partially_approve.yaml @@ -26,8 +26,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@permissions.yaml b/src/approver/paths/approver@advance_requests@permissions.yaml index 8f5d4031b..744da3b9f 100644 --- a/src/approver/paths/approver@advance_requests@permissions.yaml +++ b/src/approver/paths/approver@advance_requests@permissions.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_permissions_out' diff --git a/src/approver/paths/approver@advance_requests@reject.yaml b/src/approver/paths/approver@advance_requests@reject.yaml index c2df92a74..0930de8e2 100644 --- a/src/approver/paths/approver@advance_requests@reject.yaml +++ b/src/approver/paths/approver@advance_requests@reject.yaml @@ -29,8 +29,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@stats.yaml b/src/approver/paths/approver@advance_requests@stats.yaml index d778f6fac..9e16193ec 100644 --- a/src/approver/paths/approver@advance_requests@stats.yaml +++ b/src/approver/paths/approver@advance_requests@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_requests_approver_stats_out' diff --git a/src/approver/paths/approver@advance_requests@submit.yaml b/src/approver/paths/approver@advance_requests@submit.yaml index 287fae1b2..f511c601e 100644 --- a/src/approver/paths/approver@advance_requests@submit.yaml +++ b/src/approver/paths/approver@advance_requests@submit.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@corporate_card_transactions@match.yaml b/src/approver/paths/approver@corporate_card_transactions@match.yaml index 7cbe00818..4c60ece64 100644 --- a/src/approver/paths/approver@corporate_card_transactions@match.yaml +++ b/src/approver/paths/approver@corporate_card_transactions@match.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_match_out' diff --git a/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml b/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml index 01c7bdec8..561fa70a1 100644 --- a/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml +++ b/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmatch_out' diff --git a/src/approver/paths/approver@employee_overview@expenses@stats.yaml b/src/approver/paths/approver@employee_overview@expenses@stats.yaml index cee6c869e..b9f4a4e48 100644 --- a/src/approver/paths/approver@employee_overview@expenses@stats.yaml +++ b/src/approver/paths/approver@employee_overview@expenses@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_expense_stats_out diff --git a/src/approver/paths/approver@employee_overview@stats.yaml b/src/approver/paths/approver@employee_overview@stats.yaml index 441c9a55d..b133e3fc7 100644 --- a/src/approver/paths/approver@employee_overview@stats.yaml +++ b/src/approver/paths/approver@employee_overview@stats.yaml @@ -32,8 +32,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_stats_out diff --git a/src/approver/paths/approver@expenses.yaml b/src/approver/paths/approver@expenses.yaml index 2537789d4..d9780a8ac 100644 --- a/src/approver/paths/approver@expenses.yaml +++ b/src/approver/paths/approver@expenses.yaml @@ -53,8 +53,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/approver_expense_in' @@ -65,8 +63,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/approver/paths/approver@expenses@attach_files@bulk.yaml b/src/approver/paths/approver@expenses@attach_files@bulk.yaml index 10a43e46a..697d8e58d 100644 --- a/src/approver/paths/approver@expenses@attach_files@bulk.yaml +++ b/src/approver/paths/approver@expenses@attach_files@bulk.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@bulk.yaml b/src/approver/paths/approver@expenses@bulk.yaml index d9f30d26d..1e777f6e0 100644 --- a/src/approver/paths/approver@expenses@bulk.yaml +++ b/src/approver/paths/approver@expenses@bulk.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/approver_expenses_bulk_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@check_policies_bulk.yaml b/src/approver/paths/approver@expenses@check_policies_bulk.yaml index 9d66fc8ab..99296b6ba 100644 --- a/src/approver/paths/approver@expenses@check_policies_bulk.yaml +++ b/src/approver/paths/approver@expenses@check_policies_bulk.yaml @@ -28,8 +28,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out diff --git a/src/approver/paths/approver@expenses@comments@bulk.yaml b/src/approver/paths/approver@expenses@comments@bulk.yaml index 8ba2a5104..2fb188a45 100644 --- a/src/approver/paths/approver@expenses@comments@bulk.yaml +++ b/src/approver/paths/approver@expenses@comments@bulk.yaml @@ -13,8 +13,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_comments_bulk_in' @@ -25,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@export_configurations.yaml b/src/approver/paths/approver@expenses@export_configurations.yaml index 4d56b4cab..96be32a0d 100644 --- a/src/approver/paths/approver@expenses@export_configurations.yaml +++ b/src/approver/paths/approver@expenses@export_configurations.yaml @@ -158,8 +158,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expenses_export_configurations.yaml#/expenses_export_configuration_out' diff --git a/src/approver/paths/approver@expenses@exports.yaml b/src/approver/paths/approver@expenses@exports.yaml index 1e0d8906e..0736bd382 100644 --- a/src/approver/paths/approver@expenses@exports.yaml +++ b/src/approver/paths/approver@expenses@exports.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expenses_exports.yaml#/expenses_exports_out' diff --git a/src/approver/paths/approver@expenses@filters.yaml b/src/approver/paths/approver@expenses@filters.yaml index 38291520a..797810a62 100644 --- a/src/approver/paths/approver@expenses@filters.yaml +++ b/src/approver/paths/approver@expenses@filters.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/approver/paths/approver@expenses@filters@delete.yaml b/src/approver/paths/approver@expenses@filters@delete.yaml index 0acdb816f..144f8b063 100644 --- a/src/approver/paths/approver@expenses@filters@delete.yaml +++ b/src/approver/paths/approver@expenses@filters@delete.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/approver/paths/approver@expenses@permissions.yaml b/src/approver/paths/approver@expenses@permissions.yaml index e291a4a40..00ba5862c 100644 --- a/src/approver/paths/approver@expenses@permissions.yaml +++ b/src/approver/paths/approver@expenses@permissions.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_out' diff --git a/src/approver/paths/approver@expenses@permissions@bulk.yaml b/src/approver/paths/approver@expenses@permissions@bulk.yaml index 938f1be3c..2ffce10c5 100644 --- a/src/approver/paths/approver@expenses@permissions@bulk.yaml +++ b/src/approver/paths/approver@expenses@permissions@bulk.yaml @@ -33,8 +33,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' diff --git a/src/approver/paths/approver@expenses@split.yaml b/src/approver/paths/approver@expenses@split.yaml index e8a734bc7..6c18eb6ec 100644 --- a/src/approver/paths/approver@expenses@split.yaml +++ b/src/approver/paths/approver@expenses@split.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml b/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml index 57c713302..9a9988de2 100644 --- a/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml +++ b/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml @@ -13,8 +13,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -25,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@split@check_policies.yaml b/src/approver/paths/approver@expenses@split@check_policies.yaml index f75995482..402c93873 100644 --- a/src/approver/paths/approver@expenses@split@check_policies.yaml +++ b/src/approver/paths/approver@expenses@split@check_policies.yaml @@ -14,8 +14,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -26,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@stats.yaml b/src/approver/paths/approver@expenses@stats.yaml index 0bf898b7c..ee129cee4 100644 --- a/src/approver/paths/approver@expenses@stats.yaml +++ b/src/approver/paths/approver@expenses@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_stats_out' diff --git a/src/approver/paths/approver@files@bulk.yaml b/src/approver/paths/approver@files@bulk.yaml index 942bbd084..11b97415d 100644 --- a/src/approver/paths/approver@files@bulk.yaml +++ b/src/approver/paths/approver@files@bulk.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/approver/paths/approver@files@generate_urls@bulk.yaml b/src/approver/paths/approver@files@generate_urls@bulk.yaml index f28de9259..a29425341 100644 --- a/src/approver/paths/approver@files@generate_urls@bulk.yaml +++ b/src/approver/paths/approver@files@generate_urls@bulk.yaml @@ -32,8 +32,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/approver/paths/approver@reports@add_approver.yaml b/src/approver/paths/approver@reports@add_approver.yaml index c2451a2f6..2d728ead7 100644 --- a/src/approver/paths/approver@reports@add_approver.yaml +++ b/src/approver/paths/approver@reports@add_approver.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@add_expenses.yaml b/src/approver/paths/approver@reports@add_expenses.yaml index 3aca97649..d78c9af28 100644 --- a/src/approver/paths/approver@reports@add_expenses.yaml +++ b/src/approver/paths/approver@reports@add_expenses.yaml @@ -26,8 +26,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@comments.yaml b/src/approver/paths/approver@reports@comments.yaml index 7e3628021..883b28497 100644 --- a/src/approver/paths/approver@reports@comments.yaml +++ b/src/approver/paths/approver@reports@comments.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_comments_out' diff --git a/src/approver/paths/approver@reports@eject_expenses.yaml b/src/approver/paths/approver@reports@eject_expenses.yaml index 4e90d7e8b..f948a3806 100644 --- a/src/approver/paths/approver@reports@eject_expenses.yaml +++ b/src/approver/paths/approver@reports@eject_expenses.yaml @@ -26,8 +26,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@export_configurations.yaml b/src/approver/paths/approver@reports@export_configurations.yaml index 0eaf70cac..d0c89edbc 100644 --- a/src/approver/paths/approver@reports@export_configurations.yaml +++ b/src/approver/paths/approver@reports@export_configurations.yaml @@ -83,8 +83,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/reports_export_configurations.yaml#/reports_export_configuration_out' diff --git a/src/approver/paths/approver@reports@exports.yaml b/src/approver/paths/approver@reports@exports.yaml index 248ff4d59..683440fb1 100644 --- a/src/approver/paths/approver@reports@exports.yaml +++ b/src/approver/paths/approver@reports@exports.yaml @@ -63,8 +63,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/reports_exports.yaml#/reports_exports_out' diff --git a/src/approver/paths/approver@reports@filters.yaml b/src/approver/paths/approver@reports@filters.yaml index 3793210ec..6ae983d65 100644 --- a/src/approver/paths/approver@reports@filters.yaml +++ b/src/approver/paths/approver@reports@filters.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/approver/paths/approver@reports@filters@delete.yaml b/src/approver/paths/approver@reports@filters@delete.yaml index 63bceca83..50d56712a 100644 --- a/src/approver/paths/approver@reports@filters@delete.yaml +++ b/src/approver/paths/approver@reports@filters@delete.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/approver/paths/approver@reports@partially_approve.yaml b/src/approver/paths/approver@reports@partially_approve.yaml index 63e0f396e..d4992f6b4 100644 --- a/src/approver/paths/approver@reports@partially_approve.yaml +++ b/src/approver/paths/approver@reports@partially_approve.yaml @@ -26,8 +26,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@permissions.yaml b/src/approver/paths/approver@reports@permissions.yaml index 71ca3ad25..00c0674d9 100644 --- a/src/approver/paths/approver@reports@permissions.yaml +++ b/src/approver/paths/approver@reports@permissions.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report_permissions.yaml#/report_permissions_out' diff --git a/src/approver/paths/approver@reports@round_off_amount.yaml b/src/approver/paths/approver@reports@round_off_amount.yaml index 67b43e94c..97134cb22 100644 --- a/src/approver/paths/approver@reports@round_off_amount.yaml +++ b/src/approver/paths/approver@reports@round_off_amount.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@send_back.yaml b/src/approver/paths/approver@reports@send_back.yaml index 8502b3c9b..097602105 100644 --- a/src/approver/paths/approver@reports@send_back.yaml +++ b/src/approver/paths/approver@reports@send_back.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@stats.yaml b/src/approver/paths/approver@reports@stats.yaml index 029c82d13..bd00c4e13 100644 --- a/src/approver/paths/approver@reports@stats.yaml +++ b/src/approver/paths/approver@reports@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/reports_stats_out' diff --git a/src/approver/paths/approver@subscriptions.yaml b/src/approver/paths/approver@subscriptions.yaml index 1cece38ec..f272d4b96 100644 --- a/src/approver/paths/approver@subscriptions.yaml +++ b/src/approver/paths/approver@subscriptions.yaml @@ -11,8 +11,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/subscriptions_in' @@ -24,8 +22,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/approver_subscriptions_out' diff --git a/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml b/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml index 476aea906..ef3d14d3d 100644 --- a/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml +++ b/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml @@ -12,8 +12,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: ../../components/schemas/org_settings.yaml#/logo_file_generate_download_url_action_out diff --git a/src/components/schemas/account.yaml b/src/components/schemas/account.yaml index 094319b9e..8673451d1 100644 --- a/src/components/schemas/account.yaml +++ b/src/components/schemas/account.yaml @@ -1,17 +1,6 @@ account_out: type: object additionalProperties: false - required: - - id - - created_at - - updated_at - - user_id - - type - - currency - - current_balance_amount - - tentative_balance_amount - - org_id - - category_id properties: id: allOf: @@ -56,9 +45,6 @@ account_out: account_out_embed: type: object - required: - - id - - type properties: id: allOf: @@ -77,11 +63,6 @@ account_out_embed: account_snapshot_out_embed: type: object - required: - - account_id - - type - - currency - - balance properties: account_id: allOf: @@ -106,11 +87,6 @@ account_snapshot_out_embed: account_in: type: object additionalProperties: false - required: - - user_id - - type - - currency - - category_id properties: user_id: type: string diff --git a/src/components/schemas/advance.yaml b/src/components/schemas/advance.yaml index 0daadea92..0aaf5fc55 100644 --- a/src/components/schemas/advance.yaml +++ b/src/components/schemas/advance.yaml @@ -141,12 +141,6 @@ advance_out: advance_out_embed: type: object nullable: true - required: - - id - - currency - - amount - - advance_request_id - - seq_num properties: id: type: string @@ -252,8 +246,6 @@ advance_in: $ref: './fields.yaml#/custom_fields' advances_stats_in: - required: - - query_params properties: query_params: type: string @@ -264,9 +256,6 @@ advances_stats_in: advances_stats_out: type: object - required: - - count - - total_amount properties: count: type: integer diff --git a/src/components/schemas/advance_refund.yaml b/src/components/schemas/advance_refund.yaml index 849939512..5c533ba75 100644 --- a/src/components/schemas/advance_refund.yaml +++ b/src/components/schemas/advance_refund.yaml @@ -153,8 +153,6 @@ advance_refund_in: example: 'awfgRr8YA6KK' advance_refunds_stats_in: - required: - - query_params properties: query_params: type: string @@ -165,9 +163,6 @@ advance_refunds_stats_in: advance_refunds_stats_out: type: object - required: - - count - - total_amount properties: count: type: integer diff --git a/src/components/schemas/advance_request.yaml b/src/components/schemas/advance_request.yaml index 8be5ea210..5ca278569 100644 --- a/src/components/schemas/advance_request.yaml +++ b/src/components/schemas/advance_request.yaml @@ -216,8 +216,6 @@ advance_request_action_in: example: 'rpa21A2rdj2' advance_requests_stats_in: - required: - - query_params properties: query_params: description: | @@ -307,10 +305,6 @@ advance_requests_stats_out: advance_request_out_embed: type: object nullable: true - required: - - id - - last_approved_at - - seq_num properties: id: type: string @@ -412,17 +406,6 @@ advance_request_comments_in: advance_request_comments_out: type: object additionalProperties: false - required: - - id - - comment - - action - - advance_request_id - - creator_type - - creator_user_id - - creator_user - - created_at - - updated_at - - org_id properties: id: $ref: './fields.yaml#/id_string' @@ -487,18 +470,6 @@ advance_request_permissions_in: advance_request_permissions_out: type: object additionalProperties: false - required: - - can_save - - can_submit - - can_edit - - can_add_approver - - can_disable_approver - - can_reject - - can_approve - - can_inquire - - can_pull_back - - can_pay - - can_delete properties: can_save: type: boolean @@ -562,7 +533,6 @@ advance_request_action_pull_back_in: description: | Comment explaining the reason for pulling back the advance request example: 'sending back' - nullable: true advance_request_delete_in: type: object diff --git a/src/components/schemas/advance_request_approval.yaml b/src/components/schemas/advance_request_approval.yaml index d773cf1ea..d4e5b3d1c 100644 --- a/src/components/schemas/advance_request_approval.yaml +++ b/src/components/schemas/advance_request_approval.yaml @@ -1,10 +1,6 @@ advance_request_approval_out_embed: type: object additionalProperties: False - required: - - approver_user_id - - approver_user - - state properties: approver_user_id: allOf: diff --git a/src/components/schemas/advance_wallet.yaml b/src/components/schemas/advance_wallet.yaml index 30ed9452d..72da46164 100644 --- a/src/components/schemas/advance_wallet.yaml +++ b/src/components/schemas/advance_wallet.yaml @@ -41,9 +41,6 @@ advance_wallet_in: advance_wallet_report_out: type: object additionalProperties: false - required: - - id - - amount properties: id: allOf: diff --git a/src/components/schemas/automation.yaml b/src/components/schemas/automation.yaml index 8b49828a5..08cc75a6f 100644 --- a/src/components/schemas/automation.yaml +++ b/src/components/schemas/automation.yaml @@ -13,9 +13,6 @@ spender_automate_report_submission_next_at_out: automate_report_submission_in: type: object - required: - - description - - schedule_config properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/budget.yaml b/src/components/schemas/budget.yaml index 8b7e04cb0..71199ca3d 100644 --- a/src/components/schemas/budget.yaml +++ b/src/components/schemas/budget.yaml @@ -183,7 +183,6 @@ budget_out: - visibility - status - user_ids - - fiscal_year_start_month properties: id: $ref: './fields.yaml#/id_string' @@ -303,12 +302,6 @@ budget_out: budget_out_embed: type: object additionalProperties: False - required: - - id - - name - - type - - amount_limit - - is_enabled properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/budget_exports.yaml b/src/components/schemas/budget_exports.yaml index 4e2f0cca2..d00f343c9 100644 --- a/src/components/schemas/budget_exports.yaml +++ b/src/components/schemas/budget_exports.yaml @@ -16,15 +16,6 @@ budget_exports_in: budget_exports_out: type: object additionalProperties: false - required: - - created_at - - updated_at - - id - - org_id - - user_id - - query_params - - file_id - - state properties: created_at: $ref: './fields.yaml#/created_at' diff --git a/src/components/schemas/category.yaml b/src/components/schemas/category.yaml index 9fa66ad8c..e82a28f13 100644 --- a/src/components/schemas/category.yaml +++ b/src/components/schemas/category.yaml @@ -65,13 +65,6 @@ category_out_embed: type: object nullable: true additionalProperties: False - required: - - id - - system_category - - name - - sub_category - - code - - display_name properties: id: $ref: './fields.yaml#/id_integer' @@ -243,15 +236,10 @@ admin_approver_category_out: category_delete_summary_out: type: object - required: - - data additionalProperties: False properties: data: type: object - required: - - delete_count - - categories properties: delete_count: type: integer diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index a39c7d41d..ad233810a 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -500,16 +500,6 @@ corporate_card_unassign_out: corporate_card_out_embed: type: object additionalProperties: false - required: - - id - - bank_name - - card_number - - nickname - - cardholder_name - - masked_number - - user_full_name - - user_email - - is_archived properties: id: allOf: @@ -569,16 +559,6 @@ corporate_card_out_embed: duplicate_suggestion_corporate_card_out_embed: type: object additionalProperties: false - required: - - id - - bank_name - - card_number - - nickname - - total_transactions_count - - is_visa_enrolled - - is_mastercard_enrolled - - data_feed_source - - feed_display_name properties: id: allOf: @@ -632,8 +612,6 @@ duplicate_suggestion_corporate_card_out_embed: corporate_card_stats_in: - required: - - query_params properties: query_params: nullable: False @@ -644,10 +622,6 @@ corporate_card_stats_in: corporate_card_stats_out: type: object - required: - - count - - total_transactions_count - - transactions_count properties: count: type: integer @@ -760,9 +734,6 @@ yodlee_accounts_out: - updated_at - - org_id - - user_id - - corporate_card_id corporate_card_merge_in: type: object properties: diff --git a/src/components/schemas/corporate_card_transaction.yaml b/src/components/schemas/corporate_card_transaction.yaml index c0144790a..9146aaa5d 100644 --- a/src/components/schemas/corporate_card_transaction.yaml +++ b/src/components/schemas/corporate_card_transaction.yaml @@ -603,7 +603,6 @@ corporate_card_transaction_post_out: - is_exported - metadata - - mcc corporate_card_transaction_assign_in: type: object properties: @@ -831,7 +830,6 @@ corporate_card_transaction_assign_out: - last_user_matched_at - metadata - - mcc corporate_card_transaction_unassign_out: type: object properties: @@ -1048,8 +1046,6 @@ corporate_card_transaction_unassign_out: - last_user_matched_at - metadata - - mcc - - is_exported corporate_card_transaction_match_in: type: object properties: @@ -1283,9 +1279,6 @@ corporate_card_transaction_match_out: - last_user_matched_at - metadata - - capitalone_virtual_card_last_four - - mcc - - is_exported corporate_card_transaction_unmatch_in: type: object properties: @@ -1531,11 +1524,6 @@ corporate_card_transaction_unmatch_out: - last_user_matched_at - metadata - - transaction_status - - capitalone_virtual_card_last_four - - mcc - - bank_transaction_number - - is_exported corporate_card_transaction_id_in: type: object properties: @@ -1754,8 +1742,6 @@ corporate_card_transaction_mark_personal_out: - last_user_matched_at - metadata - - mcc - - is_exported corporate_card_transaction_unmark_personal_out: type: object properties: @@ -1965,8 +1951,6 @@ corporate_card_transaction_unmark_personal_out: - last_user_matched_at - metadata - - mcc - - is_exported corporate_card_transaction_ignore_out: type: object properties: @@ -2182,9 +2166,6 @@ corporate_card_transaction_ignore_out: - last_user_matched_at - metadata - - capitalone_virtual_card_last_four - - mcc - - is_exported corporate_card_transaction_undo_ignore_out: type: object additionalProperties: false @@ -2415,14 +2396,7 @@ corporate_card_transaction_undo_ignore_out: - last_user_matched_at - metadata - - transaction_status - - capitalone_virtual_card_last_four - - mcc - - bank_transaction_number corporate_card_transactions_stats_in: - type: object - required: - - query_params properties: query_params: nullable: false @@ -2433,10 +2407,6 @@ corporate_card_transactions_stats_in: corporate_card_transactions_stats_out: type: object - required: - - count - - debit_amount - - credit_amount properties: count: type: integer @@ -2469,9 +2439,6 @@ corporate_card_transactions_delete_summary_in: corporate_card_transactions_delete_summary_out: type: object - required: - - delete_count - - delete_amount properties: delete_count: type: integer @@ -2514,8 +2481,6 @@ corporate_card_transaction_reassign_in: corporate_card_transactions_expenses_stats_in: type: object - required: - - query_params properties: query_params: type: string diff --git a/src/components/schemas/corporate_card_transactions_exports.yaml b/src/components/schemas/corporate_card_transactions_exports.yaml index 430b52a24..8bdb03fb5 100644 --- a/src/components/schemas/corporate_card_transactions_exports.yaml +++ b/src/components/schemas/corporate_card_transactions_exports.yaml @@ -126,20 +126,6 @@ corporate_card_transactions_exports_in: corporate_card_transactions_exports_out: type: object additionalProperties: false - required: - - created_at - - updated_at - - id - - org_id - - user_id - - query_params - - notify_emails - - config - - file_id - - state - - processed_at - - completed_at - - failed_at properties: created_at: $ref: './fields.yaml#/created_at' diff --git a/src/components/schemas/corporate_credit_card_expense.yaml b/src/components/schemas/corporate_credit_card_expense.yaml index d1d152ea3..fe5669f3b 100644 --- a/src/components/schemas/corporate_credit_card_expense.yaml +++ b/src/components/schemas/corporate_credit_card_expense.yaml @@ -1,9 +1,5 @@ corporate_credit_card_expense_out_embed: type: object - required: - - id - - currency - - amount properties: id: type: string diff --git a/src/components/schemas/cost_center.yaml b/src/components/schemas/cost_center.yaml index bf9086733..b77017725 100644 --- a/src/components/schemas/cost_center.yaml +++ b/src/components/schemas/cost_center.yaml @@ -36,10 +36,6 @@ cost_center_out_embed: type: object nullable: true additionalProperties: False - required: - - id - - name - - code properties: id: $ref: './fields.yaml#/id_integer' @@ -194,8 +190,6 @@ cost_center_in_only_id: cost_center_delete_summary_out: type: object additionalProperties: False - required: - - data properties: data: type: object diff --git a/src/components/schemas/currency.yaml b/src/components/schemas/currency.yaml index 748254464..365cba351 100644 --- a/src/components/schemas/currency.yaml +++ b/src/components/schemas/currency.yaml @@ -1,7 +1,5 @@ exchange_rate_out: type: object - required: - - exchange_rate additionalProperties: false properties: exchange_rate: diff --git a/src/components/schemas/department.yaml b/src/components/schemas/department.yaml index 186d566ee..976a4bb0a 100644 --- a/src/components/schemas/department.yaml +++ b/src/components/schemas/department.yaml @@ -66,12 +66,6 @@ department_out_embed: type: object additionalProperties: False nullable: true - required: - - id - - code - - name - - sub_department - - display_name properties: id: $ref: './fields.yaml#/id_string' @@ -98,11 +92,6 @@ department_out_employee_embed: type: object additionalProperties: False nullable: true - required: - - id - - code - - name - - sub_department properties: id: $ref: './fields.yaml#/id_string' @@ -163,8 +152,6 @@ department_in_only_id: department_delete_summary_out: type: object additionalProperties: False - required: - - data properties: data: type: object diff --git a/src/components/schemas/dependent_expense_field_values.yaml b/src/components/schemas/dependent_expense_field_values.yaml index c1da6481c..3aa27fef8 100644 --- a/src/components/schemas/dependent_expense_field_values.yaml +++ b/src/components/schemas/dependent_expense_field_values.yaml @@ -1,16 +1,6 @@ dependent_expense_field_values_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - parent_expense_field_id - - expense_field_id - - parent_expense_field_value - - expense_field_value - - is_enabled properties: id: $ref: './fields.yaml#/id_integer' @@ -86,16 +76,6 @@ dependent_expense_field_values_in: dependent_expense_field_values_upload_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - parent_expense_field_id - - expense_field_id - - file_id - - error_file_id - - state properties: id: $ref: './fields.yaml#/id_integer' @@ -164,13 +144,6 @@ dependent_expense_field_values_upload_in: dependent_expense_field_values_preview_out: type: object additionalProperties: false - required: - - org_id - - parent_expense_field_id - - expense_field_id - - parent_expense_field_value - - expense_field_values - - is_enabled properties: org_id: $ref: ./fields.yaml#/org_id @@ -206,15 +179,6 @@ dependent_expense_field_values_preview_out: dependent_expense_field_values_download_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - parent_expense_field_id - - expense_field_id - - file_id - - state properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/dwolla_customer.yaml b/src/components/schemas/dwolla_customer.yaml index 393950a68..7fe9d386d 100644 --- a/src/components/schemas/dwolla_customer.yaml +++ b/src/components/schemas/dwolla_customer.yaml @@ -1,27 +1,6 @@ dwolla_customer_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - customer_id - - customer_email - - customer_added_by - - is_customer_verified - - is_beneficial_owner_added - - is_beneficial_owner_verified - - is_bank_account_added - - is_bank_account_verified - - bank_account_added_by - - is_customer_document_needed - - is_beneficial_owner_document_needed - - is_customer_retry - - is_customer_suspended - - micro_deposit_verification_status - - micro_deposit_verification_attempts - - is_beneficial_owner_retry properties: id: allOf: @@ -135,28 +114,6 @@ dwolla_customer_out: spender_dwolla_customer_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - customer_id - - customer_email - - customer_added_by - - is_customer_verified - - is_beneficial_owner_added - - is_beneficial_owner_verified - - is_bank_account_added - - is_bank_account_verified - - bank_account_added_by - - is_customer_document_needed - - is_beneficial_owner_document_needed - - is_customer_retry - - is_customer_suspended - - micro_deposit_verification_status - - micro_deposit_verification_attempts - - is_beneficial_owner_retry - - is_org_customer_verified properties: id: type: string @@ -299,9 +256,6 @@ spender_dwolla_customer_out: dwolla_customer_in: type: object additionalProperties: false - required: - - customer_id - - customer_added_by properties: customer_id: type: string diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index 39b3e47eb..ff2a7e622 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -274,14 +274,6 @@ employee_out: employee_out_embed: type: object additionalProperties: False - required: - - id - - user_id - - user - - code - - org_id - - department_id - - department properties: id: $ref: ./fields.yaml#/id_string @@ -333,7 +325,6 @@ employee_out_potential_duplicate_expenses: - user_id - email - full_name - - potential_duplicate_expenses properties: user_id: $ref: './fields.yaml#/user_id' @@ -354,25 +345,6 @@ employee_out_embed_for_expense: type: object additionalProperties: False nullable: True - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - location - - title - - business_unit - - custom_fields - - flattened_custom_field - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: ./fields.yaml#/id_string @@ -452,25 +424,6 @@ employee_out_embed_for_expense_with_department_name: type: object additionalProperties: False nullable: True - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - location - - title - - business_unit - - custom_fields - - flattened_custom_field - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: ./fields.yaml#/id_string @@ -549,24 +502,6 @@ employee_out_embed_for_expense_with_department_name: employee_out_embed_for_report: type: object additionalProperties: False - required: - - id - - user_id - - user - - code - - org_id - - org_name - - department_id - - department - - level - - ach_account - - business_unit - - location - - title - - has_accepted_invite - - is_enabled - - mobile - - joined_at properties: id: $ref: ./fields.yaml#/id_string @@ -740,19 +675,6 @@ employee_in: spender_employee_out: type: object additionalProperties: False - required: - - id - - user_id - - email - - full_name - - roles - - commute_details - - mobile - - is_mobile_verified - - sms_opt_out_source - - is_enabled - - has_accepted_invite - - delegatees properties: id: $ref: './fields.yaml#/id_string' @@ -906,19 +828,6 @@ employees_download_out: spender_commute_details_out: type: object additionalProperties: False - required: - - id - - user_id - - email - - full_name - - roles - - commute_details - - mobile - - is_mobile_verified - - sms_opt_out_source - - is_enabled - - has_accepted_invite - - delegatees properties: id: $ref: './fields.yaml#/id_string' @@ -977,10 +886,6 @@ spender_commute_details_out: spender_delegators_out: type: object additionalProperties: False - required: - - user_id - - email - - full_name properties: user_id: $ref: './fields.yaml#/user_id' @@ -996,13 +901,6 @@ spender_delegators_out: spender_delegatees_delete_out: type: object additionalProperties: False - required: - - id - - org_id - - delegator_user_id - - delegatee_user_id - - start_date - - end_date properties: id: $ref: './fields.yaml#/id_integer' @@ -1029,11 +927,6 @@ spender_delegatees_delete_out: spender_delegatees_post_in: type: object additionalProperties: False - required: - - delegatee_user_id - - start_at - - end_at - - scopes properties: delegatee_user_id: $ref: ./fields.yaml#/fk_string @@ -1057,19 +950,6 @@ spender_delegatees_post_in: spender_delegatees_post_out: type: object additionalProperties: False - required: - - id - - user_id - - email - - full_name - - roles - - commute_details - - mobile - - is_mobile_verified - - sms_opt_out_source - - is_enabled - - has_accepted_invite - - delegatees properties: id: $ref: './fields.yaml#/id_string' @@ -1208,12 +1088,6 @@ employee_change_owner_in: employees_send_mobile_verification_code_post_out: type: object - required: - - to - - channel - - status - - date_created - - attempts_left additionalProperties: False properties: to: @@ -1231,6 +1105,11 @@ employees_send_mobile_verification_code_post_out: description: | Current status of the verification attempt example: "pending" + valid: + type: boolean + description: | + Whether the verification is valid + example: false date_created: type: string format: date-time @@ -1317,44 +1196,6 @@ employee_hierarchy_out: spender_employee_current_out: type: object additionalProperties: False - required: - - id - - org_id - - user_id - - created_at - - updated_at - - user - - code - - joined_at - - title - - business_unit - - special_email - - roles - - location - - is_enabled - - has_accepted_invite - - branch_account - - branch_ifsc - - department_id - - department - - level_id - - level - - mobile - - is_mobile_verified - - mobile_verification_attempts_left - - mobile_verification_attempted_at - - org_name - - currency - - approver_user_ids - - approver_users - - locale - - delegatees - - mileage_settings - - custom_fields - - flattened_custom_field - - commute_details_id - - commute_details - - is_primary properties: id: $ref: './fields.yaml#/id_string' @@ -1622,9 +1463,6 @@ employee_overview_out: employee_overview_stats_out: type: object additionalProperties: false - required: - - count - - total_amount properties: count: type: integer @@ -1638,9 +1476,6 @@ employee_overview_stats_out: employee_overview_expense_stats_out: type: object additionalProperties: false - required: - - count - - total_amount properties: count: type: integer diff --git a/src/components/schemas/employee_account_summary.yaml b/src/components/schemas/employee_account_summary.yaml index c994c450a..a6dfee00f 100644 --- a/src/components/schemas/employee_account_summary.yaml +++ b/src/components/schemas/employee_account_summary.yaml @@ -1,23 +1,5 @@ employee_account_summary_out: type: object - required: - - id - - created_at - - updated_at - - org_id - - org_currency - - user_email - - user_full_name - - cash_account_id - - cash_account - - cash_account_balance - - ccc_account_id - - ccc_account - - ccc_account_balance - - advance_account_ids - - advance_accounts - - advance_accounts_balance - - is_settleable properties: id: diff --git a/src/components/schemas/employee_settings.yaml b/src/components/schemas/employee_settings.yaml index faa5ac749..1902e4b44 100644 --- a/src/components/schemas/employee_settings.yaml +++ b/src/components/schemas/employee_settings.yaml @@ -1,29 +1,6 @@ spender_employee_settings_out: type: object additionalProperties: false - required: - - id - - employee_id - - org_id - - created_at - - updated_at - - category_ids - - cost_center_ids - - project_ids - - per_diem_rate_ids - - mileage_rate_ids - - insta_fyle_settings - - notification_settings - - mileage_settings - - expense_form_autofills - - data_extractor_settings - - in_app_chat_settings - - payment_mode_settings - - locale - - is_personal_cards_enabled - - default_project_id - - default_payment_mode - - default_vehicle_type properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/employees_export_configurations.yaml b/src/components/schemas/employees_export_configurations.yaml index 432a05148..cbf4e6bd3 100644 --- a/src/components/schemas/employees_export_configurations.yaml +++ b/src/components/schemas/employees_export_configurations.yaml @@ -203,8 +203,6 @@ employees_export_configuration_out: - type - org_id - user_id - - created_by - - updated_by properties: id: allOf: diff --git a/src/components/schemas/employees_exports.yaml b/src/components/schemas/employees_exports.yaml index b348fad55..a5327c6cb 100644 --- a/src/components/schemas/employees_exports.yaml +++ b/src/components/schemas/employees_exports.yaml @@ -123,20 +123,6 @@ employees_exports_in: employees_exports_out: type: object - required: - - created_at - - updated_at - - id - - org_id - - user_id - - query_params - - notify_emails - - config - - file_id - - state - - processed_at - - completed_at - - failed_at properties: created_at: type: string diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 5978c1120..32bd291b3 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -83,26 +83,6 @@ expense_out: - invoice_number - is_duplicate_present - expense_policy_comments - - custom_fields_flattened - - approvals - - verifications - - employee_id - - split_group_amount - - expense_rule_id - - expense_rule_data - - is_split - - tax_group - - approver_comments - - verifier_comments - - policy_checks - - accounting_export_summary - - report_last_paid_at - - report_last_approved_at - - commute_deduction - - commute_details_id - - commute_details - - is_reconciled - - report_auto_approval_state properties: id: allOf: @@ -1593,24 +1573,6 @@ matched_corporate_card_transaction_out_embed: - id - corporate_card_id - corporate_card_number - - corporate_card_nickname - - corporate_card_cardholder_name - - capitalone_virtual_card_last_four - - masked_corporate_card_number - - bank_name - - corporate_card_user_full_name - - is_corporate_card_archived - - amount - - currency - - spent_at - - posted_at - - status - - description - - foreign_currency - - foreign_amount - - merchant - - category - - matched_by properties: id: allOf: @@ -2068,9 +2030,6 @@ expense_check_policies_in: expense_check_policies_out: type: object additionalProperties: False - required: - - individual_desired_states - - final_desired_state properties: individual_desired_states: type: array @@ -2106,8 +2065,6 @@ expense_delete_in: expenses_stats_in: - required: - - query_params properties: query_params: nullable: False @@ -2555,9 +2512,6 @@ expense_duplicate_sets_out: expense_verification_out_embed: type: object additionalProperties: false - required: - - verifier_user_id - - verifier_user properties: verifier_user_id: allOf: diff --git a/src/components/schemas/expense_duplicate_set.yaml b/src/components/schemas/expense_duplicate_set.yaml index 391fa97bc..65307d2e1 100644 --- a/src/components/schemas/expense_duplicate_set.yaml +++ b/src/components/schemas/expense_duplicate_set.yaml @@ -1,7 +1,4 @@ expenses_duplicate_sets_stats_in: - type: object - required: - - query_params properties: query_params: nullable: False @@ -13,8 +10,6 @@ expenses_duplicate_sets_stats_in: expenses_duplicate_sets_stats_out: type: object - required: - - count properties: count: type: integer diff --git a/src/components/schemas/expense_field.yaml b/src/components/schemas/expense_field.yaml index de2034c68..84540117e 100644 --- a/src/components/schemas/expense_field.yaml +++ b/src/components/schemas/expense_field.yaml @@ -1,25 +1,6 @@ expense_field_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - seq - - field_name - - column_name - - type - - options - - default_value - - placeholder - - category_ids - - is_enabled - - is_custom - - is_mandatory - - code - - parent_field_id - - display_order properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/expense_policies.yaml b/src/components/schemas/expense_policies.yaml index 8f1415fa8..df806737b 100644 --- a/src/components/schemas/expense_policies.yaml +++ b/src/components/schemas/expense_policies.yaml @@ -533,9 +533,6 @@ expense_policy_out: - action_add_department_head_approver - action_add_approver_user_ids - action_override_distance_slab_rate - - expense_merchants - - expense_merchants_op - - policy_violation_reason_required properties: id: allOf: diff --git a/src/components/schemas/expense_rules.yaml b/src/components/schemas/expense_rules.yaml index 6897cec28..ebc4fa6e2 100644 --- a/src/components/schemas/expense_rules.yaml +++ b/src/components/schemas/expense_rules.yaml @@ -26,8 +26,6 @@ expense_rule_if_out: additionalProperties: false required: - merchant_contains - - department_ids - - departments properties: merchant_contains: type: string @@ -102,18 +100,6 @@ expense_rule_data_out: nullable: false additionalProperties: false minProperties: 1 - required: - - merchant - - is_billable - - purpose - - category_id - - category - - project_id - - project - - cost_center_id - - cost_center - - custom_fields - - dependent_fields properties: merchant: type: string @@ -195,8 +181,6 @@ expense_rule_out: - creator_user - if - set - - is_suggested - - is_suggestion_dismissed properties: id: allOf: diff --git a/src/components/schemas/expenses_export_configurations.yaml b/src/components/schemas/expenses_export_configurations.yaml index c8e721e6f..2a5912f49 100644 --- a/src/components/schemas/expenses_export_configurations.yaml +++ b/src/components/schemas/expenses_export_configurations.yaml @@ -256,8 +256,6 @@ expenses_export_configuration_out: - type - org_id - user_id - - created_by - - updated_by properties: id: allOf: diff --git a/src/components/schemas/expenses_exports.yaml b/src/components/schemas/expenses_exports.yaml index de5d94e8f..58ddd91e7 100644 --- a/src/components/schemas/expenses_exports.yaml +++ b/src/components/schemas/expenses_exports.yaml @@ -116,17 +116,6 @@ expenses_exports_in: expenses_exports_out: type: object additionalProperties: false - required: - - created_at - - updated_at - - id - - org_id - - user_id - - query_params - - notify_emails - - config - - file_id - - state properties: created_at: $ref: './fields.yaml#/created_at' diff --git a/src/components/schemas/feature_configs.yaml b/src/components/schemas/feature_configs.yaml index 2bb85dcca..e8c954a00 100644 --- a/src/components/schemas/feature_configs.yaml +++ b/src/components/schemas/feature_configs.yaml @@ -1,17 +1,6 @@ feature_config_out: type: object additionalProperties: false - required: - - org_id - - user_id - - created_at - - updated_at - - target_client - - feature - - sub_feature - - key - - value - - is_shared properties: org_id: $ref: ./fields.yaml#/org_id diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index 85e8fa24a..246ff043c 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1876,12 +1876,6 @@ commute_location: commute_details: type: object - required: - - id - - distance - - distance_unit - - home_location - - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. diff --git a/src/components/schemas/file.yaml b/src/components/schemas/file.yaml index 54e666f06..ebcb48815 100644 --- a/src/components/schemas/file.yaml +++ b/src/components/schemas/file.yaml @@ -1,17 +1,6 @@ file_out: type: object additionalProperties: false - required: - - id - - org_id - - user_id - - created_at - - updated_at - - name - - type - - content_type - - download_url - - upload_url properties: id: $ref: './fields.yaml#/id_string' @@ -64,12 +53,6 @@ file_generate_urls_action_in: file_generate_urls_action_out: type: object additionalProperties: false - required: - - id - - name - - content_type - - download_url - - upload_url properties: id: $ref: './fields.yaml#/id_string' @@ -95,11 +78,6 @@ file_generate_urls_action_out: file_out_embed: type: object - required: - - id - - name - - type - - content_type properties: id: allOf: @@ -186,11 +164,6 @@ file_delete_action_in: file_out_download_url: type: object additionalProperties: false - required: - - id - - name - - content_type - - download_url properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/level.yaml b/src/components/schemas/level.yaml index 4d38ba007..0c038bbf7 100644 --- a/src/components/schemas/level.yaml +++ b/src/components/schemas/level.yaml @@ -112,8 +112,6 @@ level_in_only_id: level_delete_summary_out: type: object additionalProperties: False - required: - - data properties: data: type: object diff --git a/src/components/schemas/merchant.yaml b/src/components/schemas/merchant.yaml index dd90ece22..ba4ba3e48 100644 --- a/src/components/schemas/merchant.yaml +++ b/src/components/schemas/merchant.yaml @@ -1,11 +1,6 @@ merchant_out: type: object additionalProperties: false - required: - - id - - created_at - - updated_at - - display_name properties: id: $ref: './fields.yaml#/id_integer' @@ -22,12 +17,6 @@ merchant_out: approver_merchant_out: type: object additionalProperties: false - required: - - id - - org_id - - created_at - - updated_at - - display_name properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/mileage_rate.yaml b/src/components/schemas/mileage_rate.yaml index 230bc3276..94236a01c 100644 --- a/src/components/schemas/mileage_rate.yaml +++ b/src/components/schemas/mileage_rate.yaml @@ -61,10 +61,6 @@ mileage_rate_out_embed: type: object nullable: true additionalProperties: False - required: - - id - - vehicle_type - - code properties: id: $ref: './fields.yaml#/id_integer' @@ -78,11 +74,6 @@ mileage_rate_out_embed_for_expense: type: object nullable: true additionalProperties: False - required: - - id - - vehicle_type - - code - - rate properties: id: $ref: './fields.yaml#/id_integer' @@ -154,15 +145,10 @@ mileage_rate_in_only_id: mileage_rate_delete_summary_out: type: object - required: - - data additionalProperties: False properties: data: type: object - required: - - delete_count - - mileage_rates properties: delete_count: type: integer diff --git a/src/components/schemas/mobile_app_version.yaml b/src/components/schemas/mobile_app_version.yaml index 41e2a6511..e4960648a 100644 --- a/src/components/schemas/mobile_app_version.yaml +++ b/src/components/schemas/mobile_app_version.yaml @@ -1,13 +1,6 @@ mobile_app_version_out: type: object additionalProperties: false - required: - - id - - user_id - - version - - os - - created_at - - updated_at properties: id: type: string diff --git a/src/components/schemas/my_profile.yaml b/src/components/schemas/my_profile.yaml index a5880739a..79d292e1e 100644 --- a/src/components/schemas/my_profile.yaml +++ b/src/components/schemas/my_profile.yaml @@ -1,12 +1,6 @@ my_profile_out: type: object additionalProperties: false - required: - - user_id - - org_id - - org - - user - - roles properties: user_id: $ref: '../../components/schemas/fields.yaml#/user_id' diff --git a/src/components/schemas/org.yaml b/src/components/schemas/org.yaml index aabc8bcff..0e37dc648 100644 --- a/src/components/schemas/org.yaml +++ b/src/components/schemas/org.yaml @@ -5,7 +5,6 @@ org_weekly_invitation_usage_out: - id - invitation_sent - is_limit_reached - - weekly_limit properties: id: $ref: './fields.yaml#/org_id' @@ -31,11 +30,6 @@ org_weekly_invitation_usage_out: org_out_embed: type: object additionalProperties: False - required: - - id - - name - - domain - - currency properties: id: $ref: './fields.yaml#/org_id' @@ -61,8 +55,6 @@ org_out: - currency - created_at - updated_at - - is_current - - is_primary properties: id: $ref: './fields.yaml#/org_id' @@ -182,15 +174,6 @@ org_reset_delete_in: get_spender_orgs_out: type: object additionalProperties: False - required: - - id - - name - - domain - - currency - - created_at - - updated_at - - is_current - - is_primary properties: id: $ref: './fields.yaml#/org_id' @@ -219,12 +202,6 @@ get_spender_orgs_out: org_bank_details_out: type: object additionalProperties: false - required: - - org_id - - bank_account_number - - bank_branch_ifsc - - dwolla_customers_metadata_id - - is_bank_account_added properties: org_id: $ref: './fields.yaml#/org_id' @@ -253,9 +230,6 @@ org_bank_details_out: spender_org_bank_details_out: type: object additionalProperties: false - required: - - org_id - - is_bank_account_added properties: org_id: $ref: './fields.yaml#/org_id' diff --git a/src/components/schemas/org_settings.yaml b/src/components/schemas/org_settings.yaml index 8af0054f7..f1f8cfa54 100644 --- a/src/components/schemas/org_settings.yaml +++ b/src/components/schemas/org_settings.yaml @@ -1,10 +1,5 @@ logo_file_generate_download_url_action_out: type: object - required: - - id - - name - - content_type - - download_url additionalProperties: false properties: id: diff --git a/src/components/schemas/per_diem_rate.yaml b/src/components/schemas/per_diem_rate.yaml index 01f4b54c1..43d01f8ed 100644 --- a/src/components/schemas/per_diem_rate.yaml +++ b/src/components/schemas/per_diem_rate.yaml @@ -46,10 +46,6 @@ per_diem_rate_out_embed: type: object nullable: true additionalProperties: False - required: - - id - - name - - code properties: id: $ref: './fields.yaml#/id_integer' @@ -102,8 +98,6 @@ per_diem_rate_in_only_id: per_diem_rate_delete_summary_out: type: object additionalProperties: False - required: - - data properties: data: type: object diff --git a/src/components/schemas/personal_card.yaml b/src/components/schemas/personal_card.yaml index 9c92956be..5319ea146 100644 --- a/src/components/schemas/personal_card.yaml +++ b/src/components/schemas/personal_card.yaml @@ -1,7 +1,5 @@ personal_card_access_token_out: type: object - required: - - access_token properties: access_token: type: string @@ -22,8 +20,6 @@ personal_card_mfa_in: personal_card_mfa_out: type: object - required: - - is_mfa_enabled properties: is_mfa_enabled: type: boolean @@ -142,23 +138,6 @@ personal_card_out: personal_card_delete_out: type: object additionalProperties: false - required: - - id - - org_id - - user_id - - currency - - bank_name - - card_number - - account_type - - yodlee_account_id - - yodlee_fastlink_params - - yodlee_is_credential_update_required - - yodlee_is_mfa_required - - yodlee_last_synced_at - - yodlee_login_id - - yodlee_provider_account_id - - created_at - - updated_at properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/personal_card_transaction.yaml b/src/components/schemas/personal_card_transaction.yaml index db941b98a..a074c296a 100644 --- a/src/components/schemas/personal_card_transaction.yaml +++ b/src/components/schemas/personal_card_transaction.yaml @@ -1,24 +1,5 @@ personal_card_transaction_out: type: object - required: - - id - - org_id - - user_id - - personal_card_id - - amount - - currency - - spent_at - - category - - merchant - - state - - description - - external_transaction_id - - matched_expense_ids - - created_at - - updated_at - - foreign_amount - - foreign_currency - - matched_expenses additionalProperties: False properties: id: @@ -95,17 +76,6 @@ matched_expense_out_embed: type: object nullable: true additionalProperties: false - required: - - amount - - category_display_name - - currency - - seq_num - - id - - no_of_files - - purpose - - state - - spent_at - - merchant properties: amount: $ref: './fields.yaml#/amount' @@ -186,10 +156,6 @@ personal_card_transactions_stats_in: personal_card_transactions_stats_out: type: object - required: - - count - - debit_amount - - credit_amount properties: count: type: integer diff --git a/src/components/schemas/place.yaml b/src/components/schemas/place.yaml index 8ade16b2d..d62bfd837 100644 --- a/src/components/schemas/place.yaml +++ b/src/components/schemas/place.yaml @@ -1,14 +1,6 @@ place_out: type: object additionalProperties: false - required: - - id - - city - - state - - country - - formatted_address - - latitude - - longitude properties: id: type: string @@ -36,9 +28,6 @@ place_out: place_out_minimal: type: object - required: - - id - - formatted_address properties: id: type: string diff --git a/src/components/schemas/policy.yaml b/src/components/schemas/policy.yaml index 796ea059a..9893061f8 100644 --- a/src/components/schemas/policy.yaml +++ b/src/components/schemas/policy.yaml @@ -1,9 +1,6 @@ policy_test_out: type: object additionalProperties: false - required: - - policy_violation_summary - - policy_violations properties: policy_violation_summary: type: object diff --git a/src/components/schemas/project.yaml b/src/components/schemas/project.yaml index a1723bcfb..3e779062f 100644 --- a/src/components/schemas/project.yaml +++ b/src/components/schemas/project.yaml @@ -67,12 +67,6 @@ project_out_embed: type: object nullable: true additionalProperties: False - required: - - id - - name - - sub_project - - code - - display_name properties: id: $ref: './fields.yaml#/id_integer' @@ -274,15 +268,10 @@ admin_approver_project_out: project_delete_summary_out: type: object - required: - - data additionalProperties: False properties: data: type: object - required: - - delete_count - - projects properties: delete_count: type: integer diff --git a/src/components/schemas/reconciliation_eligible_cards.yaml b/src/components/schemas/reconciliation_eligible_cards.yaml index 584c27a41..572089e49 100644 --- a/src/components/schemas/reconciliation_eligible_cards.yaml +++ b/src/components/schemas/reconciliation_eligible_cards.yaml @@ -97,21 +97,6 @@ reconciliation_eligible_cards_stats_in: reconciliation_eligible_cards_stats_out: type: object - required: - - period_start - - period_end - - statement_transaction_count - - expense_count - - statement_total - - expense_total - - difference - - matching_issue_count - - total_cards - - card_without_statement_count - - card_with_matching_issue_count - - card_with_no_issues_found_count - - card_with_no_transactions_count - - reconciled_card_count additionalProperties: False properties: period_start: diff --git a/src/components/schemas/reconciliation_exports.yaml b/src/components/schemas/reconciliation_exports.yaml index fd9d42fb0..2b13a5630 100644 --- a/src/components/schemas/reconciliation_exports.yaml +++ b/src/components/schemas/reconciliation_exports.yaml @@ -99,15 +99,6 @@ reconciliation_export_in: reconciliation_export_out: type: object additionalProperties: false - required: - - id - - org_id - - file_id - - state - - query_params - - notify_emails - - created_at - - updated_at properties: id: allOf: diff --git a/src/components/schemas/reconciliation_transactions.yaml b/src/components/schemas/reconciliation_transactions.yaml index fb4f4c09e..218cc460e 100644 --- a/src/components/schemas/reconciliation_transactions.yaml +++ b/src/components/schemas/reconciliation_transactions.yaml @@ -11,12 +11,6 @@ reconciliation_transaction_out: - matched_expenses_count - is_reconciled - expenses - - statement_line_item_id - - expense_ids - - statement_transaction_date - - statement_post_date - - created_at - - updated_at properties: id: $ref: './fields.yaml#/id_string' @@ -92,14 +86,6 @@ reconciliation_expense_split_out_embed: - amount - state - purpose - - currency - - merchant - - spent_at - - file_ids - - category - - project - - matched_corporate_card_transaction - - files properties: id: allOf: @@ -201,9 +187,6 @@ reconciliation_matched_expense_out_embed: - project - purpose - splits - - currency - - matched_corporate_card_transaction - - files properties: id: allOf: @@ -318,15 +301,6 @@ reconciliation_transactions_stats_in: reconciliation_transactions_stats_out: type: object - required: - - period_start - - period_end - - statement_transaction_count - - expense_count - - statement_total - - expense_total - - difference - - matching_issue_count additionalProperties: False description: | Reconciliation transactions statistics for the selected filter period. diff --git a/src/components/schemas/recurring_expense.yaml b/src/components/schemas/recurring_expense.yaml index 7821dd546..9f1a8c742 100644 --- a/src/components/schemas/recurring_expense.yaml +++ b/src/components/schemas/recurring_expense.yaml @@ -49,8 +49,6 @@ recurring_expense_out: - expense_details - schedule_config - is_enabled - - created_at - - updated_at properties: id: allOf: @@ -73,8 +71,8 @@ recurring_expense_out: - MILEAGE: Mileage-based expense type example: EXPENSE expense_details: - allOf: - - $ref: './expense.yaml#/spender_expense_in' + type: object + nullable: false description: | Expense template details used for creating recurring expenses. Contains all the expense fields that will be applied to each generated expense. diff --git a/src/components/schemas/reimbursement.yaml b/src/components/schemas/reimbursement.yaml index 27b9471b8..c46df8912 100644 --- a/src/components/schemas/reimbursement.yaml +++ b/src/components/schemas/reimbursement.yaml @@ -102,8 +102,6 @@ reimbursement_out: reimbursement_in: type: object - required: - - amount properties: amount: $ref: './fields.yaml#/amount' @@ -126,12 +124,6 @@ reimbursement_in_minimal: reimbursement_out_minimal: type: object nullable: true - required: - - id - - currency - - amount - - mode - - ach_transfer properties: id: type: string diff --git a/src/components/schemas/reminder.yaml b/src/components/schemas/reminder.yaml index c28b7a7ce..f9bb5e011 100644 --- a/src/components/schemas/reminder.yaml +++ b/src/components/schemas/reminder.yaml @@ -72,13 +72,6 @@ reminder_out: reminder_in: type: object additionalProperties: False - required: - - type - - message - - schedule_config - - add_to_calendar - - send_mobile_notification - - receiver_user_ids properties: id: type: string @@ -125,8 +118,6 @@ reminder_delete_in: example: 'remindNZgN7V5pft' reminders_stats_in: - required: - - query_params properties: query_params: type: string @@ -137,9 +128,6 @@ reminders_stats_in: reminders_stats_out: type: array - required: - - last_reminded_at - - type items: type: object properties: diff --git a/src/components/schemas/report.yaml b/src/components/schemas/report.yaml index b62a118f9..7114ecd27 100644 --- a/src/components/schemas/report.yaml +++ b/src/components/schemas/report.yaml @@ -29,15 +29,6 @@ report_out: - reimbursement - comments - creator_type - - is_verified - - is_physical_bill_submitted - - physical_bill_submitted_at - - is_exported - - employee_id - - state_display_name - - accounting_export_summary - - applied_advance_wallets - - auto_approval_state properties: id: $ref: ./fields.yaml#/id_string @@ -288,14 +279,6 @@ admin_report_out: - applied_advance_wallets - can_apply_advances - creator_type - - is_verified - - is_physical_bill_submitted - - physical_bill_submitted_at - - is_exported - - employee_id - - state_display_name - - accounting_export_summary - - auto_approval_state properties: id: $ref: ./fields.yaml#/id_string @@ -578,9 +561,6 @@ report_out_embed: - last_paid_at - reimbursement_id - reimbursement_seq_num - - amount - - last_verified_at - - approvals properties: id: anyOf: @@ -1018,20 +998,6 @@ process_summary_in: process_summary_out: type: object - required: - - selected_reimbursable_amount - - selected_count - - unverified_count - - unverified_amount - - missing_bank_details_count - - missing_bank_details_amount - - missing_bank_details_employee_count - - missing_bank_details_employee_ids - - payment_initiated_amount - - payment_initiated_count - - reimbursable_amount - - reimbursable_report_ids - - closable_report_ids additionalProperties: True properties: selected_reimbursable_amount: @@ -1116,8 +1082,6 @@ process_summary_out: reports_stats_in: - required: - - query_params properties: query_params: type: string diff --git a/src/components/schemas/report_approval.yaml b/src/components/schemas/report_approval.yaml index 5fa83251c..d56c9e4a1 100644 --- a/src/components/schemas/report_approval.yaml +++ b/src/components/schemas/report_approval.yaml @@ -1,12 +1,6 @@ report_approval_out_embed: type: object additionalProperties: False - required: - - approver_user_id - - approver_type - - approver_user - - state - - approver_order properties: approver_user_id: allOf: diff --git a/src/components/schemas/reports_export_configurations.yaml b/src/components/schemas/reports_export_configurations.yaml index 372873ec2..5b82e72d0 100644 --- a/src/components/schemas/reports_export_configurations.yaml +++ b/src/components/schemas/reports_export_configurations.yaml @@ -192,8 +192,6 @@ reports_export_configuration_out: - type - org_id - user_id - - created_by - - updated_by properties: id: allOf: diff --git a/src/components/schemas/schedule.yaml b/src/components/schemas/schedule.yaml index db32e249a..d8e8726ea 100644 --- a/src/components/schemas/schedule.yaml +++ b/src/components/schemas/schedule.yaml @@ -20,14 +20,6 @@ schedule_in: schedule_out: type: object additionalProperties: False - required: - - id - - created_at - - updated_at - - config - - org_id - - user_id - - is_enabled properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/scheduled_callback.yaml b/src/components/schemas/scheduled_callback.yaml index 770ba6ff2..b34a70971 100644 --- a/src/components/schemas/scheduled_callback.yaml +++ b/src/components/schemas/scheduled_callback.yaml @@ -1,10 +1,5 @@ scheduled_callback_in: type: object - required: - - url - - payload - - schedule_config - - is_enabled properties: id: $ref: './fields.yaml#/id_string' @@ -21,15 +16,6 @@ scheduled_callback_in: scheduled_callback_out: type: object additionalProperties: False - required: - - id - - url - - payload - - schedule_config - - is_enabled - - created_at - - updated_at - - org_id properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/secondary_email.yaml b/src/components/schemas/secondary_email.yaml index 1fd908373..24fec25ef 100644 --- a/src/components/schemas/secondary_email.yaml +++ b/src/components/schemas/secondary_email.yaml @@ -13,14 +13,6 @@ secondary_email_in: secondary_email_out: type: object - required: - - id - - email - - is_verified - - org_id - - user_id - - created_at - - updated_at additionalProperties: False properties: id: diff --git a/src/components/schemas/spend_overview.yaml b/src/components/schemas/spend_overview.yaml index 163a1798a..04e186478 100644 --- a/src/components/schemas/spend_overview.yaml +++ b/src/components/schemas/spend_overview.yaml @@ -2,9 +2,6 @@ spend_overview_summary_data_out: type: object nullable: False - required: - - amount - - time_interval_marker properties: amount: $ref: './fields.yaml#/amount' @@ -15,11 +12,6 @@ spend_overview_summary_data_out: spend_overview_by_merchant_data_out: type: object nullable: False - required: - - merchant_name - - amount - - percentage - - change_percentage properties: merchant_name: $ref: './fields.yaml#/merchant' @@ -34,12 +26,6 @@ spend_overview_by_merchant_data_out: spend_overview_by_project_data_out: type: object nullable: False - required: - - project_id - - project_display_name - - amount - - percentage - - change_percentage properties: project_id: $ref: './fields.yaml#/id_integer' @@ -56,12 +42,6 @@ spend_overview_by_project_data_out: spend_overview_by_category_data_out: type: object nullable: False - required: - - category_id - - category_display_name - - amount - - percentage - - change_percentage properties: category_id: $ref: './fields.yaml#/id_integer' @@ -78,12 +58,6 @@ spend_overview_by_category_data_out: spend_overview_by_department_data_out: type: object nullable: False - required: - - department_id - - department_display_name - - amount - - percentage - - change_percentage properties: department_id: $ref: './fields.yaml#/id_string' @@ -100,13 +74,6 @@ spend_overview_by_department_data_out: spend_overview_by_user_data_out: type: object nullable: False - required: - - user_id - - user_full_name - - user_email - - amount - - percentage - - change_percentage properties: user_id: $ref: './fields.yaml#/id_string' @@ -125,15 +92,6 @@ spend_overview_by_user_data_out: spend_overview_by_corporate_card_data_out: type: object nullable: False - required: - - card_id - - card_number - - card_holder_name - - card_nickname - - user_id - - amount - - percentage - - change_percentage properties: card_id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/statements.yaml b/src/components/schemas/statements.yaml index 0097ada0f..40caae826 100644 --- a/src/components/schemas/statements.yaml +++ b/src/components/schemas/statements.yaml @@ -154,7 +154,6 @@ statements_out: - is_processed - statement_mappings_id - - creator_user card_transaction_from_statement_in: type: object properties: @@ -916,13 +915,6 @@ reconcile_from_statement_in: rtf_missing_transaction_from_statement_out: type: object - required: - - error - - missing_rtf_transactions - - rtf_confidence - - rtf_count - - total_count - - status properties: error: type: string @@ -1036,9 +1028,6 @@ rtf_missing_transaction_from_statement_out: rtf_stats_out: type: object - required: - - last_uploaded_at - - rtf_confidence properties: last_uploaded_at: $ref: './fields.yaml#/timestamptz_utc' @@ -1156,16 +1145,6 @@ preview_out: - no_of_transactions summary_out: - type: object - required: - - id - - status - - period_start - - period_end - - statement_transaction_count - - statement_total - - total_cards - - bridging_entry_change_type properties: id: allOf: @@ -1212,12 +1191,6 @@ summary_out: _reconciliation_summary_object: - type: object - required: - - expense_count - - is_recommended - - reconciliation_method - - statement_transaction_count properties: expense_count: description: Number of expense matches found @@ -1237,9 +1210,6 @@ _reconciliation_summary_object: reconciliation_summary_out: - type: object - required: - - reconciliation_summary properties: reconciliation_summary: type: array @@ -1299,13 +1269,7 @@ card_stats_out: - is_rtf_statement - - rtf_card_network - - missing_corporate_card_details matching_cards_out: - type: object - required: - - statement_card_number - - matching_cards properties: statement_card_number: type: string @@ -1357,10 +1321,6 @@ unassigned_cards_from_statement_in: - statement_id statement_archived_cards_out: - required: - - number_of_cards - - number_of_archived_cards - - archived_cards properties: number_of_cards: type: integer diff --git a/src/components/schemas/subscriptions.yaml b/src/components/schemas/subscriptions.yaml index 4db7ff318..e61b5627c 100644 --- a/src/components/schemas/subscriptions.yaml +++ b/src/components/schemas/subscriptions.yaml @@ -1,13 +1,6 @@ spender_subscriptions_out: type: object additionalProperties: False - required: - - id - - is_enabled - - webhook_url - - updated_at - - created_at - - user_id properties: id: $ref: ./fields.yaml#/id_string @@ -25,13 +18,6 @@ spender_subscriptions_out: approver_subscriptions_out: type: object additionalProperties: False - required: - - id - - is_enabled - - webhook_url - - updated_at - - created_at - - approver_user_id properties: id: $ref: ./fields.yaml#/id_string @@ -49,14 +35,6 @@ approver_subscriptions_out: admin_subscriptions_out: type: object additionalProperties: False - required: - - id - - is_enabled - - webhook_url - - updated_at - - created_at - - org_id - - subscribed_resources properties: id: $ref: ./fields.yaml#/id_string diff --git a/src/components/schemas/user.yaml b/src/components/schemas/user.yaml index 1062e0d01..8fd2e6646 100644 --- a/src/components/schemas/user.yaml +++ b/src/components/schemas/user.yaml @@ -1,13 +1,6 @@ user_out: type: object additionalProperties: False - required: - - id - - created_at - - updated_at - - email - - full_name - - email_verified_at properties: id: $ref: './fields.yaml#/id_string' @@ -29,10 +22,6 @@ user_out: user_out_embed: type: object additionalProperties: False - required: - - id - - email - - full_name properties: id: allOf: @@ -53,10 +42,6 @@ user_out_embed_nullable: type: object nullable: true additionalProperties: False - required: - - id - - email - - full_name properties: id: allOf: @@ -76,10 +61,6 @@ user_out_nullable_example_null: type: object nullable: true additionalProperties: False - required: - - id - - email - - full_name properties: id: allOf: diff --git a/src/manager/paths/manager@employee_overview@expenses@stats.yaml b/src/manager/paths/manager@employee_overview@expenses@stats.yaml index b4e9be6b4..99481ae3e 100644 --- a/src/manager/paths/manager@employee_overview@expenses@stats.yaml +++ b/src/manager/paths/manager@employee_overview@expenses@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_expense_stats_out diff --git a/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml b/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml index 91523915e..aacf96bcc 100644 --- a/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml +++ b/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml @@ -33,8 +33,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/manager/paths/manager@employee_overview@stats.yaml b/src/manager/paths/manager@employee_overview@stats.yaml index 0b90e52b4..7eb46a92a 100644 --- a/src/manager/paths/manager@employee_overview@stats.yaml +++ b/src/manager/paths/manager@employee_overview@stats.yaml @@ -32,8 +32,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_stats_out diff --git a/src/spender/openapi.yaml b/src/spender/openapi.yaml index ed6b41066..42d044303 100644 --- a/src/spender/openapi.yaml +++ b/src/spender/openapi.yaml @@ -181,7 +181,7 @@ paths: $ref: 'paths/spender@reports@suggest_purpose.yaml' /spender/reports/filters: $ref: 'paths/spender@reports@filters.yaml' - /spender/reports/filters/delete: + /spender/reports/filters/delte: $ref: 'paths/spender@reports@filters@delete.yaml' /spender/reports/comments: $ref: 'paths/spender@reports@comments.yaml' diff --git a/src/spender/paths/spender@advance_request_files.yaml b/src/spender/paths/spender@advance_request_files.yaml index 167d26a8b..fbce63cf7 100644 --- a/src/spender/paths/spender@advance_request_files.yaml +++ b/src/spender/paths/spender@advance_request_files.yaml @@ -40,8 +40,6 @@ post: application/json: schema: type: object - required: - - data properties: url: type: string diff --git a/src/spender/paths/spender@advance_requests.yaml b/src/spender/paths/spender@advance_requests.yaml index 1e735f2ca..28d9eeaa3 100644 --- a/src/spender/paths/spender@advance_requests.yaml +++ b/src/spender/paths/spender@advance_requests.yaml @@ -70,8 +70,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml b/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml index 8da910c34..14065e4b1 100644 --- a/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml +++ b/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@advance_requests@comments.yaml b/src/spender/paths/spender@advance_requests@comments.yaml index f095c09d4..8f9b06917 100644 --- a/src/spender/paths/spender@advance_requests@comments.yaml +++ b/src/spender/paths/spender@advance_requests@comments.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_out' diff --git a/src/spender/paths/spender@advance_requests@permissions.yaml b/src/spender/paths/spender@advance_requests@permissions.yaml index 8f5d4031b..744da3b9f 100644 --- a/src/spender/paths/spender@advance_requests@permissions.yaml +++ b/src/spender/paths/spender@advance_requests@permissions.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_permissions_out' diff --git a/src/spender/paths/spender@advance_requests@pull_back.yaml b/src/spender/paths/spender@advance_requests@pull_back.yaml index db7ceba87..3c718f32a 100644 --- a/src/spender/paths/spender@advance_requests@pull_back.yaml +++ b/src/spender/paths/spender@advance_requests@pull_back.yaml @@ -28,8 +28,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/spender/paths/spender@advance_requests@stats.yaml b/src/spender/paths/spender@advance_requests@stats.yaml index 456f09cd8..79f6aa154 100644 --- a/src/spender/paths/spender@advance_requests@stats.yaml +++ b/src/spender/paths/spender@advance_requests@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_requests_stats_out' diff --git a/src/spender/paths/spender@advance_requests@submit.yaml b/src/spender/paths/spender@advance_requests@submit.yaml index 287fae1b2..f511c601e 100644 --- a/src/spender/paths/spender@advance_requests@submit.yaml +++ b/src/spender/paths/spender@advance_requests@submit.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/spender/paths/spender@advances@stats.yaml b/src/spender/paths/spender@advances@stats.yaml index 2e99a08d2..54003447c 100644 --- a/src/spender/paths/spender@advances@stats.yaml +++ b/src/spender/paths/spender@advances@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/advance.yaml#/advances_stats_out' diff --git a/src/spender/paths/spender@automations@recurring_expenses.yaml b/src/spender/paths/spender@automations@recurring_expenses.yaml index d3872e9e3..47fb46b1b 100644 --- a/src/spender/paths/spender@automations@recurring_expenses.yaml +++ b/src/spender/paths/spender@automations@recurring_expenses.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/recurring_expense.yaml#/recurring_expense_out' diff --git a/src/spender/paths/spender@automations@recurring_expenses@disable.yaml b/src/spender/paths/spender@automations@recurring_expenses@disable.yaml index 3b61eea04..d42056ac1 100644 --- a/src/spender/paths/spender@automations@recurring_expenses@disable.yaml +++ b/src/spender/paths/spender@automations@recurring_expenses@disable.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/recurring_expense.yaml#/recurring_expense_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml b/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml index 5e3202893..7d6e7c526 100644 --- a/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/spender/paths/spender@corporate_card_transactions@ignore.yaml b/src/spender/paths/spender@corporate_card_transactions@ignore.yaml index 2a34f0ea2..af8d658dd 100644 --- a/src/spender/paths/spender@corporate_card_transactions@ignore.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@ignore.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_ignore_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml b/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml index 17e2e040a..446cbb7a1 100644 --- a/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_mark_personal_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@match.yaml b/src/spender/paths/spender@corporate_card_transactions@match.yaml index 7fd39f0fd..20d943d2b 100644 --- a/src/spender/paths/spender@corporate_card_transactions@match.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@match.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_match_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml b/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml index 5da053028..b31f1e80a 100644 --- a/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_undo_ignore_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml b/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml index 49b7338fd..9a9971a12 100644 --- a/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmark_personal_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml b/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml index 59edc33a2..d6225e595 100644 --- a/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmatch_out' diff --git a/src/spender/paths/spender@email_files.yaml b/src/spender/paths/spender@email_files.yaml index 33cf8a983..ee331cce0 100644 --- a/src/spender/paths/spender@email_files.yaml +++ b/src/spender/paths/spender@email_files.yaml @@ -34,8 +34,6 @@ post: application/json: schema: type: object - required: - - data properties: url: type: string diff --git a/src/spender/paths/spender@employees.yaml b/src/spender/paths/spender@employees.yaml index 811db855e..863407815 100644 --- a/src/spender/paths/spender@employees.yaml +++ b/src/spender/paths/spender@employees.yaml @@ -66,8 +66,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/employee.yaml#/spender_employee_out' diff --git a/src/spender/paths/spender@expense_files.yaml b/src/spender/paths/spender@expense_files.yaml index 19a113422..dddcb5c0a 100644 --- a/src/spender/paths/spender@expense_files.yaml +++ b/src/spender/paths/spender@expense_files.yaml @@ -39,8 +39,6 @@ post: application/json: schema: type: object - required: - - data properties: url: type: string diff --git a/src/spender/paths/spender@expense_policy_comments.yaml b/src/spender/paths/spender@expense_policy_comments.yaml index 5c3668172..32672860a 100644 --- a/src/spender/paths/spender@expense_policy_comments.yaml +++ b/src/spender/paths/spender@expense_policy_comments.yaml @@ -58,8 +58,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: object diff --git a/src/spender/paths/spender@expenses@attach_files@bulk.yaml b/src/spender/paths/spender@expenses@attach_files@bulk.yaml index 10a43e46a..697d8e58d 100644 --- a/src/spender/paths/spender@expenses@attach_files@bulk.yaml +++ b/src/spender/paths/spender@expenses@attach_files@bulk.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@attach_receipt.yaml b/src/spender/paths/spender@expenses@attach_receipt.yaml index a2a2a0b57..7f9b03b94 100644 --- a/src/spender/paths/spender@expenses@attach_receipt.yaml +++ b/src/spender/paths/spender@expenses@attach_receipt.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/spender/paths/spender@expenses@bulk.yaml b/src/spender/paths/spender@expenses@bulk.yaml index 45a44b83d..dc552913d 100644 --- a/src/spender/paths/spender@expenses@bulk.yaml +++ b/src/spender/paths/spender@expenses@bulk.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_expenses_bulk_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@check_policies.yaml b/src/spender/paths/spender@expenses@check_policies.yaml index 6de6fd159..7127e4f80 100644 --- a/src/spender/paths/spender@expenses@check_policies.yaml +++ b/src/spender/paths/spender@expenses@check_policies.yaml @@ -29,8 +29,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_out diff --git a/src/spender/paths/spender@expenses@check_policies_bulk.yaml b/src/spender/paths/spender@expenses@check_policies_bulk.yaml index c72a9c70f..46a8d4cad 100644 --- a/src/spender/paths/spender@expenses@check_policies_bulk.yaml +++ b/src/spender/paths/spender@expenses@check_policies_bulk.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out diff --git a/src/spender/paths/spender@expenses@comments@bulk.yaml b/src/spender/paths/spender@expenses@comments@bulk.yaml index 60bf39510..9411f87fc 100644 --- a/src/spender/paths/spender@expenses@comments@bulk.yaml +++ b/src/spender/paths/spender@expenses@comments@bulk.yaml @@ -13,8 +13,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_comments_bulk_in' @@ -25,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@create_from_file@bulk.yaml b/src/spender/paths/spender@expenses@create_from_file@bulk.yaml index 593289c15..6b74fb2a7 100644 --- a/src/spender/paths/spender@expenses@create_from_file@bulk.yaml +++ b/src/spender/paths/spender@expenses@create_from_file@bulk.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@create_from_receipt.yaml b/src/spender/paths/spender@expenses@create_from_receipt.yaml index 642668b1f..ffd0a8bdd 100644 --- a/src/spender/paths/spender@expenses@create_from_receipt.yaml +++ b/src/spender/paths/spender@expenses@create_from_receipt.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/spender/paths/spender@expenses@export_configurations.yaml b/src/spender/paths/spender@expenses@export_configurations.yaml index c5b29e88e..e819a0707 100644 --- a/src/spender/paths/spender@expenses@export_configurations.yaml +++ b/src/spender/paths/spender@expenses@export_configurations.yaml @@ -158,8 +158,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expenses_export_configurations.yaml#/expenses_export_configuration_out' diff --git a/src/spender/paths/spender@expenses@exports.yaml b/src/spender/paths/spender@expenses@exports.yaml index 1e0d8906e..0736bd382 100644 --- a/src/spender/paths/spender@expenses@exports.yaml +++ b/src/spender/paths/spender@expenses@exports.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expenses_exports.yaml#/expenses_exports_out' diff --git a/src/spender/paths/spender@expenses@filters.yaml b/src/spender/paths/spender@expenses@filters.yaml index ff4e69e9a..eff9d7f67 100644 --- a/src/spender/paths/spender@expenses@filters.yaml +++ b/src/spender/paths/spender@expenses@filters.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/spender/paths/spender@expenses@filters@delete.yaml b/src/spender/paths/spender@expenses@filters@delete.yaml index 0acdb816f..144f8b063 100644 --- a/src/spender/paths/spender@expenses@filters@delete.yaml +++ b/src/spender/paths/spender@expenses@filters@delete.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/spender/paths/spender@expenses@merge.yaml b/src/spender/paths/spender@expenses@merge.yaml index 1f7c77091..9684a9e75 100644 --- a/src/spender/paths/spender@expenses@merge.yaml +++ b/src/spender/paths/spender@expenses@merge.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_merge_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/spender/paths/spender@expenses@permissions.yaml b/src/spender/paths/spender@expenses@permissions.yaml index 3364da543..d6001df6f 100644 --- a/src/spender/paths/spender@expenses@permissions.yaml +++ b/src/spender/paths/spender@expenses@permissions.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_out' diff --git a/src/spender/paths/spender@expenses@permissions@bulk.yaml b/src/spender/paths/spender@expenses@permissions@bulk.yaml index 8cfe9e758..e6c19225c 100644 --- a/src/spender/paths/spender@expenses@permissions@bulk.yaml +++ b/src/spender/paths/spender@expenses@permissions@bulk.yaml @@ -33,8 +33,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' diff --git a/src/spender/paths/spender@expenses@policy_test.yaml b/src/spender/paths/spender@expenses@policy_test.yaml index 07c740338..a28d0d139 100644 --- a/src/spender/paths/spender@expenses@policy_test.yaml +++ b/src/spender/paths/spender@expenses@policy_test.yaml @@ -14,8 +14,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_expense_in' @@ -26,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/policy.yaml#/policy_test_out' diff --git a/src/spender/paths/spender@expenses@split.yaml b/src/spender/paths/spender@expenses@split.yaml index be727a4b8..207118e4d 100644 --- a/src/spender/paths/spender@expenses@split.yaml +++ b/src/spender/paths/spender@expenses@split.yaml @@ -11,8 +11,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_split_expense_in' @@ -23,8 +21,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml b/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml index 3285f9d30..2037b253e 100644 --- a/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml +++ b/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml @@ -13,8 +13,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_split_expense_in' @@ -25,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@split@check_policies.yaml b/src/spender/paths/spender@expenses@split@check_policies.yaml index 583c809e9..deeaf5fe1 100644 --- a/src/spender/paths/spender@expenses@split@check_policies.yaml +++ b/src/spender/paths/spender@expenses@split@check_policies.yaml @@ -14,8 +14,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_split_expense_in' @@ -26,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@stats.yaml b/src/spender/paths/spender@expenses@stats.yaml index 0bf898b7c..ee129cee4 100644 --- a/src/spender/paths/spender@expenses@stats.yaml +++ b/src/spender/paths/spender@expenses@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_stats_out' diff --git a/src/spender/paths/spender@files.yaml b/src/spender/paths/spender@files.yaml index 053d51b3f..eed5916ba 100644 --- a/src/spender/paths/spender@files.yaml +++ b/src/spender/paths/spender@files.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/file.yaml#/file_out diff --git a/src/spender/paths/spender@files@bulk.yaml b/src/spender/paths/spender@files@bulk.yaml index ae24251cd..0e90578db 100644 --- a/src/spender/paths/spender@files@bulk.yaml +++ b/src/spender/paths/spender@files@bulk.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@files@generate_urls.yaml b/src/spender/paths/spender@files@generate_urls.yaml index 8a3c6233b..4a7180a10 100644 --- a/src/spender/paths/spender@files@generate_urls.yaml +++ b/src/spender/paths/spender@files@generate_urls.yaml @@ -27,8 +27,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/file.yaml#/file_generate_urls_action_out diff --git a/src/spender/paths/spender@files@generate_urls@bulk.yaml b/src/spender/paths/spender@files@generate_urls@bulk.yaml index 13432b189..e132a077e 100644 --- a/src/spender/paths/spender@files@generate_urls@bulk.yaml +++ b/src/spender/paths/spender@files@generate_urls@bulk.yaml @@ -32,8 +32,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@files@upload_html.yaml b/src/spender/paths/spender@files@upload_html.yaml index b2f0c49b9..dfacbc82d 100644 --- a/src/spender/paths/spender@files@upload_html.yaml +++ b/src/spender/paths/spender@files@upload_html.yaml @@ -37,8 +37,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/file.yaml#/file_out_download_url diff --git a/src/spender/paths/spender@personal_card_transactions@stats.yaml b/src/spender/paths/spender@personal_card_transactions@stats.yaml index d15303184..9b2c4a2a5 100644 --- a/src/spender/paths/spender@personal_card_transactions@stats.yaml +++ b/src/spender/paths/spender@personal_card_transactions@stats.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data additionalProperties: False properties: data: diff --git a/src/spender/paths/spender@personal_cards.yaml b/src/spender/paths/spender@personal_cards.yaml index 6a16a44c8..0d9510cc1 100644 --- a/src/spender/paths/spender@personal_cards.yaml +++ b/src/spender/paths/spender@personal_cards.yaml @@ -19,8 +19,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: array diff --git a/src/spender/paths/spender@reports@add_expenses.yaml b/src/spender/paths/spender@reports@add_expenses.yaml index 762ca0bca..d84f51bf9 100644 --- a/src/spender/paths/spender@reports@add_expenses.yaml +++ b/src/spender/paths/spender@reports@add_expenses.yaml @@ -24,8 +24,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@comments.yaml b/src/spender/paths/spender@reports@comments.yaml index 7e3628021..883b28497 100644 --- a/src/spender/paths/spender@reports@comments.yaml +++ b/src/spender/paths/spender@reports@comments.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_comments_out' diff --git a/src/spender/paths/spender@reports@eject_expenses.yaml b/src/spender/paths/spender@reports@eject_expenses.yaml index 76358806b..ceeb17152 100644 --- a/src/spender/paths/spender@reports@eject_expenses.yaml +++ b/src/spender/paths/spender@reports@eject_expenses.yaml @@ -26,8 +26,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@export_configurations.yaml b/src/spender/paths/spender@reports@export_configurations.yaml index e19fcb464..4f63e5a79 100644 --- a/src/spender/paths/spender@reports@export_configurations.yaml +++ b/src/spender/paths/spender@reports@export_configurations.yaml @@ -83,8 +83,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/reports_export_configurations.yaml#/reports_export_configuration_out' diff --git a/src/spender/paths/spender@reports@exports.yaml b/src/spender/paths/spender@reports@exports.yaml index 9d98a5198..ae9c462cd 100644 --- a/src/spender/paths/spender@reports@exports.yaml +++ b/src/spender/paths/spender@reports@exports.yaml @@ -64,8 +64,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/reports_exports.yaml#/reports_exports_out' diff --git a/src/spender/paths/spender@reports@filters.yaml b/src/spender/paths/spender@reports@filters.yaml index 4b06a8705..88472399f 100644 --- a/src/spender/paths/spender@reports@filters.yaml +++ b/src/spender/paths/spender@reports@filters.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/spender/paths/spender@reports@filters@delete.yaml b/src/spender/paths/spender@reports@filters@delete.yaml index 63bceca83..50d56712a 100644 --- a/src/spender/paths/spender@reports@filters@delete.yaml +++ b/src/spender/paths/spender@reports@filters@delete.yaml @@ -23,8 +23,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/spender/paths/spender@reports@permissions.yaml b/src/spender/paths/spender@reports@permissions.yaml index 71ca3ad25..00c0674d9 100644 --- a/src/spender/paths/spender@reports@permissions.yaml +++ b/src/spender/paths/spender@reports@permissions.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report_permissions.yaml#/report_permissions_out' diff --git a/src/spender/paths/spender@reports@resubmit.yaml b/src/spender/paths/spender@reports@resubmit.yaml index 55b68d276..d031ff6b6 100644 --- a/src/spender/paths/spender@reports@resubmit.yaml +++ b/src/spender/paths/spender@reports@resubmit.yaml @@ -24,8 +24,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@stats.yaml b/src/spender/paths/spender@reports@stats.yaml index 029c82d13..bd00c4e13 100644 --- a/src/spender/paths/spender@reports@stats.yaml +++ b/src/spender/paths/spender@reports@stats.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/reports_stats_out' diff --git a/src/spender/paths/spender@reports@submit.yaml b/src/spender/paths/spender@reports@submit.yaml index 3b521a248..c655c82df 100644 --- a/src/spender/paths/spender@reports@submit.yaml +++ b/src/spender/paths/spender@reports@submit.yaml @@ -24,8 +24,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@suggest_purpose.yaml b/src/spender/paths/spender@reports@suggest_purpose.yaml index 3079e4f37..62e20eac5 100644 --- a/src/spender/paths/spender@reports@suggest_purpose.yaml +++ b/src/spender/paths/spender@reports@suggest_purpose.yaml @@ -24,8 +24,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: '../../components/schemas/report.yaml#/report_purpose_out' diff --git a/src/spender/paths/spender@schedules.yaml b/src/spender/paths/spender@schedules.yaml index 13cf2a8f6..7ed0100ad 100644 --- a/src/spender/paths/spender@schedules.yaml +++ b/src/spender/paths/spender@schedules.yaml @@ -25,8 +25,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/schedule.yaml#/schedule_out diff --git a/src/spender/paths/spender@secondary_emails.yaml b/src/spender/paths/spender@secondary_emails.yaml index d5f554748..4d964929a 100644 --- a/src/spender/paths/spender@secondary_emails.yaml +++ b/src/spender/paths/spender@secondary_emails.yaml @@ -66,8 +66,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: $ref: ../../components/schemas/secondary_email.yaml#/secondary_email_out diff --git a/src/spender/paths/spender@secondary_emails@check.yaml b/src/spender/paths/spender@secondary_emails@check.yaml index 4f316949c..20eb49ab5 100644 --- a/src/spender/paths/spender@secondary_emails@check.yaml +++ b/src/spender/paths/spender@secondary_emails@check.yaml @@ -35,8 +35,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: object diff --git a/src/spender/paths/spender@secondary_emails@delete.yaml b/src/spender/paths/spender@secondary_emails@delete.yaml index 273910199..2def9c992 100644 --- a/src/spender/paths/spender@secondary_emails@delete.yaml +++ b/src/spender/paths/spender@secondary_emails@delete.yaml @@ -35,8 +35,6 @@ post: schema: type: object additionalProperties: False - required: - - data properties: data: type: object diff --git a/src/spender/paths/spender@subscriptions.yaml b/src/spender/paths/spender@subscriptions.yaml index d9ab5b93a..fae027bcc 100644 --- a/src/spender/paths/spender@subscriptions.yaml +++ b/src/spender/paths/spender@subscriptions.yaml @@ -11,8 +11,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/subscriptions_in' @@ -24,8 +22,6 @@ post: schema: type: object additionalProperties: false - required: - - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/spender_subscriptions_out' diff --git a/src/spender/paths/spender@virtual_cards@get_current_amount.yaml b/src/spender/paths/spender@virtual_cards@get_current_amount.yaml index c241f2727..7de87d1e4 100644 --- a/src/spender/paths/spender@virtual_cards@get_current_amount.yaml +++ b/src/spender/paths/spender@virtual_cards@get_current_amount.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_get_current_balance_out' diff --git a/src/spender/paths/spender@virtual_cards@show_card_details.yaml b/src/spender/paths/spender@virtual_cards@show_card_details.yaml index 017381b29..49e8b924f 100644 --- a/src/spender/paths/spender@virtual_cards@show_card_details.yaml +++ b/src/spender/paths/spender@virtual_cards@show_card_details.yaml @@ -24,8 +24,6 @@ post: application/json: schema: type: object - required: - - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_show_card_details_out' From 02efe0625858cdb01358bd5b765bb017320849f7 Mon Sep 17 00:00:00 2001 From: Tirth Bhagwat Date: Thu, 6 Aug 2026 15:57:29 +0530 Subject: [PATCH 088/107] feat: Add advanced mileage rate properties (#842) * feat: add advanced mileage rate properties for mileage rate apis * adding ref folder * Auto generate API docs * fix mileage rate docs * Auto generate API docs * refactor: update mileage rate properties to be optional in schema * Auto generate API docs --- reference/admin.yaml | 109 ++++++++++++++++++ reference/approver.yaml | 57 +++++++++ reference/spender.yaml | 57 +++++++++ .../paths/approver@mileage_rates.yaml | 2 +- src/components/schemas/mileage_rate.yaml | 109 ++++++++++++++++++ 5 files changed, 333 insertions(+), 1 deletion(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index c609fa7c3..3b5f0e7a8 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -17422,6 +17422,11 @@ components: - slab_rates - is_enabled - code + - vehicle_ownership + - vehicle_category + - fuel_type + - engine_capacity + - charging_location properties: id: $ref: '#/components/schemas/id_integer' @@ -17462,6 +17467,58 @@ components: $ref: '#/components/schemas/is_enabled' code: $ref: '#/components/schemas/code' + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Vehicle ownership for advanced mileage rates. `null` for basic mileage rates. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Vehicle category for advanced mileage rates. `null` for basic mileage rates. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Fuel type for advanced car mileage rates. `null` otherwise. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Engine capacity band for petrol, diesel, and LPG advanced car rates. An empty object for basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Charging location for advanced electric car mileage rates. `null` otherwise. mileage_rate_in: type: object required: @@ -17503,6 +17560,58 @@ components: $ref: '#/components/schemas/is_enabled' code: $ref: '#/components/schemas/code' + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Optional. Use `null` for a basic mileage rate; an advanced rate requires a non-null value. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Optional. Use `null` for a basic mileage rate; an advanced rate requires a non-null value. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Optional. Use `null` for motorcycles, bicycles, and basic mileage rates. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Optional. Use an empty object for electric and basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Optional. Use `null` unless the rate is an advanced electric car. mileage_rate_in_only_id: type: object required: diff --git a/reference/approver.yaml b/reference/approver.yaml index 1fa85bd52..8aa8f489d 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -8830,6 +8830,11 @@ components: - slab_rates - is_enabled - code + - vehicle_ownership + - vehicle_category + - fuel_type + - engine_capacity + - charging_location properties: id: $ref: '#/components/schemas/id_integer' @@ -8870,6 +8875,58 @@ components: $ref: '#/components/schemas/is_enabled' code: $ref: '#/components/schemas/code' + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Vehicle ownership for advanced mileage rates. `null` for basic mileage rates. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Vehicle category for advanced mileage rates. `null` for basic mileage rates. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Fuel type for advanced car mileage rates. `null` otherwise. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Engine capacity band for petrol, diesel, and LPG advanced car rates. An empty object for basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Charging location for advanced electric car mileage rates. `null` otherwise. expense_policy_rule_embed: type: object additionalProperties: false diff --git a/reference/spender.yaml b/reference/spender.yaml index 414f89946..2d25945d9 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -8213,6 +8213,11 @@ components: - slab_rates - is_enabled - code + - vehicle_ownership + - vehicle_category + - fuel_type + - engine_capacity + - charging_location properties: id: $ref: '#/components/schemas/id_integer' @@ -8253,6 +8258,58 @@ components: $ref: '#/components/schemas/is_enabled' code: $ref: '#/components/schemas/code' + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Vehicle ownership for advanced mileage rates. `null` for basic mileage rates. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Vehicle category for advanced mileage rates. `null` for basic mileage rates. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Fuel type for advanced car mileage rates. `null` otherwise. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Engine capacity band for petrol, diesel, and LPG advanced car rates. An empty object for basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Charging location for advanced electric car mileage rates. `null` otherwise. user_id: type: string description: | diff --git a/src/approver/paths/approver@mileage_rates.yaml b/src/approver/paths/approver@mileage_rates.yaml index e970fe75e..440abc29e 100644 --- a/src/approver/paths/approver@mileage_rates.yaml +++ b/src/approver/paths/approver@mileage_rates.yaml @@ -36,4 +36,4 @@ get: content: application/json: schema: - $ref: ../../components/schemas/401.yaml \ No newline at end of file + $ref: ../../components/schemas/401.yaml diff --git a/src/components/schemas/mileage_rate.yaml b/src/components/schemas/mileage_rate.yaml index 94236a01c..207d9c4b2 100644 --- a/src/components/schemas/mileage_rate.yaml +++ b/src/components/schemas/mileage_rate.yaml @@ -12,6 +12,11 @@ mileage_rate_out: - slab_rates - is_enabled - code + - vehicle_ownership + - vehicle_category + - fuel_type + - engine_capacity + - charging_location properties: id: $ref: './fields.yaml#/id_integer' @@ -56,6 +61,58 @@ mileage_rate_out: $ref: ./fields.yaml#/is_enabled code: $ref: ./fields.yaml#/code + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Vehicle ownership for advanced mileage rates. `null` for basic mileage rates. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Vehicle category for advanced mileage rates. `null` for basic mileage rates. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Fuel type for advanced car mileage rates. `null` otherwise. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Engine capacity band for petrol, diesel, and LPG advanced car rates. An empty object for basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Charging location for advanced electric car mileage rates. `null` otherwise. mileage_rate_out_embed: type: object @@ -133,6 +190,58 @@ mileage_rate_in: $ref: ./fields.yaml#/is_enabled code: $ref: ./fields.yaml#/code + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Optional. Use `null` for a basic mileage rate; an advanced rate requires a non-null value. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Optional. Use `null` for a basic mileage rate; an advanced rate requires a non-null value. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Optional. Use `null` for motorcycles, bicycles, and basic mileage rates. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Optional. Use an empty object for electric and basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Optional. Use `null` unless the rate is an advanced electric car. mileage_rate_in_only_id: type: object From 1720e620433a6a321fbe60028ede831be726dc2d Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 10 Aug 2026 10:26:58 +0530 Subject: [PATCH 089/107] chore: update required fields (#858) --- reference/accountant.yaml | 6 + reference/admin.yaml | 1132 ++++++++++++++++- reference/approver.yaml | 456 ++++++- reference/common.yaml | 20 + reference/hod.yaml | 6 + reference/hop.yaml | 6 + reference/manager.yaml | 141 ++ reference/spender.yaml | 762 ++++++++++- .../admin@accounting_export_lineitems.yaml | 2 + src/admin/paths/admin@accounting_exports.yaml | 2 + src/admin/paths/admin@accounts.yaml | 2 + src/admin/paths/admin@advance_refunds.yaml | 2 + .../paths/admin@advance_refunds@stats.yaml | 2 + src/admin/paths/admin@advance_requests.yaml | 2 + .../admin@advance_requests@add_approver.yaml | 4 + ...min@advance_requests@bulk_attach_file.yaml | 2 + .../admin@advance_requests@comments.yaml | 4 + .../admin@advance_requests@custom_fields.yaml | 2 + .../paths/admin@advance_requests@inquire.yaml | 2 + .../admin@advance_requests@permissions.yaml | 2 + .../paths/admin@advance_requests@reject.yaml | 2 + ...dmin@advance_requests@remove_approver.yaml | 4 + .../paths/admin@advance_requests@stats.yaml | 2 + .../paths/admin@advance_requests@submit.yaml | 2 + src/admin/paths/admin@advance_wallets.yaml | 2 + src/admin/paths/admin@advances.yaml | 2 + src/admin/paths/admin@advances@stats.yaml | 2 + .../admin@automations@report_submissions.yaml | 2 + ...automations@report_submissions@delete.yaml | 2 + src/admin/paths/admin@budgets.yaml | 2 + src/admin/paths/admin@budgets@exports.yaml | 2 + src/admin/paths/admin@categories.yaml | 2 + .../admin@categories@system_categories.yaml | 1 + .../admin@corporate_card_transactions.yaml | 2 + ...in@corporate_card_transactions@assign.yaml | 2 + ...in@corporate_card_transactions@delete.yaml | 2 + ...card_transactions@delete_summary@bulk.yaml | 2 + ...rd_transactions@export_configurations.yaml | 2 + ...n@corporate_card_transactions@exports.yaml | 2 + ...n@corporate_card_transactions@filters.yaml | 2 + ...rate_card_transactions@filters@delete.yaml | 2 + ...in@corporate_card_transactions@ignore.yaml | 2 + ...orate_card_transactions@mark_personal.yaml | 2 + ...min@corporate_card_transactions@match.yaml | 2 + ...min@corporate_card_transactions@stats.yaml | 2 + ...@corporate_card_transactions@unassign.yaml | 2 + ...rporate_card_transactions@undo_ignore.yaml | 2 + ...ate_card_transactions@unmark_personal.yaml | 2 + ...n@corporate_card_transactions@unmatch.yaml | 2 + src/admin/paths/admin@corporate_cards.yaml | 2 + .../paths/admin@corporate_cards@archive.yaml | 2 + ...ate_cards@archive_suggestions@dismiss.yaml | 2 + .../paths/admin@corporate_cards@assign.yaml | 2 + .../admin@corporate_cards@bank_names.yaml | 2 + .../paths/admin@corporate_cards@delete.yaml | 2 + ...e_cards@duplicate_suggestions@dismiss.yaml | 2 + .../paths/admin@corporate_cards@merge.yaml | 2 + .../paths/admin@corporate_cards@reassign.yaml | 2 + .../paths/admin@corporate_cards@stats.yaml | 2 + .../admin@corporate_cards@unarchive.yaml | 2 + .../admin@corporate_cards@unarchive@bulk.yaml | 2 + .../paths/admin@corporate_cards@unassign.yaml | 2 + src/admin/paths/admin@cost_centers.yaml | 2 + src/admin/paths/admin@departments.yaml | 2 + ...endent_expense_field_values@downloads.yaml | 2 + ...ependent_expense_field_values@uploads.yaml | 2 + src/admin/paths/admin@dwolla_customers.yaml | 2 + src/admin/paths/admin@employee_fields.yaml | 2 + .../paths/admin@employees@downloads.yaml | 2 + ...admin@employees@export_configurations.yaml | 2 + src/admin/paths/admin@employees@exports.yaml | 2 + src/admin/paths/admin@employees@filters.yaml | 2 + .../paths/admin@employees@filters@delete.yaml | 2 + src/admin/paths/admin@employees@stats.yaml | 2 + src/admin/paths/admin@employees@uploads.yaml | 2 + src/admin/paths/admin@expense_fields.yaml | 2 + src/admin/paths/admin@expense_policies.yaml | 2 + .../paths/admin@expense_policies@disable.yaml | 2 + .../paths/admin@expense_policies@enable.yaml | 2 + .../paths/admin@expense_policy_comments.yaml | 2 + src/admin/paths/admin@expenses.yaml | 4 + .../admin@expenses@attach_files@bulk.yaml | 2 + src/admin/paths/admin@expenses@bulk.yaml | 4 + .../admin@expenses@check_policies_bulk.yaml | 2 + .../paths/admin@expenses@comments@bulk.yaml | 4 + .../admin@expenses@export_configurations.yaml | 2 + src/admin/paths/admin@expenses@exports.yaml | 2 + src/admin/paths/admin@expenses@filters.yaml | 2 + .../paths/admin@expenses@filters@delete.yaml | 2 + src/admin/paths/admin@expenses@merge.yaml | 4 + .../paths/admin@expenses@permissions.yaml | 2 + .../admin@expenses@permissions@bulk.yaml | 2 + src/admin/paths/admin@expenses@split.yaml | 4 + ...expenses@split@check_mandatory_fields.yaml | 4 + .../admin@expenses@split@check_policies.yaml | 4 + src/admin/paths/admin@expenses@stats.yaml | 2 + src/admin/paths/admin@files.yaml | 2 + src/admin/paths/admin@files@bulk.yaml | 2 + .../paths/admin@files@generate_urls@bulk.yaml | 2 + src/admin/paths/admin@levels.yaml | 2 + src/admin/paths/admin@mileage_rates.yaml | 2 + src/admin/paths/admin@per_diem_rates.yaml | 2 + src/admin/paths/admin@projects.yaml | 2 + .../admin@reconciliation_entries@close.yaml | 2 + ...iation_entries@eligible_cards@exports.yaml | 2 + ...iliation_entries@eligible_cards@stats.yaml | 2 + ...tion_entries@transactions@delete@bulk.yaml | 2 + ...iliation_entries@transactions@exports.yaml | 2 + ...ation_entries@transactions@find_match.yaml | 2 + ...transactions@match_and_reconcile@bulk.yaml | 2 + ...transactions@move_to_next_period@bulk.yaml | 2 + ...n_entries@transactions@reconcile@bulk.yaml | 2 + ...es@transactions@resolve_multi_matches.yaml | 2 + ...nciliation_entries@transactions@stats.yaml | 2 + ...ion_entries@transactions@unmatch@bulk.yaml | 2 + .../admin@reimbursements@mark_complete.yaml | 2 + src/admin/paths/admin@reminders.yaml | 2 + src/admin/paths/admin@reminders@delete.yaml | 2 + src/admin/paths/admin@reminders@stats.yaml | 2 + .../paths/admin@reports@add_approver.yaml | 2 + .../admin@reports@apply_advance_wallets.yaml | 2 + src/admin/paths/admin@reports@comments.yaml | 2 + .../paths/admin@reports@delete_filter.yaml | 2 + .../paths/admin@reports@eject_expenses.yaml | 2 + .../admin@reports@export_configurations.yaml | 2 + src/admin/paths/admin@reports@exports.yaml | 2 + .../paths/admin@reports@permissions.yaml | 2 + .../admin@reports@process_summary@bulk.yaml | 2 + .../admin@reports@remove_advance_wallets.yaml | 2 + .../paths/admin@reports@remove_approver.yaml | 2 + .../admin@reports@revert_to_approved.yaml | 2 + .../admin@reports@revert_to_processing.yaml | 2 + .../paths/admin@reports@round_off_amount.yaml | 2 + .../paths/admin@reports@save_filters.yaml | 2 + src/admin/paths/admin@reports@send_back.yaml | 2 + src/admin/paths/admin@reports@stats.yaml | 2 + .../paths/admin@scheduled_callbacks.yaml | 2 + src/admin/paths/admin@schedules.yaml | 2 + .../admin@statements@archived_cards.yaml | 2 + ...dmin@statements@archived_cards@ignore.yaml | 2 + .../paths/admin@statements@card_stats.yaml | 2 + .../admin@statements@matching_cards.yaml | 2 + src/admin/paths/admin@statements@preview.yaml | 2 + .../paths/admin@statements@reconcile.yaml | 2 + ...min@statements@reconciliation_summary.yaml | 2 + .../admin@statements@suggest_mappings.yaml | 2 + src/admin/paths/admin@statements@summary.yaml | 2 + .../admin@statements@unassigned_cards.yaml | 2 + src/admin/paths/admin@statements@upload.yaml | 2 + src/admin/paths/admin@subscriptions.yaml | 4 + src/admin/paths/admin@tax_groups.yaml | 2 + .../paths/admin@virtual_cards@delete.yaml | 2 + ...dmin@virtual_cards@get_current_amount.yaml | 2 + ...admin@virtual_cards@show_card_details.yaml | 2 + ...pprover@advance_requests@add_approver.yaml | 4 + ...ver@advance_requests@bulk_attach_file.yaml | 2 + .../approver@advance_requests@comments.yaml | 4 + ...ance_requests@generate_file_urls@bulk.yaml | 2 + .../approver@advance_requests@inquire.yaml | 2 + ...er@advance_requests@partially_approve.yaml | 2 + ...approver@advance_requests@permissions.yaml | 2 + .../approver@advance_requests@reject.yaml | 2 + .../approver@advance_requests@stats.yaml | 2 + .../approver@advance_requests@submit.yaml | 2 + ...ver@corporate_card_transactions@match.yaml | 2 + ...r@corporate_card_transactions@unmatch.yaml | 2 + ...over@employee_overview@expenses@stats.yaml | 2 + .../approver@employee_overview@stats.yaml | 2 + src/approver/paths/approver@expenses.yaml | 4 + .../approver@expenses@attach_files@bulk.yaml | 2 + .../paths/approver@expenses@bulk.yaml | 4 + ...approver@expenses@check_policies_bulk.yaml | 2 + .../approver@expenses@comments@bulk.yaml | 4 + ...prover@expenses@export_configurations.yaml | 2 + .../paths/approver@expenses@exports.yaml | 2 + .../paths/approver@expenses@filters.yaml | 2 + .../approver@expenses@filters@delete.yaml | 2 + .../paths/approver@expenses@permissions.yaml | 2 + .../approver@expenses@permissions@bulk.yaml | 2 + .../paths/approver@expenses@split.yaml | 4 + ...expenses@split@check_mandatory_fields.yaml | 4 + ...pprover@expenses@split@check_policies.yaml | 4 + .../paths/approver@expenses@stats.yaml | 2 + src/approver/paths/approver@files@bulk.yaml | 2 + .../approver@files@generate_urls@bulk.yaml | 2 + .../paths/approver@reports@add_approver.yaml | 2 + .../paths/approver@reports@add_expenses.yaml | 2 + .../paths/approver@reports@comments.yaml | 2 + .../approver@reports@eject_expenses.yaml | 2 + ...pprover@reports@export_configurations.yaml | 2 + .../paths/approver@reports@exports.yaml | 2 + .../paths/approver@reports@filters.yaml | 2 + .../approver@reports@filters@delete.yaml | 2 + .../approver@reports@partially_approve.yaml | 2 + .../paths/approver@reports@permissions.yaml | 2 + .../approver@reports@round_off_amount.yaml | 2 + .../paths/approver@reports@send_back.yaml | 2 + .../paths/approver@reports@stats.yaml | 2 + .../paths/approver@subscriptions.yaml | 4 + ...g_logo_settings@generate_download_url.yaml | 2 + src/components/schemas/account.yaml | 23 + src/components/schemas/advance.yaml | 11 + src/components/schemas/advance_refund.yaml | 5 + src/components/schemas/advance_request.yaml | 64 +- .../schemas/advance_request_approval.yaml | 4 + src/components/schemas/advance_wallet.yaml | 3 + src/components/schemas/budget.yaml | 19 +- src/components/schemas/budget_exports.yaml | 9 + src/components/schemas/category.yaml | 12 + src/components/schemas/corporate_card.yaml | 29 +- .../schemas/corporate_card_transaction.yaml | 35 + .../corporate_card_transactions_exports.yaml | 14 + .../corporate_credit_card_expense.yaml | 4 + src/components/schemas/cost_center.yaml | 6 + src/components/schemas/currency.yaml | 2 + src/components/schemas/department.yaml | 13 + .../dependent_expense_field_values.yaml | 35 + src/components/schemas/employee.yaml | 122 +- .../schemas/employee_account_summary.yaml | 18 + src/components/schemas/employee_settings.yaml | 23 + .../employees_export_configurations.yaml | 10 - src/components/schemas/employees_exports.yaml | 14 + src/components/schemas/expense.yaml | 43 + .../schemas/expense_duplicate_set.yaml | 5 + src/components/schemas/expense_field.yaml | 19 + src/components/schemas/expense_policies.yaml | 3 + src/components/schemas/expense_rules.yaml | 16 + .../expenses_export_configurations.yaml | 10 - src/components/schemas/expenses_exports.yaml | 11 + src/components/schemas/feature_configs.yaml | 11 + src/components/schemas/fields.yaml | 6 + src/components/schemas/file.yaml | 27 + src/components/schemas/level.yaml | 2 + src/components/schemas/merchant.yaml | 11 + src/components/schemas/mileage_rate.yaml | 14 + .../schemas/mobile_app_version.yaml | 7 + src/components/schemas/my_profile.yaml | 6 + src/components/schemas/org.yaml | 26 + src/components/schemas/org_settings.yaml | 5 + src/components/schemas/per_diem_rate.yaml | 6 + src/components/schemas/personal_card.yaml | 21 + .../schemas/personal_card_transaction.yaml | 34 + src/components/schemas/place.yaml | 11 + src/components/schemas/policy.yaml | 3 + src/components/schemas/project.yaml | 11 + .../reconciliation_eligible_cards.yaml | 15 + .../schemas/reconciliation_exports.yaml | 9 + .../schemas/reconciliation_transactions.yaml | 22 + src/components/schemas/recurring_expense.yaml | 6 +- src/components/schemas/reimbursement.yaml | 8 + src/components/schemas/reminder.yaml | 12 + src/components/schemas/report.yaml | 36 + src/components/schemas/report_approval.yaml | 4 + .../reports_export_configurations.yaml | 10 - src/components/schemas/schedule.yaml | 8 + .../schemas/scheduled_callback.yaml | 14 + src/components/schemas/secondary_email.yaml | 8 + src/components/schemas/spend_overview.yaml | 42 + src/components/schemas/statements.yaml | 41 +- src/components/schemas/subscriptions.yaml | 22 + src/components/schemas/user.yaml | 19 + ...ager@employee_overview@expenses@stats.yaml | 2 + ...yee_overview@files@generate_urls@bulk.yaml | 2 + .../manager@employee_overview@stats.yaml | 2 + src/spender/openapi.yaml | 2 +- .../paths/spender@advance_request_files.yaml | 2 + .../paths/spender@advance_requests.yaml | 2 + ...der@advance_requests@bulk_attach_file.yaml | 2 + .../spender@advance_requests@comments.yaml | 4 + .../spender@advance_requests@permissions.yaml | 2 + .../spender@advance_requests@pull_back.yaml | 2 + .../paths/spender@advance_requests@stats.yaml | 2 + .../spender@advance_requests@submit.yaml | 2 + src/spender/paths/spender@advances@stats.yaml | 2 + ...pender@automations@recurring_expenses.yaml | 2 + ...utomations@recurring_expenses@disable.yaml | 2 + ...rate_card_transactions@expenses@stats.yaml | 2 + ...er@corporate_card_transactions@ignore.yaml | 2 + ...orate_card_transactions@mark_personal.yaml | 2 + ...der@corporate_card_transactions@match.yaml | 2 + ...rporate_card_transactions@undo_ignore.yaml | 2 + ...ate_card_transactions@unmark_personal.yaml | 2 + ...r@corporate_card_transactions@unmatch.yaml | 2 + src/spender/paths/spender@email_files.yaml | 2 + src/spender/paths/spender@employees.yaml | 2 + src/spender/paths/spender@expense_files.yaml | 2 + .../spender@expense_policy_comments.yaml | 2 + .../spender@expenses@attach_files@bulk.yaml | 2 + .../spender@expenses@attach_receipt.yaml | 2 + src/spender/paths/spender@expenses@bulk.yaml | 4 + .../spender@expenses@check_policies.yaml | 2 + .../spender@expenses@check_policies_bulk.yaml | 2 + .../paths/spender@expenses@comments@bulk.yaml | 4 + ...pender@expenses@create_from_file@bulk.yaml | 2 + .../spender@expenses@create_from_receipt.yaml | 2 + ...pender@expenses@export_configurations.yaml | 2 + .../paths/spender@expenses@exports.yaml | 2 + .../paths/spender@expenses@filters.yaml | 2 + .../spender@expenses@filters@delete.yaml | 2 + src/spender/paths/spender@expenses@merge.yaml | 4 + .../paths/spender@expenses@permissions.yaml | 2 + .../spender@expenses@permissions@bulk.yaml | 2 + .../paths/spender@expenses@policy_test.yaml | 4 + src/spender/paths/spender@expenses@split.yaml | 4 + ...expenses@split@check_mandatory_fields.yaml | 4 + ...spender@expenses@split@check_policies.yaml | 4 + src/spender/paths/spender@expenses@stats.yaml | 2 + src/spender/paths/spender@files.yaml | 2 + src/spender/paths/spender@files@bulk.yaml | 2 + .../paths/spender@files@generate_urls.yaml | 2 + .../spender@files@generate_urls@bulk.yaml | 2 + .../paths/spender@files@upload_html.yaml | 2 + ...nder@personal_card_transactions@stats.yaml | 2 + src/spender/paths/spender@personal_cards.yaml | 2 + .../paths/spender@reports@add_expenses.yaml | 2 + .../paths/spender@reports@comments.yaml | 2 + .../paths/spender@reports@eject_expenses.yaml | 2 + ...spender@reports@export_configurations.yaml | 2 + .../paths/spender@reports@exports.yaml | 2 + .../paths/spender@reports@filters.yaml | 2 + .../paths/spender@reports@filters@delete.yaml | 2 + .../paths/spender@reports@permissions.yaml | 2 + .../paths/spender@reports@resubmit.yaml | 2 + src/spender/paths/spender@reports@stats.yaml | 2 + src/spender/paths/spender@reports@submit.yaml | 2 + .../spender@reports@suggest_purpose.yaml | 2 + src/spender/paths/spender@schedules.yaml | 2 + .../paths/spender@secondary_emails.yaml | 2 + .../paths/spender@secondary_emails@check.yaml | 2 + .../spender@secondary_emails@delete.yaml | 2 + src/spender/paths/spender@subscriptions.yaml | 4 + ...nder@virtual_cards@get_current_amount.yaml | 2 + ...ender@virtual_cards@show_card_details.yaml | 2 + 333 files changed, 3983 insertions(+), 190 deletions(-) diff --git a/reference/accountant.yaml b/reference/accountant.yaml index 67e660e74..4d6485071 100644 --- a/reference/accountant.yaml +++ b/reference/accountant.yaml @@ -190,6 +190,12 @@ components: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/admin.yaml b/reference/admin.yaml index 3b5f0e7a8..ba3960cc9 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -182,6 +182,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_approver_project_out' @@ -439,6 +441,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_cost_center_out' @@ -690,6 +694,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_approver_category_out' @@ -892,6 +898,7 @@ paths: additionalProperties: false required: - data + - count properties: count: $ref: '#/components/schemas/count' @@ -974,6 +981,8 @@ paths: application/json: schema: type: object + required: + - data properties: url: type: string @@ -1330,6 +1339,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/dependent_expense_field_values_upload_out' @@ -1422,6 +1433,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/dependent_expense_field_values_download_out' @@ -1512,6 +1525,8 @@ paths: application/json: schema: type: object + required: + - data properties: url: type: string @@ -1609,6 +1624,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/per_diem_rate_out' @@ -1848,6 +1865,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/department_out' @@ -2082,6 +2101,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/mileage_rate_out' @@ -2379,6 +2400,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/level_out' @@ -2617,6 +2640,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/employees_stats_out' @@ -2757,6 +2782,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employees_exports_out' @@ -3004,6 +3031,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employee_filters_out' @@ -3085,6 +3114,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employee_filters_out' @@ -3178,6 +3209,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employees_upload_out' @@ -3271,6 +3304,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employees_download_out' @@ -3507,6 +3542,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/employees_export_configuration_out' @@ -3646,6 +3683,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/file_out' @@ -3703,6 +3742,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -3779,6 +3820,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -3937,6 +3980,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/automate_report_submission_out' @@ -4031,6 +4076,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/automate_report_submission_out' @@ -4126,6 +4173,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/accounting_export_out' @@ -4221,6 +4270,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/accounting_export_lineitem_out' @@ -4358,6 +4409,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_expense_in' @@ -4368,6 +4421,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -4409,6 +4464,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_expenses_bulk_in' @@ -4419,6 +4476,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -4478,6 +4537,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -4582,6 +4643,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -4669,6 +4732,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -4793,6 +4858,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expenses_stats_out' @@ -4846,6 +4913,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_exports_out' @@ -5017,6 +5086,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_export_configuration_out' @@ -5158,6 +5229,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_out' @@ -5221,6 +5294,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_bulk_out' @@ -5287,6 +5362,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_merge_in' @@ -5297,6 +5374,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -5397,6 +5476,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -5452,6 +5533,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_requests_stats_out' @@ -5507,6 +5590,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_permissions_out' @@ -5548,6 +5633,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_in' @@ -5558,6 +5645,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_out' @@ -5599,6 +5688,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_remove_approver_in' @@ -5613,6 +5704,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -5723,6 +5816,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_out' @@ -5833,6 +5928,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advances_stats_out' @@ -5933,6 +6030,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_wallet_out' @@ -6033,6 +6132,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_refund_out' @@ -6142,6 +6243,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -6237,6 +6340,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reminder_out' @@ -6291,6 +6396,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -6346,6 +6453,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -6499,6 +6608,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -6546,6 +6657,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -6633,6 +6746,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -6687,6 +6802,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_comments_out' @@ -6736,6 +6853,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -6789,6 +6908,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -6899,6 +7020,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -6954,6 +7077,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7014,6 +7139,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7258,6 +7385,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -7387,6 +7516,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reports_stats_out' @@ -7482,6 +7613,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_permissions_out' @@ -7536,6 +7669,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7585,6 +7720,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7632,6 +7769,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_report_out' @@ -7718,6 +7857,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_exports_out' @@ -7812,6 +7953,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_export_configuration_out' @@ -7995,6 +8138,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8097,6 +8242,8 @@ paths: properties: data: type: object + required: + - bank_names properties: bank_names: type: array @@ -8191,6 +8338,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_stats_out' @@ -8245,6 +8394,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8299,6 +8450,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_unassign_out' @@ -8353,6 +8506,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8407,6 +8562,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8461,6 +8618,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8515,6 +8674,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8569,6 +8730,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_out' @@ -8624,6 +8787,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -8733,6 +8898,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_duplicate_suggestion_out' @@ -8834,6 +9001,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_archive_suggestion_out' @@ -8933,6 +9102,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_post_out' @@ -9041,6 +9212,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -9098,6 +9271,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -9155,6 +9330,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -9211,6 +9388,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_filters_out' @@ -9292,6 +9471,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_filters_out' @@ -9345,6 +9526,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_assign_out' @@ -9506,6 +9689,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unassign_out' @@ -9559,6 +9744,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_mark_personal_out' @@ -9666,6 +9853,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmark_personal_out' @@ -9719,6 +9908,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_ignore_out' @@ -9826,6 +10017,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_undo_ignore_out' @@ -9879,6 +10072,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_match_out' @@ -9932,6 +10127,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmatch_out' @@ -9985,6 +10182,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transactions_exports_out' @@ -10079,6 +10278,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/virtual_cards_get_current_balance_out' @@ -10133,6 +10334,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/virtual_cards_show_card_details_out' @@ -10187,6 +10390,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/virtual_card_out' @@ -10228,6 +10433,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_subscriptions_in' @@ -10239,6 +10446,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/admin_subscriptions_out' @@ -10484,6 +10693,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/schedule_out' @@ -10572,6 +10783,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/scheduled_callback_out' @@ -11136,6 +11349,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/account_out' @@ -11225,6 +11440,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/tax_group_out' @@ -11335,6 +11552,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/budget_post_out' @@ -11473,6 +11692,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/budget_exports_out' @@ -11668,6 +11889,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_policy_out' @@ -11795,6 +12018,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_policy_out' @@ -11850,6 +12075,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_policy_out' @@ -12066,6 +12293,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/statements_out' @@ -12173,6 +12402,8 @@ paths: application/json: schema: type: object + required: + - data properties: count: $ref: '#/components/schemas/count' @@ -12226,6 +12457,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/preview_out' @@ -12279,6 +12512,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12334,6 +12569,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12389,6 +12626,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -12444,6 +12683,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12499,6 +12740,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/card_stats_out' @@ -12552,6 +12795,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12782,6 +13027,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -12837,6 +13084,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -13211,6 +13460,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_check_policies_bulk_out' @@ -13295,6 +13546,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_comments_bulk_in' @@ -13305,6 +13558,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -13596,6 +13851,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -13606,6 +13863,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -13651,6 +13910,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -13661,6 +13922,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -13707,6 +13970,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -13717,6 +13982,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -14074,6 +14341,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -14164,6 +14433,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -14240,6 +14511,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -14300,6 +14573,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -14431,6 +14706,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -14489,6 +14766,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reconciliation_export_out' @@ -14558,6 +14837,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -14641,6 +14922,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -14716,6 +14999,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: object @@ -14785,6 +15070,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -14844,6 +15131,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reconciliation_export_out' @@ -14907,6 +15196,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -15075,6 +15366,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -15214,6 +15507,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -15274,6 +15569,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_add_approver_in' @@ -15289,6 +15586,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15358,6 +15657,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15421,6 +15722,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15486,6 +15789,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -15591,6 +15896,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_custom_field_out' @@ -15690,6 +15997,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/dwolla_customer_out' @@ -15875,6 +16184,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transactions_export_configuration_out' @@ -16158,6 +16469,10 @@ components: user_out_embed: type: object additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -16378,10 +16693,15 @@ components: $ref: '#/components/schemas/id_integer' project_delete_summary_out: type: object + required: + - data additionalProperties: false properties: data: type: object + required: + - delete_count + - projects properties: delete_count: type: integer @@ -16499,6 +16819,8 @@ components: cost_center_delete_summary_out: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -16645,10 +16967,15 @@ components: $ref: '#/components/schemas/id_integer' category_delete_summary_out: type: object + required: + - data additionalProperties: false properties: data: type: object + required: + - delete_count + - categories properties: delete_count: type: integer @@ -16683,6 +17010,25 @@ components: expense_field_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - seq + - field_name + - column_name + - type + - options + - default_value + - placeholder + - category_ids + - is_enabled + - is_custom + - is_mandatory + - code + - parent_field_id + - display_order properties: id: $ref: '#/components/schemas/id_integer' @@ -16846,6 +17192,16 @@ components: dependent_expense_field_values_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - parent_expense_field_value + - expense_field_value + - is_enabled properties: id: $ref: '#/components/schemas/id_integer' @@ -16919,6 +17275,12 @@ components: dependent_expense_field_values_preview_out: type: object additionalProperties: false + required: + - org_id + - parent_expense_field_id + - expense_field_id + - parent_expense_field_value + - expense_field_values properties: org_id: $ref: '#/components/schemas/org_id' @@ -16953,6 +17315,16 @@ components: dependent_expense_field_values_upload_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - file_id + - error_file_id + - state properties: id: $ref: '#/components/schemas/id_integer' @@ -17019,6 +17391,15 @@ components: dependent_expense_field_values_download_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - file_id + - state properties: id: $ref: '#/components/schemas/id_integer' @@ -17259,6 +17640,8 @@ components: per_diem_rate_delete_summary_out: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -17391,6 +17774,8 @@ components: department_delete_summary_out: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -17622,10 +18007,15 @@ components: $ref: '#/components/schemas/id_integer' mileage_rate_delete_summary_out: type: object + required: + - data additionalProperties: false properties: data: type: object + required: + - delete_count + - mileage_rates properties: delete_count: type: integer @@ -17722,6 +18112,8 @@ components: level_delete_summary_out: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -17750,6 +18142,11 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -17920,6 +18317,12 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - sub_project + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -17946,6 +18349,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -17961,6 +18368,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -17974,6 +18385,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -18127,6 +18542,13 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - system_category + - name + - sub_category + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -18476,6 +18898,7 @@ components: - user_id - email - full_name + - potential_duplicate_expenses properties: user_id: $ref: '#/components/schemas/user_id' @@ -18618,6 +19041,20 @@ components: Configuration for the export. employees_exports_out: type: object + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state + - processed_at + - completed_at + - failed_at properties: created_at: type: string @@ -19054,6 +19491,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -19294,16 +19735,6 @@ components: $ref: '#/components/schemas/created_at' updated_at: $ref: '#/components/schemas/updated_at' - created_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who created this export configuration. - updated_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who last updated this export configuration. name: type: string description: | @@ -19426,6 +19857,17 @@ components: file_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - created_at + - updated_at + - name + - type + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -19473,6 +19915,12 @@ components: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -19823,6 +20271,9 @@ components: example: 1234 account_out_embed: type: object + required: + - id + - type properties: id: allOf: @@ -19842,6 +20293,11 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code + - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -19922,6 +20378,10 @@ components: report_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: @@ -19974,6 +20434,9 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num + - amount + - last_verified_at + - approvals properties: id: anyOf: @@ -20062,6 +20525,11 @@ components: List of report_approval objects file_out_embed: type: object + required: + - id + - name + - type + - content_type properties: id: allOf: @@ -20107,6 +20575,9 @@ components: expense_verification_out_embed: type: object additionalProperties: false + required: + - verifier_user_id + - verifier_user properties: verifier_user_id: allOf: @@ -20129,6 +20600,12 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department + - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -20151,6 +20628,19 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department + - location + - title + - business_unit + - custom_fields + - flattened_custom_field properties: id: $ref: '#/components/schemas/id_string' @@ -20252,6 +20742,21 @@ components: - id - corporate_card_id - corporate_card_number + - corporate_card_nickname + - masked_corporate_card_number + - bank_name + - corporate_card_user_full_name + - amount + - currency + - spent_at + - posted_at + - status + - description + - foreign_currency + - foreign_amount + - merchant + - category + - matched_by properties: id: allOf: @@ -20736,6 +21241,12 @@ components: example: 77.594566 commute_details: type: object + required: + - id + - distance + - distance_unit + - home_location + - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -20857,6 +21368,26 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments + - custom_fields_flattened + - approvals + - verifications + - employee_id + - split_group_amount + - expense_rule_id + - expense_rule_data + - is_split + - tax_group + - approver_comments + - verifier_comments + - policy_checks + - accounting_export_summary + - report_last_paid_at + - report_last_approved_at + - commute_deduction + - commute_details_id + - commute_details + - is_reconciled + - report_auto_approval_state properties: id: allOf: @@ -21889,6 +22420,8 @@ components: Expense ID of the expense to be verified. example: tx0agOdICdbV expenses_stats_in: + required: + - query_params properties: query_params: nullable: false @@ -22092,6 +22625,17 @@ components: expenses_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -22283,16 +22827,6 @@ components: $ref: '#/components/schemas/created_at' updated_at: $ref: '#/components/schemas/updated_at' - created_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who created this export configuration. - updated_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who last updated this export configuration. name: type: string description: | @@ -22580,6 +23114,12 @@ components: advance_out_embed: type: object nullable: true + required: + - id + - currency + - amount + - advance_request_id + - seq_num properties: id: type: string @@ -22660,6 +23200,10 @@ components: advance_request_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: @@ -22679,6 +23223,14 @@ components: employee_out_embed: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department properties: id: $ref: '#/components/schemas/id_string' @@ -22709,9 +23261,16 @@ components: readOnly: true nullable: true example: uswjwgnwwgo - advance_request_comments_out: + advance_request_comments_out_embed: type: object additionalProperties: false + required: + - id + - comment + - creator_type + - creator_user_id + - creator_user + - created_at properties: id: $ref: '#/components/schemas/id_string' @@ -22719,12 +23278,6 @@ components: type: string description: A comment on the advance request example: Advance request was created - action: - type: string - description: Advance request action for which comment is added. - example: SUBMITTED - advance_request_id: - $ref: '#/components/schemas/id_string' creator_type: type: string description: Describes whether the comment is system-generated or User made. @@ -22739,10 +23292,6 @@ components: $ref: '#/components/schemas/user_out_embed_nullable' created_at: $ref: '#/components/schemas/created_at' - updated_at: - $ref: '#/components/schemas/updated_at' - org_id: - $ref: '#/components/schemas/org_id' advance_request_out: type: object additionalProperties: false @@ -22872,7 +23421,7 @@ components: comments: type: array items: - $ref: '#/components/schemas/advance_request_comments_out' + $ref: '#/components/schemas/advance_request_comments_out_embed' description: | List of comments in the advance request file_ids: @@ -22930,6 +23479,8 @@ components: required: - id advance_requests_stats_in: + required: + - query_params properties: query_params: description: | @@ -23025,6 +23576,18 @@ components: advance_request_permissions_out: type: object additionalProperties: false + required: + - can_save + - can_submit + - can_edit + - can_add_approver + - can_disable_approver + - can_reject + - can_approve + - can_inquire + - can_pull_back + - can_pay + - can_delete properties: can_save: type: boolean @@ -23085,6 +23648,51 @@ components: type: string description: Comment text to be added to the advance request example: test + advance_request_comments_out: + type: object + additionalProperties: false + required: + - id + - comment + - action + - advance_request_id + - creator_type + - creator_user_id + - creator_user + - created_at + - updated_at + - org_id + properties: + id: + $ref: '#/components/schemas/id_string' + comment: + type: string + description: A comment on the advance request + example: Advance request was created + action: + type: string + description: Advance request action for which comment is added. + example: SUBMITTED + advance_request_id: + $ref: '#/components/schemas/id_string' + creator_type: + type: string + description: Describes whether the comment is system-generated or User made. + enum: + - SYSTEM + - POLICY + - USER + example: USER + creator_user_id: + $ref: '#/components/schemas/user_id_nullable' + creator_user: + $ref: '#/components/schemas/user_out_embed_nullable' + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' + org_id: + $ref: '#/components/schemas/org_id' advance_request_remove_approver_in: type: object additionalProperties: false @@ -23103,6 +23711,10 @@ components: advance_request_out_embed: type: object nullable: true + required: + - id + - last_approved_at + - seq_num properties: id: type: string @@ -23341,6 +23953,8 @@ components: custom_fields: $ref: '#/components/schemas/custom_fields' advances_stats_in: + required: + - query_params properties: query_params: type: string @@ -23350,6 +23964,9 @@ components: example: id=in.('adv1263', 'adv1569') advances_stats_out: type: object + required: + - count + - total_amount properties: count: type: integer @@ -23554,6 +24171,8 @@ components: - $ref: '#/components/schemas/id_string' example: awfgRr8YA6KK advance_refunds_stats_in: + required: + - query_params properties: query_params: type: string @@ -23563,6 +24182,9 @@ components: example: id=in.('adr1263', 'adr1569') advance_refunds_stats_out: type: object + required: + - count + - total_amount properties: count: type: integer @@ -23744,6 +24366,13 @@ components: reminder_in: type: object additionalProperties: false + required: + - type + - message + - schedule_config + - add_to_calendar + - send_mobile_notification + - receiver_user_ids properties: id: type: string @@ -23788,6 +24417,8 @@ components: ID of the reminder that needs to be deleted. example: remindNZgN7V5pft reminders_stats_in: + required: + - query_params properties: query_params: type: string @@ -23799,6 +24430,9 @@ components: type: array items: type: object + required: + - last_reminded_at + - type properties: last_reminded_at: type: string @@ -23811,6 +24445,18 @@ components: employee_out_embed_for_report: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department + - ach_account + - business_unit + - location + - title properties: id: $ref: '#/components/schemas/id_string' @@ -23954,6 +24600,12 @@ components: reimbursement_out_minimal: type: object nullable: true + required: + - id + - currency + - amount + - mode + - ach_transfer properties: id: type: string @@ -24006,6 +24658,9 @@ components: advance_wallet_report_out: type: object additionalProperties: false + required: + - id + - amount properties: id: allOf: @@ -24046,6 +24701,14 @@ components: - applied_advance_wallets - can_apply_advances - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -24523,6 +25186,20 @@ components: - id process_summary_out: type: object + required: + - selected_reimbursable_amount + - selected_count + - unverified_count + - unverified_amount + - missing_bank_details_count + - missing_bank_details_amount + - missing_bank_details_employee_count + - missing_bank_details_employee_ids + - payment_initiated_amount + - payment_initiated_count + - reimbursable_amount + - reimbursable_report_ids + - closable_report_ids additionalProperties: true properties: selected_reimbursable_amount: @@ -24615,6 +25292,8 @@ components: id: $ref: '#/components/schemas/id_string' reports_stats_in: + required: + - query_params properties: query_params: type: string @@ -25194,16 +25873,6 @@ components: $ref: '#/components/schemas/created_at' updated_at: $ref: '#/components/schemas/updated_at' - created_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who created this export configuration. - updated_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who last updated this export configuration. name: type: string description: | @@ -25490,7 +26159,6 @@ components: - virtual_card_id - virtual_card_state - nickname - - is_archived - archived_at - archived_by_user_id - total_transactions_count @@ -25550,6 +26218,8 @@ components: - bank_name - card_number corporate_card_stats_in: + required: + - query_params properties: query_params: nullable: false @@ -25559,6 +26229,9 @@ components: example: user_id=eq.null corporate_card_stats_out: type: object + required: + - count + - transactions_count properties: count: type: integer @@ -25600,6 +26273,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -25820,7 +26497,6 @@ components: - virtual_card_id - virtual_card_state - nickname - - is_archived - archived_at - archived_by_user_id - total_transactions_count @@ -25879,6 +26555,16 @@ components: duplicate_suggestion_corporate_card_out_embed: type: object additionalProperties: false + required: + - id + - bank_name + - card_number + - nickname + - total_transactions_count + - is_visa_enrolled + - is_mastercard_enrolled + - data_feed_source + - feed_display_name properties: id: allOf: @@ -26093,6 +26779,15 @@ components: corporate_card_out_embed: type: object additionalProperties: false + required: + - id + - bank_name + - card_number + - nickname + - cardholder_name + - masked_number + - user_full_name + - user_email properties: id: allOf: @@ -26851,7 +27546,11 @@ components: - last_user_matched_at - is_exported - metadata + - mcc corporate_card_transactions_stats_in: + type: object + required: + - query_params properties: query_params: nullable: false @@ -26861,6 +27560,10 @@ components: example: amount=gt.0&amount=lt.1000&created_at=gt.2021-01-01T00:00:00.000Z&created_at=lt.2021-12-31T23:59:59.999Z corporate_card_transactions_stats_out: type: object + required: + - count + - debit_amount + - credit_amount properties: count: type: integer @@ -26891,6 +27594,9 @@ components: - id corporate_card_transactions_delete_summary_out: type: object + required: + - delete_count + - delete_amount properties: delete_count: type: integer @@ -27192,6 +27898,7 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc corporate_card_transaction_reassign_in: type: object properties: @@ -27431,6 +28138,8 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_mark_personal_out: type: object properties: @@ -27638,6 +28347,8 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_unmark_personal_out: type: object properties: @@ -27846,6 +28557,8 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_ignore_out: type: object properties: @@ -28060,6 +28773,9 @@ components: - matched_expenses - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_undo_ignore_out: type: object additionalProperties: false @@ -28289,6 +29005,10 @@ components: - matched_expenses - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number corporate_card_transaction_match_in: type: object properties: @@ -28520,6 +29240,9 @@ components: - matched_expenses - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_unmatch_in: type: object properties: @@ -28763,6 +29486,11 @@ components: - matched_expenses - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number + - is_exported corporate_card_transactions_export_config_column_formula: type: object required: @@ -28909,6 +29637,20 @@ components: corporate_card_transactions_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state + - processed_at + - completed_at + - failed_at properties: created_at: $ref: '#/components/schemas/created_at' @@ -29132,6 +29874,14 @@ components: admin_subscriptions_out: type: object additionalProperties: false + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - org_id + - subscribed_resources properties: id: $ref: '#/components/schemas/id_string' @@ -29192,6 +29942,15 @@ components: - reimbursement - comments - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - applied_advance_wallets + - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -29554,6 +30313,24 @@ components: example: 100 employee_account_summary_out: type: object + required: + - id + - created_at + - updated_at + - org_id + - org_currency + - user_email + - user_full_name + - cash_account_id + - cash_account + - cash_account_balance + - ccc_account_id + - ccc_account + - ccc_account_balance + - advance_account_ids + - advance_accounts + - advance_accounts_balance + - is_settleable properties: id: $ref: '#/components/schemas/id_integer' @@ -29611,6 +30388,14 @@ components: schedule_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - config + - org_id + - user_id + - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -29668,6 +30453,15 @@ components: scheduled_callback_out: type: object additionalProperties: false + required: + - id + - url + - payload + - schedule_config + - is_enabled + - created_at + - updated_at + - org_id properties: id: $ref: '#/components/schemas/id_string' @@ -29687,6 +30481,11 @@ components: $ref: '#/components/schemas/org_id' scheduled_callback_in: type: object + required: + - url + - payload + - schedule_config + - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -29729,6 +30528,9 @@ components: spend_overview_summary_data_out: type: object nullable: false + required: + - amount + - time_interval_marker properties: amount: $ref: '#/components/schemas/amount' @@ -29747,6 +30549,11 @@ components: spend_overview_by_merchant_data_out: type: object nullable: false + required: + - merchant_name + - amount + - percentage + - change_percentage properties: merchant_name: $ref: '#/components/schemas/merchant' @@ -29765,6 +30572,12 @@ components: spend_overview_by_project_data_out: type: object nullable: false + required: + - project_id + - project_display_name + - amount + - percentage + - change_percentage properties: project_id: $ref: '#/components/schemas/id_integer' @@ -29785,6 +30598,12 @@ components: spend_overview_by_category_data_out: type: object nullable: false + required: + - category_id + - category_display_name + - amount + - percentage + - change_percentage properties: category_id: $ref: '#/components/schemas/id_integer' @@ -29805,6 +30624,12 @@ components: spend_overview_by_department_data_out: type: object nullable: false + required: + - department_id + - department_display_name + - amount + - percentage + - change_percentage properties: department_id: $ref: '#/components/schemas/id_string' @@ -29819,6 +30644,13 @@ components: spend_overview_by_user_data_out: type: object nullable: false + required: + - user_id + - user_full_name + - user_email + - amount + - percentage + - change_percentage properties: user_id: $ref: '#/components/schemas/id_string' @@ -29835,6 +30667,15 @@ components: spend_overview_by_corporate_card_data_out: type: object nullable: false + required: + - card_id + - card_number + - card_holder_name + - card_nickname + - user_id + - amount + - percentage + - change_percentage properties: card_id: $ref: '#/components/schemas/id_string' @@ -29870,6 +30711,17 @@ components: account_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - user_id + - type + - currency + - current_balance_amount + - tentative_balance_amount + - org_id + - category_id properties: id: allOf: @@ -29914,6 +30766,10 @@ components: account_in: type: object additionalProperties: false + required: + - user_id + - type + - currency properties: user_id: type: string @@ -30134,12 +30990,6 @@ components: $ref: '#/components/schemas/id_string' example: - usge49ielgel - fiscal_year_start_month: - type: number - example: 10 - description: Month number of start of fiscal year - minimum: 1 - maximum: 12 budget_start_date: type: string nullable: true @@ -30215,7 +31065,6 @@ components: - type - observer_ids - amount_limit - - fiscal_year_start_month - department_ids - project_ids - cost_center_ids @@ -30282,12 +31131,6 @@ components: $ref: '#/components/schemas/id_string' example: - usge49ielgel - fiscal_year_start_month: - type: number - example: 10 - description: Month number of start of fisical year - minimum: 1 - maximum: 12 visibility: $ref: '#/components/schemas/budget_visibility' user_ids: @@ -30381,6 +31224,12 @@ components: budget_out_embed: type: object additionalProperties: false + required: + - id + - name + - type + - amount_limit + - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -30486,6 +31335,15 @@ components: budget_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - file_id + - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -30530,6 +31388,8 @@ components: - currency - created_at - updated_at + - is_current + - is_primary properties: id: $ref: '#/components/schemas/org_id' @@ -30597,6 +31457,7 @@ components: - id - invitation_sent - is_limit_reached + - weekly_limit properties: id: $ref: '#/components/schemas/org_id' @@ -30747,6 +31608,9 @@ components: - action_add_department_head_approver - action_add_approver_user_ids - action_override_distance_slab_rate + - expense_merchants + - expense_merchants_op + - policy_violation_reason_required properties: id: allOf: @@ -32090,6 +32954,7 @@ components: - file_id - is_processed - statement_mappings_id + - creator_user statements_in: type: object properties: @@ -32653,6 +33518,16 @@ components: - id - statement_mapping summary_out: + type: object + required: + - id + - status + - period_start + - period_end + - statement_transaction_count + - statement_total + - total_cards + - bridging_entry_change_type properties: id: allOf: @@ -32825,6 +33700,12 @@ components: - statement_mapping - reconciliation_entry_ids _reconciliation_summary_object: + type: object + required: + - expense_count + - is_recommended + - reconciliation_method + - statement_transaction_count properties: expense_count: description: Number of expense matches found @@ -32842,6 +33723,9 @@ components: type: number example: 12 reconciliation_summary_out: + type: object + required: + - reconciliation_summary properties: reconciliation_summary: type: array @@ -33165,7 +34049,12 @@ components: required: - missing_transactions_count - is_rtf_statement + - rtf_card_network matching_cards_out: + type: object + required: + - statement_card_number + - matching_cards properties: statement_card_number: type: string @@ -33204,6 +34093,13 @@ components: $ref: '#/components/schemas/user_out_embed_nullable' rtf_missing_transaction_from_statement_out: type: object + required: + - error + - missing_rtf_transactions + - rtf_confidence + - rtf_count + - total_count + - status properties: error: type: string @@ -33446,6 +34342,9 @@ components: - reconciliation_method rtf_stats_out: type: object + required: + - last_uploaded_at + - rtf_confidence properties: last_uploaded_at: $ref: '#/components/schemas/timestamptz_utc' @@ -33570,6 +34469,10 @@ components: - id - statement_mapping statement_archived_cards_out: + required: + - number_of_cards + - number_of_archived_cards + - archived_cards properties: number_of_cards: type: integer @@ -33631,6 +34534,8 @@ components: additionalProperties: false required: - merchant_contains + - department_ids + - departments properties: merchant_contains: type: string @@ -33659,6 +34564,18 @@ components: nullable: false additionalProperties: false minProperties: 1 + required: + - merchant + - is_billable + - purpose + - category_id + - category + - project_id + - project + - cost_center_id + - cost_center + - custom_fields + - dependent_fields properties: merchant: type: string @@ -33729,6 +34646,8 @@ components: - creator_user - if - set + - is_suggested + - is_suggestion_dismissed properties: id: allOf: @@ -34287,6 +35206,9 @@ components: description: | List of expense IDs that needs to be dismissed as a duplicate from the target expense expenses_duplicate_sets_stats_in: + type: object + required: + - query_params properties: query_params: nullable: false @@ -34297,6 +35219,8 @@ components: example: '' expenses_duplicate_sets_stats_out: type: object + required: + - count properties: count: type: integer @@ -34317,6 +35241,17 @@ components: feature_config_out: type: object additionalProperties: false + required: + - org_id + - user_id + - created_at + - updated_at + - target_client + - feature + - sub_feature + - key + - value + - is_shared properties: org_id: $ref: '#/components/schemas/org_id' @@ -34586,6 +35521,9 @@ components: expense_check_policies_out: type: object additionalProperties: false + required: + - individual_desired_states + - final_desired_state properties: individual_desired_states: type: array @@ -34596,6 +35534,12 @@ components: org_bank_details_out: type: object additionalProperties: false + required: + - org_id + - bank_account_number + - bank_branch_ifsc + - dwolla_customers_metadata_id + - is_bank_account_added properties: org_id: $ref: '#/components/schemas/org_id' @@ -34624,6 +35568,11 @@ components: merchant_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -34765,6 +35714,12 @@ components: - amount - state - purpose + - currency + - merchant + - spent_at + - file_ids + - category + - project properties: id: allOf: @@ -34867,6 +35822,7 @@ components: - project - purpose - splits + - currency properties: id: allOf: @@ -34976,6 +35932,12 @@ components: - matched_expenses_count - is_reconciled - expenses + - statement_line_item_id + - expense_ids + - statement_transaction_date + - statement_post_date + - created_at + - updated_at properties: id: $ref: '#/components/schemas/id_string' @@ -35062,6 +36024,15 @@ components: example: corporate_card_id=eq.bawownwrng reconciliation_transactions_stats_out: type: object + required: + - period_start + - period_end + - statement_transaction_count + - expense_count + - statement_total + - expense_total + - difference + - matching_issue_count additionalProperties: false description: | Reconciliation transactions statistics for the selected filter period. @@ -35200,6 +36171,21 @@ components: example: reconciliation_entry_id=eq.receabc12345 reconciliation_eligible_cards_stats_out: type: object + required: + - period_start + - period_end + - statement_transaction_count + - expense_count + - statement_total + - expense_total + - difference + - matching_issue_count + - total_cards + - card_without_statement_count + - card_with_matching_issue_count + - card_with_no_issues_found_count + - card_with_no_transactions_count + - reconciled_card_count additionalProperties: false properties: period_start: @@ -35360,6 +36346,15 @@ components: reconciliation_export_out: type: object additionalProperties: false + required: + - id + - org_id + - file_id + - state + - query_params + - notify_emails + - created_at + - updated_at properties: id: allOf: @@ -35413,6 +36408,29 @@ components: spender_employee_settings_out: type: object additionalProperties: false + required: + - id + - employee_id + - org_id + - created_at + - updated_at + - category_ids + - cost_center_ids + - project_ids + - per_diem_rate_ids + - mileage_rate_ids + - insta_fyle_settings + - notification_settings + - mileage_settings + - expense_form_autofills + - data_extractor_settings + - in_app_chat_settings + - payment_mode_settings + - locale + - is_personal_cards_enabled + - default_project_id + - default_payment_mode + - default_vehicle_type properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/approver.yaml b/reference/approver.yaml index 8aa8f489d..df704a20e 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -169,6 +169,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -225,6 +227,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -330,6 +334,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -422,6 +428,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_exports_out' @@ -498,6 +506,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/approver_expense_in' @@ -508,6 +518,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -549,6 +561,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/approver_expenses_bulk_in' @@ -559,6 +573,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -618,6 +634,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -671,6 +689,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_out' @@ -734,6 +754,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_bulk_out' @@ -815,6 +837,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -862,6 +886,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -949,6 +975,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -1004,6 +1032,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reports_stats_out' @@ -1058,6 +1088,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_comments_out' @@ -1107,6 +1139,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_permissions_out' @@ -1160,6 +1194,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -1195,6 +1231,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/subscriptions_in' @@ -1206,6 +1244,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/approver_subscriptions_out' @@ -1366,6 +1406,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_requests_approver_stats_out' @@ -1421,6 +1463,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_permissions_out' @@ -1462,6 +1506,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_in' @@ -1472,6 +1518,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_out' @@ -2011,6 +2059,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_check_policies_bulk_out' @@ -2095,6 +2145,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_comments_bulk_in' @@ -2105,6 +2157,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -2258,6 +2312,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expenses_stats_out' @@ -2311,6 +2367,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -2398,6 +2456,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -2451,6 +2511,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_exports_out' @@ -2486,6 +2548,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -2496,6 +2560,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -2542,6 +2608,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -2552,6 +2620,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -2597,6 +2667,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/admin_split_expense_in' @@ -2607,6 +2679,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -2666,6 +2740,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -2742,6 +2818,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -3038,6 +3116,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -3081,6 +3161,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_add_approver_in' @@ -3096,6 +3178,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3165,6 +3249,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3277,6 +3363,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3342,6 +3430,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -3457,6 +3547,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -3639,6 +3731,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/employee_overview_stats_out' @@ -3770,6 +3864,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/employee_overview_expense_stats_out' @@ -3958,6 +4054,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_export_configuration_out' @@ -4155,6 +4253,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_export_configuration_out' @@ -4361,6 +4461,10 @@ components: user_out_embed: type: object additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -4388,6 +4492,10 @@ components: report_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: @@ -4467,6 +4575,12 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department + - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -4543,6 +4657,18 @@ components: employee_out_embed_for_report: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department + - ach_account + - business_unit + - location + - title properties: id: $ref: '#/components/schemas/id_string' @@ -4686,6 +4812,12 @@ components: reimbursement_out_minimal: type: object nullable: true + required: + - id + - currency + - amount + - mode + - ach_transfer properties: id: type: string @@ -4712,6 +4844,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -4755,6 +4891,9 @@ components: advance_wallet_report_out: type: object additionalProperties: false + required: + - id + - amount properties: id: allOf: @@ -4793,6 +4932,15 @@ components: - reimbursement - comments - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - applied_advance_wallets + - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -5314,6 +5462,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -5329,6 +5481,13 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - system_category + - name + - sub_category + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -5360,6 +5519,12 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - sub_project + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -5391,6 +5556,9 @@ components: example: sdfd2391 account_out_embed: type: object + required: + - id + - type properties: id: allOf: @@ -5410,6 +5578,11 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code + - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -5427,6 +5600,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -5570,6 +5747,9 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num + - amount + - last_verified_at + - approvals properties: id: anyOf: @@ -5658,6 +5838,11 @@ components: List of report_approval objects file_out_embed: type: object + required: + - id + - name + - type + - content_type properties: id: allOf: @@ -5703,6 +5888,9 @@ components: expense_verification_out_embed: type: object additionalProperties: false + required: + - verifier_user_id + - verifier_user properties: verifier_user_id: allOf: @@ -5743,6 +5931,19 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department + - location + - title + - business_unit + - custom_fields + - flattened_custom_field properties: id: $ref: '#/components/schemas/id_string' @@ -5857,6 +6058,21 @@ components: - id - corporate_card_id - corporate_card_number + - corporate_card_nickname + - masked_corporate_card_number + - bank_name + - corporate_card_user_full_name + - amount + - currency + - spent_at + - posted_at + - status + - description + - foreign_currency + - foreign_amount + - merchant + - category + - matched_by properties: id: allOf: @@ -6341,6 +6557,12 @@ components: example: 77.594566 commute_details: type: object + required: + - id + - distance + - distance_unit + - home_location + - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -6462,6 +6684,26 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments + - custom_fields_flattened + - approvals + - verifications + - employee_id + - split_group_amount + - expense_rule_id + - expense_rule_data + - is_split + - tax_group + - approver_comments + - verifier_comments + - policy_checks + - accounting_export_summary + - report_last_paid_at + - report_last_approved_at + - commute_deduction + - commute_details_id + - commute_details + - is_reconciled + - report_auto_approval_state properties: id: allOf: @@ -7555,6 +7797,8 @@ components: - $ref: '#/components/schemas/id_string' example: rpfilumWHrlPf7K reports_stats_in: + required: + - query_params properties: query_params: type: string @@ -7828,6 +8072,13 @@ components: approver_subscriptions_out: type: object additionalProperties: false + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - approver_user_id properties: id: $ref: '#/components/schemas/id_string' @@ -7884,6 +8135,12 @@ components: advance_out_embed: type: object nullable: true + required: + - id + - currency + - amount + - advance_request_id + - seq_num properties: id: type: string @@ -7964,6 +8221,10 @@ components: advance_request_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: @@ -7984,6 +8245,11 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -8000,6 +8266,14 @@ components: employee_out_embed: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department properties: id: $ref: '#/components/schemas/id_string' @@ -8030,9 +8304,16 @@ components: readOnly: true nullable: true example: uswjwgnwwgo - advance_request_comments_out: + advance_request_comments_out_embed: type: object additionalProperties: false + required: + - id + - comment + - creator_type + - creator_user_id + - creator_user + - created_at properties: id: $ref: '#/components/schemas/id_string' @@ -8040,12 +8321,6 @@ components: type: string description: A comment on the advance request example: Advance request was created - action: - type: string - description: Advance request action for which comment is added. - example: SUBMITTED - advance_request_id: - $ref: '#/components/schemas/id_string' creator_type: type: string description: Describes whether the comment is system-generated or User made. @@ -8060,10 +8335,6 @@ components: $ref: '#/components/schemas/user_out_embed_nullable' created_at: $ref: '#/components/schemas/created_at' - updated_at: - $ref: '#/components/schemas/updated_at' - org_id: - $ref: '#/components/schemas/org_id' advance_request_out: type: object additionalProperties: false @@ -8193,7 +8464,7 @@ components: comments: type: array items: - $ref: '#/components/schemas/advance_request_comments_out' + $ref: '#/components/schemas/advance_request_comments_out_embed' description: | List of comments in the advance request file_ids: @@ -8276,6 +8547,18 @@ components: advance_request_permissions_out: type: object additionalProperties: false + required: + - can_save + - can_submit + - can_edit + - can_add_approver + - can_disable_approver + - can_reject + - can_approve + - can_inquire + - can_pull_back + - can_pay + - can_delete properties: can_save: type: boolean @@ -8336,6 +8619,51 @@ components: type: string description: Comment text to be added to the advance request example: test + advance_request_comments_out: + type: object + additionalProperties: false + required: + - id + - comment + - action + - advance_request_id + - creator_type + - creator_user_id + - creator_user + - created_at + - updated_at + - org_id + properties: + id: + $ref: '#/components/schemas/id_string' + comment: + type: string + description: A comment on the advance request + example: Advance request was created + action: + type: string + description: Advance request action for which comment is added. + example: SUBMITTED + advance_request_id: + $ref: '#/components/schemas/id_string' + creator_type: + type: string + description: Describes whether the comment is system-generated or User made. + enum: + - SYSTEM + - POLICY + - USER + example: USER + creator_user_id: + $ref: '#/components/schemas/user_id_nullable' + creator_user: + $ref: '#/components/schemas/user_out_embed_nullable' + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' + org_id: + $ref: '#/components/schemas/org_id' description: type: string nullable: true @@ -8716,7 +9044,6 @@ components: - virtual_card_id - virtual_card_state - nickname - - is_archived - archived_at - archived_by_user_id - total_transactions_count @@ -8802,6 +9129,12 @@ components: approver_merchant_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -9673,6 +10006,8 @@ components: description: | List of expense IDs that are part of the duplicate set expenses_stats_in: + required: + - query_params properties: query_params: nullable: false @@ -9930,6 +10265,17 @@ components: expenses_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -10139,6 +10485,9 @@ components: expense_check_policies_out: type: object additionalProperties: false + required: + - individual_desired_states + - final_desired_state properties: individual_desired_states: type: array @@ -10191,6 +10540,17 @@ components: file_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - created_at + - updated_at + - name + - type + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -10238,6 +10598,12 @@ components: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -10289,6 +10655,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -10699,6 +11069,17 @@ components: account_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - user_id + - type + - currency + - current_balance_amount + - tentative_balance_amount + - org_id + - category_id properties: id: allOf: @@ -10743,6 +11124,29 @@ components: spender_employee_settings_out: type: object additionalProperties: false + required: + - id + - employee_id + - org_id + - created_at + - updated_at + - category_ids + - cost_center_ids + - project_ids + - per_diem_rate_ids + - mileage_rate_ids + - insta_fyle_settings + - notification_settings + - mileage_settings + - expense_form_autofills + - data_extractor_settings + - in_app_chat_settings + - payment_mode_settings + - locale + - is_personal_cards_enabled + - default_project_id + - default_payment_mode + - default_vehicle_type properties: id: $ref: '#/components/schemas/id_string' @@ -11381,6 +11785,9 @@ components: employee_overview_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer @@ -11393,6 +11800,9 @@ components: employee_overview_expense_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer @@ -11550,16 +11960,6 @@ components: $ref: '#/components/schemas/created_at' updated_at: $ref: '#/components/schemas/updated_at' - created_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who created this export configuration. - updated_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who last updated this export configuration. name: type: string description: | @@ -11787,16 +12187,6 @@ components: $ref: '#/components/schemas/created_at' updated_at: $ref: '#/components/schemas/updated_at' - created_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who created this export configuration. - updated_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who last updated this export configuration. name: type: string description: | diff --git a/reference/common.yaml b/reference/common.yaml index 7cc7339e7..e4ca01c8b 100644 --- a/reference/common.yaml +++ b/reference/common.yaml @@ -419,6 +419,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/logo_file_generate_download_url_action_out' @@ -493,6 +495,9 @@ components: example: 10 place_out_minimal: type: object + required: + - id + - formatted_address properties: id: type: string @@ -505,6 +510,14 @@ components: place_out: type: object additionalProperties: false + required: + - id + - city + - state + - country + - formatted_address + - latitude + - longitude properties: id: type: string @@ -531,6 +544,8 @@ components: example: 77.594566 exchange_rate_out: type: object + required: + - exchange_rate additionalProperties: false properties: exchange_rate: @@ -544,6 +559,11 @@ components: example: sdfd2391 logo_file_generate_download_url_action_out: type: object + required: + - id + - name + - content_type + - download_url additionalProperties: false properties: id: diff --git a/reference/hod.yaml b/reference/hod.yaml index 2b7f7d1a7..d2371946e 100644 --- a/reference/hod.yaml +++ b/reference/hod.yaml @@ -155,6 +155,12 @@ components: budget_out_embed: type: object additionalProperties: false + required: + - id + - name + - type + - amount_limit + - is_enabled properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/hop.yaml b/reference/hop.yaml index 7a0d27b23..0403992ce 100644 --- a/reference/hop.yaml +++ b/reference/hop.yaml @@ -155,6 +155,12 @@ components: budget_out_embed: type: object additionalProperties: false + required: + - id + - name + - type + - amount_limit + - is_enabled properties: id: $ref: '#/components/schemas/id_string' diff --git a/reference/manager.yaml b/reference/manager.yaml index 1a85e2a87..06b7a8363 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -114,6 +114,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -381,6 +383,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/employee_overview_stats_out' @@ -570,6 +574,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/employee_overview_expense_stats_out' @@ -711,6 +717,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -822,6 +832,12 @@ components: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -1287,6 +1303,9 @@ components: employee_overview_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer @@ -1306,6 +1325,10 @@ components: user_out_embed: type: object additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -1336,6 +1359,11 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -1508,6 +1536,12 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - sub_project + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -1534,6 +1568,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -1549,6 +1587,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -1562,6 +1604,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -1704,6 +1750,13 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - system_category + - name + - sub_category + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -2033,6 +2086,9 @@ components: example: 1234 account_out_embed: type: object + required: + - id + - type properties: id: allOf: @@ -2052,6 +2108,11 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code + - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -2127,6 +2188,10 @@ components: report_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: @@ -2179,6 +2244,9 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num + - amount + - last_verified_at + - approvals properties: id: anyOf: @@ -2267,6 +2335,11 @@ components: List of report_approval objects file_out_embed: type: object + required: + - id + - name + - type + - content_type properties: id: allOf: @@ -2312,6 +2385,9 @@ components: expense_verification_out_embed: type: object additionalProperties: false + required: + - verifier_user_id + - verifier_user properties: verifier_user_id: allOf: @@ -2335,6 +2411,12 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department + - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -2357,6 +2439,19 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department + - location + - title + - business_unit + - custom_fields + - flattened_custom_field properties: id: $ref: '#/components/schemas/id_string' @@ -2471,6 +2566,21 @@ components: - id - corporate_card_id - corporate_card_number + - corporate_card_nickname + - masked_corporate_card_number + - bank_name + - corporate_card_user_full_name + - amount + - currency + - spent_at + - posted_at + - status + - description + - foreign_currency + - foreign_amount + - merchant + - category + - matched_by properties: id: allOf: @@ -2955,6 +3065,12 @@ components: example: 77.594566 commute_details: type: object + required: + - id + - distance + - distance_unit + - home_location + - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -3076,6 +3192,26 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments + - custom_fields_flattened + - approvals + - verifications + - employee_id + - split_group_amount + - expense_rule_id + - expense_rule_data + - is_split + - tax_group + - approver_comments + - verifier_comments + - policy_checks + - accounting_export_summary + - report_last_paid_at + - report_last_approved_at + - commute_deduction + - commute_details_id + - commute_details + - is_reconciled + - report_auto_approval_state properties: id: allOf: @@ -3622,6 +3758,8 @@ components: - AUTO_APPROVED - null expenses_stats_in: + required: + - query_params properties: query_params: nullable: false @@ -3632,6 +3770,9 @@ components: employee_overview_expense_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer diff --git a/reference/spender.yaml b/reference/spender.yaml index 2d25945d9..3a1d25b69 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -685,6 +685,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/spender_expenses_bulk_in' @@ -695,6 +697,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -806,6 +810,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -855,6 +861,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -906,6 +914,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -971,6 +981,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -1024,6 +1036,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_out' @@ -1087,6 +1101,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_permissions_bulk_out' @@ -1241,6 +1257,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/subscriptions_in' @@ -1252,6 +1270,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/spender_subscriptions_out' @@ -1360,6 +1380,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/schedule_out' @@ -1601,6 +1623,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -1651,6 +1675,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -1699,6 +1725,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -1747,6 +1775,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_out' @@ -1796,6 +1826,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/reports_stats_out' @@ -1850,6 +1882,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_purpose_out' @@ -1897,6 +1931,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -1958,7 +1994,7 @@ paths: application/json: schema: $ref: '#/components/schemas/401' - /spender/reports/filters/delte: + /spender/reports/filters/delete: post: tags: - Reports @@ -1984,6 +2020,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/report_filters_out' @@ -2038,6 +2076,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_comments_out' @@ -2087,6 +2127,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/report_permissions_out' @@ -2179,6 +2221,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_exports_out' @@ -2273,6 +2317,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -2328,6 +2374,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_requests_stats_out' @@ -2429,6 +2477,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advances_stats_out' @@ -2649,6 +2699,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -2703,6 +2755,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_mark_personal_out' @@ -2756,6 +2810,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmark_personal_out' @@ -2809,6 +2865,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_ignore_out' @@ -2862,6 +2920,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_undo_ignore_out' @@ -2915,6 +2975,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_match_out' @@ -2968,6 +3030,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/corporate_card_transaction_unmatch_out' @@ -3063,6 +3127,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/spender_employee_out' @@ -3745,6 +3811,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/virtual_cards_get_current_balance_out' @@ -3799,6 +3867,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/virtual_cards_show_card_details_out' @@ -3895,6 +3965,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/file_out' @@ -3952,6 +4024,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -4023,6 +4097,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/file_generate_urls_action_out' @@ -4079,6 +4155,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -4248,6 +4326,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/file_out_download_url' @@ -4454,6 +4534,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_check_policies_out' @@ -4505,6 +4587,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expense_check_policies_bulk_out' @@ -4604,6 +4688,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/recurring_expense_out' @@ -4707,6 +4793,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/recurring_expense_out' @@ -4927,6 +5015,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_comments_bulk_in' @@ -4937,6 +5027,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -5090,6 +5182,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/expenses_stats_out' @@ -5143,6 +5237,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -5230,6 +5326,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_filters_out' @@ -5283,6 +5381,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_exports_out' @@ -5318,6 +5418,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/spender_split_expense_in' @@ -5328,6 +5430,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -5374,6 +5478,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/spender_split_expense_in' @@ -5384,6 +5490,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -5429,6 +5537,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/spender_split_expense_in' @@ -5439,6 +5549,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: type: array @@ -5482,6 +5594,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_merge_in' @@ -5492,6 +5606,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expense_out' @@ -5636,6 +5752,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -6141,6 +6259,8 @@ paths: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: @@ -6312,6 +6432,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -6386,6 +6508,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -6451,6 +6575,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_permissions_out' @@ -6509,6 +6635,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/advance_request_out' @@ -6571,6 +6699,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: array @@ -6614,6 +6744,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_in' @@ -6624,6 +6756,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/advance_request_comments_out' @@ -6771,6 +6905,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '#/components/schemas/secondary_email_out' @@ -6830,6 +6966,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -6893,6 +7031,8 @@ paths: schema: type: object additionalProperties: false + required: + - data properties: data: type: object @@ -7207,6 +7347,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/expenses_export_configuration_out' @@ -7404,6 +7546,8 @@ paths: application/json: schema: type: object + required: + - data properties: data: $ref: '#/components/schemas/reports_export_configuration_out' @@ -8088,6 +8232,25 @@ components: expense_field_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - seq + - field_name + - column_name + - type + - options + - default_value + - placeholder + - category_ids + - is_enabled + - is_custom + - is_mandatory + - code + - parent_field_id + - display_order properties: id: $ref: '#/components/schemas/id_integer' @@ -8168,6 +8331,16 @@ components: dependent_expense_field_values_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - parent_expense_field_value + - expense_field_value + - is_enabled properties: id: $ref: '#/components/schemas/id_integer' @@ -8325,6 +8498,11 @@ components: org_out_embed: type: object additionalProperties: false + required: + - id + - name + - domain + - currency properties: id: $ref: '#/components/schemas/org_id' @@ -8350,6 +8528,10 @@ components: user_out_embed: type: object additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -8385,6 +8567,12 @@ components: my_profile_out: type: object additionalProperties: false + required: + - user_id + - org_id + - org + - user + - roles properties: user_id: $ref: '#/components/schemas/user_id' @@ -8484,6 +8672,17 @@ components: account_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - user_id + - type + - currency + - current_balance_amount + - tentative_balance_amount + - org_id + - category_id properties: id: allOf: @@ -8628,6 +8827,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -8643,6 +8846,13 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - system_category + - name + - sub_category + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -8674,6 +8884,12 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - sub_project + - code + - display_name properties: id: $ref: '#/components/schemas/id_integer' @@ -8705,6 +8921,9 @@ components: example: sdfd2391 account_out_embed: type: object + required: + - id + - type properties: id: allOf: @@ -8724,6 +8943,11 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - vehicle_type + - code + - rate properties: id: $ref: '#/components/schemas/id_integer' @@ -8741,6 +8965,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - name + - code properties: id: $ref: '#/components/schemas/id_integer' @@ -8876,6 +9104,10 @@ components: report_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: @@ -8928,6 +9160,9 @@ components: - last_paid_at - reimbursement_id - reimbursement_seq_num + - amount + - last_verified_at + - approvals properties: id: anyOf: @@ -9016,6 +9251,11 @@ components: List of report_approval objects file_out_embed: type: object + required: + - id + - name + - type + - content_type properties: id: allOf: @@ -9061,6 +9301,9 @@ components: expense_verification_out_embed: type: object additionalProperties: false + required: + - verifier_user_id + - verifier_user properties: verifier_user_id: allOf: @@ -9090,6 +9333,12 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department + - display_name properties: id: $ref: '#/components/schemas/id_string' @@ -9182,6 +9431,19 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department + - location + - title + - business_unit + - custom_fields + - flattened_custom_field properties: id: $ref: '#/components/schemas/id_string' @@ -9296,6 +9558,21 @@ components: - id - corporate_card_id - corporate_card_number + - corporate_card_nickname + - masked_corporate_card_number + - bank_name + - corporate_card_user_full_name + - amount + - currency + - spent_at + - posted_at + - status + - description + - foreign_currency + - foreign_amount + - merchant + - category + - matched_by properties: id: allOf: @@ -9780,6 +10057,12 @@ components: example: 77.594566 commute_details: type: object + required: + - id + - distance + - distance_unit + - home_location + - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. @@ -9901,6 +10184,26 @@ components: - invoice_number - is_duplicate_present - expense_policy_comments + - custom_fields_flattened + - approvals + - verifications + - employee_id + - split_group_amount + - expense_rule_id + - expense_rule_data + - is_split + - tax_group + - approver_comments + - verifier_comments + - policy_checks + - accounting_export_summary + - report_last_paid_at + - report_last_approved_at + - commute_deduction + - commute_details_id + - commute_details + - is_reconciled + - report_auto_approval_state properties: id: allOf: @@ -11031,7 +11334,12 @@ components: merchant_out: type: object additionalProperties: false - properties: + required: + - id + - created_at + - updated_at + - display_name + properties: id: $ref: '#/components/schemas/id_integer' created_at: @@ -11051,6 +11359,13 @@ components: spender_subscriptions_out: type: object additionalProperties: false + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - user_id properties: id: $ref: '#/components/schemas/id_string' @@ -11078,6 +11393,18 @@ components: employee_out_embed_for_report: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department + - ach_account + - business_unit + - location + - title properties: id: $ref: '#/components/schemas/id_string' @@ -11221,6 +11548,12 @@ components: reimbursement_out_minimal: type: object nullable: true + required: + - id + - currency + - amount + - mode + - ach_transfer properties: id: type: string @@ -11247,6 +11580,10 @@ components: type: object nullable: true additionalProperties: false + required: + - id + - email + - full_name properties: id: allOf: @@ -11290,6 +11627,9 @@ components: advance_wallet_report_out: type: object additionalProperties: false + required: + - id + - amount properties: id: allOf: @@ -11328,6 +11668,15 @@ components: - reimbursement - comments - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - applied_advance_wallets + - auto_approval_state properties: id: $ref: '#/components/schemas/id_string' @@ -11673,6 +12022,14 @@ components: schedule_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - config + - org_id + - user_id + - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -11820,6 +12177,8 @@ components: id of report, which needs to be resubmitted example: rpa21A2rdj2 reports_stats_in: + required: + - query_params properties: query_params: type: string @@ -12381,6 +12740,12 @@ components: advance_out_embed: type: object nullable: true + required: + - id + - currency + - amount + - advance_request_id + - seq_num properties: id: type: string @@ -12461,6 +12826,10 @@ components: advance_request_approval_out_embed: type: object additionalProperties: false + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: @@ -12481,6 +12850,11 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - code + - name + - sub_department properties: id: $ref: '#/components/schemas/id_string' @@ -12497,6 +12871,14 @@ components: employee_out_embed: type: object additionalProperties: false + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department properties: id: $ref: '#/components/schemas/id_string' @@ -12527,9 +12909,16 @@ components: readOnly: true nullable: true example: uswjwgnwwgo - advance_request_comments_out: + advance_request_comments_out_embed: type: object additionalProperties: false + required: + - id + - comment + - creator_type + - creator_user_id + - creator_user + - created_at properties: id: $ref: '#/components/schemas/id_string' @@ -12537,12 +12926,6 @@ components: type: string description: A comment on the advance request example: Advance request was created - action: - type: string - description: Advance request action for which comment is added. - example: SUBMITTED - advance_request_id: - $ref: '#/components/schemas/id_string' creator_type: type: string description: Describes whether the comment is system-generated or User made. @@ -12557,10 +12940,6 @@ components: $ref: '#/components/schemas/user_out_embed_nullable' created_at: $ref: '#/components/schemas/created_at' - updated_at: - $ref: '#/components/schemas/updated_at' - org_id: - $ref: '#/components/schemas/org_id' advance_request_out: type: object additionalProperties: false @@ -12690,7 +13069,7 @@ components: comments: type: array items: - $ref: '#/components/schemas/advance_request_comments_out' + $ref: '#/components/schemas/advance_request_comments_out_embed' description: | List of comments in the advance request file_ids: @@ -12749,6 +13128,8 @@ components: - currency - amount advance_requests_stats_in: + required: + - query_params properties: query_params: description: | @@ -12834,6 +13215,10 @@ components: advance_request_out_embed: type: object nullable: true + required: + - id + - last_approved_at + - seq_num properties: id: type: string @@ -12994,6 +13379,8 @@ components: creator_user: $ref: '#/components/schemas/user_out_embed_nullable' advances_stats_in: + required: + - query_params properties: query_params: type: string @@ -13003,6 +13390,9 @@ components: example: id=in.('adv1263', 'adv1569') advances_stats_out: type: object + required: + - count + - total_amount properties: count: type: integer @@ -13246,7 +13636,6 @@ components: - virtual_card_id - virtual_card_state - nickname - - is_archived - archived_at - archived_by_user_id - total_transactions_count @@ -13329,6 +13718,7 @@ components: - yodlee_fastlink_params - created_at - updated_at + - corporate_card_id string_detail: type: string description: Additional string details of the card transaction. Can hold details upto 256 characters in length. @@ -13337,6 +13727,15 @@ components: corporate_card_out_embed: type: object additionalProperties: false + required: + - id + - bank_name + - card_number + - nickname + - cardholder_name + - masked_number + - user_full_name + - user_email properties: id: allOf: @@ -13810,6 +14209,8 @@ components: - capitalone_virtual_card_last_four corporate_card_transactions_expenses_stats_in: type: object + required: + - query_params properties: query_params: type: string @@ -14102,6 +14503,8 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_unmark_personal_out: type: object properties: @@ -14310,6 +14713,8 @@ components: - matched_expenses - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_ignore_out: type: object properties: @@ -14524,6 +14929,9 @@ components: - matched_expenses - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_undo_ignore_out: type: object additionalProperties: false @@ -14753,6 +15161,10 @@ components: - matched_expenses - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number corporate_card_transaction_match_in: type: object properties: @@ -14984,6 +15396,9 @@ components: - matched_expenses - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_unmatch_in: type: object properties: @@ -15227,6 +15642,11 @@ components: - matched_expenses - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number + - is_exported user_full_name: type: string maxLength: 255 @@ -15295,6 +15715,19 @@ components: spender_employee_out: type: object additionalProperties: false + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: '#/components/schemas/id_string' @@ -15646,6 +16079,19 @@ components: spender_commute_details_out: type: object additionalProperties: false + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: '#/components/schemas/id_string' @@ -15703,6 +16149,10 @@ components: spender_delegatees_post_in: type: object additionalProperties: false + required: + - delegatee_user_id + - start_at + - end_at properties: delegatee_user_id: $ref: '#/components/schemas/fk_string' @@ -15725,6 +16175,19 @@ components: spender_delegatees_post_out: type: object additionalProperties: false + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: '#/components/schemas/id_string' @@ -15782,6 +16245,10 @@ components: spender_delegators_out: type: object additionalProperties: false + required: + - user_id + - email + - full_name properties: user_id: $ref: '#/components/schemas/user_id' @@ -15796,6 +16263,13 @@ components: spender_delegatees_delete_out: type: object additionalProperties: false + required: + - id + - org_id + - delegator_user_id + - delegatee_user_id + - start_date + - end_date properties: id: $ref: '#/components/schemas/id_integer' @@ -15819,6 +16293,12 @@ components: $ref: '#/components/schemas/timestamptz_utc' employees_send_mobile_verification_code_post_out: type: object + required: + - to + - channel + - status + - date_created + - attempts_left additionalProperties: false properties: to: @@ -15836,11 +16316,6 @@ components: description: | Current status of the verification attempt example: pending - valid: - type: boolean - description: | - Whether the verification is valid - example: false date_created: type: string format: date-time @@ -15873,6 +16348,29 @@ components: spender_employee_settings_out: type: object additionalProperties: false + required: + - id + - employee_id + - org_id + - created_at + - updated_at + - category_ids + - cost_center_ids + - project_ids + - per_diem_rate_ids + - mileage_rate_ids + - insta_fyle_settings + - notification_settings + - mileage_settings + - expense_form_autofills + - data_extractor_settings + - in_app_chat_settings + - payment_mode_settings + - locale + - is_personal_cards_enabled + - default_project_id + - default_payment_mode + - default_vehicle_type properties: id: $ref: '#/components/schemas/id_string' @@ -16562,6 +17060,17 @@ components: file_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - created_at + - updated_at + - name + - type + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -16609,6 +17118,12 @@ components: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: '#/components/schemas/id_string' @@ -16640,6 +17155,11 @@ components: file_out_download_url: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url properties: id: $ref: '#/components/schemas/id_string' @@ -16784,6 +17304,9 @@ components: - action_add_department_head_approver - action_add_approver_user_ids - action_override_distance_slab_rate + - expense_merchants + - expense_merchants_op + - policy_violation_reason_required properties: id: allOf: @@ -17795,6 +18318,9 @@ components: expense_check_policies_out: type: object additionalProperties: false + required: + - individual_desired_states + - final_desired_state properties: individual_desired_states: type: array @@ -17944,6 +18470,8 @@ components: - expense_details - schedule_config - is_enabled + - created_at + - updated_at properties: id: allOf: @@ -17966,8 +18494,8 @@ components: - MILEAGE: Mileage-based expense type example: EXPENSE expense_details: - type: object - nullable: false + allOf: + - $ref: '#/components/schemas/spender_expense_in' description: | Expense template details used for creating recurring expenses. Contains all the expense fields that will be applied to each generated expense. @@ -18345,6 +18873,8 @@ components: description: | List of expense IDs that are part of the duplicate set expenses_stats_in: + required: + - query_params properties: query_params: nullable: false @@ -18602,6 +19132,17 @@ components: expenses_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state properties: created_at: $ref: '#/components/schemas/created_at' @@ -18945,6 +19486,17 @@ components: feature_config_out: type: object additionalProperties: false + required: + - org_id + - user_id + - created_at + - updated_at + - target_client + - feature + - sub_feature + - key + - value + - is_shared properties: org_id: $ref: '#/components/schemas/org_id' @@ -19149,6 +19701,23 @@ components: personal_card_delete_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - currency + - bank_name + - card_number + - account_type + - yodlee_account_id + - yodlee_fastlink_params + - yodlee_is_credential_update_required + - yodlee_is_mfa_required + - yodlee_last_synced_at + - yodlee_login_id + - yodlee_provider_account_id + - created_at + - updated_at properties: id: $ref: '#/components/schemas/id_string' @@ -19213,6 +19782,8 @@ components: $ref: '#/components/schemas/updated_at' personal_card_access_token_out: type: object + required: + - access_token properties: access_token: type: string @@ -19231,6 +19802,8 @@ components: example: baccymJEDziL9Y personal_card_mfa_out: type: object + required: + - is_mfa_enabled properties: is_mfa_enabled: type: boolean @@ -19240,6 +19813,25 @@ components: description: Determines wether the user card has MFA enabled or not personal_card_transaction_out: type: object + required: + - id + - org_id + - user_id + - personal_card_id + - amount + - currency + - spent_at + - category + - merchant + - state + - description + - external_transaction_id + - matched_expense_ids + - created_at + - updated_at + - foreign_amount + - foreign_currency + - matched_expenses additionalProperties: false properties: id: @@ -19323,6 +19915,23 @@ components: type: object additionalProperties: false nullable: true + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - location + - title + - business_unit + - custom_fields + - flattened_custom_field + - has_accepted_invite + - is_enabled properties: id: $ref: '#/components/schemas/id_string' @@ -19414,6 +20023,10 @@ components: example: personal_card_id=eq.bacctW9DfNhwOt&state=eq.HIDDEN personal_card_transactions_stats_out: type: object + required: + - count + - debit_amount + - credit_amount properties: count: type: integer @@ -19436,6 +20049,15 @@ components: get_spender_orgs_out: type: object additionalProperties: false + required: + - id + - name + - domain + - currency + - created_at + - updated_at + - is_current + - is_primary properties: id: $ref: '#/components/schemas/org_id' @@ -19464,6 +20086,9 @@ components: spender_org_bank_details_out: type: object additionalProperties: false + required: + - org_id + - is_bank_account_added properties: org_id: $ref: '#/components/schemas/org_id' @@ -19491,6 +20116,18 @@ components: advance_request_permissions_out: type: object additionalProperties: false + required: + - can_save + - can_submit + - can_edit + - can_add_approver + - can_disable_approver + - can_reject + - can_approve + - can_inquire + - can_pull_back + - can_pay + - can_delete properties: can_save: type: boolean @@ -19553,6 +20190,7 @@ components: description: | Comment explaining the reason for pulling back the advance request example: sending back + nullable: true attach_files_to_advance_request_in: type: object required: @@ -19585,6 +20223,51 @@ components: type: string description: Comment text to be added to the advance request example: test + advance_request_comments_out: + type: object + additionalProperties: false + required: + - id + - comment + - action + - advance_request_id + - creator_type + - creator_user_id + - creator_user + - created_at + - updated_at + - org_id + properties: + id: + $ref: '#/components/schemas/id_string' + comment: + type: string + description: A comment on the advance request + example: Advance request was created + action: + type: string + description: Advance request action for which comment is added. + example: SUBMITTED + advance_request_id: + $ref: '#/components/schemas/id_string' + creator_type: + type: string + description: Describes whether the comment is system-generated or User made. + enum: + - SYSTEM + - POLICY + - USER + example: USER + creator_user_id: + $ref: '#/components/schemas/user_id_nullable' + creator_user: + $ref: '#/components/schemas/user_out_embed_nullable' + created_at: + $ref: '#/components/schemas/created_at' + updated_at: + $ref: '#/components/schemas/updated_at' + org_id: + $ref: '#/components/schemas/org_id' advance_request_delete_in: type: object required: @@ -19596,6 +20279,14 @@ components: example: adrkvnwrnpwi secondary_email_out: type: object + required: + - id + - email + - is_verified + - org_id + - user_id + - created_at + - updated_at additionalProperties: false properties: id: @@ -20223,16 +20914,6 @@ components: $ref: '#/components/schemas/created_at' updated_at: $ref: '#/components/schemas/updated_at' - created_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who created this export configuration. - updated_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who last updated this export configuration. name: type: string description: | @@ -20460,16 +21141,6 @@ components: $ref: '#/components/schemas/created_at' updated_at: $ref: '#/components/schemas/updated_at' - created_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who created this export configuration. - updated_by: - allOf: - - $ref: '#/components/schemas/user_out_embed_nullable' - description: | - User who last updated this export configuration. name: type: string description: | @@ -20572,6 +21243,13 @@ components: mobile_app_version_out: type: object additionalProperties: false + required: + - id + - user_id + - version + - os + - created_at + - updated_at properties: id: type: string diff --git a/src/admin/paths/admin@accounting_export_lineitems.yaml b/src/admin/paths/admin@accounting_export_lineitems.yaml index 0e3d3c7cb..dfb06f7d5 100644 --- a/src/admin/paths/admin@accounting_export_lineitems.yaml +++ b/src/admin/paths/admin@accounting_export_lineitems.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/accounting_export_lineitem.yaml#/accounting_export_lineitem_out diff --git a/src/admin/paths/admin@accounting_exports.yaml b/src/admin/paths/admin@accounting_exports.yaml index 125fbb7c4..b65f01698 100644 --- a/src/admin/paths/admin@accounting_exports.yaml +++ b/src/admin/paths/admin@accounting_exports.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/accounting_export.yaml#/accounting_export_out diff --git a/src/admin/paths/admin@accounts.yaml b/src/admin/paths/admin@accounts.yaml index 93ef0e4b0..39ddc6b8e 100644 --- a/src/admin/paths/admin@accounts.yaml +++ b/src/admin/paths/admin@accounts.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/account.yaml#/account_out' diff --git a/src/admin/paths/admin@advance_refunds.yaml b/src/admin/paths/admin@advance_refunds.yaml index 82ceaf581..f1508b5b8 100644 --- a/src/admin/paths/admin@advance_refunds.yaml +++ b/src/admin/paths/admin@advance_refunds.yaml @@ -70,6 +70,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_refund.yaml#/advance_refund_out' diff --git a/src/admin/paths/admin@advance_refunds@stats.yaml b/src/admin/paths/admin@advance_refunds@stats.yaml index 7c0f8062c..be42f477c 100644 --- a/src/admin/paths/admin@advance_refunds@stats.yaml +++ b/src/admin/paths/admin@advance_refunds@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@advance_requests.yaml b/src/admin/paths/admin@advance_requests.yaml index 8bed4709e..6b447d513 100644 --- a/src/admin/paths/admin@advance_requests.yaml +++ b/src/admin/paths/admin@advance_requests.yaml @@ -70,6 +70,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@add_approver.yaml b/src/admin/paths/admin@advance_requests@add_approver.yaml index 56de6b4b5..1128508d7 100644 --- a/src/admin/paths/admin@advance_requests@add_approver.yaml +++ b/src/admin/paths/admin@advance_requests@add_approver.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_add_approver_in' @@ -26,6 +28,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml b/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml index 14065e4b1..8da910c34 100644 --- a/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml +++ b/src/admin/paths/admin@advance_requests@bulk_attach_file.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@advance_requests@comments.yaml b/src/admin/paths/admin@advance_requests@comments.yaml index 4bac5d7f9..c4d14ca36 100644 --- a/src/admin/paths/admin@advance_requests@comments.yaml +++ b/src/admin/paths/admin@advance_requests@comments.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_out' diff --git a/src/admin/paths/admin@advance_requests@custom_fields.yaml b/src/admin/paths/admin@advance_requests@custom_fields.yaml index 1f43da81b..cac7f388f 100644 --- a/src/admin/paths/admin@advance_requests@custom_fields.yaml +++ b/src/admin/paths/admin@advance_requests@custom_fields.yaml @@ -66,6 +66,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_custom_field_out' diff --git a/src/admin/paths/admin@advance_requests@inquire.yaml b/src/admin/paths/admin@advance_requests@inquire.yaml index 7edb2e29b..939704db3 100644 --- a/src/admin/paths/admin@advance_requests@inquire.yaml +++ b/src/admin/paths/admin@advance_requests@inquire.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@permissions.yaml b/src/admin/paths/admin@advance_requests@permissions.yaml index 744da3b9f..8f5d4031b 100644 --- a/src/admin/paths/admin@advance_requests@permissions.yaml +++ b/src/admin/paths/admin@advance_requests@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_permissions_out' diff --git a/src/admin/paths/admin@advance_requests@reject.yaml b/src/admin/paths/admin@advance_requests@reject.yaml index b3e8c6577..4ef47efba 100644 --- a/src/admin/paths/admin@advance_requests@reject.yaml +++ b/src/admin/paths/admin@advance_requests@reject.yaml @@ -29,6 +29,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@remove_approver.yaml b/src/admin/paths/admin@advance_requests@remove_approver.yaml index 916bb571e..749d58844 100644 --- a/src/admin/paths/admin@advance_requests@remove_approver.yaml +++ b/src/admin/paths/admin@advance_requests@remove_approver.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_remove_approver_in' @@ -25,6 +27,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_requests@stats.yaml b/src/admin/paths/admin@advance_requests@stats.yaml index f8899cb51..34b7bc4fe 100644 --- a/src/admin/paths/admin@advance_requests@stats.yaml +++ b/src/admin/paths/admin@advance_requests@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_requests_stats_out' diff --git a/src/admin/paths/admin@advance_requests@submit.yaml b/src/admin/paths/admin@advance_requests@submit.yaml index f511c601e..287fae1b2 100644 --- a/src/admin/paths/admin@advance_requests@submit.yaml +++ b/src/admin/paths/admin@advance_requests@submit.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/admin/paths/admin@advance_wallets.yaml b/src/admin/paths/admin@advance_wallets.yaml index 99ef3be7a..9dd1379ea 100644 --- a/src/admin/paths/admin@advance_wallets.yaml +++ b/src/admin/paths/admin@advance_wallets.yaml @@ -70,6 +70,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_wallet.yaml#/advance_wallet_out' diff --git a/src/admin/paths/admin@advances.yaml b/src/admin/paths/admin@advances.yaml index eb7ce5a16..b9d19a5b7 100644 --- a/src/admin/paths/admin@advances.yaml +++ b/src/admin/paths/admin@advances.yaml @@ -70,6 +70,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance.yaml#/advance_out' diff --git a/src/admin/paths/admin@advances@stats.yaml b/src/admin/paths/admin@advances@stats.yaml index 54003447c..2e99a08d2 100644 --- a/src/admin/paths/admin@advances@stats.yaml +++ b/src/admin/paths/admin@advances@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance.yaml#/advances_stats_out' diff --git a/src/admin/paths/admin@automations@report_submissions.yaml b/src/admin/paths/admin@automations@report_submissions.yaml index c860d8292..20d28a5d3 100644 --- a/src/admin/paths/admin@automations@report_submissions.yaml +++ b/src/admin/paths/admin@automations@report_submissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/automation.yaml#/automate_report_submission_out diff --git a/src/admin/paths/admin@automations@report_submissions@delete.yaml b/src/admin/paths/admin@automations@report_submissions@delete.yaml index 6f363fe20..6e4787d82 100644 --- a/src/admin/paths/admin@automations@report_submissions@delete.yaml +++ b/src/admin/paths/admin@automations@report_submissions@delete.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/automation.yaml#/automate_report_submission_out diff --git a/src/admin/paths/admin@budgets.yaml b/src/admin/paths/admin@budgets.yaml index 43e606171..25c99f06b 100644 --- a/src/admin/paths/admin@budgets.yaml +++ b/src/admin/paths/admin@budgets.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/budget.yaml#/budget_post_out diff --git a/src/admin/paths/admin@budgets@exports.yaml b/src/admin/paths/admin@budgets@exports.yaml index a130c8ba3..771917194 100644 --- a/src/admin/paths/admin@budgets@exports.yaml +++ b/src/admin/paths/admin@budgets@exports.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/budget_exports.yaml#/budget_exports_out' diff --git a/src/admin/paths/admin@categories.yaml b/src/admin/paths/admin@categories.yaml index ba8839075..b83f6e782 100644 --- a/src/admin/paths/admin@categories.yaml +++ b/src/admin/paths/admin@categories.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/category.yaml#/admin_approver_category_out diff --git a/src/admin/paths/admin@categories@system_categories.yaml b/src/admin/paths/admin@categories@system_categories.yaml index cfbc62464..701ced45b 100644 --- a/src/admin/paths/admin@categories@system_categories.yaml +++ b/src/admin/paths/admin@categories@system_categories.yaml @@ -15,6 +15,7 @@ get: additionalProperties: False required: - data + - count properties: count: $ref: ../../components/schemas/count.yaml diff --git a/src/admin/paths/admin@corporate_card_transactions.yaml b/src/admin/paths/admin@corporate_card_transactions.yaml index 7232506a6..3c075f769 100644 --- a/src/admin/paths/admin@corporate_card_transactions.yaml +++ b/src/admin/paths/admin@corporate_card_transactions.yaml @@ -69,6 +69,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_post_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@assign.yaml b/src/admin/paths/admin@corporate_card_transactions@assign.yaml index a4c225645..164cf9037 100644 --- a/src/admin/paths/admin@corporate_card_transactions@assign.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@assign.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_assign_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@delete.yaml b/src/admin/paths/admin@corporate_card_transactions@delete.yaml index 61b423a22..07939d246 100644 --- a/src/admin/paths/admin@corporate_card_transactions@delete.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@delete.yaml @@ -26,6 +26,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml b/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml index 8f4c16436..7bfa398ce 100644 --- a/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@delete_summary@bulk.yaml @@ -26,6 +26,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml b/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml index 9386ab470..7213a20b8 100644 --- a/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@export_configurations.yaml @@ -161,6 +161,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transactions_export_configurations.yaml#/corporate_card_transactions_export_configuration_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@exports.yaml b/src/admin/paths/admin@corporate_card_transactions@exports.yaml index a0600ae9b..1adce438e 100644 --- a/src/admin/paths/admin@corporate_card_transactions@exports.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@exports.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transactions_exports.yaml#/corporate_card_transactions_exports_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@filters.yaml b/src/admin/paths/admin@corporate_card_transactions@filters.yaml index 556a241ac..8034539b3 100644 --- a/src/admin/paths/admin@corporate_card_transactions@filters.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction_filters.yaml#/corporate_card_transaction_filters_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml b/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml index b3e617efb..2666a271b 100644 --- a/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction_filters.yaml#/corporate_card_transaction_filters_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@ignore.yaml b/src/admin/paths/admin@corporate_card_transactions@ignore.yaml index af8d658dd..2a34f0ea2 100644 --- a/src/admin/paths/admin@corporate_card_transactions@ignore.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@ignore.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_ignore_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml b/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml index 8105cd9de..a689b154c 100644 --- a/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@mark_personal.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_mark_personal_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@match.yaml b/src/admin/paths/admin@corporate_card_transactions@match.yaml index 4c60ece64..7cbe00818 100644 --- a/src/admin/paths/admin@corporate_card_transactions@match.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@match.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_match_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@stats.yaml b/src/admin/paths/admin@corporate_card_transactions@stats.yaml index fc87585f1..3c19e125e 100644 --- a/src/admin/paths/admin@corporate_card_transactions@stats.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@corporate_card_transactions@unassign.yaml b/src/admin/paths/admin@corporate_card_transactions@unassign.yaml index 3bab0bb07..bc01a9857 100644 --- a/src/admin/paths/admin@corporate_card_transactions@unassign.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@unassign.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unassign_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml b/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml index fec689502..5f28cd2e5 100644 --- a/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@undo_ignore.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_undo_ignore_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml b/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml index b68b9b0a8..91bebf4fe 100644 --- a/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@unmark_personal.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmark_personal_out' diff --git a/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml b/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml index a5f3244d4..7677284cd 100644 --- a/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml +++ b/src/admin/paths/admin@corporate_card_transactions@unmatch.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmatch_out' diff --git a/src/admin/paths/admin@corporate_cards.yaml b/src/admin/paths/admin@corporate_cards.yaml index 86bdc40b0..7544044b4 100644 --- a/src/admin/paths/admin@corporate_cards.yaml +++ b/src/admin/paths/admin@corporate_cards.yaml @@ -69,6 +69,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@archive.yaml b/src/admin/paths/admin@corporate_cards@archive.yaml index 704fde701..63b51ae9f 100644 --- a/src/admin/paths/admin@corporate_cards@archive.yaml +++ b/src/admin/paths/admin@corporate_cards@archive.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml b/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml index e52b39b20..67621dd1d 100644 --- a/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml +++ b/src/admin/paths/admin@corporate_cards@archive_suggestions@dismiss.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_archive_suggestion_out' diff --git a/src/admin/paths/admin@corporate_cards@assign.yaml b/src/admin/paths/admin@corporate_cards@assign.yaml index ff739e803..36a0d7256 100644 --- a/src/admin/paths/admin@corporate_cards@assign.yaml +++ b/src/admin/paths/admin@corporate_cards@assign.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@bank_names.yaml b/src/admin/paths/admin@corporate_cards@bank_names.yaml index 5d09c4458..feed534db 100644 --- a/src/admin/paths/admin@corporate_cards@bank_names.yaml +++ b/src/admin/paths/admin@corporate_cards@bank_names.yaml @@ -17,6 +17,8 @@ get: properties: data: type: object + required: + - bank_names properties: bank_names: type: array diff --git a/src/admin/paths/admin@corporate_cards@delete.yaml b/src/admin/paths/admin@corporate_cards@delete.yaml index aad46e8e8..e562ea251 100644 --- a/src/admin/paths/admin@corporate_cards@delete.yaml +++ b/src/admin/paths/admin@corporate_cards@delete.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml b/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml index 88ed5f0b2..e53b58c97 100644 --- a/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml +++ b/src/admin/paths/admin@corporate_cards@duplicate_suggestions@dismiss.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_duplicate_suggestion_out' diff --git a/src/admin/paths/admin@corporate_cards@merge.yaml b/src/admin/paths/admin@corporate_cards@merge.yaml index e2850c21d..452aeeeb0 100644 --- a/src/admin/paths/admin@corporate_cards@merge.yaml +++ b/src/admin/paths/admin@corporate_cards@merge.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@reassign.yaml b/src/admin/paths/admin@corporate_cards@reassign.yaml index 6c609bdc1..bd454839e 100644 --- a/src/admin/paths/admin@corporate_cards@reassign.yaml +++ b/src/admin/paths/admin@corporate_cards@reassign.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@stats.yaml b/src/admin/paths/admin@corporate_cards@stats.yaml index f994b78a8..bfec761b7 100644 --- a/src/admin/paths/admin@corporate_cards@stats.yaml +++ b/src/admin/paths/admin@corporate_cards@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_stats_out' diff --git a/src/admin/paths/admin@corporate_cards@unarchive.yaml b/src/admin/paths/admin@corporate_cards@unarchive.yaml index 3e21aabdf..ad5809880 100644 --- a/src/admin/paths/admin@corporate_cards@unarchive.yaml +++ b/src/admin/paths/admin@corporate_cards@unarchive.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out' diff --git a/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml b/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml index bce9c0ae3..9e95f516e 100644 --- a/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml +++ b/src/admin/paths/admin@corporate_cards@unarchive@bulk.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@corporate_cards@unassign.yaml b/src/admin/paths/admin@corporate_cards@unassign.yaml index 24bba1d9d..8798ff037 100644 --- a/src/admin/paths/admin@corporate_cards@unassign.yaml +++ b/src/admin/paths/admin@corporate_cards@unassign.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_unassign_out' diff --git a/src/admin/paths/admin@cost_centers.yaml b/src/admin/paths/admin@cost_centers.yaml index 8b0ec51bf..18b840621 100644 --- a/src/admin/paths/admin@cost_centers.yaml +++ b/src/admin/paths/admin@cost_centers.yaml @@ -71,6 +71,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/cost_center.yaml#/admin_cost_center_out diff --git a/src/admin/paths/admin@departments.yaml b/src/admin/paths/admin@departments.yaml index 21da1b722..39511bd9b 100644 --- a/src/admin/paths/admin@departments.yaml +++ b/src/admin/paths/admin@departments.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/department.yaml#/department_out diff --git a/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml b/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml index bf7b2f72b..d3875747b 100644 --- a/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml +++ b/src/admin/paths/admin@dependent_expense_field_values@downloads.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/dependent_expense_field_values.yaml#/dependent_expense_field_values_download_out' diff --git a/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml b/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml index 1fa6cacb6..ea2bc809e 100644 --- a/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml +++ b/src/admin/paths/admin@dependent_expense_field_values@uploads.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/dependent_expense_field_values.yaml#/dependent_expense_field_values_upload_out' diff --git a/src/admin/paths/admin@dwolla_customers.yaml b/src/admin/paths/admin@dwolla_customers.yaml index 9512dee79..a944eb6bb 100644 --- a/src/admin/paths/admin@dwolla_customers.yaml +++ b/src/admin/paths/admin@dwolla_customers.yaml @@ -60,6 +60,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/dwolla_customer.yaml#/dwolla_customer_out' diff --git a/src/admin/paths/admin@employee_fields.yaml b/src/admin/paths/admin@employee_fields.yaml index 4bcf4e824..fa8537f02 100644 --- a/src/admin/paths/admin@employee_fields.yaml +++ b/src/admin/paths/admin@employee_fields.yaml @@ -60,6 +60,8 @@ post: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/admin/paths/admin@employees@downloads.yaml b/src/admin/paths/admin@employees@downloads.yaml index 0f02c685f..a6522340a 100644 --- a/src/admin/paths/admin@employees@downloads.yaml +++ b/src/admin/paths/admin@employees@downloads.yaml @@ -65,6 +65,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employee.yaml#/employees_download_out' diff --git a/src/admin/paths/admin@employees@export_configurations.yaml b/src/admin/paths/admin@employees@export_configurations.yaml index 883dbe342..1ebea4124 100644 --- a/src/admin/paths/admin@employees@export_configurations.yaml +++ b/src/admin/paths/admin@employees@export_configurations.yaml @@ -163,6 +163,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employees_export_configurations.yaml#/employees_export_configuration_out' diff --git a/src/admin/paths/admin@employees@exports.yaml b/src/admin/paths/admin@employees@exports.yaml index e9e34ca4e..142c571e6 100644 --- a/src/admin/paths/admin@employees@exports.yaml +++ b/src/admin/paths/admin@employees@exports.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employees_exports.yaml#/employees_exports_out' diff --git a/src/admin/paths/admin@employees@filters.yaml b/src/admin/paths/admin@employees@filters.yaml index 2fd76e63e..f5832b22a 100644 --- a/src/admin/paths/admin@employees@filters.yaml +++ b/src/admin/paths/admin@employees@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employee_filters.yaml#/employee_filters_out' diff --git a/src/admin/paths/admin@employees@filters@delete.yaml b/src/admin/paths/admin@employees@filters@delete.yaml index 9a485e223..4c3ec7877 100644 --- a/src/admin/paths/admin@employees@filters@delete.yaml +++ b/src/admin/paths/admin@employees@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employee_filters.yaml#/employee_filters_out' diff --git a/src/admin/paths/admin@employees@stats.yaml b/src/admin/paths/admin@employees@stats.yaml index bebfd19ae..aab808494 100644 --- a/src/admin/paths/admin@employees@stats.yaml +++ b/src/admin/paths/admin@employees@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/employee.yaml#/employees_stats_out' diff --git a/src/admin/paths/admin@employees@uploads.yaml b/src/admin/paths/admin@employees@uploads.yaml index 98301a851..289929f91 100644 --- a/src/admin/paths/admin@employees@uploads.yaml +++ b/src/admin/paths/admin@employees@uploads.yaml @@ -65,6 +65,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/employee.yaml#/employees_upload_out' diff --git a/src/admin/paths/admin@expense_fields.yaml b/src/admin/paths/admin@expense_fields.yaml index a5183e230..2efd1d8f6 100644 --- a/src/admin/paths/admin@expense_fields.yaml +++ b/src/admin/paths/admin@expense_fields.yaml @@ -60,6 +60,8 @@ post: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/admin/paths/admin@expense_policies.yaml b/src/admin/paths/admin@expense_policies.yaml index f2d99bfed..3a0dc57b5 100644 --- a/src/admin/paths/admin@expense_policies.yaml +++ b/src/admin/paths/admin@expense_policies.yaml @@ -31,6 +31,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense_policies.yaml#/expense_policy_out diff --git a/src/admin/paths/admin@expense_policies@disable.yaml b/src/admin/paths/admin@expense_policies@disable.yaml index 9e804fcb6..80784a21d 100644 --- a/src/admin/paths/admin@expense_policies@disable.yaml +++ b/src/admin/paths/admin@expense_policies@disable.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense_policies.yaml#/expense_policy_out diff --git a/src/admin/paths/admin@expense_policies@enable.yaml b/src/admin/paths/admin@expense_policies@enable.yaml index d2268e290..d23e1c5c8 100644 --- a/src/admin/paths/admin@expense_policies@enable.yaml +++ b/src/admin/paths/admin@expense_policies@enable.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense_policies.yaml#/expense_policy_out diff --git a/src/admin/paths/admin@expense_policy_comments.yaml b/src/admin/paths/admin@expense_policy_comments.yaml index 32672860a..5c3668172 100644 --- a/src/admin/paths/admin@expense_policy_comments.yaml +++ b/src/admin/paths/admin@expense_policy_comments.yaml @@ -58,6 +58,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@expenses.yaml b/src/admin/paths/admin@expenses.yaml index 8e5610fa4..5c9213e25 100644 --- a/src/admin/paths/admin@expenses.yaml +++ b/src/admin/paths/admin@expenses.yaml @@ -52,6 +52,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_expense_in' @@ -62,6 +64,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/admin/paths/admin@expenses@attach_files@bulk.yaml b/src/admin/paths/admin@expenses@attach_files@bulk.yaml index 697d8e58d..10a43e46a 100644 --- a/src/admin/paths/admin@expenses@attach_files@bulk.yaml +++ b/src/admin/paths/admin@expenses@attach_files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@bulk.yaml b/src/admin/paths/admin@expenses@bulk.yaml index 7d4a8e59e..07ec4dae0 100644 --- a/src/admin/paths/admin@expenses@bulk.yaml +++ b/src/admin/paths/admin@expenses@bulk.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_expenses_bulk_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@check_policies_bulk.yaml b/src/admin/paths/admin@expenses@check_policies_bulk.yaml index 89319cc95..5a4e15542 100644 --- a/src/admin/paths/admin@expenses@check_policies_bulk.yaml +++ b/src/admin/paths/admin@expenses@check_policies_bulk.yaml @@ -28,6 +28,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out diff --git a/src/admin/paths/admin@expenses@comments@bulk.yaml b/src/admin/paths/admin@expenses@comments@bulk.yaml index a48fa6c05..4d597c219 100644 --- a/src/admin/paths/admin@expenses@comments@bulk.yaml +++ b/src/admin/paths/admin@expenses@comments@bulk.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_comments_bulk_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@export_configurations.yaml b/src/admin/paths/admin@expenses@export_configurations.yaml index 3573fbac4..837605ec1 100644 --- a/src/admin/paths/admin@expenses@export_configurations.yaml +++ b/src/admin/paths/admin@expenses@export_configurations.yaml @@ -147,6 +147,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_export_configurations.yaml#/expenses_export_configuration_out' diff --git a/src/admin/paths/admin@expenses@exports.yaml b/src/admin/paths/admin@expenses@exports.yaml index 0736bd382..1e0d8906e 100644 --- a/src/admin/paths/admin@expenses@exports.yaml +++ b/src/admin/paths/admin@expenses@exports.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_exports.yaml#/expenses_exports_out' diff --git a/src/admin/paths/admin@expenses@filters.yaml b/src/admin/paths/admin@expenses@filters.yaml index d3ab7b27e..10e5f6f1c 100644 --- a/src/admin/paths/admin@expenses@filters.yaml +++ b/src/admin/paths/admin@expenses@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/admin/paths/admin@expenses@filters@delete.yaml b/src/admin/paths/admin@expenses@filters@delete.yaml index 144f8b063..0acdb816f 100644 --- a/src/admin/paths/admin@expenses@filters@delete.yaml +++ b/src/admin/paths/admin@expenses@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/admin/paths/admin@expenses@merge.yaml b/src/admin/paths/admin@expenses@merge.yaml index 9684a9e75..1f7c77091 100644 --- a/src/admin/paths/admin@expenses@merge.yaml +++ b/src/admin/paths/admin@expenses@merge.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_merge_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/admin/paths/admin@expenses@permissions.yaml b/src/admin/paths/admin@expenses@permissions.yaml index d6001df6f..3364da543 100644 --- a/src/admin/paths/admin@expenses@permissions.yaml +++ b/src/admin/paths/admin@expenses@permissions.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_out' diff --git a/src/admin/paths/admin@expenses@permissions@bulk.yaml b/src/admin/paths/admin@expenses@permissions@bulk.yaml index 0c0719457..8664840e7 100644 --- a/src/admin/paths/admin@expenses@permissions@bulk.yaml +++ b/src/admin/paths/admin@expenses@permissions@bulk.yaml @@ -33,6 +33,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' diff --git a/src/admin/paths/admin@expenses@split.yaml b/src/admin/paths/admin@expenses@split.yaml index d0754dc82..b07231780 100644 --- a/src/admin/paths/admin@expenses@split.yaml +++ b/src/admin/paths/admin@expenses@split.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml b/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml index 9a9988de2..57c713302 100644 --- a/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml +++ b/src/admin/paths/admin@expenses@split@check_mandatory_fields.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@split@check_policies.yaml b/src/admin/paths/admin@expenses@split@check_policies.yaml index e8a60dddd..0c9410c0b 100644 --- a/src/admin/paths/admin@expenses@split@check_policies.yaml +++ b/src/admin/paths/admin@expenses@split@check_policies.yaml @@ -14,6 +14,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -24,6 +26,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@expenses@stats.yaml b/src/admin/paths/admin@expenses@stats.yaml index ee129cee4..0bf898b7c 100644 --- a/src/admin/paths/admin@expenses@stats.yaml +++ b/src/admin/paths/admin@expenses@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_stats_out' diff --git a/src/admin/paths/admin@files.yaml b/src/admin/paths/admin@files.yaml index 02998c601..65603ab8e 100644 --- a/src/admin/paths/admin@files.yaml +++ b/src/admin/paths/admin@files.yaml @@ -59,6 +59,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/file.yaml#/file_out diff --git a/src/admin/paths/admin@files@bulk.yaml b/src/admin/paths/admin@files@bulk.yaml index d48b10505..ffd179f21 100644 --- a/src/admin/paths/admin@files@bulk.yaml +++ b/src/admin/paths/admin@files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@files@generate_urls@bulk.yaml b/src/admin/paths/admin@files@generate_urls@bulk.yaml index a29425341..f28de9259 100644 --- a/src/admin/paths/admin@files@generate_urls@bulk.yaml +++ b/src/admin/paths/admin@files@generate_urls@bulk.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@levels.yaml b/src/admin/paths/admin@levels.yaml index aaadf0736..fc01a971d 100644 --- a/src/admin/paths/admin@levels.yaml +++ b/src/admin/paths/admin@levels.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: ../../components/schemas/level.yaml#/level_out diff --git a/src/admin/paths/admin@mileage_rates.yaml b/src/admin/paths/admin@mileage_rates.yaml index b6f199e99..7f3e8559c 100644 --- a/src/admin/paths/admin@mileage_rates.yaml +++ b/src/admin/paths/admin@mileage_rates.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: ../../components/schemas/mileage_rate.yaml#/mileage_rate_out diff --git a/src/admin/paths/admin@per_diem_rates.yaml b/src/admin/paths/admin@per_diem_rates.yaml index 4cb54f536..f363a51a8 100644 --- a/src/admin/paths/admin@per_diem_rates.yaml +++ b/src/admin/paths/admin@per_diem_rates.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/per_diem_rate.yaml#/per_diem_rate_out diff --git a/src/admin/paths/admin@projects.yaml b/src/admin/paths/admin@projects.yaml index d9dbe32e5..d311d685d 100644 --- a/src/admin/paths/admin@projects.yaml +++ b/src/admin/paths/admin@projects.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/project.yaml#/admin_approver_project_out diff --git a/src/admin/paths/admin@reconciliation_entries@close.yaml b/src/admin/paths/admin@reconciliation_entries@close.yaml index 5e8b56b7d..f491c1fdb 100644 --- a/src/admin/paths/admin@reconciliation_entries@close.yaml +++ b/src/admin/paths/admin@reconciliation_entries@close.yaml @@ -33,6 +33,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml b/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml index 3755c345e..04c6923c2 100644 --- a/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml +++ b/src/admin/paths/admin@reconciliation_entries@eligible_cards@exports.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/reconciliation_exports.yaml#/reconciliation_export_out' diff --git a/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml b/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml index d36857e54..c7c16dcf5 100644 --- a/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml +++ b/src/admin/paths/admin@reconciliation_entries@eligible_cards@stats.yaml @@ -26,6 +26,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml index 698c0e4be..c2f5a66c2 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@delete@bulk.yaml @@ -39,6 +39,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml index 0d4f54b96..d1b11f39c 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@exports.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/reconciliation_exports.yaml#/reconciliation_export_out' diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml index 40c7ee40e..149cac5f6 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@find_match.yaml @@ -32,6 +32,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: false properties: data: diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml index 70600a3d6..08ba7772c 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@match_and_reconcile@bulk.yaml @@ -46,6 +46,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml index e9b88c92c..a21847a8d 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@move_to_next_period@bulk.yaml @@ -31,6 +31,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml index 92b38f5be..b93a11236 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@reconcile@bulk.yaml @@ -39,6 +39,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml index d54070960..246efefd8 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@resolve_multi_matches.yaml @@ -38,6 +38,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml index 4a291f7f5..60d0a3581 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@stats.yaml @@ -26,6 +26,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml b/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml index fbd004c12..0af2981f0 100644 --- a/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml +++ b/src/admin/paths/admin@reconciliation_entries@transactions@unmatch@bulk.yaml @@ -39,6 +39,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@reimbursements@mark_complete.yaml b/src/admin/paths/admin@reimbursements@mark_complete.yaml index 5dce2ef6e..5f29952d4 100644 --- a/src/admin/paths/admin@reimbursements@mark_complete.yaml +++ b/src/admin/paths/admin@reimbursements@mark_complete.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/reimbursement.yaml#/reimbursement_out' diff --git a/src/admin/paths/admin@reminders.yaml b/src/admin/paths/admin@reminders.yaml index e7490eb72..7aa19a6bf 100644 --- a/src/admin/paths/admin@reminders.yaml +++ b/src/admin/paths/admin@reminders.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/reminder.yaml#/reminder_out diff --git a/src/admin/paths/admin@reminders@delete.yaml b/src/admin/paths/admin@reminders@delete.yaml index 95ec9b7e0..3e060b578 100644 --- a/src/admin/paths/admin@reminders@delete.yaml +++ b/src/admin/paths/admin@reminders@delete.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reminders@stats.yaml b/src/admin/paths/admin@reminders@stats.yaml index 3cca816f3..e22926d51 100644 --- a/src/admin/paths/admin@reminders@stats.yaml +++ b/src/admin/paths/admin@reminders@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reports@add_approver.yaml b/src/admin/paths/admin@reports@add_approver.yaml index 226ad05bd..19a0e87f0 100644 --- a/src/admin/paths/admin@reports@add_approver.yaml +++ b/src/admin/paths/admin@reports@add_approver.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@apply_advance_wallets.yaml b/src/admin/paths/admin@reports@apply_advance_wallets.yaml index fceba0263..c5fee00fa 100644 --- a/src/admin/paths/admin@reports@apply_advance_wallets.yaml +++ b/src/admin/paths/admin@reports@apply_advance_wallets.yaml @@ -24,6 +24,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@comments.yaml b/src/admin/paths/admin@reports@comments.yaml index 9b48e93b2..ffdef235d 100644 --- a/src/admin/paths/admin@reports@comments.yaml +++ b/src/admin/paths/admin@reports@comments.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_comments_out' diff --git a/src/admin/paths/admin@reports@delete_filter.yaml b/src/admin/paths/admin@reports@delete_filter.yaml index 50d56712a..63bceca83 100644 --- a/src/admin/paths/admin@reports@delete_filter.yaml +++ b/src/admin/paths/admin@reports@delete_filter.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/admin/paths/admin@reports@eject_expenses.yaml b/src/admin/paths/admin@reports@eject_expenses.yaml index d293caddb..3a9717f45 100644 --- a/src/admin/paths/admin@reports@eject_expenses.yaml +++ b/src/admin/paths/admin@reports@eject_expenses.yaml @@ -30,6 +30,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@export_configurations.yaml b/src/admin/paths/admin@reports@export_configurations.yaml index 3f4c2f255..d544fa796 100644 --- a/src/admin/paths/admin@reports@export_configurations.yaml +++ b/src/admin/paths/admin@reports@export_configurations.yaml @@ -70,6 +70,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_export_configurations.yaml#/reports_export_configuration_out' diff --git a/src/admin/paths/admin@reports@exports.yaml b/src/admin/paths/admin@reports@exports.yaml index 683440fb1..248ff4d59 100644 --- a/src/admin/paths/admin@reports@exports.yaml +++ b/src/admin/paths/admin@reports@exports.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_exports.yaml#/reports_exports_out' diff --git a/src/admin/paths/admin@reports@permissions.yaml b/src/admin/paths/admin@reports@permissions.yaml index 00c0674d9..71ca3ad25 100644 --- a/src/admin/paths/admin@reports@permissions.yaml +++ b/src/admin/paths/admin@reports@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report_permissions.yaml#/report_permissions_out' diff --git a/src/admin/paths/admin@reports@process_summary@bulk.yaml b/src/admin/paths/admin@reports@process_summary@bulk.yaml index 7ca2d35c9..84f8a99f4 100644 --- a/src/admin/paths/admin@reports@process_summary@bulk.yaml +++ b/src/admin/paths/admin@reports@process_summary@bulk.yaml @@ -26,6 +26,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/admin/paths/admin@reports@remove_advance_wallets.yaml b/src/admin/paths/admin@reports@remove_advance_wallets.yaml index ebc30e859..f4675ef0a 100644 --- a/src/admin/paths/admin@reports@remove_advance_wallets.yaml +++ b/src/admin/paths/admin@reports@remove_advance_wallets.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@remove_approver.yaml b/src/admin/paths/admin@reports@remove_approver.yaml index a305e8946..cf117eacd 100644 --- a/src/admin/paths/admin@reports@remove_approver.yaml +++ b/src/admin/paths/admin@reports@remove_approver.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@revert_to_approved.yaml b/src/admin/paths/admin@reports@revert_to_approved.yaml index 7c411b0ba..51e3af78d 100644 --- a/src/admin/paths/admin@reports@revert_to_approved.yaml +++ b/src/admin/paths/admin@reports@revert_to_approved.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@revert_to_processing.yaml b/src/admin/paths/admin@reports@revert_to_processing.yaml index 6d00142dd..22ab342dc 100644 --- a/src/admin/paths/admin@reports@revert_to_processing.yaml +++ b/src/admin/paths/admin@reports@revert_to_processing.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@round_off_amount.yaml b/src/admin/paths/admin@reports@round_off_amount.yaml index 06614451f..f99731a3a 100644 --- a/src/admin/paths/admin@reports@round_off_amount.yaml +++ b/src/admin/paths/admin@reports@round_off_amount.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@save_filters.yaml b/src/admin/paths/admin@reports@save_filters.yaml index 36652d425..2da3220ee 100644 --- a/src/admin/paths/admin@reports@save_filters.yaml +++ b/src/admin/paths/admin@reports@save_filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/admin/paths/admin@reports@send_back.yaml b/src/admin/paths/admin@reports@send_back.yaml index acd3ca98d..3cc52c0aa 100644 --- a/src/admin/paths/admin@reports@send_back.yaml +++ b/src/admin/paths/admin@reports@send_back.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/admin_report_out' diff --git a/src/admin/paths/admin@reports@stats.yaml b/src/admin/paths/admin@reports@stats.yaml index bd00c4e13..029c82d13 100644 --- a/src/admin/paths/admin@reports@stats.yaml +++ b/src/admin/paths/admin@reports@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/reports_stats_out' diff --git a/src/admin/paths/admin@scheduled_callbacks.yaml b/src/admin/paths/admin@scheduled_callbacks.yaml index 8a1ad4f51..d6b9f008f 100644 --- a/src/admin/paths/admin@scheduled_callbacks.yaml +++ b/src/admin/paths/admin@scheduled_callbacks.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/scheduled_callback.yaml#/scheduled_callback_out diff --git a/src/admin/paths/admin@schedules.yaml b/src/admin/paths/admin@schedules.yaml index 5ab588a35..c6e4eb8ca 100644 --- a/src/admin/paths/admin@schedules.yaml +++ b/src/admin/paths/admin@schedules.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/schedule.yaml#/schedule_out diff --git a/src/admin/paths/admin@statements@archived_cards.yaml b/src/admin/paths/admin@statements@archived_cards.yaml index 60b5d27b6..09083e129 100644 --- a/src/admin/paths/admin@statements@archived_cards.yaml +++ b/src/admin/paths/admin@statements@archived_cards.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@archived_cards@ignore.yaml b/src/admin/paths/admin@statements@archived_cards@ignore.yaml index e3a06ac61..575dc0970 100644 --- a/src/admin/paths/admin@statements@archived_cards@ignore.yaml +++ b/src/admin/paths/admin@statements@archived_cards@ignore.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@statements@card_stats.yaml b/src/admin/paths/admin@statements@card_stats.yaml index 5906f74f6..3a9d20431 100644 --- a/src/admin/paths/admin@statements@card_stats.yaml +++ b/src/admin/paths/admin@statements@card_stats.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/statements.yaml#/card_stats_out' diff --git a/src/admin/paths/admin@statements@matching_cards.yaml b/src/admin/paths/admin@statements@matching_cards.yaml index 05cf558fa..68b4b9aa6 100644 --- a/src/admin/paths/admin@statements@matching_cards.yaml +++ b/src/admin/paths/admin@statements@matching_cards.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@preview.yaml b/src/admin/paths/admin@statements@preview.yaml index 5a21fb962..f57f87bb3 100644 --- a/src/admin/paths/admin@statements@preview.yaml +++ b/src/admin/paths/admin@statements@preview.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/statements.yaml#/preview_out' diff --git a/src/admin/paths/admin@statements@reconcile.yaml b/src/admin/paths/admin@statements@reconcile.yaml index d35298686..1669a3032 100644 --- a/src/admin/paths/admin@statements@reconcile.yaml +++ b/src/admin/paths/admin@statements@reconcile.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: object diff --git a/src/admin/paths/admin@statements@reconciliation_summary.yaml b/src/admin/paths/admin@statements@reconciliation_summary.yaml index e752af7ef..f6b325be4 100644 --- a/src/admin/paths/admin@statements@reconciliation_summary.yaml +++ b/src/admin/paths/admin@statements@reconciliation_summary.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@suggest_mappings.yaml b/src/admin/paths/admin@statements@suggest_mappings.yaml index 9343af7e8..145589db5 100644 --- a/src/admin/paths/admin@statements@suggest_mappings.yaml +++ b/src/admin/paths/admin@statements@suggest_mappings.yaml @@ -31,6 +31,8 @@ post: application/json: schema: type: object + required: + - data properties: count: $ref: '../../components/schemas/count.yaml' diff --git a/src/admin/paths/admin@statements@summary.yaml b/src/admin/paths/admin@statements@summary.yaml index f0e6aca4c..6da4d23c5 100644 --- a/src/admin/paths/admin@statements@summary.yaml +++ b/src/admin/paths/admin@statements@summary.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@unassigned_cards.yaml b/src/admin/paths/admin@statements@unassigned_cards.yaml index 515510f52..18fc4f299 100644 --- a/src/admin/paths/admin@statements@unassigned_cards.yaml +++ b/src/admin/paths/admin@statements@unassigned_cards.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/admin/paths/admin@statements@upload.yaml b/src/admin/paths/admin@statements@upload.yaml index c14faeba1..704d3c069 100644 --- a/src/admin/paths/admin@statements@upload.yaml +++ b/src/admin/paths/admin@statements@upload.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/statements.yaml#/statements_out' diff --git a/src/admin/paths/admin@subscriptions.yaml b/src/admin/paths/admin@subscriptions.yaml index 8d0b401c7..dc8b04e6e 100644 --- a/src/admin/paths/admin@subscriptions.yaml +++ b/src/admin/paths/admin@subscriptions.yaml @@ -11,6 +11,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/admin_subscriptions_in' @@ -22,6 +24,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/admin_subscriptions_out' diff --git a/src/admin/paths/admin@tax_groups.yaml b/src/admin/paths/admin@tax_groups.yaml index 12179977b..f0551647f 100644 --- a/src/admin/paths/admin@tax_groups.yaml +++ b/src/admin/paths/admin@tax_groups.yaml @@ -65,6 +65,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/tax_group.yaml#/tax_group_out' diff --git a/src/admin/paths/admin@virtual_cards@delete.yaml b/src/admin/paths/admin@virtual_cards@delete.yaml index 065ae1e09..7ca783e98 100644 --- a/src/admin/paths/admin@virtual_cards@delete.yaml +++ b/src/admin/paths/admin@virtual_cards@delete.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_card_out' diff --git a/src/admin/paths/admin@virtual_cards@get_current_amount.yaml b/src/admin/paths/admin@virtual_cards@get_current_amount.yaml index b326a885c..4e422c72f 100644 --- a/src/admin/paths/admin@virtual_cards@get_current_amount.yaml +++ b/src/admin/paths/admin@virtual_cards@get_current_amount.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_get_current_balance_out' diff --git a/src/admin/paths/admin@virtual_cards@show_card_details.yaml b/src/admin/paths/admin@virtual_cards@show_card_details.yaml index e1b3bcc92..ac9d647f2 100644 --- a/src/admin/paths/admin@virtual_cards@show_card_details.yaml +++ b/src/admin/paths/admin@virtual_cards@show_card_details.yaml @@ -25,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_show_card_details_out' diff --git a/src/approver/paths/approver@advance_requests@add_approver.yaml b/src/approver/paths/approver@advance_requests@add_approver.yaml index 81c08199f..7685fd3e4 100644 --- a/src/approver/paths/approver@advance_requests@add_approver.yaml +++ b/src/approver/paths/approver@advance_requests@add_approver.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_add_approver_in' @@ -26,6 +28,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml b/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml index 14065e4b1..8da910c34 100644 --- a/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml +++ b/src/approver/paths/approver@advance_requests@bulk_attach_file.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@advance_requests@comments.yaml b/src/approver/paths/approver@advance_requests@comments.yaml index 81f9ea81d..2ce3237c2 100644 --- a/src/approver/paths/approver@advance_requests@comments.yaml +++ b/src/approver/paths/approver@advance_requests@comments.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_out' diff --git a/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml b/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml index 66b6174f8..3b633a735 100644 --- a/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml +++ b/src/approver/paths/approver@advance_requests@generate_file_urls@bulk.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@advance_requests@inquire.yaml b/src/approver/paths/approver@advance_requests@inquire.yaml index 806a56798..da8dd2440 100644 --- a/src/approver/paths/approver@advance_requests@inquire.yaml +++ b/src/approver/paths/approver@advance_requests@inquire.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@partially_approve.yaml b/src/approver/paths/approver@advance_requests@partially_approve.yaml index 0068c6c50..13bbc1386 100644 --- a/src/approver/paths/approver@advance_requests@partially_approve.yaml +++ b/src/approver/paths/approver@advance_requests@partially_approve.yaml @@ -26,6 +26,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@permissions.yaml b/src/approver/paths/approver@advance_requests@permissions.yaml index 744da3b9f..8f5d4031b 100644 --- a/src/approver/paths/approver@advance_requests@permissions.yaml +++ b/src/approver/paths/approver@advance_requests@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_permissions_out' diff --git a/src/approver/paths/approver@advance_requests@reject.yaml b/src/approver/paths/approver@advance_requests@reject.yaml index 0930de8e2..c2df92a74 100644 --- a/src/approver/paths/approver@advance_requests@reject.yaml +++ b/src/approver/paths/approver@advance_requests@reject.yaml @@ -29,6 +29,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@advance_requests@stats.yaml b/src/approver/paths/approver@advance_requests@stats.yaml index 9e16193ec..d778f6fac 100644 --- a/src/approver/paths/approver@advance_requests@stats.yaml +++ b/src/approver/paths/approver@advance_requests@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_requests_approver_stats_out' diff --git a/src/approver/paths/approver@advance_requests@submit.yaml b/src/approver/paths/approver@advance_requests@submit.yaml index f511c601e..287fae1b2 100644 --- a/src/approver/paths/approver@advance_requests@submit.yaml +++ b/src/approver/paths/approver@advance_requests@submit.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/approver/paths/approver@corporate_card_transactions@match.yaml b/src/approver/paths/approver@corporate_card_transactions@match.yaml index 4c60ece64..7cbe00818 100644 --- a/src/approver/paths/approver@corporate_card_transactions@match.yaml +++ b/src/approver/paths/approver@corporate_card_transactions@match.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_match_out' diff --git a/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml b/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml index 561fa70a1..01c7bdec8 100644 --- a/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml +++ b/src/approver/paths/approver@corporate_card_transactions@unmatch.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmatch_out' diff --git a/src/approver/paths/approver@employee_overview@expenses@stats.yaml b/src/approver/paths/approver@employee_overview@expenses@stats.yaml index b9f4a4e48..cee6c869e 100644 --- a/src/approver/paths/approver@employee_overview@expenses@stats.yaml +++ b/src/approver/paths/approver@employee_overview@expenses@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_expense_stats_out diff --git a/src/approver/paths/approver@employee_overview@stats.yaml b/src/approver/paths/approver@employee_overview@stats.yaml index b133e3fc7..441c9a55d 100644 --- a/src/approver/paths/approver@employee_overview@stats.yaml +++ b/src/approver/paths/approver@employee_overview@stats.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_stats_out diff --git a/src/approver/paths/approver@expenses.yaml b/src/approver/paths/approver@expenses.yaml index d9780a8ac..2537789d4 100644 --- a/src/approver/paths/approver@expenses.yaml +++ b/src/approver/paths/approver@expenses.yaml @@ -53,6 +53,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/approver_expense_in' @@ -63,6 +65,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/approver/paths/approver@expenses@attach_files@bulk.yaml b/src/approver/paths/approver@expenses@attach_files@bulk.yaml index 697d8e58d..10a43e46a 100644 --- a/src/approver/paths/approver@expenses@attach_files@bulk.yaml +++ b/src/approver/paths/approver@expenses@attach_files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@bulk.yaml b/src/approver/paths/approver@expenses@bulk.yaml index 1e777f6e0..d9f30d26d 100644 --- a/src/approver/paths/approver@expenses@bulk.yaml +++ b/src/approver/paths/approver@expenses@bulk.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/approver_expenses_bulk_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@check_policies_bulk.yaml b/src/approver/paths/approver@expenses@check_policies_bulk.yaml index 99296b6ba..9d66fc8ab 100644 --- a/src/approver/paths/approver@expenses@check_policies_bulk.yaml +++ b/src/approver/paths/approver@expenses@check_policies_bulk.yaml @@ -28,6 +28,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out diff --git a/src/approver/paths/approver@expenses@comments@bulk.yaml b/src/approver/paths/approver@expenses@comments@bulk.yaml index 2fb188a45..8ba2a5104 100644 --- a/src/approver/paths/approver@expenses@comments@bulk.yaml +++ b/src/approver/paths/approver@expenses@comments@bulk.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_comments_bulk_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@export_configurations.yaml b/src/approver/paths/approver@expenses@export_configurations.yaml index 96be32a0d..4d56b4cab 100644 --- a/src/approver/paths/approver@expenses@export_configurations.yaml +++ b/src/approver/paths/approver@expenses@export_configurations.yaml @@ -158,6 +158,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_export_configurations.yaml#/expenses_export_configuration_out' diff --git a/src/approver/paths/approver@expenses@exports.yaml b/src/approver/paths/approver@expenses@exports.yaml index 0736bd382..1e0d8906e 100644 --- a/src/approver/paths/approver@expenses@exports.yaml +++ b/src/approver/paths/approver@expenses@exports.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_exports.yaml#/expenses_exports_out' diff --git a/src/approver/paths/approver@expenses@filters.yaml b/src/approver/paths/approver@expenses@filters.yaml index 797810a62..38291520a 100644 --- a/src/approver/paths/approver@expenses@filters.yaml +++ b/src/approver/paths/approver@expenses@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/approver/paths/approver@expenses@filters@delete.yaml b/src/approver/paths/approver@expenses@filters@delete.yaml index 144f8b063..0acdb816f 100644 --- a/src/approver/paths/approver@expenses@filters@delete.yaml +++ b/src/approver/paths/approver@expenses@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/approver/paths/approver@expenses@permissions.yaml b/src/approver/paths/approver@expenses@permissions.yaml index 00ba5862c..e291a4a40 100644 --- a/src/approver/paths/approver@expenses@permissions.yaml +++ b/src/approver/paths/approver@expenses@permissions.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_out' diff --git a/src/approver/paths/approver@expenses@permissions@bulk.yaml b/src/approver/paths/approver@expenses@permissions@bulk.yaml index 2ffce10c5..938f1be3c 100644 --- a/src/approver/paths/approver@expenses@permissions@bulk.yaml +++ b/src/approver/paths/approver@expenses@permissions@bulk.yaml @@ -33,6 +33,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' diff --git a/src/approver/paths/approver@expenses@split.yaml b/src/approver/paths/approver@expenses@split.yaml index 6c18eb6ec..e8a734bc7 100644 --- a/src/approver/paths/approver@expenses@split.yaml +++ b/src/approver/paths/approver@expenses@split.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml b/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml index 9a9988de2..57c713302 100644 --- a/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml +++ b/src/approver/paths/approver@expenses@split@check_mandatory_fields.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@split@check_policies.yaml b/src/approver/paths/approver@expenses@split@check_policies.yaml index 402c93873..f75995482 100644 --- a/src/approver/paths/approver@expenses@split@check_policies.yaml +++ b/src/approver/paths/approver@expenses@split@check_policies.yaml @@ -14,6 +14,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/admin_split_expense_in' @@ -24,6 +26,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@expenses@stats.yaml b/src/approver/paths/approver@expenses@stats.yaml index ee129cee4..0bf898b7c 100644 --- a/src/approver/paths/approver@expenses@stats.yaml +++ b/src/approver/paths/approver@expenses@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_stats_out' diff --git a/src/approver/paths/approver@files@bulk.yaml b/src/approver/paths/approver@files@bulk.yaml index 11b97415d..942bbd084 100644 --- a/src/approver/paths/approver@files@bulk.yaml +++ b/src/approver/paths/approver@files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@files@generate_urls@bulk.yaml b/src/approver/paths/approver@files@generate_urls@bulk.yaml index a29425341..f28de9259 100644 --- a/src/approver/paths/approver@files@generate_urls@bulk.yaml +++ b/src/approver/paths/approver@files@generate_urls@bulk.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/approver/paths/approver@reports@add_approver.yaml b/src/approver/paths/approver@reports@add_approver.yaml index 2d728ead7..c2451a2f6 100644 --- a/src/approver/paths/approver@reports@add_approver.yaml +++ b/src/approver/paths/approver@reports@add_approver.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@add_expenses.yaml b/src/approver/paths/approver@reports@add_expenses.yaml index d78c9af28..3aca97649 100644 --- a/src/approver/paths/approver@reports@add_expenses.yaml +++ b/src/approver/paths/approver@reports@add_expenses.yaml @@ -26,6 +26,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@comments.yaml b/src/approver/paths/approver@reports@comments.yaml index 883b28497..7e3628021 100644 --- a/src/approver/paths/approver@reports@comments.yaml +++ b/src/approver/paths/approver@reports@comments.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_comments_out' diff --git a/src/approver/paths/approver@reports@eject_expenses.yaml b/src/approver/paths/approver@reports@eject_expenses.yaml index f948a3806..4e90d7e8b 100644 --- a/src/approver/paths/approver@reports@eject_expenses.yaml +++ b/src/approver/paths/approver@reports@eject_expenses.yaml @@ -26,6 +26,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@export_configurations.yaml b/src/approver/paths/approver@reports@export_configurations.yaml index d0c89edbc..0eaf70cac 100644 --- a/src/approver/paths/approver@reports@export_configurations.yaml +++ b/src/approver/paths/approver@reports@export_configurations.yaml @@ -83,6 +83,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_export_configurations.yaml#/reports_export_configuration_out' diff --git a/src/approver/paths/approver@reports@exports.yaml b/src/approver/paths/approver@reports@exports.yaml index 683440fb1..248ff4d59 100644 --- a/src/approver/paths/approver@reports@exports.yaml +++ b/src/approver/paths/approver@reports@exports.yaml @@ -63,6 +63,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_exports.yaml#/reports_exports_out' diff --git a/src/approver/paths/approver@reports@filters.yaml b/src/approver/paths/approver@reports@filters.yaml index 6ae983d65..3793210ec 100644 --- a/src/approver/paths/approver@reports@filters.yaml +++ b/src/approver/paths/approver@reports@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/approver/paths/approver@reports@filters@delete.yaml b/src/approver/paths/approver@reports@filters@delete.yaml index 50d56712a..63bceca83 100644 --- a/src/approver/paths/approver@reports@filters@delete.yaml +++ b/src/approver/paths/approver@reports@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/approver/paths/approver@reports@partially_approve.yaml b/src/approver/paths/approver@reports@partially_approve.yaml index d4992f6b4..63e0f396e 100644 --- a/src/approver/paths/approver@reports@partially_approve.yaml +++ b/src/approver/paths/approver@reports@partially_approve.yaml @@ -26,6 +26,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@permissions.yaml b/src/approver/paths/approver@reports@permissions.yaml index 00c0674d9..71ca3ad25 100644 --- a/src/approver/paths/approver@reports@permissions.yaml +++ b/src/approver/paths/approver@reports@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report_permissions.yaml#/report_permissions_out' diff --git a/src/approver/paths/approver@reports@round_off_amount.yaml b/src/approver/paths/approver@reports@round_off_amount.yaml index 97134cb22..67b43e94c 100644 --- a/src/approver/paths/approver@reports@round_off_amount.yaml +++ b/src/approver/paths/approver@reports@round_off_amount.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@send_back.yaml b/src/approver/paths/approver@reports@send_back.yaml index 097602105..8502b3c9b 100644 --- a/src/approver/paths/approver@reports@send_back.yaml +++ b/src/approver/paths/approver@reports@send_back.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/approver/paths/approver@reports@stats.yaml b/src/approver/paths/approver@reports@stats.yaml index bd00c4e13..029c82d13 100644 --- a/src/approver/paths/approver@reports@stats.yaml +++ b/src/approver/paths/approver@reports@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/reports_stats_out' diff --git a/src/approver/paths/approver@subscriptions.yaml b/src/approver/paths/approver@subscriptions.yaml index f272d4b96..1cece38ec 100644 --- a/src/approver/paths/approver@subscriptions.yaml +++ b/src/approver/paths/approver@subscriptions.yaml @@ -11,6 +11,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/subscriptions_in' @@ -22,6 +24,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/approver_subscriptions_out' diff --git a/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml b/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml index ef3d14d3d..476aea906 100644 --- a/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml +++ b/src/common/paths/common@org_settings@org_logo_settings@generate_download_url.yaml @@ -12,6 +12,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: ../../components/schemas/org_settings.yaml#/logo_file_generate_download_url_action_out diff --git a/src/components/schemas/account.yaml b/src/components/schemas/account.yaml index 8673451d1..82b9bf642 100644 --- a/src/components/schemas/account.yaml +++ b/src/components/schemas/account.yaml @@ -1,6 +1,17 @@ account_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - user_id + - type + - currency + - current_balance_amount + - tentative_balance_amount + - org_id + - category_id properties: id: allOf: @@ -45,6 +56,9 @@ account_out: account_out_embed: type: object + required: + - id + - type properties: id: allOf: @@ -63,6 +77,11 @@ account_out_embed: account_snapshot_out_embed: type: object + required: + - account_id + - type + - currency + - balance properties: account_id: allOf: @@ -87,6 +106,10 @@ account_snapshot_out_embed: account_in: type: object additionalProperties: false + required: + - user_id + - type + - currency properties: user_id: type: string diff --git a/src/components/schemas/advance.yaml b/src/components/schemas/advance.yaml index 0aaf5fc55..0daadea92 100644 --- a/src/components/schemas/advance.yaml +++ b/src/components/schemas/advance.yaml @@ -141,6 +141,12 @@ advance_out: advance_out_embed: type: object nullable: true + required: + - id + - currency + - amount + - advance_request_id + - seq_num properties: id: type: string @@ -246,6 +252,8 @@ advance_in: $ref: './fields.yaml#/custom_fields' advances_stats_in: + required: + - query_params properties: query_params: type: string @@ -256,6 +264,9 @@ advances_stats_in: advances_stats_out: type: object + required: + - count + - total_amount properties: count: type: integer diff --git a/src/components/schemas/advance_refund.yaml b/src/components/schemas/advance_refund.yaml index 5c533ba75..849939512 100644 --- a/src/components/schemas/advance_refund.yaml +++ b/src/components/schemas/advance_refund.yaml @@ -153,6 +153,8 @@ advance_refund_in: example: 'awfgRr8YA6KK' advance_refunds_stats_in: + required: + - query_params properties: query_params: type: string @@ -163,6 +165,9 @@ advance_refunds_stats_in: advance_refunds_stats_out: type: object + required: + - count + - total_amount properties: count: type: integer diff --git a/src/components/schemas/advance_request.yaml b/src/components/schemas/advance_request.yaml index 5ca278569..42f246f1c 100644 --- a/src/components/schemas/advance_request.yaml +++ b/src/components/schemas/advance_request.yaml @@ -127,7 +127,7 @@ advance_request_out: comments: type: array items: - $ref: '#/advance_request_comments_out' + $ref: '#/advance_request_comments_out_embed' description: | List of comments in the advance request file_ids: @@ -216,6 +216,8 @@ advance_request_action_in: example: 'rpa21A2rdj2' advance_requests_stats_in: + required: + - query_params properties: query_params: description: | @@ -305,6 +307,10 @@ advance_requests_stats_out: advance_request_out_embed: type: object nullable: true + required: + - id + - last_approved_at + - seq_num properties: id: type: string @@ -403,9 +409,52 @@ advance_request_comments_in: description: Comment text to be added to the advance request example: test +advance_request_comments_out_embed: + type: object + additionalProperties: false + required: + - id + - comment + - creator_type + - creator_user_id + - creator_user + - created_at + properties: + id: + $ref: './fields.yaml#/id_string' + comment: + type: string + description: A comment on the advance request + example: Advance request was created + creator_type: + type: string + description: Describes whether the comment is system-generated or User made. + enum: + - SYSTEM + - POLICY + - USER + example: USER + creator_user_id: + $ref: './fields.yaml#/user_id_nullable' + creator_user: + $ref: './user.yaml#/user_out_embed_nullable' + created_at: + $ref: './fields.yaml#/created_at' + advance_request_comments_out: type: object additionalProperties: false + required: + - id + - comment + - action + - advance_request_id + - creator_type + - creator_user_id + - creator_user + - created_at + - updated_at + - org_id properties: id: $ref: './fields.yaml#/id_string' @@ -470,6 +519,18 @@ advance_request_permissions_in: advance_request_permissions_out: type: object additionalProperties: false + required: + - can_save + - can_submit + - can_edit + - can_add_approver + - can_disable_approver + - can_reject + - can_approve + - can_inquire + - can_pull_back + - can_pay + - can_delete properties: can_save: type: boolean @@ -533,6 +594,7 @@ advance_request_action_pull_back_in: description: | Comment explaining the reason for pulling back the advance request example: 'sending back' + nullable: true advance_request_delete_in: type: object diff --git a/src/components/schemas/advance_request_approval.yaml b/src/components/schemas/advance_request_approval.yaml index d4e5b3d1c..d773cf1ea 100644 --- a/src/components/schemas/advance_request_approval.yaml +++ b/src/components/schemas/advance_request_approval.yaml @@ -1,6 +1,10 @@ advance_request_approval_out_embed: type: object additionalProperties: False + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: diff --git a/src/components/schemas/advance_wallet.yaml b/src/components/schemas/advance_wallet.yaml index 72da46164..30ed9452d 100644 --- a/src/components/schemas/advance_wallet.yaml +++ b/src/components/schemas/advance_wallet.yaml @@ -41,6 +41,9 @@ advance_wallet_in: advance_wallet_report_out: type: object additionalProperties: false + required: + - id + - amount properties: id: allOf: diff --git a/src/components/schemas/budget.yaml b/src/components/schemas/budget.yaml index 71199ca3d..3e6eb59c8 100644 --- a/src/components/schemas/budget.yaml +++ b/src/components/schemas/budget.yaml @@ -6,7 +6,6 @@ budget_in: - type - observer_ids - amount_limit - - fiscal_year_start_month - department_ids - project_ids - cost_center_ids @@ -65,12 +64,6 @@ budget_in: $ref: './fields.yaml#/id_string' example: - usge49ielgel - fiscal_year_start_month: - type: number - example: 10 - description: Month number of start of fisical year - minimum: 1 - maximum: 12 visibility: $ref: ./fields.yaml#/budget_visibility user_ids: @@ -240,12 +233,6 @@ budget_out: $ref: './fields.yaml#/id_string' example: - usge49ielgel - fiscal_year_start_month: - type: number - example: 10 - description: Month number of start of fiscal year - minimum: 1 - maximum: 12 budget_start_date: type: string nullable: true @@ -302,6 +289,12 @@ budget_out: budget_out_embed: type: object additionalProperties: False + required: + - id + - name + - type + - amount_limit + - is_enabled properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/budget_exports.yaml b/src/components/schemas/budget_exports.yaml index d00f343c9..4e2f0cca2 100644 --- a/src/components/schemas/budget_exports.yaml +++ b/src/components/schemas/budget_exports.yaml @@ -16,6 +16,15 @@ budget_exports_in: budget_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - file_id + - state properties: created_at: $ref: './fields.yaml#/created_at' diff --git a/src/components/schemas/category.yaml b/src/components/schemas/category.yaml index e82a28f13..9fa66ad8c 100644 --- a/src/components/schemas/category.yaml +++ b/src/components/schemas/category.yaml @@ -65,6 +65,13 @@ category_out_embed: type: object nullable: true additionalProperties: False + required: + - id + - system_category + - name + - sub_category + - code + - display_name properties: id: $ref: './fields.yaml#/id_integer' @@ -236,10 +243,15 @@ admin_approver_category_out: category_delete_summary_out: type: object + required: + - data additionalProperties: False properties: data: type: object + required: + - delete_count + - categories properties: delete_count: type: integer diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index ad233810a..17f7754b1 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -200,7 +200,6 @@ corporate_card_out: - virtual_card_id - virtual_card_state - nickname - - is_archived - archived_at - archived_by_user_id - total_transactions_count @@ -492,7 +491,6 @@ corporate_card_unassign_out: - virtual_card_id - virtual_card_state - nickname - - is_archived - archived_at - archived_by_user_id - total_transactions_count @@ -500,6 +498,15 @@ corporate_card_unassign_out: corporate_card_out_embed: type: object additionalProperties: false + required: + - id + - bank_name + - card_number + - nickname + - cardholder_name + - masked_number + - user_full_name + - user_email properties: id: allOf: @@ -559,6 +566,16 @@ corporate_card_out_embed: duplicate_suggestion_corporate_card_out_embed: type: object additionalProperties: false + required: + - id + - bank_name + - card_number + - nickname + - total_transactions_count + - is_visa_enrolled + - is_mastercard_enrolled + - data_feed_source + - feed_display_name properties: id: allOf: @@ -612,6 +629,8 @@ duplicate_suggestion_corporate_card_out_embed: corporate_card_stats_in: + required: + - query_params properties: query_params: nullable: False @@ -622,6 +641,9 @@ corporate_card_stats_in: corporate_card_stats_out: type: object + required: + - count + - transactions_count properties: count: type: integer @@ -732,8 +754,7 @@ yodlee_accounts_out: - yodlee_fastlink_params - created_at - updated_at - - + - corporate_card_id corporate_card_merge_in: type: object properties: diff --git a/src/components/schemas/corporate_card_transaction.yaml b/src/components/schemas/corporate_card_transaction.yaml index 9146aaa5d..c0144790a 100644 --- a/src/components/schemas/corporate_card_transaction.yaml +++ b/src/components/schemas/corporate_card_transaction.yaml @@ -603,6 +603,7 @@ corporate_card_transaction_post_out: - is_exported - metadata + - mcc corporate_card_transaction_assign_in: type: object properties: @@ -830,6 +831,7 @@ corporate_card_transaction_assign_out: - last_user_matched_at - metadata + - mcc corporate_card_transaction_unassign_out: type: object properties: @@ -1046,6 +1048,8 @@ corporate_card_transaction_unassign_out: - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_match_in: type: object properties: @@ -1279,6 +1283,9 @@ corporate_card_transaction_match_out: - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_unmatch_in: type: object properties: @@ -1524,6 +1531,11 @@ corporate_card_transaction_unmatch_out: - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number + - is_exported corporate_card_transaction_id_in: type: object properties: @@ -1742,6 +1754,8 @@ corporate_card_transaction_mark_personal_out: - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_unmark_personal_out: type: object properties: @@ -1951,6 +1965,8 @@ corporate_card_transaction_unmark_personal_out: - last_user_matched_at - metadata + - mcc + - is_exported corporate_card_transaction_ignore_out: type: object properties: @@ -2166,6 +2182,9 @@ corporate_card_transaction_ignore_out: - last_user_matched_at - metadata + - capitalone_virtual_card_last_four + - mcc + - is_exported corporate_card_transaction_undo_ignore_out: type: object additionalProperties: false @@ -2396,7 +2415,14 @@ corporate_card_transaction_undo_ignore_out: - last_user_matched_at - metadata + - transaction_status + - capitalone_virtual_card_last_four + - mcc + - bank_transaction_number corporate_card_transactions_stats_in: + type: object + required: + - query_params properties: query_params: nullable: false @@ -2407,6 +2433,10 @@ corporate_card_transactions_stats_in: corporate_card_transactions_stats_out: type: object + required: + - count + - debit_amount + - credit_amount properties: count: type: integer @@ -2439,6 +2469,9 @@ corporate_card_transactions_delete_summary_in: corporate_card_transactions_delete_summary_out: type: object + required: + - delete_count + - delete_amount properties: delete_count: type: integer @@ -2481,6 +2514,8 @@ corporate_card_transaction_reassign_in: corporate_card_transactions_expenses_stats_in: type: object + required: + - query_params properties: query_params: type: string diff --git a/src/components/schemas/corporate_card_transactions_exports.yaml b/src/components/schemas/corporate_card_transactions_exports.yaml index 8bdb03fb5..430b52a24 100644 --- a/src/components/schemas/corporate_card_transactions_exports.yaml +++ b/src/components/schemas/corporate_card_transactions_exports.yaml @@ -126,6 +126,20 @@ corporate_card_transactions_exports_in: corporate_card_transactions_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state + - processed_at + - completed_at + - failed_at properties: created_at: $ref: './fields.yaml#/created_at' diff --git a/src/components/schemas/corporate_credit_card_expense.yaml b/src/components/schemas/corporate_credit_card_expense.yaml index fe5669f3b..d1d152ea3 100644 --- a/src/components/schemas/corporate_credit_card_expense.yaml +++ b/src/components/schemas/corporate_credit_card_expense.yaml @@ -1,5 +1,9 @@ corporate_credit_card_expense_out_embed: type: object + required: + - id + - currency + - amount properties: id: type: string diff --git a/src/components/schemas/cost_center.yaml b/src/components/schemas/cost_center.yaml index b77017725..bf9086733 100644 --- a/src/components/schemas/cost_center.yaml +++ b/src/components/schemas/cost_center.yaml @@ -36,6 +36,10 @@ cost_center_out_embed: type: object nullable: true additionalProperties: False + required: + - id + - name + - code properties: id: $ref: './fields.yaml#/id_integer' @@ -190,6 +194,8 @@ cost_center_in_only_id: cost_center_delete_summary_out: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/components/schemas/currency.yaml b/src/components/schemas/currency.yaml index 365cba351..748254464 100644 --- a/src/components/schemas/currency.yaml +++ b/src/components/schemas/currency.yaml @@ -1,5 +1,7 @@ exchange_rate_out: type: object + required: + - exchange_rate additionalProperties: false properties: exchange_rate: diff --git a/src/components/schemas/department.yaml b/src/components/schemas/department.yaml index 976a4bb0a..186d566ee 100644 --- a/src/components/schemas/department.yaml +++ b/src/components/schemas/department.yaml @@ -66,6 +66,12 @@ department_out_embed: type: object additionalProperties: False nullable: true + required: + - id + - code + - name + - sub_department + - display_name properties: id: $ref: './fields.yaml#/id_string' @@ -92,6 +98,11 @@ department_out_employee_embed: type: object additionalProperties: False nullable: true + required: + - id + - code + - name + - sub_department properties: id: $ref: './fields.yaml#/id_string' @@ -152,6 +163,8 @@ department_in_only_id: department_delete_summary_out: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/components/schemas/dependent_expense_field_values.yaml b/src/components/schemas/dependent_expense_field_values.yaml index 3aa27fef8..7e9a8ff5c 100644 --- a/src/components/schemas/dependent_expense_field_values.yaml +++ b/src/components/schemas/dependent_expense_field_values.yaml @@ -1,6 +1,16 @@ dependent_expense_field_values_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - parent_expense_field_value + - expense_field_value + - is_enabled properties: id: $ref: './fields.yaml#/id_integer' @@ -76,6 +86,16 @@ dependent_expense_field_values_in: dependent_expense_field_values_upload_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - file_id + - error_file_id + - state properties: id: $ref: './fields.yaml#/id_integer' @@ -144,6 +164,12 @@ dependent_expense_field_values_upload_in: dependent_expense_field_values_preview_out: type: object additionalProperties: false + required: + - org_id + - parent_expense_field_id + - expense_field_id + - parent_expense_field_value + - expense_field_values properties: org_id: $ref: ./fields.yaml#/org_id @@ -179,6 +205,15 @@ dependent_expense_field_values_preview_out: dependent_expense_field_values_download_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - parent_expense_field_id + - expense_field_id + - file_id + - state properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index ff2a7e622..b2ce276b1 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -274,6 +274,14 @@ employee_out: employee_out_embed: type: object additionalProperties: False + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department properties: id: $ref: ./fields.yaml#/id_string @@ -325,6 +333,7 @@ employee_out_potential_duplicate_expenses: - user_id - email - full_name + - potential_duplicate_expenses properties: user_id: $ref: './fields.yaml#/user_id' @@ -345,6 +354,19 @@ employee_out_embed_for_expense: type: object additionalProperties: False nullable: True + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department + - location + - title + - business_unit + - custom_fields + - flattened_custom_field properties: id: $ref: ./fields.yaml#/id_string @@ -424,6 +446,23 @@ employee_out_embed_for_expense_with_department_name: type: object additionalProperties: False nullable: True + required: + - id + - user_id + - user + - code + - org_id + - org_name + - department_id + - department + - level + - location + - title + - business_unit + - custom_fields + - flattened_custom_field + - has_accepted_invite + - is_enabled properties: id: $ref: ./fields.yaml#/id_string @@ -502,6 +541,18 @@ employee_out_embed_for_expense_with_department_name: employee_out_embed_for_report: type: object additionalProperties: False + required: + - id + - user_id + - user + - code + - org_id + - department_id + - department + - ach_account + - business_unit + - location + - title properties: id: $ref: ./fields.yaml#/id_string @@ -675,6 +726,19 @@ employee_in: spender_employee_out: type: object additionalProperties: False + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: './fields.yaml#/id_string' @@ -828,6 +892,19 @@ employees_download_out: spender_commute_details_out: type: object additionalProperties: False + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: './fields.yaml#/id_string' @@ -886,6 +963,10 @@ spender_commute_details_out: spender_delegators_out: type: object additionalProperties: False + required: + - user_id + - email + - full_name properties: user_id: $ref: './fields.yaml#/user_id' @@ -901,6 +982,13 @@ spender_delegators_out: spender_delegatees_delete_out: type: object additionalProperties: False + required: + - id + - org_id + - delegator_user_id + - delegatee_user_id + - start_date + - end_date properties: id: $ref: './fields.yaml#/id_integer' @@ -927,6 +1015,10 @@ spender_delegatees_delete_out: spender_delegatees_post_in: type: object additionalProperties: False + required: + - delegatee_user_id + - start_at + - end_at properties: delegatee_user_id: $ref: ./fields.yaml#/fk_string @@ -950,6 +1042,19 @@ spender_delegatees_post_in: spender_delegatees_post_out: type: object additionalProperties: False + required: + - id + - user_id + - email + - full_name + - roles + - commute_details + - mobile + - is_mobile_verified + - sms_opt_out_source + - is_enabled + - has_accepted_invite + - delegatees properties: id: $ref: './fields.yaml#/id_string' @@ -1088,6 +1193,12 @@ employee_change_owner_in: employees_send_mobile_verification_code_post_out: type: object + required: + - to + - channel + - status + - date_created + - attempts_left additionalProperties: False properties: to: @@ -1105,11 +1216,6 @@ employees_send_mobile_verification_code_post_out: description: | Current status of the verification attempt example: "pending" - valid: - type: boolean - description: | - Whether the verification is valid - example: false date_created: type: string format: date-time @@ -1463,6 +1569,9 @@ employee_overview_out: employee_overview_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer @@ -1476,6 +1585,9 @@ employee_overview_stats_out: employee_overview_expense_stats_out: type: object additionalProperties: false + required: + - count + - total_amount properties: count: type: integer diff --git a/src/components/schemas/employee_account_summary.yaml b/src/components/schemas/employee_account_summary.yaml index a6dfee00f..c994c450a 100644 --- a/src/components/schemas/employee_account_summary.yaml +++ b/src/components/schemas/employee_account_summary.yaml @@ -1,5 +1,23 @@ employee_account_summary_out: type: object + required: + - id + - created_at + - updated_at + - org_id + - org_currency + - user_email + - user_full_name + - cash_account_id + - cash_account + - cash_account_balance + - ccc_account_id + - ccc_account + - ccc_account_balance + - advance_account_ids + - advance_accounts + - advance_accounts_balance + - is_settleable properties: id: diff --git a/src/components/schemas/employee_settings.yaml b/src/components/schemas/employee_settings.yaml index 1902e4b44..faa5ac749 100644 --- a/src/components/schemas/employee_settings.yaml +++ b/src/components/schemas/employee_settings.yaml @@ -1,6 +1,29 @@ spender_employee_settings_out: type: object additionalProperties: false + required: + - id + - employee_id + - org_id + - created_at + - updated_at + - category_ids + - cost_center_ids + - project_ids + - per_diem_rate_ids + - mileage_rate_ids + - insta_fyle_settings + - notification_settings + - mileage_settings + - expense_form_autofills + - data_extractor_settings + - in_app_chat_settings + - payment_mode_settings + - locale + - is_personal_cards_enabled + - default_project_id + - default_payment_mode + - default_vehicle_type properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/employees_export_configurations.yaml b/src/components/schemas/employees_export_configurations.yaml index cbf4e6bd3..f8339ec77 100644 --- a/src/components/schemas/employees_export_configurations.yaml +++ b/src/components/schemas/employees_export_configurations.yaml @@ -218,16 +218,6 @@ employees_export_configuration_out: $ref: './fields.yaml#/created_at' updated_at: $ref: './fields.yaml#/updated_at' - created_by: - allOf: - - $ref: './user.yaml#/user_out_embed_nullable' - description: | - User who created this export configuration. - updated_by: - allOf: - - $ref: './user.yaml#/user_out_embed_nullable' - description: | - User who last updated this export configuration. name: type: string description: | diff --git a/src/components/schemas/employees_exports.yaml b/src/components/schemas/employees_exports.yaml index a5327c6cb..b348fad55 100644 --- a/src/components/schemas/employees_exports.yaml +++ b/src/components/schemas/employees_exports.yaml @@ -123,6 +123,20 @@ employees_exports_in: employees_exports_out: type: object + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state + - processed_at + - completed_at + - failed_at properties: created_at: type: string diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 32bd291b3..60558e1b6 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -83,6 +83,26 @@ expense_out: - invoice_number - is_duplicate_present - expense_policy_comments + - custom_fields_flattened + - approvals + - verifications + - employee_id + - split_group_amount + - expense_rule_id + - expense_rule_data + - is_split + - tax_group + - approver_comments + - verifier_comments + - policy_checks + - accounting_export_summary + - report_last_paid_at + - report_last_approved_at + - commute_deduction + - commute_details_id + - commute_details + - is_reconciled + - report_auto_approval_state properties: id: allOf: @@ -1573,6 +1593,21 @@ matched_corporate_card_transaction_out_embed: - id - corporate_card_id - corporate_card_number + - corporate_card_nickname + - masked_corporate_card_number + - bank_name + - corporate_card_user_full_name + - amount + - currency + - spent_at + - posted_at + - status + - description + - foreign_currency + - foreign_amount + - merchant + - category + - matched_by properties: id: allOf: @@ -2030,6 +2065,9 @@ expense_check_policies_in: expense_check_policies_out: type: object additionalProperties: False + required: + - individual_desired_states + - final_desired_state properties: individual_desired_states: type: array @@ -2065,6 +2103,8 @@ expense_delete_in: expenses_stats_in: + required: + - query_params properties: query_params: nullable: False @@ -2512,6 +2552,9 @@ expense_duplicate_sets_out: expense_verification_out_embed: type: object additionalProperties: false + required: + - verifier_user_id + - verifier_user properties: verifier_user_id: allOf: diff --git a/src/components/schemas/expense_duplicate_set.yaml b/src/components/schemas/expense_duplicate_set.yaml index 65307d2e1..391fa97bc 100644 --- a/src/components/schemas/expense_duplicate_set.yaml +++ b/src/components/schemas/expense_duplicate_set.yaml @@ -1,4 +1,7 @@ expenses_duplicate_sets_stats_in: + type: object + required: + - query_params properties: query_params: nullable: False @@ -10,6 +13,8 @@ expenses_duplicate_sets_stats_in: expenses_duplicate_sets_stats_out: type: object + required: + - count properties: count: type: integer diff --git a/src/components/schemas/expense_field.yaml b/src/components/schemas/expense_field.yaml index 84540117e..de2034c68 100644 --- a/src/components/schemas/expense_field.yaml +++ b/src/components/schemas/expense_field.yaml @@ -1,6 +1,25 @@ expense_field_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - seq + - field_name + - column_name + - type + - options + - default_value + - placeholder + - category_ids + - is_enabled + - is_custom + - is_mandatory + - code + - parent_field_id + - display_order properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/expense_policies.yaml b/src/components/schemas/expense_policies.yaml index df806737b..8f1415fa8 100644 --- a/src/components/schemas/expense_policies.yaml +++ b/src/components/schemas/expense_policies.yaml @@ -533,6 +533,9 @@ expense_policy_out: - action_add_department_head_approver - action_add_approver_user_ids - action_override_distance_slab_rate + - expense_merchants + - expense_merchants_op + - policy_violation_reason_required properties: id: allOf: diff --git a/src/components/schemas/expense_rules.yaml b/src/components/schemas/expense_rules.yaml index ebc4fa6e2..6897cec28 100644 --- a/src/components/schemas/expense_rules.yaml +++ b/src/components/schemas/expense_rules.yaml @@ -26,6 +26,8 @@ expense_rule_if_out: additionalProperties: false required: - merchant_contains + - department_ids + - departments properties: merchant_contains: type: string @@ -100,6 +102,18 @@ expense_rule_data_out: nullable: false additionalProperties: false minProperties: 1 + required: + - merchant + - is_billable + - purpose + - category_id + - category + - project_id + - project + - cost_center_id + - cost_center + - custom_fields + - dependent_fields properties: merchant: type: string @@ -181,6 +195,8 @@ expense_rule_out: - creator_user - if - set + - is_suggested + - is_suggestion_dismissed properties: id: allOf: diff --git a/src/components/schemas/expenses_export_configurations.yaml b/src/components/schemas/expenses_export_configurations.yaml index 2a5912f49..d5793430c 100644 --- a/src/components/schemas/expenses_export_configurations.yaml +++ b/src/components/schemas/expenses_export_configurations.yaml @@ -271,16 +271,6 @@ expenses_export_configuration_out: $ref: './fields.yaml#/created_at' updated_at: $ref: './fields.yaml#/updated_at' - created_by: - allOf: - - $ref: './user.yaml#/user_out_embed_nullable' - description: | - User who created this export configuration. - updated_by: - allOf: - - $ref: './user.yaml#/user_out_embed_nullable' - description: | - User who last updated this export configuration. name: type: string description: | diff --git a/src/components/schemas/expenses_exports.yaml b/src/components/schemas/expenses_exports.yaml index 58ddd91e7..de5d94e8f 100644 --- a/src/components/schemas/expenses_exports.yaml +++ b/src/components/schemas/expenses_exports.yaml @@ -116,6 +116,17 @@ expenses_exports_in: expenses_exports_out: type: object additionalProperties: false + required: + - created_at + - updated_at + - id + - org_id + - user_id + - query_params + - notify_emails + - config + - file_id + - state properties: created_at: $ref: './fields.yaml#/created_at' diff --git a/src/components/schemas/feature_configs.yaml b/src/components/schemas/feature_configs.yaml index e8c954a00..2bb85dcca 100644 --- a/src/components/schemas/feature_configs.yaml +++ b/src/components/schemas/feature_configs.yaml @@ -1,6 +1,17 @@ feature_config_out: type: object additionalProperties: false + required: + - org_id + - user_id + - created_at + - updated_at + - target_client + - feature + - sub_feature + - key + - value + - is_shared properties: org_id: $ref: ./fields.yaml#/org_id diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index 246ff043c..85e8fa24a 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1876,6 +1876,12 @@ commute_location: commute_details: type: object + required: + - id + - distance + - distance_unit + - home_location + - work_location nullable: true description: | Commute details of the employee. This is used to deduct daily commute from the employee's mileage expenses. diff --git a/src/components/schemas/file.yaml b/src/components/schemas/file.yaml index ebcb48815..54e666f06 100644 --- a/src/components/schemas/file.yaml +++ b/src/components/schemas/file.yaml @@ -1,6 +1,17 @@ file_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - created_at + - updated_at + - name + - type + - content_type + - download_url + - upload_url properties: id: $ref: './fields.yaml#/id_string' @@ -53,6 +64,12 @@ file_generate_urls_action_in: file_generate_urls_action_out: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url + - upload_url properties: id: $ref: './fields.yaml#/id_string' @@ -78,6 +95,11 @@ file_generate_urls_action_out: file_out_embed: type: object + required: + - id + - name + - type + - content_type properties: id: allOf: @@ -164,6 +186,11 @@ file_delete_action_in: file_out_download_url: type: object additionalProperties: false + required: + - id + - name + - content_type + - download_url properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/level.yaml b/src/components/schemas/level.yaml index 0c038bbf7..4d38ba007 100644 --- a/src/components/schemas/level.yaml +++ b/src/components/schemas/level.yaml @@ -112,6 +112,8 @@ level_in_only_id: level_delete_summary_out: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/components/schemas/merchant.yaml b/src/components/schemas/merchant.yaml index ba4ba3e48..dd90ece22 100644 --- a/src/components/schemas/merchant.yaml +++ b/src/components/schemas/merchant.yaml @@ -1,6 +1,11 @@ merchant_out: type: object additionalProperties: false + required: + - id + - created_at + - updated_at + - display_name properties: id: $ref: './fields.yaml#/id_integer' @@ -17,6 +22,12 @@ merchant_out: approver_merchant_out: type: object additionalProperties: false + required: + - id + - org_id + - created_at + - updated_at + - display_name properties: id: $ref: './fields.yaml#/id_integer' diff --git a/src/components/schemas/mileage_rate.yaml b/src/components/schemas/mileage_rate.yaml index 207d9c4b2..d101d68f3 100644 --- a/src/components/schemas/mileage_rate.yaml +++ b/src/components/schemas/mileage_rate.yaml @@ -118,6 +118,10 @@ mileage_rate_out_embed: type: object nullable: true additionalProperties: False + required: + - id + - vehicle_type + - code properties: id: $ref: './fields.yaml#/id_integer' @@ -131,6 +135,11 @@ mileage_rate_out_embed_for_expense: type: object nullable: true additionalProperties: False + required: + - id + - vehicle_type + - code + - rate properties: id: $ref: './fields.yaml#/id_integer' @@ -254,10 +263,15 @@ mileage_rate_in_only_id: mileage_rate_delete_summary_out: type: object + required: + - data additionalProperties: False properties: data: type: object + required: + - delete_count + - mileage_rates properties: delete_count: type: integer diff --git a/src/components/schemas/mobile_app_version.yaml b/src/components/schemas/mobile_app_version.yaml index e4960648a..41e2a6511 100644 --- a/src/components/schemas/mobile_app_version.yaml +++ b/src/components/schemas/mobile_app_version.yaml @@ -1,6 +1,13 @@ mobile_app_version_out: type: object additionalProperties: false + required: + - id + - user_id + - version + - os + - created_at + - updated_at properties: id: type: string diff --git a/src/components/schemas/my_profile.yaml b/src/components/schemas/my_profile.yaml index 79d292e1e..a5880739a 100644 --- a/src/components/schemas/my_profile.yaml +++ b/src/components/schemas/my_profile.yaml @@ -1,6 +1,12 @@ my_profile_out: type: object additionalProperties: false + required: + - user_id + - org_id + - org + - user + - roles properties: user_id: $ref: '../../components/schemas/fields.yaml#/user_id' diff --git a/src/components/schemas/org.yaml b/src/components/schemas/org.yaml index 0e37dc648..aabc8bcff 100644 --- a/src/components/schemas/org.yaml +++ b/src/components/schemas/org.yaml @@ -5,6 +5,7 @@ org_weekly_invitation_usage_out: - id - invitation_sent - is_limit_reached + - weekly_limit properties: id: $ref: './fields.yaml#/org_id' @@ -30,6 +31,11 @@ org_weekly_invitation_usage_out: org_out_embed: type: object additionalProperties: False + required: + - id + - name + - domain + - currency properties: id: $ref: './fields.yaml#/org_id' @@ -55,6 +61,8 @@ org_out: - currency - created_at - updated_at + - is_current + - is_primary properties: id: $ref: './fields.yaml#/org_id' @@ -174,6 +182,15 @@ org_reset_delete_in: get_spender_orgs_out: type: object additionalProperties: False + required: + - id + - name + - domain + - currency + - created_at + - updated_at + - is_current + - is_primary properties: id: $ref: './fields.yaml#/org_id' @@ -202,6 +219,12 @@ get_spender_orgs_out: org_bank_details_out: type: object additionalProperties: false + required: + - org_id + - bank_account_number + - bank_branch_ifsc + - dwolla_customers_metadata_id + - is_bank_account_added properties: org_id: $ref: './fields.yaml#/org_id' @@ -230,6 +253,9 @@ org_bank_details_out: spender_org_bank_details_out: type: object additionalProperties: false + required: + - org_id + - is_bank_account_added properties: org_id: $ref: './fields.yaml#/org_id' diff --git a/src/components/schemas/org_settings.yaml b/src/components/schemas/org_settings.yaml index f1f8cfa54..8af0054f7 100644 --- a/src/components/schemas/org_settings.yaml +++ b/src/components/schemas/org_settings.yaml @@ -1,5 +1,10 @@ logo_file_generate_download_url_action_out: type: object + required: + - id + - name + - content_type + - download_url additionalProperties: false properties: id: diff --git a/src/components/schemas/per_diem_rate.yaml b/src/components/schemas/per_diem_rate.yaml index 43d01f8ed..01f4b54c1 100644 --- a/src/components/schemas/per_diem_rate.yaml +++ b/src/components/schemas/per_diem_rate.yaml @@ -46,6 +46,10 @@ per_diem_rate_out_embed: type: object nullable: true additionalProperties: False + required: + - id + - name + - code properties: id: $ref: './fields.yaml#/id_integer' @@ -98,6 +102,8 @@ per_diem_rate_in_only_id: per_diem_rate_delete_summary_out: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/components/schemas/personal_card.yaml b/src/components/schemas/personal_card.yaml index 5319ea146..9c92956be 100644 --- a/src/components/schemas/personal_card.yaml +++ b/src/components/schemas/personal_card.yaml @@ -1,5 +1,7 @@ personal_card_access_token_out: type: object + required: + - access_token properties: access_token: type: string @@ -20,6 +22,8 @@ personal_card_mfa_in: personal_card_mfa_out: type: object + required: + - is_mfa_enabled properties: is_mfa_enabled: type: boolean @@ -138,6 +142,23 @@ personal_card_out: personal_card_delete_out: type: object additionalProperties: false + required: + - id + - org_id + - user_id + - currency + - bank_name + - card_number + - account_type + - yodlee_account_id + - yodlee_fastlink_params + - yodlee_is_credential_update_required + - yodlee_is_mfa_required + - yodlee_last_synced_at + - yodlee_login_id + - yodlee_provider_account_id + - created_at + - updated_at properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/personal_card_transaction.yaml b/src/components/schemas/personal_card_transaction.yaml index a074c296a..db941b98a 100644 --- a/src/components/schemas/personal_card_transaction.yaml +++ b/src/components/schemas/personal_card_transaction.yaml @@ -1,5 +1,24 @@ personal_card_transaction_out: type: object + required: + - id + - org_id + - user_id + - personal_card_id + - amount + - currency + - spent_at + - category + - merchant + - state + - description + - external_transaction_id + - matched_expense_ids + - created_at + - updated_at + - foreign_amount + - foreign_currency + - matched_expenses additionalProperties: False properties: id: @@ -76,6 +95,17 @@ matched_expense_out_embed: type: object nullable: true additionalProperties: false + required: + - amount + - category_display_name + - currency + - seq_num + - id + - no_of_files + - purpose + - state + - spent_at + - merchant properties: amount: $ref: './fields.yaml#/amount' @@ -156,6 +186,10 @@ personal_card_transactions_stats_in: personal_card_transactions_stats_out: type: object + required: + - count + - debit_amount + - credit_amount properties: count: type: integer diff --git a/src/components/schemas/place.yaml b/src/components/schemas/place.yaml index d62bfd837..8ade16b2d 100644 --- a/src/components/schemas/place.yaml +++ b/src/components/schemas/place.yaml @@ -1,6 +1,14 @@ place_out: type: object additionalProperties: false + required: + - id + - city + - state + - country + - formatted_address + - latitude + - longitude properties: id: type: string @@ -28,6 +36,9 @@ place_out: place_out_minimal: type: object + required: + - id + - formatted_address properties: id: type: string diff --git a/src/components/schemas/policy.yaml b/src/components/schemas/policy.yaml index 9893061f8..796ea059a 100644 --- a/src/components/schemas/policy.yaml +++ b/src/components/schemas/policy.yaml @@ -1,6 +1,9 @@ policy_test_out: type: object additionalProperties: false + required: + - policy_violation_summary + - policy_violations properties: policy_violation_summary: type: object diff --git a/src/components/schemas/project.yaml b/src/components/schemas/project.yaml index 3e779062f..a1723bcfb 100644 --- a/src/components/schemas/project.yaml +++ b/src/components/schemas/project.yaml @@ -67,6 +67,12 @@ project_out_embed: type: object nullable: true additionalProperties: False + required: + - id + - name + - sub_project + - code + - display_name properties: id: $ref: './fields.yaml#/id_integer' @@ -268,10 +274,15 @@ admin_approver_project_out: project_delete_summary_out: type: object + required: + - data additionalProperties: False properties: data: type: object + required: + - delete_count + - projects properties: delete_count: type: integer diff --git a/src/components/schemas/reconciliation_eligible_cards.yaml b/src/components/schemas/reconciliation_eligible_cards.yaml index 572089e49..584c27a41 100644 --- a/src/components/schemas/reconciliation_eligible_cards.yaml +++ b/src/components/schemas/reconciliation_eligible_cards.yaml @@ -97,6 +97,21 @@ reconciliation_eligible_cards_stats_in: reconciliation_eligible_cards_stats_out: type: object + required: + - period_start + - period_end + - statement_transaction_count + - expense_count + - statement_total + - expense_total + - difference + - matching_issue_count + - total_cards + - card_without_statement_count + - card_with_matching_issue_count + - card_with_no_issues_found_count + - card_with_no_transactions_count + - reconciled_card_count additionalProperties: False properties: period_start: diff --git a/src/components/schemas/reconciliation_exports.yaml b/src/components/schemas/reconciliation_exports.yaml index 2b13a5630..fd9d42fb0 100644 --- a/src/components/schemas/reconciliation_exports.yaml +++ b/src/components/schemas/reconciliation_exports.yaml @@ -99,6 +99,15 @@ reconciliation_export_in: reconciliation_export_out: type: object additionalProperties: false + required: + - id + - org_id + - file_id + - state + - query_params + - notify_emails + - created_at + - updated_at properties: id: allOf: diff --git a/src/components/schemas/reconciliation_transactions.yaml b/src/components/schemas/reconciliation_transactions.yaml index 218cc460e..27946a54f 100644 --- a/src/components/schemas/reconciliation_transactions.yaml +++ b/src/components/schemas/reconciliation_transactions.yaml @@ -11,6 +11,12 @@ reconciliation_transaction_out: - matched_expenses_count - is_reconciled - expenses + - statement_line_item_id + - expense_ids + - statement_transaction_date + - statement_post_date + - created_at + - updated_at properties: id: $ref: './fields.yaml#/id_string' @@ -86,6 +92,12 @@ reconciliation_expense_split_out_embed: - amount - state - purpose + - currency + - merchant + - spent_at + - file_ids + - category + - project properties: id: allOf: @@ -187,6 +199,7 @@ reconciliation_matched_expense_out_embed: - project - purpose - splits + - currency properties: id: allOf: @@ -301,6 +314,15 @@ reconciliation_transactions_stats_in: reconciliation_transactions_stats_out: type: object + required: + - period_start + - period_end + - statement_transaction_count + - expense_count + - statement_total + - expense_total + - difference + - matching_issue_count additionalProperties: False description: | Reconciliation transactions statistics for the selected filter period. diff --git a/src/components/schemas/recurring_expense.yaml b/src/components/schemas/recurring_expense.yaml index 9f1a8c742..7821dd546 100644 --- a/src/components/schemas/recurring_expense.yaml +++ b/src/components/schemas/recurring_expense.yaml @@ -49,6 +49,8 @@ recurring_expense_out: - expense_details - schedule_config - is_enabled + - created_at + - updated_at properties: id: allOf: @@ -71,8 +73,8 @@ recurring_expense_out: - MILEAGE: Mileage-based expense type example: EXPENSE expense_details: - type: object - nullable: false + allOf: + - $ref: './expense.yaml#/spender_expense_in' description: | Expense template details used for creating recurring expenses. Contains all the expense fields that will be applied to each generated expense. diff --git a/src/components/schemas/reimbursement.yaml b/src/components/schemas/reimbursement.yaml index c46df8912..27b9471b8 100644 --- a/src/components/schemas/reimbursement.yaml +++ b/src/components/schemas/reimbursement.yaml @@ -102,6 +102,8 @@ reimbursement_out: reimbursement_in: type: object + required: + - amount properties: amount: $ref: './fields.yaml#/amount' @@ -124,6 +126,12 @@ reimbursement_in_minimal: reimbursement_out_minimal: type: object nullable: true + required: + - id + - currency + - amount + - mode + - ach_transfer properties: id: type: string diff --git a/src/components/schemas/reminder.yaml b/src/components/schemas/reminder.yaml index f9bb5e011..fdf1c64ab 100644 --- a/src/components/schemas/reminder.yaml +++ b/src/components/schemas/reminder.yaml @@ -72,6 +72,13 @@ reminder_out: reminder_in: type: object additionalProperties: False + required: + - type + - message + - schedule_config + - add_to_calendar + - send_mobile_notification + - receiver_user_ids properties: id: type: string @@ -118,6 +125,8 @@ reminder_delete_in: example: 'remindNZgN7V5pft' reminders_stats_in: + required: + - query_params properties: query_params: type: string @@ -130,6 +139,9 @@ reminders_stats_out: type: array items: type: object + required: + - last_reminded_at + - type properties: last_reminded_at: type: string diff --git a/src/components/schemas/report.yaml b/src/components/schemas/report.yaml index 7114ecd27..b62a118f9 100644 --- a/src/components/schemas/report.yaml +++ b/src/components/schemas/report.yaml @@ -29,6 +29,15 @@ report_out: - reimbursement - comments - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - applied_advance_wallets + - auto_approval_state properties: id: $ref: ./fields.yaml#/id_string @@ -279,6 +288,14 @@ admin_report_out: - applied_advance_wallets - can_apply_advances - creator_type + - is_verified + - is_physical_bill_submitted + - physical_bill_submitted_at + - is_exported + - employee_id + - state_display_name + - accounting_export_summary + - auto_approval_state properties: id: $ref: ./fields.yaml#/id_string @@ -561,6 +578,9 @@ report_out_embed: - last_paid_at - reimbursement_id - reimbursement_seq_num + - amount + - last_verified_at + - approvals properties: id: anyOf: @@ -998,6 +1018,20 @@ process_summary_in: process_summary_out: type: object + required: + - selected_reimbursable_amount + - selected_count + - unverified_count + - unverified_amount + - missing_bank_details_count + - missing_bank_details_amount + - missing_bank_details_employee_count + - missing_bank_details_employee_ids + - payment_initiated_amount + - payment_initiated_count + - reimbursable_amount + - reimbursable_report_ids + - closable_report_ids additionalProperties: True properties: selected_reimbursable_amount: @@ -1082,6 +1116,8 @@ process_summary_out: reports_stats_in: + required: + - query_params properties: query_params: type: string diff --git a/src/components/schemas/report_approval.yaml b/src/components/schemas/report_approval.yaml index d56c9e4a1..7c850ffd4 100644 --- a/src/components/schemas/report_approval.yaml +++ b/src/components/schemas/report_approval.yaml @@ -1,6 +1,10 @@ report_approval_out_embed: type: object additionalProperties: False + required: + - approver_user_id + - approver_user + - state properties: approver_user_id: allOf: diff --git a/src/components/schemas/reports_export_configurations.yaml b/src/components/schemas/reports_export_configurations.yaml index 5b82e72d0..43ef02a2d 100644 --- a/src/components/schemas/reports_export_configurations.yaml +++ b/src/components/schemas/reports_export_configurations.yaml @@ -207,16 +207,6 @@ reports_export_configuration_out: $ref: './fields.yaml#/created_at' updated_at: $ref: './fields.yaml#/updated_at' - created_by: - allOf: - - $ref: './user.yaml#/user_out_embed_nullable' - description: | - User who created this export configuration. - updated_by: - allOf: - - $ref: './user.yaml#/user_out_embed_nullable' - description: | - User who last updated this export configuration. name: type: string description: | diff --git a/src/components/schemas/schedule.yaml b/src/components/schemas/schedule.yaml index d8e8726ea..db32e249a 100644 --- a/src/components/schemas/schedule.yaml +++ b/src/components/schemas/schedule.yaml @@ -20,6 +20,14 @@ schedule_in: schedule_out: type: object additionalProperties: False + required: + - id + - created_at + - updated_at + - config + - org_id + - user_id + - is_enabled properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/scheduled_callback.yaml b/src/components/schemas/scheduled_callback.yaml index b34a70971..770ba6ff2 100644 --- a/src/components/schemas/scheduled_callback.yaml +++ b/src/components/schemas/scheduled_callback.yaml @@ -1,5 +1,10 @@ scheduled_callback_in: type: object + required: + - url + - payload + - schedule_config + - is_enabled properties: id: $ref: './fields.yaml#/id_string' @@ -16,6 +21,15 @@ scheduled_callback_in: scheduled_callback_out: type: object additionalProperties: False + required: + - id + - url + - payload + - schedule_config + - is_enabled + - created_at + - updated_at + - org_id properties: id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/secondary_email.yaml b/src/components/schemas/secondary_email.yaml index 24fec25ef..1fd908373 100644 --- a/src/components/schemas/secondary_email.yaml +++ b/src/components/schemas/secondary_email.yaml @@ -13,6 +13,14 @@ secondary_email_in: secondary_email_out: type: object + required: + - id + - email + - is_verified + - org_id + - user_id + - created_at + - updated_at additionalProperties: False properties: id: diff --git a/src/components/schemas/spend_overview.yaml b/src/components/schemas/spend_overview.yaml index 04e186478..163a1798a 100644 --- a/src/components/schemas/spend_overview.yaml +++ b/src/components/schemas/spend_overview.yaml @@ -2,6 +2,9 @@ spend_overview_summary_data_out: type: object nullable: False + required: + - amount + - time_interval_marker properties: amount: $ref: './fields.yaml#/amount' @@ -12,6 +15,11 @@ spend_overview_summary_data_out: spend_overview_by_merchant_data_out: type: object nullable: False + required: + - merchant_name + - amount + - percentage + - change_percentage properties: merchant_name: $ref: './fields.yaml#/merchant' @@ -26,6 +34,12 @@ spend_overview_by_merchant_data_out: spend_overview_by_project_data_out: type: object nullable: False + required: + - project_id + - project_display_name + - amount + - percentage + - change_percentage properties: project_id: $ref: './fields.yaml#/id_integer' @@ -42,6 +56,12 @@ spend_overview_by_project_data_out: spend_overview_by_category_data_out: type: object nullable: False + required: + - category_id + - category_display_name + - amount + - percentage + - change_percentage properties: category_id: $ref: './fields.yaml#/id_integer' @@ -58,6 +78,12 @@ spend_overview_by_category_data_out: spend_overview_by_department_data_out: type: object nullable: False + required: + - department_id + - department_display_name + - amount + - percentage + - change_percentage properties: department_id: $ref: './fields.yaml#/id_string' @@ -74,6 +100,13 @@ spend_overview_by_department_data_out: spend_overview_by_user_data_out: type: object nullable: False + required: + - user_id + - user_full_name + - user_email + - amount + - percentage + - change_percentage properties: user_id: $ref: './fields.yaml#/id_string' @@ -92,6 +125,15 @@ spend_overview_by_user_data_out: spend_overview_by_corporate_card_data_out: type: object nullable: False + required: + - card_id + - card_number + - card_holder_name + - card_nickname + - user_id + - amount + - percentage + - change_percentage properties: card_id: $ref: './fields.yaml#/id_string' diff --git a/src/components/schemas/statements.yaml b/src/components/schemas/statements.yaml index 40caae826..b22010bc4 100644 --- a/src/components/schemas/statements.yaml +++ b/src/components/schemas/statements.yaml @@ -154,6 +154,7 @@ statements_out: - is_processed - statement_mappings_id + - creator_user card_transaction_from_statement_in: type: object properties: @@ -915,6 +916,13 @@ reconcile_from_statement_in: rtf_missing_transaction_from_statement_out: type: object + required: + - error + - missing_rtf_transactions + - rtf_confidence + - rtf_count + - total_count + - status properties: error: type: string @@ -1028,6 +1036,9 @@ rtf_missing_transaction_from_statement_out: rtf_stats_out: type: object + required: + - last_uploaded_at + - rtf_confidence properties: last_uploaded_at: $ref: './fields.yaml#/timestamptz_utc' @@ -1145,6 +1156,16 @@ preview_out: - no_of_transactions summary_out: + type: object + required: + - id + - status + - period_start + - period_end + - statement_transaction_count + - statement_total + - total_cards + - bridging_entry_change_type properties: id: allOf: @@ -1191,6 +1212,12 @@ summary_out: _reconciliation_summary_object: + type: object + required: + - expense_count + - is_recommended + - reconciliation_method + - statement_transaction_count properties: expense_count: description: Number of expense matches found @@ -1210,6 +1237,9 @@ _reconciliation_summary_object: reconciliation_summary_out: + type: object + required: + - reconciliation_summary properties: reconciliation_summary: type: array @@ -1267,9 +1297,12 @@ card_stats_out: required: - missing_transactions_count - is_rtf_statement - - + - rtf_card_network matching_cards_out: + type: object + required: + - statement_card_number + - matching_cards properties: statement_card_number: type: string @@ -1321,6 +1354,10 @@ unassigned_cards_from_statement_in: - statement_id statement_archived_cards_out: + required: + - number_of_cards + - number_of_archived_cards + - archived_cards properties: number_of_cards: type: integer diff --git a/src/components/schemas/subscriptions.yaml b/src/components/schemas/subscriptions.yaml index e61b5627c..4db7ff318 100644 --- a/src/components/schemas/subscriptions.yaml +++ b/src/components/schemas/subscriptions.yaml @@ -1,6 +1,13 @@ spender_subscriptions_out: type: object additionalProperties: False + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - user_id properties: id: $ref: ./fields.yaml#/id_string @@ -18,6 +25,13 @@ spender_subscriptions_out: approver_subscriptions_out: type: object additionalProperties: False + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - approver_user_id properties: id: $ref: ./fields.yaml#/id_string @@ -35,6 +49,14 @@ approver_subscriptions_out: admin_subscriptions_out: type: object additionalProperties: False + required: + - id + - is_enabled + - webhook_url + - updated_at + - created_at + - org_id + - subscribed_resources properties: id: $ref: ./fields.yaml#/id_string diff --git a/src/components/schemas/user.yaml b/src/components/schemas/user.yaml index 8fd2e6646..1062e0d01 100644 --- a/src/components/schemas/user.yaml +++ b/src/components/schemas/user.yaml @@ -1,6 +1,13 @@ user_out: type: object additionalProperties: False + required: + - id + - created_at + - updated_at + - email + - full_name + - email_verified_at properties: id: $ref: './fields.yaml#/id_string' @@ -22,6 +29,10 @@ user_out: user_out_embed: type: object additionalProperties: False + required: + - id + - email + - full_name properties: id: allOf: @@ -42,6 +53,10 @@ user_out_embed_nullable: type: object nullable: true additionalProperties: False + required: + - id + - email + - full_name properties: id: allOf: @@ -61,6 +76,10 @@ user_out_nullable_example_null: type: object nullable: true additionalProperties: False + required: + - id + - email + - full_name properties: id: allOf: diff --git a/src/manager/paths/manager@employee_overview@expenses@stats.yaml b/src/manager/paths/manager@employee_overview@expenses@stats.yaml index 99481ae3e..b4e9be6b4 100644 --- a/src/manager/paths/manager@employee_overview@expenses@stats.yaml +++ b/src/manager/paths/manager@employee_overview@expenses@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_expense_stats_out diff --git a/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml b/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml index aacf96bcc..91523915e 100644 --- a/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml +++ b/src/manager/paths/manager@employee_overview@files@generate_urls@bulk.yaml @@ -33,6 +33,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/manager/paths/manager@employee_overview@stats.yaml b/src/manager/paths/manager@employee_overview@stats.yaml index 7eb46a92a..0b90e52b4 100644 --- a/src/manager/paths/manager@employee_overview@stats.yaml +++ b/src/manager/paths/manager@employee_overview@stats.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: ../../components/schemas/employee.yaml#/employee_overview_stats_out diff --git a/src/spender/openapi.yaml b/src/spender/openapi.yaml index 42d044303..ed6b41066 100644 --- a/src/spender/openapi.yaml +++ b/src/spender/openapi.yaml @@ -181,7 +181,7 @@ paths: $ref: 'paths/spender@reports@suggest_purpose.yaml' /spender/reports/filters: $ref: 'paths/spender@reports@filters.yaml' - /spender/reports/filters/delte: + /spender/reports/filters/delete: $ref: 'paths/spender@reports@filters@delete.yaml' /spender/reports/comments: $ref: 'paths/spender@reports@comments.yaml' diff --git a/src/spender/paths/spender@advance_request_files.yaml b/src/spender/paths/spender@advance_request_files.yaml index fbce63cf7..167d26a8b 100644 --- a/src/spender/paths/spender@advance_request_files.yaml +++ b/src/spender/paths/spender@advance_request_files.yaml @@ -40,6 +40,8 @@ post: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/spender/paths/spender@advance_requests.yaml b/src/spender/paths/spender@advance_requests.yaml index 28d9eeaa3..1e735f2ca 100644 --- a/src/spender/paths/spender@advance_requests.yaml +++ b/src/spender/paths/spender@advance_requests.yaml @@ -70,6 +70,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml b/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml index 14065e4b1..8da910c34 100644 --- a/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml +++ b/src/spender/paths/spender@advance_requests@bulk_attach_file.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@advance_requests@comments.yaml b/src/spender/paths/spender@advance_requests@comments.yaml index 8f9b06917..f095c09d4 100644 --- a/src/spender/paths/spender@advance_requests@comments.yaml +++ b/src/spender/paths/spender@advance_requests@comments.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_comments_out' diff --git a/src/spender/paths/spender@advance_requests@permissions.yaml b/src/spender/paths/spender@advance_requests@permissions.yaml index 744da3b9f..8f5d4031b 100644 --- a/src/spender/paths/spender@advance_requests@permissions.yaml +++ b/src/spender/paths/spender@advance_requests@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_permissions_out' diff --git a/src/spender/paths/spender@advance_requests@pull_back.yaml b/src/spender/paths/spender@advance_requests@pull_back.yaml index 3c718f32a..db7ceba87 100644 --- a/src/spender/paths/spender@advance_requests@pull_back.yaml +++ b/src/spender/paths/spender@advance_requests@pull_back.yaml @@ -28,6 +28,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/spender/paths/spender@advance_requests@stats.yaml b/src/spender/paths/spender@advance_requests@stats.yaml index 79f6aa154..456f09cd8 100644 --- a/src/spender/paths/spender@advance_requests@stats.yaml +++ b/src/spender/paths/spender@advance_requests@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_requests_stats_out' diff --git a/src/spender/paths/spender@advance_requests@submit.yaml b/src/spender/paths/spender@advance_requests@submit.yaml index f511c601e..287fae1b2 100644 --- a/src/spender/paths/spender@advance_requests@submit.yaml +++ b/src/spender/paths/spender@advance_requests@submit.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance_request.yaml#/advance_request_out' diff --git a/src/spender/paths/spender@advances@stats.yaml b/src/spender/paths/spender@advances@stats.yaml index 54003447c..2e99a08d2 100644 --- a/src/spender/paths/spender@advances@stats.yaml +++ b/src/spender/paths/spender@advances@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/advance.yaml#/advances_stats_out' diff --git a/src/spender/paths/spender@automations@recurring_expenses.yaml b/src/spender/paths/spender@automations@recurring_expenses.yaml index 47fb46b1b..d3872e9e3 100644 --- a/src/spender/paths/spender@automations@recurring_expenses.yaml +++ b/src/spender/paths/spender@automations@recurring_expenses.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/recurring_expense.yaml#/recurring_expense_out' diff --git a/src/spender/paths/spender@automations@recurring_expenses@disable.yaml b/src/spender/paths/spender@automations@recurring_expenses@disable.yaml index d42056ac1..3b61eea04 100644 --- a/src/spender/paths/spender@automations@recurring_expenses@disable.yaml +++ b/src/spender/paths/spender@automations@recurring_expenses@disable.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/recurring_expense.yaml#/recurring_expense_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml b/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml index 7d6e7c526..5e3202893 100644 --- a/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@expenses@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/spender/paths/spender@corporate_card_transactions@ignore.yaml b/src/spender/paths/spender@corporate_card_transactions@ignore.yaml index af8d658dd..2a34f0ea2 100644 --- a/src/spender/paths/spender@corporate_card_transactions@ignore.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@ignore.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_ignore_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml b/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml index 446cbb7a1..17e2e040a 100644 --- a/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@mark_personal.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_mark_personal_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@match.yaml b/src/spender/paths/spender@corporate_card_transactions@match.yaml index 20d943d2b..7fd39f0fd 100644 --- a/src/spender/paths/spender@corporate_card_transactions@match.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@match.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_match_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml b/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml index b31f1e80a..5da053028 100644 --- a/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@undo_ignore.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_undo_ignore_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml b/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml index 9a9971a12..49b7338fd 100644 --- a/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@unmark_personal.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmark_personal_out' diff --git a/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml b/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml index d6225e595..59edc33a2 100644 --- a/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml +++ b/src/spender/paths/spender@corporate_card_transactions@unmatch.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/corporate_card_transaction.yaml#/corporate_card_transaction_unmatch_out' diff --git a/src/spender/paths/spender@email_files.yaml b/src/spender/paths/spender@email_files.yaml index ee331cce0..33cf8a983 100644 --- a/src/spender/paths/spender@email_files.yaml +++ b/src/spender/paths/spender@email_files.yaml @@ -34,6 +34,8 @@ post: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/spender/paths/spender@employees.yaml b/src/spender/paths/spender@employees.yaml index 863407815..811db855e 100644 --- a/src/spender/paths/spender@employees.yaml +++ b/src/spender/paths/spender@employees.yaml @@ -66,6 +66,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/employee.yaml#/spender_employee_out' diff --git a/src/spender/paths/spender@expense_files.yaml b/src/spender/paths/spender@expense_files.yaml index dddcb5c0a..19a113422 100644 --- a/src/spender/paths/spender@expense_files.yaml +++ b/src/spender/paths/spender@expense_files.yaml @@ -39,6 +39,8 @@ post: application/json: schema: type: object + required: + - data properties: url: type: string diff --git a/src/spender/paths/spender@expense_policy_comments.yaml b/src/spender/paths/spender@expense_policy_comments.yaml index 32672860a..5c3668172 100644 --- a/src/spender/paths/spender@expense_policy_comments.yaml +++ b/src/spender/paths/spender@expense_policy_comments.yaml @@ -58,6 +58,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/spender/paths/spender@expenses@attach_files@bulk.yaml b/src/spender/paths/spender@expenses@attach_files@bulk.yaml index 697d8e58d..10a43e46a 100644 --- a/src/spender/paths/spender@expenses@attach_files@bulk.yaml +++ b/src/spender/paths/spender@expenses@attach_files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@attach_receipt.yaml b/src/spender/paths/spender@expenses@attach_receipt.yaml index 7f9b03b94..a2a2a0b57 100644 --- a/src/spender/paths/spender@expenses@attach_receipt.yaml +++ b/src/spender/paths/spender@expenses@attach_receipt.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/spender/paths/spender@expenses@bulk.yaml b/src/spender/paths/spender@expenses@bulk.yaml index dc552913d..45a44b83d 100644 --- a/src/spender/paths/spender@expenses@bulk.yaml +++ b/src/spender/paths/spender@expenses@bulk.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_expenses_bulk_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@check_policies.yaml b/src/spender/paths/spender@expenses@check_policies.yaml index 7127e4f80..6de6fd159 100644 --- a/src/spender/paths/spender@expenses@check_policies.yaml +++ b/src/spender/paths/spender@expenses@check_policies.yaml @@ -29,6 +29,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_out diff --git a/src/spender/paths/spender@expenses@check_policies_bulk.yaml b/src/spender/paths/spender@expenses@check_policies_bulk.yaml index 46a8d4cad..c72a9c70f 100644 --- a/src/spender/paths/spender@expenses@check_policies_bulk.yaml +++ b/src/spender/paths/spender@expenses@check_policies_bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/expense.yaml#/expense_check_policies_bulk_out diff --git a/src/spender/paths/spender@expenses@comments@bulk.yaml b/src/spender/paths/spender@expenses@comments@bulk.yaml index 9411f87fc..60bf39510 100644 --- a/src/spender/paths/spender@expenses@comments@bulk.yaml +++ b/src/spender/paths/spender@expenses@comments@bulk.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_comments_bulk_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@create_from_file@bulk.yaml b/src/spender/paths/spender@expenses@create_from_file@bulk.yaml index 6b74fb2a7..593289c15 100644 --- a/src/spender/paths/spender@expenses@create_from_file@bulk.yaml +++ b/src/spender/paths/spender@expenses@create_from_file@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@create_from_receipt.yaml b/src/spender/paths/spender@expenses@create_from_receipt.yaml index ffd0a8bdd..642668b1f 100644 --- a/src/spender/paths/spender@expenses@create_from_receipt.yaml +++ b/src/spender/paths/spender@expenses@create_from_receipt.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/spender/paths/spender@expenses@export_configurations.yaml b/src/spender/paths/spender@expenses@export_configurations.yaml index e819a0707..c5b29e88e 100644 --- a/src/spender/paths/spender@expenses@export_configurations.yaml +++ b/src/spender/paths/spender@expenses@export_configurations.yaml @@ -158,6 +158,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_export_configurations.yaml#/expenses_export_configuration_out' diff --git a/src/spender/paths/spender@expenses@exports.yaml b/src/spender/paths/spender@expenses@exports.yaml index 0736bd382..1e0d8906e 100644 --- a/src/spender/paths/spender@expenses@exports.yaml +++ b/src/spender/paths/spender@expenses@exports.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expenses_exports.yaml#/expenses_exports_out' diff --git a/src/spender/paths/spender@expenses@filters.yaml b/src/spender/paths/spender@expenses@filters.yaml index eff9d7f67..ff4e69e9a 100644 --- a/src/spender/paths/spender@expenses@filters.yaml +++ b/src/spender/paths/spender@expenses@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/spender/paths/spender@expenses@filters@delete.yaml b/src/spender/paths/spender@expenses@filters@delete.yaml index 144f8b063..0acdb816f 100644 --- a/src/spender/paths/spender@expenses@filters@delete.yaml +++ b/src/spender/paths/spender@expenses@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense_filters.yaml#/expense_filters_out' diff --git a/src/spender/paths/spender@expenses@merge.yaml b/src/spender/paths/spender@expenses@merge.yaml index 9684a9e75..1f7c77091 100644 --- a/src/spender/paths/spender@expenses@merge.yaml +++ b/src/spender/paths/spender@expenses@merge.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_merge_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_out' diff --git a/src/spender/paths/spender@expenses@permissions.yaml b/src/spender/paths/spender@expenses@permissions.yaml index d6001df6f..3364da543 100644 --- a/src/spender/paths/spender@expenses@permissions.yaml +++ b/src/spender/paths/spender@expenses@permissions.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_out' diff --git a/src/spender/paths/spender@expenses@permissions@bulk.yaml b/src/spender/paths/spender@expenses@permissions@bulk.yaml index e6c19225c..8cfe9e758 100644 --- a/src/spender/paths/spender@expenses@permissions@bulk.yaml +++ b/src/spender/paths/spender@expenses@permissions@bulk.yaml @@ -33,6 +33,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expense_permissions_bulk_out' diff --git a/src/spender/paths/spender@expenses@policy_test.yaml b/src/spender/paths/spender@expenses@policy_test.yaml index a28d0d139..07c740338 100644 --- a/src/spender/paths/spender@expenses@policy_test.yaml +++ b/src/spender/paths/spender@expenses@policy_test.yaml @@ -14,6 +14,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_expense_in' @@ -24,6 +26,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/policy.yaml#/policy_test_out' diff --git a/src/spender/paths/spender@expenses@split.yaml b/src/spender/paths/spender@expenses@split.yaml index 207118e4d..be727a4b8 100644 --- a/src/spender/paths/spender@expenses@split.yaml +++ b/src/spender/paths/spender@expenses@split.yaml @@ -11,6 +11,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_split_expense_in' @@ -21,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml b/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml index 2037b253e..3285f9d30 100644 --- a/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml +++ b/src/spender/paths/spender@expenses@split@check_mandatory_fields.yaml @@ -13,6 +13,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_split_expense_in' @@ -23,6 +25,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@split@check_policies.yaml b/src/spender/paths/spender@expenses@split@check_policies.yaml index deeaf5fe1..583c809e9 100644 --- a/src/spender/paths/spender@expenses@split@check_policies.yaml +++ b/src/spender/paths/spender@expenses@split@check_policies.yaml @@ -14,6 +14,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/spender_split_expense_in' @@ -24,6 +26,8 @@ post: application/json: schema: type: object + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@expenses@stats.yaml b/src/spender/paths/spender@expenses@stats.yaml index ee129cee4..0bf898b7c 100644 --- a/src/spender/paths/spender@expenses@stats.yaml +++ b/src/spender/paths/spender@expenses@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/expense.yaml#/expenses_stats_out' diff --git a/src/spender/paths/spender@files.yaml b/src/spender/paths/spender@files.yaml index eed5916ba..053d51b3f 100644 --- a/src/spender/paths/spender@files.yaml +++ b/src/spender/paths/spender@files.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/file.yaml#/file_out diff --git a/src/spender/paths/spender@files@bulk.yaml b/src/spender/paths/spender@files@bulk.yaml index 0e90578db..ae24251cd 100644 --- a/src/spender/paths/spender@files@bulk.yaml +++ b/src/spender/paths/spender@files@bulk.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@files@generate_urls.yaml b/src/spender/paths/spender@files@generate_urls.yaml index 4a7180a10..8a3c6233b 100644 --- a/src/spender/paths/spender@files@generate_urls.yaml +++ b/src/spender/paths/spender@files@generate_urls.yaml @@ -27,6 +27,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/file.yaml#/file_generate_urls_action_out diff --git a/src/spender/paths/spender@files@generate_urls@bulk.yaml b/src/spender/paths/spender@files@generate_urls@bulk.yaml index e132a077e..13432b189 100644 --- a/src/spender/paths/spender@files@generate_urls@bulk.yaml +++ b/src/spender/paths/spender@files@generate_urls@bulk.yaml @@ -32,6 +32,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@files@upload_html.yaml b/src/spender/paths/spender@files@upload_html.yaml index dfacbc82d..b2f0c49b9 100644 --- a/src/spender/paths/spender@files@upload_html.yaml +++ b/src/spender/paths/spender@files@upload_html.yaml @@ -37,6 +37,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/file.yaml#/file_out_download_url diff --git a/src/spender/paths/spender@personal_card_transactions@stats.yaml b/src/spender/paths/spender@personal_card_transactions@stats.yaml index 9b2c4a2a5..d15303184 100644 --- a/src/spender/paths/spender@personal_card_transactions@stats.yaml +++ b/src/spender/paths/spender@personal_card_transactions@stats.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data additionalProperties: False properties: data: diff --git a/src/spender/paths/spender@personal_cards.yaml b/src/spender/paths/spender@personal_cards.yaml index 0d9510cc1..6a16a44c8 100644 --- a/src/spender/paths/spender@personal_cards.yaml +++ b/src/spender/paths/spender@personal_cards.yaml @@ -19,6 +19,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: array diff --git a/src/spender/paths/spender@reports@add_expenses.yaml b/src/spender/paths/spender@reports@add_expenses.yaml index d84f51bf9..762ca0bca 100644 --- a/src/spender/paths/spender@reports@add_expenses.yaml +++ b/src/spender/paths/spender@reports@add_expenses.yaml @@ -24,6 +24,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@comments.yaml b/src/spender/paths/spender@reports@comments.yaml index 883b28497..7e3628021 100644 --- a/src/spender/paths/spender@reports@comments.yaml +++ b/src/spender/paths/spender@reports@comments.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_comments_out' diff --git a/src/spender/paths/spender@reports@eject_expenses.yaml b/src/spender/paths/spender@reports@eject_expenses.yaml index ceeb17152..76358806b 100644 --- a/src/spender/paths/spender@reports@eject_expenses.yaml +++ b/src/spender/paths/spender@reports@eject_expenses.yaml @@ -26,6 +26,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@export_configurations.yaml b/src/spender/paths/spender@reports@export_configurations.yaml index 4f63e5a79..e19fcb464 100644 --- a/src/spender/paths/spender@reports@export_configurations.yaml +++ b/src/spender/paths/spender@reports@export_configurations.yaml @@ -83,6 +83,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_export_configurations.yaml#/reports_export_configuration_out' diff --git a/src/spender/paths/spender@reports@exports.yaml b/src/spender/paths/spender@reports@exports.yaml index ae9c462cd..9d98a5198 100644 --- a/src/spender/paths/spender@reports@exports.yaml +++ b/src/spender/paths/spender@reports@exports.yaml @@ -64,6 +64,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/reports_exports.yaml#/reports_exports_out' diff --git a/src/spender/paths/spender@reports@filters.yaml b/src/spender/paths/spender@reports@filters.yaml index 88472399f..4b06a8705 100644 --- a/src/spender/paths/spender@reports@filters.yaml +++ b/src/spender/paths/spender@reports@filters.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/spender/paths/spender@reports@filters@delete.yaml b/src/spender/paths/spender@reports@filters@delete.yaml index 50d56712a..63bceca83 100644 --- a/src/spender/paths/spender@reports@filters@delete.yaml +++ b/src/spender/paths/spender@reports@filters@delete.yaml @@ -23,6 +23,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/report_filters.yaml#/report_filters_out' diff --git a/src/spender/paths/spender@reports@permissions.yaml b/src/spender/paths/spender@reports@permissions.yaml index 00c0674d9..71ca3ad25 100644 --- a/src/spender/paths/spender@reports@permissions.yaml +++ b/src/spender/paths/spender@reports@permissions.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report_permissions.yaml#/report_permissions_out' diff --git a/src/spender/paths/spender@reports@resubmit.yaml b/src/spender/paths/spender@reports@resubmit.yaml index d031ff6b6..55b68d276 100644 --- a/src/spender/paths/spender@reports@resubmit.yaml +++ b/src/spender/paths/spender@reports@resubmit.yaml @@ -24,6 +24,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@stats.yaml b/src/spender/paths/spender@reports@stats.yaml index bd00c4e13..029c82d13 100644 --- a/src/spender/paths/spender@reports@stats.yaml +++ b/src/spender/paths/spender@reports@stats.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/reports_stats_out' diff --git a/src/spender/paths/spender@reports@submit.yaml b/src/spender/paths/spender@reports@submit.yaml index c655c82df..3b521a248 100644 --- a/src/spender/paths/spender@reports@submit.yaml +++ b/src/spender/paths/spender@reports@submit.yaml @@ -24,6 +24,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_out' diff --git a/src/spender/paths/spender@reports@suggest_purpose.yaml b/src/spender/paths/spender@reports@suggest_purpose.yaml index 62e20eac5..3079e4f37 100644 --- a/src/spender/paths/spender@reports@suggest_purpose.yaml +++ b/src/spender/paths/spender@reports@suggest_purpose.yaml @@ -24,6 +24,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: '../../components/schemas/report.yaml#/report_purpose_out' diff --git a/src/spender/paths/spender@schedules.yaml b/src/spender/paths/spender@schedules.yaml index 7ed0100ad..13cf2a8f6 100644 --- a/src/spender/paths/spender@schedules.yaml +++ b/src/spender/paths/spender@schedules.yaml @@ -25,6 +25,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/schedule.yaml#/schedule_out diff --git a/src/spender/paths/spender@secondary_emails.yaml b/src/spender/paths/spender@secondary_emails.yaml index 4d964929a..d5f554748 100644 --- a/src/spender/paths/spender@secondary_emails.yaml +++ b/src/spender/paths/spender@secondary_emails.yaml @@ -66,6 +66,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: $ref: ../../components/schemas/secondary_email.yaml#/secondary_email_out diff --git a/src/spender/paths/spender@secondary_emails@check.yaml b/src/spender/paths/spender@secondary_emails@check.yaml index 20eb49ab5..4f316949c 100644 --- a/src/spender/paths/spender@secondary_emails@check.yaml +++ b/src/spender/paths/spender@secondary_emails@check.yaml @@ -35,6 +35,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/spender/paths/spender@secondary_emails@delete.yaml b/src/spender/paths/spender@secondary_emails@delete.yaml index 2def9c992..273910199 100644 --- a/src/spender/paths/spender@secondary_emails@delete.yaml +++ b/src/spender/paths/spender@secondary_emails@delete.yaml @@ -35,6 +35,8 @@ post: schema: type: object additionalProperties: False + required: + - data properties: data: type: object diff --git a/src/spender/paths/spender@subscriptions.yaml b/src/spender/paths/spender@subscriptions.yaml index fae027bcc..d9ab5b93a 100644 --- a/src/spender/paths/spender@subscriptions.yaml +++ b/src/spender/paths/spender@subscriptions.yaml @@ -11,6 +11,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/subscriptions_in' @@ -22,6 +24,8 @@ post: schema: type: object additionalProperties: false + required: + - data properties: data: $ref: '../../components/schemas/subscriptions.yaml#/spender_subscriptions_out' diff --git a/src/spender/paths/spender@virtual_cards@get_current_amount.yaml b/src/spender/paths/spender@virtual_cards@get_current_amount.yaml index 7de87d1e4..c241f2727 100644 --- a/src/spender/paths/spender@virtual_cards@get_current_amount.yaml +++ b/src/spender/paths/spender@virtual_cards@get_current_amount.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_get_current_balance_out' diff --git a/src/spender/paths/spender@virtual_cards@show_card_details.yaml b/src/spender/paths/spender@virtual_cards@show_card_details.yaml index 49e8b924f..017381b29 100644 --- a/src/spender/paths/spender@virtual_cards@show_card_details.yaml +++ b/src/spender/paths/spender@virtual_cards@show_card_details.yaml @@ -24,6 +24,8 @@ post: application/json: schema: type: object + required: + - data properties: data: $ref: '../../components/schemas/virtual_card.yaml#/virtual_cards_show_card_details_out' From 4fb59b7805fec055745a84740ff20e93df9e39a1 Mon Sep 17 00:00:00 2001 From: Abhishek Jain Date: Tue, 11 Aug 2026 15:21:50 +0530 Subject: [PATCH 090/107] chore: add Platform API contract review skill (#807) * chore: add Platform API contract review skill * chore: simplify API contract review skill * fix: correct contract skill repository guidance * fix: make contract reviews evidence-complete --------- Co-authored-by: Abhishek Jain --- .../review-platform-api-contract/SKILL.md | 76 +++++ .../agents/openai.yaml | 4 + .../references/contract-chain.md | 121 ++++++++ .../scripts/contract_diff_inventory.py | 278 ++++++++++++++++++ 4 files changed, 479 insertions(+) create mode 100644 .agents/skills/review-platform-api-contract/SKILL.md create mode 100644 .agents/skills/review-platform-api-contract/agents/openai.yaml create mode 100644 .agents/skills/review-platform-api-contract/references/contract-chain.md create mode 100644 .agents/skills/review-platform-api-contract/scripts/contract_diff_inventory.py diff --git a/.agents/skills/review-platform-api-contract/SKILL.md b/.agents/skills/review-platform-api-contract/SKILL.md new file mode 100644 index 000000000..2b666d569 --- /dev/null +++ b/.agents/skills/review-platform-api-contract/SKILL.md @@ -0,0 +1,76 @@ +--- +name: review-platform-api-contract +description: Review Fyle Platform API contract pull requests across runtime code, OpenAPI source and bundles, generated TypeScript, and consumers. Use for changes to endpoints, request or response schemas, requiredness, nullability, enums, or compatibility in fyle-platform-docs, fyle-platform-api, or fyle-platform-types. Produce evidence-backed findings and do not publish review comments unless explicitly asked. +--- + +# Review Platform API Contracts + +Compare the proposed API contract change with runtime behavior, OpenAPI, and downstream types. Read [references/contract-chain.md](references/contract-chain.md) for repository-specific paths and commands. + +## 1. Fix the review scope + +- Resolve the PR base and head to immutable commits. Resolve the runtime revision separately: prefer a linked API PR or commit; otherwise use the API default-branch commit only as evidence of current behavior. Never use a sibling checkout unless its commit matches the recorded revision. +- Label each repository commit as proposed, current, or historical evidence. Do not use current behavior to prove what an old or closed PR did. +- Read the repository-local guidance files that exist, such as `AGENTS.md` or `CLAUDE.md`, and inspect each working-tree status. +- Preserve local changes. Use GitHub, `git show`, temporary copies, or a temporary worktree when a sibling repository is dirty. +- Inspect changed files, checks, reviews, and existing comments so findings are scoped and not duplicated. +- For docs-backed changes, run `/scripts/contract_diff_inventory.py` with the PR base and head. Use its source-file, risk, role, and bulk-mode counts as review denominators. +- Triage changed source lines first. Prioritize `$ref`, requiredness, nullability, enums, shared schemas, and request/response shape changes; trace high-risk candidates through the full chain before expanding the review. + +If a required repository is unavailable, continue only with supported conclusions and state the evidence gap. + +## 2. Review source before generated output + +- Treat `fyle-platform-docs/src/**` as source and `reference/*.yaml` as generated output. +- Map generated changes back to the exact source schema or path and attach findings there. +- Read the affected root document's OpenAPI version. +- Lint and rebuild every role reported by the inventory. A change under `src/components/**` requires every discoverable role root; a role-local change requires that role. + +## 3. Prove runtime behavior + +Trace each high-risk changed field from the endpoint through the exact runtime path. + +Read runtime files from the selected immutable commit with `git show` or an isolated worktree. If no revision is linked strongly enough to support the claim, report the gap instead of treating an unrelated current checkout as proof. + +- For requests, inspect the loaded Marshmallow schema, validation, defaults, `post_load`, action logic, and request/error fixtures. +- For responses, inspect the handler's dump schema, serialization hooks, the object being dumped, models, current database views and constraints, relevant migrations, and response fixtures. +- For enums, compare OpenAPI with the runtime enum, validators, storage representation, fixtures, migrations, and history for removed values. + +Use these contract rules: + +- Marshmallow `required` primarily controls loading; it does not prove response-key presence. +- OpenAPI object-level `required` means the key is present. `nullable` means a present key may be `null`. +- Omitted and present-with-`null` are different contracts. +- In OpenAPI 3.0, schema keywords beside `$ref` do not extend the referenced schema. Use `allOf` only after runtime evidence proves the added constraint is correct. +- When input and output behavior differ, prefer separate request and response schemas over weakening the response contract. + +Do not infer runtime behavior from the OpenAPI diff or a Marshmallow field flag alone. + +## 4. Check generated types and consumers + +- Compare base and proposed bundles in isolated directories in `fyle-platform-types`. +- Run the version classifier and generate representative before/after TypeScript when the contract shape changes. +- If dependencies are unavailable, compare the specs and generator configuration only. Generated output is not committed in `fyle-platform-types`; mark TypeScript shape and semver as unverified instead of installing into a sibling repository. +- Search identifiable consumers for affected imports, enum members, request arguments, optional fields, and null handling. +- Classify runtime compatibility, documentation accuracy, generated-source compatibility, and semver impact separately. + +Do not call a change runtime-breaking only because a generated type breaks, or call it documentation-only when generated consumers need a migration. + +## 5. Validate and report + +Run the smallest relevant checks from the repository map. Report failures and skipped checks without hiding them. + +When the inventory selects bulk mode, account for the whole diff: + +- Disposition every changed source file as manually reviewed or covered by a named deterministic check. +- Triage every risk-marker line and trace every resulting high-risk candidate; group mechanical edits only after proving the same rule covers every member. +- Report `reviewed/total` for source files, risk-marker lines, high-risk candidates, bundle roles, generated roles, and known consumer symbols. Sampling can support a finding, but cannot support a claim of complete review. + +Return findings in severity order. Each finding must include: + +1. The exact changed source line; for docs changes, prefer `src/**` over `reference/**`. +2. The concrete contract mismatch and user or SDK impact. +3. Concise runtime and generated-type evidence. +4. A specific requested change and, when useful, a proposed inline comment. + +Finish with the reviewed commits, checks run or skipped, evidence gaps, and publication status. Keep comments as proposals unless the user explicitly authorizes posting them. diff --git a/.agents/skills/review-platform-api-contract/agents/openai.yaml b/.agents/skills/review-platform-api-contract/agents/openai.yaml new file mode 100644 index 000000000..d99f5a2dd --- /dev/null +++ b/.agents/skills/review-platform-api-contract/agents/openai.yaml @@ -0,0 +1,4 @@ +interface: + display_name: "Review Platform API Contract" + short_description: "Review API contracts across runtime and types" + default_prompt: "Use $review-platform-api-contract to review this API contract PR across runtime, OpenAPI source, generated types, and consumers." diff --git a/.agents/skills/review-platform-api-contract/references/contract-chain.md b/.agents/skills/review-platform-api-contract/references/contract-chain.md new file mode 100644 index 000000000..d3230dc8c --- /dev/null +++ b/.agents/skills/review-platform-api-contract/references/contract-chain.md @@ -0,0 +1,121 @@ +# Platform API contract chain + +The repositories normally live beside one another: + +| Repository | Contract role | +| --- | --- | +| `fyle-platform-api` | Runtime handlers, schemas, models, database views, migrations, and fixtures | +| `fyle-platform-docs` | OpenAPI source in `src/` and generated bundles in `reference/` | +| `fyle-platform-types` | Synced bundles, generated TypeScript, and semver classification | +| `fyle-app` | Known direct consumer of `@fylein/types`; do not assume it is the only consumer | + +Resolve default branches and commits at review time. The contract flow is: + +```text +fyle-platform-api runtime + -> fyle-platform-docs/src + -> fyle-platform-docs/reference + -> fyle-platform-types/specs + -> @fylein/types + -> consumers +``` + +## Record repository state + +```bash +git status --short --branch +git symbolic-ref --short refs/remotes/origin/HEAD +git log -1 --format='%H %cI %s' +gh pr view --json baseRefOid,headRefOid,state,url +``` + +The PR base branch may advance after the PR opens. Resolve both PR refs, then use their merge base for the reviewed diff. For runtime evidence, use a linked `fyle-platform-api` PR or commit when one exists. Otherwise, an exact default-branch commit can prove only current behavior. A checked-out branch, similar timestamp, or current file is not evidence for a historical PR unless its commit is the selected revision. + +Record the evidence role beside every commit: proposed change, current behavior, or historical context. Read files with `git show :` or from an isolated worktree so paths from different revisions are not mixed. + +Do not switch, pull, install into, or generate inside a dirty sibling. Use read-only evidence or an isolated worktree instead. + +## Review and validate docs + +`src//openapi.yaml` declares the document version, tags, security, and path references. Endpoint definitions live in `src//paths/`; shared schemas live in `src/components/schemas/`. Filenames use `@` for URL separators. + +Inventory a docs diff before tracing it: + +```bash +python3 /scripts/contract_diff_inventory.py \ + --repo --base --head +``` + +The script resolves immutable commits, computes the merge base, counts changed source files and risk-marker lines, discovers role roots from `src/*/openapi.yaml`, and selects bulk mode for more than 10 source files or more than 3 directly changed roles. Use `--format json` when file-level details are needed. + +`reference/.yaml` is generated. Read the pinned Redocly version from `.github/workflows/bundler.yml` at the reviewed revision and verify its bundle steps cover every discovered role root. Lint and bundle every role reported by the inventory: + +```bash +openapi lint src//openapi.yaml +openapi bundle -o /tmp/.yaml src//openapi.yaml +``` + +Compare temporary base and head bundles with their corresponding committed `reference/.yaml` files, then compare base with head. A shared `src/components/**` change requires all role roots because shared-schema fan-out is not reliably visible from changed paths alone. + +## Trace runtime behavior + +Start from the route and inspect only the evidence needed for the changed field: + +- `api//.py` or the relevant blueprint and view. +- `api//schema.py` and inherited `core/schema/**` fields. +- The action class and model validation for writes. +- `db/models/**` column definitions. +- Current `db-migrations/views/**` plus migrations that changed the field or view. +- `api/tests/**/input.yaml` and `expected_output.yaml` for successful and validation-error cases. + +Use history when removed enum values or legacy storage are relevant: + +```bash +git log -p -G '' --all -- +``` + +Run the narrowest affected test group or test case using the commands in `fyle-platform-api/CLAUDE.md` when runtime verification is needed. + +## Compare generated types + +Read `package.json` for the required Node and pnpm versions. The useful entry points are: + +```bash +pnpm test +OLD_SPECS_DIR= NEW_SPECS_DIR= pnpm run version:check +OPENAPI_SPECS_DIR= OPENAPI_OUTPUT_DIR= pnpm exec openapi-ts +``` + +Use temporary base/head spec and output directories. `pnpm run build` syncs local docs into the types worktree, so run it only in an isolated worktree. + +`dist/` and `.generated/` are ignored rather than committed. If generation dependencies cannot run, compare the input specs and generator configuration, state that generated TypeScript and semver are unverified, and stop short of claiming full-chain validation. + +The classifier's highest result wins: + +- `major`: `oasdiff breaking` reports a breaking OpenAPI change or a role disappears. +- `minor`: generated structure changes without an OpenAPI breaking result, or a role appears. +- `patch`: only generated documentation changes. +- `none`: no generated or documentation change. + +## Account for broad changes + +For bulk mode, keep a coverage manifest with these denominators: + +- changed `src/**` files reviewed; +- risk-marker lines triaged and resulting candidates traced to runtime evidence; +- bundle roles linted and regenerated; +- generated roles compared when shape changes; +- affected symbols checked in every known available consumer. + +Report each as `reviewed/total` and name the deterministic check used for grouped mechanical edits. Do not describe a sampled review as exhaustive; list any uncovered files, roles, or consumers as evidence gaps. + +## Find consumers + +`TYPES_CONSUMER_REPOS` is a GitHub repository variable and is not enumerated in source. Search available sibling repositories instead: + +```bash +rg -l '"@fylein/types"\s*:' .. -g 'package.json' -g '!**/node_modules/**' -g '!**/.pnpm-store/**' +rg '' ../ -g '*.ts' -g '*.tsx' -g '!**/node_modules/**' +``` + +Inspect only consumers that use affected generated symbols. State that the search is incomplete when private or unavailable consumers may exist. diff --git a/.agents/skills/review-platform-api-contract/scripts/contract_diff_inventory.py b/.agents/skills/review-platform-api-contract/scripts/contract_diff_inventory.py new file mode 100644 index 000000000..b7493ffde --- /dev/null +++ b/.agents/skills/review-platform-api-contract/scripts/contract_diff_inventory.py @@ -0,0 +1,278 @@ +#!/usr/bin/env python3 +"""Inventory an OpenAPI source diff without modifying the repository.""" + +from __future__ import annotations + +import argparse +import json +import re +import subprocess +import sys +from dataclasses import asdict, dataclass +from pathlib import Path + + +BULK_SOURCE_FILE_LIMIT = 10 +BULK_ROLE_LIMIT = 3 +ROLE_ROOT = re.compile(r"^src/([^/]+)/openapi\.yaml$") +RISK_MARKERS = { + "ref": re.compile(r"\$ref\s*:"), + "required": re.compile(r"\brequired\s*:"), + "nullable": re.compile(r"\bnullable\s*:"), + "enum": re.compile(r"\benum\s*:"), + "composition": re.compile(r"\b(?:allOf|anyOf|oneOf)\s*:"), + "shape": re.compile(r"\b(?:type|properties|items|additionalProperties)\s*:"), + "operation": re.compile(r"\b(?:requestBody|responses|schema)\s*:"), + "list_item": re.compile(r"^\s*-\s+\S"), +} + + +@dataclass(frozen=True) +class SourceChange: + status: str + old_path: str | None + new_path: str | None + + +@dataclass(frozen=True) +class RiskLine: + path: str + side: str + line: int + markers: tuple[str, ...] + text: str + + +def run_git(repo: Path, *args: str, binary: bool = False) -> str | bytes: + result = subprocess.run( + ["git", "-C", str(repo), *args], + capture_output=True, + text=not binary, + check=False, + ) + if result.returncode != 0: + stderr = result.stderr.decode() if binary else result.stderr + raise RuntimeError(stderr.strip() or f"git {' '.join(args)} failed") + return result.stdout + + +def resolve_commit(repo: Path, ref: str) -> str: + output = run_git(repo, "rev-parse", "--verify", f"{ref}^{{commit}}") + assert isinstance(output, str) + return output.strip() + + +def parse_source_changes(repo: Path, base: str, head: str) -> list[SourceChange]: + output = run_git( + repo, + "diff", + "--name-status", + "-z", + "--find-renames", + base, + head, + "--", + "src", + binary=True, + ) + assert isinstance(output, bytes) + tokens = output.decode("utf-8", errors="surrogateescape").split("\0") + if tokens and not tokens[-1]: + tokens.pop() + + changes: list[SourceChange] = [] + index = 0 + while index < len(tokens): + status = tokens[index] + index += 1 + if status.startswith(("R", "C")): + old_path, new_path = tokens[index : index + 2] + index += 2 + else: + path = tokens[index] + index += 1 + old_path = None if status == "A" else path + new_path = None if status == "D" else path + changes.append(SourceChange(status, old_path, new_path)) + return changes + + +def role_roots(repo: Path, commit: str) -> set[str]: + output = run_git(repo, "ls-tree", "-r", "--name-only", commit, "--", "src") + assert isinstance(output, str) + roles = set() + for path in output.splitlines(): + match = ROLE_ROOT.match(path) + if match: + roles.add(match.group(1)) + return roles + + +def changed_paths(change: SourceChange) -> tuple[str, ...]: + return tuple(path for path in (change.old_path, change.new_path) if path) + + +def parse_hunk_start(header: str) -> tuple[int, int]: + match = re.match(r"@@ -(\d+)(?:,\d+)? \+(\d+)(?:,\d+)? @@", header) + if not match: + raise RuntimeError(f"cannot parse diff hunk: {header}") + return int(match.group(1)), int(match.group(2)) + + +def risk_lines(repo: Path, base: str, head: str) -> list[RiskLine]: + output = run_git( + repo, + "diff", + "--unified=0", + "--no-color", + "--no-ext-diff", + base, + head, + "--", + "src", + ) + assert isinstance(output, str) + + old_path: str | None = None + new_path: str | None = None + old_line = 0 + new_line = 0 + hits: list[RiskLine] = [] + for raw_line in output.splitlines(): + if raw_line.startswith("diff --git "): + old_path = None + new_path = None + continue + if raw_line.startswith("--- "): + path = raw_line[4:] + old_path = path[2:] if path.startswith("a/") else None + continue + if raw_line.startswith("+++ "): + path = raw_line[4:] + new_path = path[2:] if path.startswith("b/") else None + continue + if raw_line.startswith("@@ "): + old_line, new_line = parse_hunk_start(raw_line) + continue + if raw_line.startswith("index "): + continue + + side: str | None = None + line_number = 0 + content = "" + if raw_line.startswith("+"): + side, line_number, content = "added", new_line, raw_line[1:] + new_line += 1 + elif raw_line.startswith("-"): + side, line_number, content = "removed", old_line, raw_line[1:] + old_line += 1 + elif raw_line.startswith(" "): + old_line += 1 + new_line += 1 + + path = new_path if side == "added" else old_path + if side and path: + markers = tuple( + name for name, pattern in RISK_MARKERS.items() if pattern.search(content) + ) + if markers: + hits.append(RiskLine(path, side, line_number, markers, content.strip())) + return hits + + +def build_inventory(repo: Path, base_ref: str, head_ref: str) -> dict[str, object]: + base_commit = resolve_commit(repo, base_ref) + head_commit = resolve_commit(repo, head_ref) + merge_base = run_git(repo, "merge-base", base_commit, head_commit) + assert isinstance(merge_base, str) + merge_base = merge_base.strip() + + changes = parse_source_changes(repo, merge_base, head_commit) + roles = role_roots(repo, merge_base) | role_roots(repo, head_commit) + shared_changes = [ + change + for change in changes + if any(path.startswith("src/components/") for path in changed_paths(change)) + ] + direct_roles = sorted( + role + for role in roles + if any( + path.startswith(f"src/{role}/") + for change in changes + for path in changed_paths(change) + ) + ) + bundle_roles = sorted(roles if shared_changes else direct_roles) + hits = risk_lines(repo, merge_base, head_commit) + marker_counts = { + marker: sum(marker in hit.markers for hit in hits) for marker in RISK_MARKERS + } + marker_counts = {name: count for name, count in marker_counts.items() if count} + bulk_mode = len(changes) > BULK_SOURCE_FILE_LIMIT or len(direct_roles) > BULK_ROLE_LIMIT + + return { + "repository": str(repo), + "base_ref": base_ref, + "base_commit": base_commit, + "head_ref": head_ref, + "head_commit": head_commit, + "merge_base": merge_base, + "source_file_count": len(changes), + "shared_component_file_count": len(shared_changes), + "direct_roles": direct_roles, + "bundle_roles": bundle_roles, + "risk_marker_line_count": len(hits), + "risk_marker_counts": marker_counts, + "bulk_mode": bulk_mode, + "bulk_thresholds": { + "source_files_greater_than": BULK_SOURCE_FILE_LIMIT, + "direct_roles_greater_than": BULK_ROLE_LIMIT, + }, + "source_changes": [asdict(change) for change in changes], + "risk_lines": [asdict(hit) for hit in hits], + } + + +def print_summary(inventory: dict[str, object]) -> None: + print(f"base_commit: {inventory['base_commit']}") + print(f"head_commit: {inventory['head_commit']}") + print(f"merge_base: {inventory['merge_base']}") + print(f"source_files: {inventory['source_file_count']}") + print(f"shared_component_files: {inventory['shared_component_file_count']}") + print(f"direct_roles: {', '.join(inventory['direct_roles']) or '-'}") + print(f"bundle_roles: {', '.join(inventory['bundle_roles']) or '-'}") + print(f"risk_marker_lines: {inventory['risk_marker_line_count']}") + counts = inventory["risk_marker_counts"] + assert isinstance(counts, dict) + formatted_counts = ", ".join(f"{name}={count}" for name, count in counts.items()) + print(f"risk_markers: {formatted_counts or '-'}") + print(f"bulk_mode: {'yes' if inventory['bulk_mode'] else 'no'}") + + +def main() -> int: + parser = argparse.ArgumentParser(description=__doc__) + parser.add_argument("--repo", default=".", help="fyle-platform-docs checkout") + parser.add_argument("--base", required=True, help="PR base ref or commit") + parser.add_argument("--head", required=True, help="PR head ref or commit") + parser.add_argument("--format", choices=("summary", "json"), default="summary") + args = parser.parse_args() + + try: + repo_output = run_git(Path(args.repo).resolve(), "rev-parse", "--show-toplevel") + assert isinstance(repo_output, str) + repo = Path(repo_output.strip()) + inventory = build_inventory(repo, args.base, args.head) + except RuntimeError as error: + print(f"error: {error}", file=sys.stderr) + return 2 + + if args.format == "json": + print(json.dumps(inventory, indent=2)) + else: + print_summary(inventory) + return 0 + + +if __name__ == "__main__": + raise SystemExit(main()) From 3590c71a49b45ef85967c36a51cdf626263f3f3f Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Tue, 11 Aug 2026 16:50:56 +0530 Subject: [PATCH 091/107] fix: Fix expense action_data dropped from package types (#861) * wip * Auto generate API docs --- reference/admin.yaml | 8 +++++--- reference/approver.yaml | 8 +++++--- reference/manager.yaml | 8 +++++--- reference/spender.yaml | 8 +++++--- src/components/schemas/expense.yaml | 9 ++++++--- 5 files changed, 26 insertions(+), 15 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index ba3960cc9..1e5c06acb 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -35095,6 +35095,10 @@ components: $ref: '#/components/schemas/expense_check_policies_individual_desired_states' final_desired_state: $ref: '#/components/schemas/expense_check_policies_final_desired_state' + expense_action_data_embed: + type: object + description: Data related to expense action. + nullable: true expense_comments_out: type: object additionalProperties: false @@ -35142,9 +35146,7 @@ components: - UNMATCHED example: COMMENTED_WITH_NOTIFICATION action_data: - type: object - description: Data related to expense action. - nullable: true + $ref: '#/components/schemas/expense_action_data_embed' expense_id: $ref: '#/components/schemas/id_string' creator_type: diff --git a/reference/approver.yaml b/reference/approver.yaml index df704a20e..ab0c880d9 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -9879,6 +9879,10 @@ components: $ref: '#/components/schemas/expense_check_policies_individual_desired_states' final_desired_state: $ref: '#/components/schemas/expense_check_policies_final_desired_state' + expense_action_data_embed: + type: object + description: Data related to expense action. + nullable: true expense_comments_out: type: object additionalProperties: false @@ -9926,9 +9930,7 @@ components: - UNMATCHED example: COMMENTED_WITH_NOTIFICATION action_data: - type: object - description: Data related to expense action. - nullable: true + $ref: '#/components/schemas/expense_action_data_embed' expense_id: $ref: '#/components/schemas/id_string' creator_type: diff --git a/reference/manager.yaml b/reference/manager.yaml index 06b7a8363..1d74717e9 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -699,6 +699,10 @@ components: description: | This id is provided by Sage Exp Mgmt to identify an object. example: sdfd2391 + expense_action_data_embed: + type: object + description: Data related to expense action. + nullable: true user_id_nullable: type: string description: | @@ -799,9 +803,7 @@ components: - UNMATCHED example: COMMENTED_WITH_NOTIFICATION action_data: - type: object - description: Data related to expense action. - nullable: true + $ref: '#/components/schemas/expense_action_data_embed' expense_id: $ref: '#/components/schemas/id_string' creator_type: diff --git a/reference/spender.yaml b/reference/spender.yaml index 3a1d25b69..31d7659f6 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -18746,6 +18746,10 @@ components: - 12423 description: | List of IDs of expense fields which are mandatory but are missing. + expense_action_data_embed: + type: object + description: Data related to expense action. + nullable: true expense_comments_out: type: object additionalProperties: false @@ -18793,9 +18797,7 @@ components: - UNMATCHED example: COMMENTED_WITH_NOTIFICATION action_data: - type: object - description: Data related to expense action. - nullable: true + $ref: '#/components/schemas/expense_action_data_embed' expense_id: $ref: '#/components/schemas/id_string' creator_type: diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 60558e1b6..640c60520 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -2470,9 +2470,7 @@ expense_comments_out: - UNMATCHED example: COMMENTED_WITH_NOTIFICATION action_data: - type: object - description: Data related to expense action. - nullable: true + $ref: './expense.yaml#/expense_action_data_embed' expense_id: $ref: './fields.yaml#/id_string' creator_type: @@ -2516,6 +2514,11 @@ expense_comments_bulk_in: description: Whether to notify the user about the comment example: true +expense_action_data_embed: + type: object + description: Data related to expense action. + nullable: true + expense_dismiss_duplicates_in: type: object required: From d79d4d981aa741003bded8735fc310a8445e06f6 Mon Sep 17 00:00:00 2001 From: Tirth Bhagwat Date: Wed, 12 Aug 2026 11:48:57 +0530 Subject: [PATCH 092/107] feat: adding docs for mileate rates related fields in expenses api (#850) * feat: add advanced mileage rate properties for mileage rate apis * adding ref folder * Auto generate API docs * feat: add advanced properties for mileage expenses and rates * update schema * Auto generate API docs * update comments * Auto generate API docs --------- Co-authored-by: kulasekar --- reference/admin.yaml | 112 ++++++++++++++++++++++ reference/approver.yaml | 107 +++++++++++++++++++++ reference/manager.yaml | 87 +++++++++++++++++ reference/spender.yaml | 117 +++++++++++++++++++++++ src/components/schemas/expense.yaml | 95 ++++++++++++++++++ src/components/schemas/mileage_rate.yaml | 57 +++++++++++ 6 files changed, 575 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 1e5c06acb..7127393d1 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -17911,6 +17911,11 @@ components: - rate - vehicle_type - is_enabled + - vehicle_ownership + - vehicle_category + - fuel_type + - engine_capacity + - charging_location properties: id: $ref: '#/components/schemas/id_integer' @@ -20311,6 +20316,58 @@ components: example: 10 nullable: true description: Amount (in Home currency) per unit. + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Vehicle ownership for advanced mileage rates. `null` for basic mileage rates. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Vehicle category for advanced mileage rates. `null` for basic mileage rates. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Fuel type for advanced car mileage rates. `null` otherwise. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Engine capacity band for petrol, diesel, and LPG advanced car rates. An empty object for basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Charging location for advanced electric car mileage rates. `null` otherwise. expense_custom_field: type: object description: | @@ -21322,6 +21379,11 @@ components: - distance_unit - mileage_calculated_distance - mileage_calculated_amount + - selected_vehicle_ownership + - selected_vehicle_category + - passenger_count + - passenger_mileage_rate + - passenger_amount - mileage_rate_id - mileage_rate - mileage_is_round_trip @@ -21546,6 +21608,36 @@ components: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + selected_vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Selected vehicle ownership for an advanced mileage expense. `null` for a basic mileage expense. + selected_vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Selected vehicle category for an advanced mileage expense. `null` for a basic mileage expense. + passenger_count: + type: integer + nullable: true + description: Number of passengers carried on the mileage journey. + passenger_mileage_rate: + type: number + nullable: true + readOnly: true + description: Passenger mileage rate snapshot applied to this expense. `null` when passenger mileage does not apply. + passenger_amount: + type: number + nullable: true + description: Passenger mileage reimbursement amount for this expense. mileage_rate_id: allOf: - $ref: '#/components/schemas/fk_integer' @@ -22155,6 +22247,16 @@ components: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. commute_details_id: type: integer nullable: true @@ -34810,6 +34912,16 @@ components: $ref: '#/components/schemas/distance' distance_unit: $ref: '#/components/schemas/distance_unit' + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. started_at: $ref: '#/components/schemas/timestamptz_pst' ended_at: diff --git a/reference/approver.yaml b/reference/approver.yaml index ab0c880d9..c11f4abe8 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -5596,6 +5596,58 @@ components: example: 10 nullable: true description: Amount (in Home currency) per unit. + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Vehicle ownership for advanced mileage rates. `null` for basic mileage rates. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Vehicle category for advanced mileage rates. `null` for basic mileage rates. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Fuel type for advanced car mileage rates. `null` otherwise. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Engine capacity band for petrol, diesel, and LPG advanced car rates. An empty object for basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Charging location for advanced electric car mileage rates. `null` otherwise. per_diem_rate_out_embed: type: object nullable: true @@ -6638,6 +6690,11 @@ components: - distance_unit - mileage_calculated_distance - mileage_calculated_amount + - selected_vehicle_ownership + - selected_vehicle_category + - passenger_count + - passenger_mileage_rate + - passenger_amount - mileage_rate_id - mileage_rate - mileage_is_round_trip @@ -6862,6 +6919,36 @@ components: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + selected_vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Selected vehicle ownership for an advanced mileage expense. `null` for a basic mileage expense. + selected_vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Selected vehicle category for an advanced mileage expense. `null` for a basic mileage expense. + passenger_count: + type: integer + nullable: true + description: Number of passengers carried on the mileage journey. + passenger_mileage_rate: + type: number + nullable: true + readOnly: true + description: Passenger mileage rate snapshot applied to this expense. `null` when passenger mileage does not apply. + passenger_amount: + type: number + nullable: true + description: Passenger mileage reimbursement amount for this expense. mileage_rate_id: allOf: - $ref: '#/components/schemas/fk_integer' @@ -7449,6 +7536,16 @@ components: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. commute_details_id: type: integer nullable: true @@ -9594,6 +9691,16 @@ components: $ref: '#/components/schemas/distance' distance_unit: $ref: '#/components/schemas/distance_unit' + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. started_at: $ref: '#/components/schemas/timestamptz_pst' ended_at: diff --git a/reference/manager.yaml b/reference/manager.yaml index 1d74717e9..5145a8abf 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -2128,6 +2128,58 @@ components: example: 10 nullable: true description: Amount (in Home currency) per unit. + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Vehicle ownership for advanced mileage rates. `null` for basic mileage rates. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Vehicle category for advanced mileage rates. `null` for basic mileage rates. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Fuel type for advanced car mileage rates. `null` otherwise. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Engine capacity band for petrol, diesel, and LPG advanced car rates. An empty object for basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Charging location for advanced electric car mileage rates. `null` otherwise. expense_custom_field: type: object description: | @@ -3148,6 +3200,11 @@ components: - distance_unit - mileage_calculated_distance - mileage_calculated_amount + - selected_vehicle_ownership + - selected_vehicle_category + - passenger_count + - passenger_mileage_rate + - passenger_amount - mileage_rate_id - mileage_rate - mileage_is_round_trip @@ -3372,6 +3429,36 @@ components: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + selected_vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Selected vehicle ownership for an advanced mileage expense. `null` for a basic mileage expense. + selected_vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Selected vehicle category for an advanced mileage expense. `null` for a basic mileage expense. + passenger_count: + type: integer + nullable: true + description: Number of passengers carried on the mileage journey. + passenger_mileage_rate: + type: number + nullable: true + readOnly: true + description: Passenger mileage rate snapshot applied to this expense. `null` when passenger mileage does not apply. + passenger_amount: + type: number + nullable: true + description: Passenger mileage reimbursement amount for this expense. mileage_rate_id: allOf: - $ref: '#/components/schemas/fk_integer' diff --git a/reference/spender.yaml b/reference/spender.yaml index 31d7659f6..ca086743f 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -8961,6 +8961,58 @@ components: example: 10 nullable: true description: Amount (in Home currency) per unit. + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Vehicle ownership for advanced mileage rates. `null` for basic mileage rates. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Vehicle category for advanced mileage rates. `null` for basic mileage rates. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Fuel type for advanced car mileage rates. `null` otherwise. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Engine capacity band for petrol, diesel, and LPG advanced car rates. An empty object for basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Charging location for advanced electric car mileage rates. `null` otherwise. per_diem_rate_out_embed: type: object nullable: true @@ -10138,6 +10190,11 @@ components: - distance_unit - mileage_calculated_distance - mileage_calculated_amount + - selected_vehicle_ownership + - selected_vehicle_category + - passenger_count + - passenger_mileage_rate + - passenger_amount - mileage_rate_id - mileage_rate - mileage_is_round_trip @@ -10362,6 +10419,36 @@ components: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + selected_vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Selected vehicle ownership for an advanced mileage expense. `null` for a basic mileage expense. + selected_vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Selected vehicle category for an advanced mileage expense. `null` for a basic mileage expense. + passenger_count: + type: integer + nullable: true + description: Number of passengers carried on the mileage journey. + passenger_mileage_rate: + type: number + nullable: true + readOnly: true + description: Passenger mileage rate snapshot applied to this expense. `null` when passenger mileage does not apply. + passenger_amount: + type: number + nullable: true + description: Passenger mileage reimbursement amount for this expense. mileage_rate_id: allOf: - $ref: '#/components/schemas/fk_integer' @@ -10986,6 +11073,16 @@ components: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. commute_details_id: type: integer nullable: true @@ -18176,6 +18273,16 @@ components: type: number nullable: true description: Specific to mileage expense. Amount computed by Sage Exp Mgmt for mileage expenses. + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. expense_check_policies_individual_desired_states: type: object properties: @@ -18635,6 +18742,16 @@ components: $ref: '#/components/schemas/distance' distance_unit: $ref: '#/components/schemas/distance_unit' + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. started_at: $ref: '#/components/schemas/timestamptz_pst' ended_at: diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index 640c60520..ee6bc9c46 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -37,6 +37,11 @@ expense_out: - distance_unit - mileage_calculated_distance - mileage_calculated_amount + - selected_vehicle_ownership + - selected_vehicle_category + - passenger_count + - passenger_mileage_rate + - passenger_amount - mileage_rate_id - mileage_rate - mileage_is_round_trip @@ -261,6 +266,36 @@ expense_out: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + selected_vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Selected vehicle ownership for an advanced mileage expense. `null` for a basic mileage expense. + selected_vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Selected vehicle category for an advanced mileage expense. `null` for a basic mileage expense. + passenger_count: + type: integer + nullable: true + description: Number of passengers carried on the mileage journey. + passenger_mileage_rate: + type: number + nullable: true + readOnly: true + description: Passenger mileage rate snapshot applied to this expense. `null` when passenger mileage does not apply. + passenger_amount: + type: number + nullable: true + description: Passenger mileage reimbursement amount for this expense. mileage_rate_id: allOf: - $ref: './fields.yaml#/fk_integer' @@ -753,6 +788,16 @@ expense_in: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. mileage_rate_id: allOf: - $ref: './fields.yaml#/fk_integer' @@ -963,6 +1008,16 @@ spender_expense_in: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. commute_details_id: type: integer nullable: true @@ -1289,6 +1344,16 @@ admin_expense_in: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. commute_details_id: type: integer nullable: true @@ -1444,6 +1509,16 @@ approver_expense_in: type: number nullable: true description: Amount computed by Sage Exp Mgmt in mileage expenses. + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. commute_details_id: type: integer nullable: true @@ -2061,6 +2136,16 @@ expense_check_policies_in: type: number nullable: true description: Specific to mileage expense. Amount computed by Sage Exp Mgmt for mileage expenses. + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. expense_check_policies_out: type: object @@ -2298,6 +2383,16 @@ spender_expense_check_mandatory_fields_in: $ref: './fields.yaml#/distance' distance_unit: $ref: './fields.yaml#/distance_unit' + passenger_count: + type: integer + nullable: true + description: | + Number of passengers carried on the mileage journey. For advanced CAR mileage when passenger mileage is enabled, this is optional; when provided, it must be between 1 and 6. It must be `0` for MOTORCYCLE or BICYCLE mileage, and `null` for basic mileage or when passenger mileage is disabled. + passenger_amount: + type: number + nullable: true + description: | + Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. started_at: $ref: './fields.yaml#/timestamptz_pst' ended_at: diff --git a/src/components/schemas/mileage_rate.yaml b/src/components/schemas/mileage_rate.yaml index d101d68f3..211af4637 100644 --- a/src/components/schemas/mileage_rate.yaml +++ b/src/components/schemas/mileage_rate.yaml @@ -153,6 +153,58 @@ mileage_rate_out_embed_for_expense: example: 10.0 nullable: true description: Amount (in Home currency) per unit. + vehicle_ownership: + type: string + nullable: true + enum: + - PERSONAL + - COMPANY + - null + description: Vehicle ownership for advanced mileage rates. `null` for basic mileage rates. + vehicle_category: + type: string + nullable: true + enum: + - CAR + - MOTORCYCLE + - BICYCLE + - null + description: Vehicle category for advanced mileage rates. `null` for basic mileage rates. + fuel_type: + type: string + nullable: true + enum: + - PETROL + - DIESEL + - LPG + - ELECTRIC + - null + description: Fuel type for advanced car mileage rates. `null` otherwise. + engine_capacity: + type: object + nullable: true + additionalProperties: false + description: Engine capacity band for petrol, diesel, and LPG advanced car rates. An empty object for basic mileage rates. + properties: + from: + type: string + nullable: true + example: '0' + to: + type: string + nullable: true + example: '1400' + unit: + type: string + example: cc + charging_location: + type: string + nullable: true + enum: + - HOME + - PUBLIC + - null + description: Charging location for advanced electric car mileage rates. `null` otherwise. mileage_rate_in: type: object @@ -161,6 +213,11 @@ mileage_rate_in: - rate - vehicle_type - is_enabled + - vehicle_ownership + - vehicle_category + - fuel_type + - engine_capacity + - charging_location properties: id: $ref: './fields.yaml#/id_integer' From bf0e8fe45f1ba27989187a86334a707fbefe7cfb Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 12 Aug 2026 12:54:47 +0530 Subject: [PATCH 093/107] feat: update required fields (#862) --- reference/admin.yaml | 4 ++ reference/spender.yaml | 38 +++++++++++++++++++ .../paths/admin@employees@business_units.yaml | 2 + .../paths/admin@employees@locations.yaml | 2 + src/components/schemas/employee.yaml | 38 +++++++++++++++++++ 5 files changed, 84 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 7127393d1..3d578f5fb 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -2733,6 +2733,8 @@ paths: properties: data: type: object + required: + - business_units properties: business_units: type: array @@ -2873,6 +2875,8 @@ paths: properties: data: type: object + required: + - locations properties: locations: type: array diff --git a/reference/spender.yaml b/reference/spender.yaml index ca086743f..781f4af5e 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -15948,6 +15948,44 @@ components: Mileage settings of the employee. spender_employee_current_out: type: object + required: + - id + - org_id + - user_id + - created_at + - updated_at + - user + - code + - joined_at + - title + - business_unit + - special_email + - roles + - location + - is_enabled + - has_accepted_invite + - branch_account + - branch_ifsc + - department_id + - department + - level_id + - level + - mobile + - is_mobile_verified + - mobile_verification_attempts_left + - mobile_verification_attempted_at + - org_name + - currency + - approver_user_ids + - approver_users + - locale + - delegatees + - mileage_settings + - custom_fields + - flattened_custom_field + - commute_details_id + - commute_details + - is_primary additionalProperties: false properties: id: diff --git a/src/admin/paths/admin@employees@business_units.yaml b/src/admin/paths/admin@employees@business_units.yaml index 2bf6ac391..217f567b6 100644 --- a/src/admin/paths/admin@employees@business_units.yaml +++ b/src/admin/paths/admin@employees@business_units.yaml @@ -20,6 +20,8 @@ get: properties: data: type: object + required: + - business_units properties: business_units: type: array diff --git a/src/admin/paths/admin@employees@locations.yaml b/src/admin/paths/admin@employees@locations.yaml index 9fb416700..0651b1adc 100644 --- a/src/admin/paths/admin@employees@locations.yaml +++ b/src/admin/paths/admin@employees@locations.yaml @@ -20,6 +20,8 @@ get: properties: data: type: object + required: + - locations properties: locations: type: array diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index b2ce276b1..3fd029f32 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -1301,6 +1301,44 @@ employee_hierarchy_out: spender_employee_current_out: type: object + required: + - id + - org_id + - user_id + - created_at + - updated_at + - user + - code + - joined_at + - title + - business_unit + - special_email + - roles + - location + - is_enabled + - has_accepted_invite + - branch_account + - branch_ifsc + - department_id + - department + - level_id + - level + - mobile + - is_mobile_verified + - mobile_verification_attempts_left + - mobile_verification_attempted_at + - org_name + - currency + - approver_user_ids + - approver_users + - locale + - delegatees + - mileage_settings + - custom_fields + - flattened_custom_field + - commute_details_id + - commute_details + - is_primary additionalProperties: False properties: id: From bfd5f8c4d83dd8f1f228f3f371a5a3f742820699 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 12 Aug 2026 17:19:43 +0530 Subject: [PATCH 094/107] fix: API mismatch keys (#864) --- reference/admin.yaml | 52 +++++++++++++------ reference/approver.yaml | 42 +++++++++------ reference/manager.yaml | 26 +++++++++- reference/spender.yaml | 47 ++++++++++------- src/components/schemas/employee_settings.yaml | 16 +----- src/components/schemas/fields.yaml | 26 +++++++++- src/components/schemas/invitation.yaml | 8 +++ .../paths/spender@employees@current.yaml | 5 +- 8 files changed, 150 insertions(+), 72 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 3d578f5fb..2ca1a49a2 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -19210,6 +19210,16 @@ components: example: Branch Manager custom_fields: $ref: '#/components/schemas/custom_fields' + roles: + type: array + nullable: false + items: + $ref: '#/components/schemas/role' + example: + - FYLER + - APPROVER + description: | + List of roles for this employee approver_emails: type: array maxItems: 3 @@ -32731,6 +32741,7 @@ components: example: eq.ouNSnadfaLA expense_policy_expenses_query_object: type: object + nullable: true description: | An expense may be violating an expense policy rule due to a group of other expenses. These query params can be used to fetch those expenses because of which this expense is causing a violation.
@@ -32750,6 +32761,17 @@ components: $ref: '#/components/schemas/expense_policy_expenses_query_object_params' expense_policy_individual_desired_states: type: object + required: + - add_approver_user_ids + - approver_policy_order + - approver_source + - expense_id + - expense_policy_rule_id + - expense_policy_rule + - run_status + - run_result + - amount + - expenses_query_object properties: add_approver_user_ids: nullable: true @@ -32820,7 +32842,7 @@ components: description: | This represents the id of the expense policy rule. example: tprabsdfSYqd - rule: + expense_policy_rule: $ref: '#/components/schemas/expense_policy_rule_embed' amount: nullable: true @@ -32830,11 +32852,21 @@ components: description: | Amount that the policy calculation suggests for this expense. example: 500 - expenses_query_object_params: + expenses_query_object: nullable: true $ref: '#/components/schemas/expense_policy_expenses_query_object' expense_policy_final_desired_state: type: object + required: + - expense_id + - flag + - amount + - unreportable + - is_receipt_mandatory + - add_approver_user_ids + - remove_employee_approver1 + - run_status + - run_summary properties: expense_id: type: string @@ -36686,21 +36718,7 @@ components: example: true description: Whether to notify the delegatee about events mileage_settings: - type: object - nullable: true - additionalProperties: false - description: Settings for mileage tracking and rates - properties: - mileage_rate_labels: - type: object - nullable: true - example: null - description: Labels for different mileage rates - annual_mileage_of_user_before_joining_fyle: - type: object - nullable: true - example: {} - description: Annual mileage limit for user before joining Sage Exp Mgmt + $ref: '#/components/schemas/mileage_settings' expense_form_autofills: type: object nullable: true diff --git a/reference/approver.yaml b/reference/approver.yaml index c11f4abe8..e9f1a3068 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -9422,6 +9422,7 @@ components: example: eq.ouNSnadfaLA expense_policy_expenses_query_object: type: object + nullable: true description: | An expense may be violating an expense policy rule due to a group of other expenses. These query params can be used to fetch those expenses because of which this expense is causing a violation.
@@ -9441,6 +9442,17 @@ components: $ref: '#/components/schemas/expense_policy_expenses_query_object_params' expense_policy_individual_desired_states: type: object + required: + - add_approver_user_ids + - approver_policy_order + - approver_source + - expense_id + - expense_policy_rule_id + - expense_policy_rule + - run_status + - run_result + - amount + - expenses_query_object properties: add_approver_user_ids: nullable: true @@ -9511,7 +9523,7 @@ components: description: | This represents the id of the expense policy rule. example: tprabsdfSYqd - rule: + expense_policy_rule: $ref: '#/components/schemas/expense_policy_rule_embed' amount: nullable: true @@ -9521,11 +9533,21 @@ components: description: | Amount that the policy calculation suggests for this expense. example: 500 - expenses_query_object_params: + expenses_query_object: nullable: true $ref: '#/components/schemas/expense_policy_expenses_query_object' expense_policy_final_desired_state: type: object + required: + - expense_id + - flag + - amount + - unreportable + - is_receipt_mandatory + - add_approver_user_ids + - remove_employee_approver1 + - run_status + - run_summary properties: expense_id: type: string @@ -11393,21 +11415,7 @@ components: example: true description: Whether to notify the delegatee about events mileage_settings: - type: object - nullable: true - additionalProperties: false - description: Settings for mileage tracking and rates - properties: - mileage_rate_labels: - type: object - nullable: true - example: null - description: Labels for different mileage rates - annual_mileage_of_user_before_joining_fyle: - type: object - nullable: true - example: {} - description: Annual mileage limit for user before joining Sage Exp Mgmt + $ref: '#/components/schemas/mileage_settings' expense_form_autofills: type: object nullable: true diff --git a/reference/manager.yaml b/reference/manager.yaml index 5145a8abf..9cb714f5a 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -941,6 +941,7 @@ components: example: eq.ouNSnadfaLA expense_policy_expenses_query_object: type: object + nullable: true description: | An expense may be violating an expense policy rule due to a group of other expenses. These query params can be used to fetch those expenses because of which this expense is causing a violation.
@@ -960,6 +961,17 @@ components: $ref: '#/components/schemas/expense_policy_expenses_query_object_params' expense_policy_individual_desired_states: type: object + required: + - add_approver_user_ids + - approver_policy_order + - approver_source + - expense_id + - expense_policy_rule_id + - expense_policy_rule + - run_status + - run_result + - amount + - expenses_query_object properties: add_approver_user_ids: nullable: true @@ -1030,7 +1042,7 @@ components: description: | This represents the id of the expense policy rule. example: tprabsdfSYqd - rule: + expense_policy_rule: $ref: '#/components/schemas/expense_policy_rule_embed' amount: nullable: true @@ -1040,11 +1052,21 @@ components: description: | Amount that the policy calculation suggests for this expense. example: 500 - expenses_query_object_params: + expenses_query_object: nullable: true $ref: '#/components/schemas/expense_policy_expenses_query_object' expense_policy_final_desired_state: type: object + required: + - expense_id + - flag + - amount + - unreportable + - is_receipt_mandatory + - add_approver_user_ids + - remove_employee_approver1 + - run_status + - run_summary properties: expense_id: type: string diff --git a/reference/spender.yaml b/reference/spender.yaml index 781f4af5e..8c8acdd5a 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -3176,7 +3176,10 @@ paths: - data properties: data: - $ref: '#/components/schemas/spender_employee_current_out' + anyOf: + - $ref: '#/components/schemas/spender_employee_current_out' + - type: object + additionalProperties: false '400': description: Bad request content: @@ -16643,21 +16646,7 @@ components: example: true description: Whether to notify the delegatee about events mileage_settings: - type: object - nullable: true - additionalProperties: false - description: Settings for mileage tracking and rates - properties: - mileage_rate_labels: - type: object - nullable: true - example: null - description: Labels for different mileage rates - annual_mileage_of_user_before_joining_fyle: - type: object - nullable: true - example: {} - description: Annual mileage limit for user before joining Sage Exp Mgmt + $ref: '#/components/schemas/mileage_settings' expense_form_autofills: type: object nullable: true @@ -17963,6 +17952,7 @@ components: example: eq.ouNSnadfaLA expense_policy_expenses_query_object: type: object + nullable: true description: | An expense may be violating an expense policy rule due to a group of other expenses. These query params can be used to fetch those expenses because of which this expense is causing a violation.
@@ -17982,6 +17972,17 @@ components: $ref: '#/components/schemas/expense_policy_expenses_query_object_params' expense_policy_individual_desired_states: type: object + required: + - add_approver_user_ids + - approver_policy_order + - approver_source + - expense_id + - expense_policy_rule_id + - expense_policy_rule + - run_status + - run_result + - amount + - expenses_query_object properties: add_approver_user_ids: nullable: true @@ -18052,7 +18053,7 @@ components: description: | This represents the id of the expense policy rule. example: tprabsdfSYqd - rule: + expense_policy_rule: $ref: '#/components/schemas/expense_policy_rule_embed' amount: nullable: true @@ -18062,11 +18063,21 @@ components: description: | Amount that the policy calculation suggests for this expense. example: 500 - expenses_query_object_params: + expenses_query_object: nullable: true $ref: '#/components/schemas/expense_policy_expenses_query_object' expense_policy_final_desired_state: type: object + required: + - expense_id + - flag + - amount + - unreportable + - is_receipt_mandatory + - add_approver_user_ids + - remove_employee_approver1 + - run_status + - run_summary properties: expense_id: type: string diff --git a/src/components/schemas/employee_settings.yaml b/src/components/schemas/employee_settings.yaml index faa5ac749..3551425ca 100644 --- a/src/components/schemas/employee_settings.yaml +++ b/src/components/schemas/employee_settings.yaml @@ -154,21 +154,7 @@ spender_employee_settings_out: example: true description: Whether to notify the delegatee about events mileage_settings: - type: object - nullable: true - additionalProperties: false - description: Settings for mileage tracking and rates - properties: - mileage_rate_labels: - type: object - nullable: true - example: null - description: Labels for different mileage rates - annual_mileage_of_user_before_joining_fyle: - type: object - nullable: true - example: {} - description: Annual mileage limit for user before joining Sage Exp Mgmt + $ref: './fields.yaml#/mileage_settings' expense_form_autofills: type: object nullable: true diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index 85e8fa24a..efa664d8d 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -399,6 +399,7 @@ expense_policy_rule_embed: expense_policy_expenses_query_object: type: object + nullable: true description: | An expense may be violating an expense policy rule due to a group of other expenses. These query params can be used to fetch those expenses because of which this expense is causing a violation.
@@ -560,6 +561,17 @@ expense_check_policies_final_desired_state: expense_policy_individual_desired_states: type: object + required: + - add_approver_user_ids + - approver_policy_order + - approver_source + - expense_id + - expense_policy_rule_id + - expense_policy_rule + - run_status + - run_result + - amount + - expenses_query_object properties: add_approver_user_ids: nullable: true @@ -630,7 +642,7 @@ expense_policy_individual_desired_states: description: | This represents the id of the expense policy rule. example: "tprabsdfSYqd" - rule: + expense_policy_rule: $ref: '#/expense_policy_rule_embed' amount: nullable: true @@ -640,7 +652,7 @@ expense_policy_individual_desired_states: description: | Amount that the policy calculation suggests for this expense. example: 500 - expenses_query_object_params: + expenses_query_object: nullable: true $ref: '#/expense_policy_expenses_query_object' @@ -680,6 +692,16 @@ expense_policy_expenses_query_object_params: expense_policy_final_desired_state: type: object + required: + - expense_id + - flag + - amount + - unreportable + - is_receipt_mandatory + - add_approver_user_ids + - remove_employee_approver1 + - run_status + - run_summary properties: expense_id: type: string diff --git a/src/components/schemas/invitation.yaml b/src/components/schemas/invitation.yaml index 1ff91df21..84c3b9e85 100644 --- a/src/components/schemas/invitation.yaml +++ b/src/components/schemas/invitation.yaml @@ -51,6 +51,14 @@ invitation_in: example: Branch Manager custom_fields: $ref: './fields.yaml#/custom_fields' + roles: + type: array + nullable: False + items: + $ref: './fields.yaml#/role' + example: [ 'FYLER', 'APPROVER' ] + description: | + List of roles for this employee approver_emails: type: array diff --git a/src/spender/paths/spender@employees@current.yaml b/src/spender/paths/spender@employees@current.yaml index 7baadc66e..04650aea9 100644 --- a/src/spender/paths/spender@employees@current.yaml +++ b/src/spender/paths/spender@employees@current.yaml @@ -17,7 +17,10 @@ get: - data properties: data: - $ref: ../../components/schemas/employee.yaml#/spender_employee_current_out + anyOf: + - $ref: ../../components/schemas/employee.yaml#/spender_employee_current_out + - type: object + additionalProperties: false '400': description: Bad request content: From cded48cd41ff842ce936626bd3eecc9eb6e3f6c3 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Thu, 13 Aug 2026 15:22:30 +0530 Subject: [PATCH 095/107] chore: update required fields (#865) --- reference/admin.yaml | 35 +++++++++++++++++++-- reference/approver.yaml | 26 ++++++++++++++- reference/manager.yaml | 5 +++ reference/spender.yaml | 26 ++++++++++++++- src/admin/paths/admin@employees@titles.yaml | 2 ++ src/components/schemas/employee.yaml | 3 ++ src/components/schemas/fields.yaml | 26 ++++++++++++++- src/components/schemas/invitation.yaml | 4 ++- 8 files changed, 121 insertions(+), 6 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 2ca1a49a2..46a1ad20b 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -2830,6 +2830,8 @@ paths: properties: data: type: object + required: + - titles properties: titles: type: array @@ -18876,6 +18878,9 @@ components: additionalProperties: false items: type: object + required: + - role + - count additionalProperties: false properties: role: @@ -19225,7 +19230,9 @@ components: maxItems: 3 nullable: false items: - $ref: '#/components/schemas/email' + anyOf: + - $ref: '#/components/schemas/email' + - $ref: '#/components/schemas/null_field' example: - approver1@example.com - approver2@example.com @@ -32741,6 +32748,10 @@ components: example: eq.ouNSnadfaLA expense_policy_expenses_query_object: type: object + required: + - limit_start_date + - limit_end_date + - params nullable: true description: | An expense may be violating an expense policy rule due to a group of other expenses. @@ -32752,6 +32763,7 @@ components: description: | Spend start date query param to find the list of violating expenses. example: '2021-12-01' + nullable: true limit_end_date: type: string description: | @@ -35090,6 +35102,16 @@ components: $ref: '#/components/schemas/items' expense_check_policies_individual_desired_states: type: object + required: + - add_approver_user_ids + - approver_policy_order + - approver_source + - expense_policy_rule_id + - expense_policy_rule + - run_status + - run_result + - amount + - expenses_query_object properties: add_approver_user_ids: nullable: true @@ -35164,11 +35186,20 @@ components: description: | Amount that the policy calculation suggests for this expense. example: 500 - expenses_query_object_params: + expenses_query_object: nullable: true $ref: '#/components/schemas/expense_policy_expenses_query_object' expense_check_policies_final_desired_state: type: object + required: + - flag + - amount + - unreportable + - is_receipt_mandatory + - add_approver_user_ids + - remove_employee_approver1 + - run_status + - run_summary properties: flag: type: boolean diff --git a/reference/approver.yaml b/reference/approver.yaml index e9f1a3068..45a898ed0 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -9422,6 +9422,10 @@ components: example: eq.ouNSnadfaLA expense_policy_expenses_query_object: type: object + required: + - limit_start_date + - limit_end_date + - params nullable: true description: | An expense may be violating an expense policy rule due to a group of other expenses. @@ -9433,6 +9437,7 @@ components: description: | Spend start date query param to find the list of violating expenses. example: '2021-12-01' + nullable: true limit_end_date: type: string description: | @@ -9855,6 +9860,16 @@ components: $ref: '#/components/schemas/items' expense_check_policies_individual_desired_states: type: object + required: + - add_approver_user_ids + - approver_policy_order + - approver_source + - expense_policy_rule_id + - expense_policy_rule + - run_status + - run_result + - amount + - expenses_query_object properties: add_approver_user_ids: nullable: true @@ -9929,11 +9944,20 @@ components: description: | Amount that the policy calculation suggests for this expense. example: 500 - expenses_query_object_params: + expenses_query_object: nullable: true $ref: '#/components/schemas/expense_policy_expenses_query_object' expense_check_policies_final_desired_state: type: object + required: + - flag + - amount + - unreportable + - is_receipt_mandatory + - add_approver_user_ids + - remove_employee_approver1 + - run_status + - run_summary properties: flag: type: boolean diff --git a/reference/manager.yaml b/reference/manager.yaml index 9cb714f5a..fa1b6f47e 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -941,6 +941,10 @@ components: example: eq.ouNSnadfaLA expense_policy_expenses_query_object: type: object + required: + - limit_start_date + - limit_end_date + - params nullable: true description: | An expense may be violating an expense policy rule due to a group of other expenses. @@ -952,6 +956,7 @@ components: description: | Spend start date query param to find the list of violating expenses. example: '2021-12-01' + nullable: true limit_end_date: type: string description: | diff --git a/reference/spender.yaml b/reference/spender.yaml index 8c8acdd5a..f417b4a86 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -17952,6 +17952,10 @@ components: example: eq.ouNSnadfaLA expense_policy_expenses_query_object: type: object + required: + - limit_start_date + - limit_end_date + - params nullable: true description: | An expense may be violating an expense policy rule due to a group of other expenses. @@ -17963,6 +17967,7 @@ components: description: | Spend start date query param to find the list of violating expenses. example: '2021-12-01' + nullable: true limit_end_date: type: string description: | @@ -18334,6 +18339,16 @@ components: Passenger mileage reimbursement amount for this expense. For advanced CAR mileage when passenger mileage is enabled and `passenger_count` is provided, it must equal `passenger_count * passenger_mileage_rate * distance`, rounded to two decimal places. It must be `null` when `passenger_count` is `null`, for basic mileage, or when passenger mileage is disabled; no passenger reimbursement is applied for MOTORCYCLE or BICYCLE mileage. expense_check_policies_individual_desired_states: type: object + required: + - add_approver_user_ids + - approver_policy_order + - approver_source + - expense_policy_rule_id + - expense_policy_rule + - run_status + - run_result + - amount + - expenses_query_object properties: add_approver_user_ids: nullable: true @@ -18408,11 +18423,20 @@ components: description: | Amount that the policy calculation suggests for this expense. example: 500 - expenses_query_object_params: + expenses_query_object: nullable: true $ref: '#/components/schemas/expense_policy_expenses_query_object' expense_check_policies_final_desired_state: type: object + required: + - flag + - amount + - unreportable + - is_receipt_mandatory + - add_approver_user_ids + - remove_employee_approver1 + - run_status + - run_summary properties: flag: type: boolean diff --git a/src/admin/paths/admin@employees@titles.yaml b/src/admin/paths/admin@employees@titles.yaml index 44363adc3..a611bc875 100644 --- a/src/admin/paths/admin@employees@titles.yaml +++ b/src/admin/paths/admin@employees@titles.yaml @@ -20,6 +20,8 @@ get: properties: data: type: object + required: + - titles properties: titles: type: array diff --git a/src/components/schemas/employee.yaml b/src/components/schemas/employee.yaml index 3fd029f32..5b5086d29 100644 --- a/src/components/schemas/employee.yaml +++ b/src/components/schemas/employee.yaml @@ -1662,6 +1662,9 @@ employees_stats_out: additionalProperties: false items: type: object + required: + - role + - count additionalProperties: false properties: role: diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index efa664d8d..5f9e1081e 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -399,6 +399,10 @@ expense_policy_rule_embed: expense_policy_expenses_query_object: type: object + required: + - limit_start_date + - limit_end_date + - params nullable: true description: | An expense may be violating an expense policy rule due to a group of other expenses. @@ -410,6 +414,7 @@ expense_policy_expenses_query_object: description: | Spend start date query param to find the list of violating expenses. example: "2021-12-01" + nullable: true limit_end_date: type: string description: | @@ -420,6 +425,16 @@ expense_policy_expenses_query_object: expense_check_policies_individual_desired_states: type: object + required: + - add_approver_user_ids + - approver_policy_order + - approver_source + - expense_policy_rule_id + - expense_policy_rule + - run_status + - run_result + - amount + - expenses_query_object properties: add_approver_user_ids: nullable: true @@ -494,12 +509,21 @@ expense_check_policies_individual_desired_states: description: | Amount that the policy calculation suggests for this expense. example: 500 - expenses_query_object_params: + expenses_query_object: nullable: true $ref: '#/expense_policy_expenses_query_object' expense_check_policies_final_desired_state: type: object + required: + - flag + - amount + - unreportable + - is_receipt_mandatory + - add_approver_user_ids + - remove_employee_approver1 + - run_status + - run_summary properties: flag: type: boolean diff --git a/src/components/schemas/invitation.yaml b/src/components/schemas/invitation.yaml index 84c3b9e85..dc3291262 100644 --- a/src/components/schemas/invitation.yaml +++ b/src/components/schemas/invitation.yaml @@ -65,7 +65,9 @@ invitation_in: maxItems: 3 nullable: False items: - $ref: './fields.yaml#/email' + anyOf: + - $ref: './fields.yaml#/email' + - $ref: './fields.yaml#/null_field' example: [ 'approver1@example.com', 'approver2@example.com', null ] description: | List of emails of employees that are approvers for this employee. Use null in case of no approver or to remove the approver. From a1a2c08576c99e5538e685640591c4cfb6750e93 Mon Sep 17 00:00:00 2001 From: Shwetabh Kumar Date: Thu, 13 Aug 2026 15:33:39 +0530 Subject: [PATCH 096/107] feat: document admin report resubmission (#866) * feat: document admin report resubmission * Auto generate API docs --- reference/admin.yaml | 67 +++++++++++++++++++++ src/admin/openapi.yaml | 2 + src/admin/paths/admin@reports@resubmit.yaml | 55 +++++++++++++++++ 3 files changed, 124 insertions(+) create mode 100644 src/admin/paths/admin@reports@resubmit.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index 46a1ad20b..baf0391c4 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -7591,6 +7591,62 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/reports/resubmit: + post: + tags: + - Reports + summary: Resubmit an employee's report + description: Resubmit an employee's report that is in the `APPROVER_INQUIRY` state. + operationId: report_resubmit + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/report_action_resubmit' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/admin_report_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/404' /admin/reports/permissions: post: tags: @@ -25575,6 +25631,17 @@ components: example: - txelntgwgwll - txavbdabass + report_action_resubmit: + type: object + additionalProperties: false + required: + - id + properties: + id: + type: string + description: | + id of report, which needs to be resubmitted + example: rpa21A2rdj2 report_permissions_in: type: object additionalProperties: false diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index 551e928d9..b5ef74d90 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -359,6 +359,8 @@ paths: $ref: paths/admin@reports@stats.yaml /admin/reports/create_and_submit: $ref: paths/admin@reports@create_and_submit.yaml + /admin/reports/resubmit: + $ref: paths/admin@reports@resubmit.yaml /admin/reports/permissions: $ref: paths/admin@reports@permissions.yaml /admin/reports/apply_advance_wallets: diff --git a/src/admin/paths/admin@reports@resubmit.yaml b/src/admin/paths/admin@reports@resubmit.yaml new file mode 100644 index 000000000..d27b766ad --- /dev/null +++ b/src/admin/paths/admin@reports@resubmit.yaml @@ -0,0 +1,55 @@ +post: + tags: + - Reports + summary: Resubmit an employee's report + description: Resubmit an employee's report that is in the `APPROVER_INQUIRY` state. + operationId: report_resubmit + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../../components/schemas/report.yaml#/report_action_resubmit' + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../../components/schemas/report.yaml#/admin_report_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' + '404': + description: Not Found + content: + application/json: + schema: + $ref: '../../components/schemas/404.yaml' From c9d0b6cb48bdc65e8b1f0d9c667ecf78d214ba91 Mon Sep 17 00:00:00 2001 From: Anjanna Date: Mon, 17 Aug 2026 11:50:54 +0530 Subject: [PATCH 097/107] feat: Added api docs for get expenses count based on state (#863) * added api docs for get expenses count based on state * Auto generate API docs * updated 403 error schema * Auto generate API docs * updated api description * updated description: removed enum values * Auto generate API docs --- reference/admin.yaml | 79 +++++++++++++++++++++++ src/admin/openapi.yaml | 2 + src/admin/paths/admin@expenses@count.yaml | 66 +++++++++++++++++++ src/components/schemas/expense.yaml | 14 ++++ 4 files changed, 161 insertions(+) create mode 100644 src/admin/paths/admin@expenses@count.yaml diff --git a/reference/admin.yaml b/reference/admin.yaml index baf0391c4..936df6282 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -4893,6 +4893,73 @@ paths: application/json: schema: $ref: '#/components/schemas/404' + /admin/expenses/count: + get: + tags: + - Expenses + summary: Get expense count + description: | + Returns the number of expenses in the requested state that belong to enabled employees in the organization. + operationId: expenses_count + parameters: + - in: query + name: state + required: true + description: | + Valid expense state for which the count should be returned.
+ Supported operators are `eq`.
+ state=eq.DRAFT + schema: + type: string + example: eq.DRAFT + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/expenses_count_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + - error + - message + properties: + data: + type: object + nullable: true + example: null + error: + type: string + enum: + - InvalidUsage + message: + type: string + example: You don't have permissions to access this resource /admin/expenses/exports: post: tags: @@ -22684,6 +22751,18 @@ components: - state: UNREPORTABLE count: 0 total_amount: 0 + expenses_count_out: + type: object + additionalProperties: false + required: + - count + properties: + count: + type: integer + minimum: 0 + nullable: false + description: Number of expenses matching the requested state and enabled-employee criteria. + example: 33 query_params: type: string description: | diff --git a/src/admin/openapi.yaml b/src/admin/openapi.yaml index b5ef74d90..44fb4d0c4 100644 --- a/src/admin/openapi.yaml +++ b/src/admin/openapi.yaml @@ -281,6 +281,8 @@ paths: $ref: paths/admin@expenses@verify@bulk.yaml /admin/expenses/stats: $ref: paths/admin@expenses@stats.yaml + /admin/expenses/count: + $ref: paths/admin@expenses@count.yaml /admin/expenses/exports: $ref: paths/admin@expenses@exports.yaml /admin/expenses/export_configurations: diff --git a/src/admin/paths/admin@expenses@count.yaml b/src/admin/paths/admin@expenses@count.yaml new file mode 100644 index 000000000..205fcaa86 --- /dev/null +++ b/src/admin/paths/admin@expenses@count.yaml @@ -0,0 +1,66 @@ +get: + tags: + - Expenses + summary: Get expense count + description: | + Returns the number of expenses in the requested state that belong to enabled employees in the organization. + operationId: expenses_count + parameters: + - in: query + name: state + required: true + description: | + Valid expense state for which the count should be returned.
+ Supported operators are `eq`.
+ state=eq.DRAFT + schema: + type: string + example: eq.DRAFT + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + properties: + data: + $ref: '../../components/schemas/expense.yaml#/expenses_count_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + type: object + additionalProperties: False + required: + - data + - error + - message + properties: + data: + type: object + nullable: true + example: null + error: + type: string + enum: + - InvalidUsage + message: + type: string + example: You don't have permissions to access this resource diff --git a/src/components/schemas/expense.yaml b/src/components/schemas/expense.yaml index ee6bc9c46..1999ace8f 100644 --- a/src/components/schemas/expense.yaml +++ b/src/components/schemas/expense.yaml @@ -2187,6 +2187,20 @@ expense_delete_in: $ref: './fields.yaml#/id_string' +expenses_count_out: + type: object + additionalProperties: False + required: + - count + properties: + count: + type: integer + minimum: 0 + nullable: false + description: Number of expenses matching the requested state and enabled-employee criteria. + example: 33 + + expenses_stats_in: required: - query_params From 2f5c53e7164f22d60428f913dca62b5fc72dbe26 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 19 Aug 2026 08:11:24 +0530 Subject: [PATCH 098/107] chore: update required fields (#867) * chore: update required fields * Auto generate API docs --- reference/admin.yaml | 3 +++ reference/spender.yaml | 8 ++++---- src/components/schemas/per_diem_rate.yaml | 3 +++ src/components/schemas/personal_card.yaml | 8 ++++---- 4 files changed, 14 insertions(+), 8 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 936df6282..c1ad2f953 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -17774,6 +17774,9 @@ components: properties: data: type: object + required: + - delete_count + - per_diem_rates properties: delete_count: type: integer diff --git a/reference/spender.yaml b/reference/spender.yaml index f417b4a86..d8b8021a0 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -19787,6 +19787,10 @@ components: order: 1 fastlink_params: type: object + required: + - configName + - flow + - providerAccountId nullable: true additionalProperties: false properties: @@ -19855,10 +19859,6 @@ components: $ref: '#/components/schemas/fk_string' yodlee_fastlink_params: $ref: '#/components/schemas/fastlink_params' - type: object - nullable: true - description: | - Configuration to open Yodlee Fastlink yodlee_is_credential_update_required: type: boolean nullable: false diff --git a/src/components/schemas/per_diem_rate.yaml b/src/components/schemas/per_diem_rate.yaml index 01f4b54c1..61033cd2b 100644 --- a/src/components/schemas/per_diem_rate.yaml +++ b/src/components/schemas/per_diem_rate.yaml @@ -107,6 +107,9 @@ per_diem_rate_delete_summary_out: properties: data: type: object + required: + - delete_count + - per_diem_rates properties: delete_count: type: integer diff --git a/src/components/schemas/personal_card.yaml b/src/components/schemas/personal_card.yaml index 9c92956be..4c8ae8ccc 100644 --- a/src/components/schemas/personal_card.yaml +++ b/src/components/schemas/personal_card.yaml @@ -34,6 +34,10 @@ personal_card_mfa_out: fastlink_params: type: object + required: + - configName + - flow + - providerAccountId nullable: true additionalProperties: False properties: @@ -103,10 +107,6 @@ personal_card_out: $ref: './fields.yaml#/fk_string' yodlee_fastlink_params: $ref: '#/fastlink_params' - type: object - nullable: true - description: | - Configuration to open Yodlee Fastlink yodlee_is_credential_update_required: type: boolean nullable: false From 9b014b2dcfd6a285c7f2cd031af38acdb259c941 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 19 Aug 2026 12:31:44 +0530 Subject: [PATCH 099/107] chore: update reminder API schema (#868) * chore: update reminder API schema * wip --- src/components/schemas/fields.yaml | 8 ++++++++ src/components/schemas/reminder.yaml | 1 - 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index 5f9e1081e..b6beb7876 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1465,6 +1465,14 @@ reminder_schedule_config: pattern: '^[1-7](?:,[1-7])*$' example: 1,3,5 description: comma-separated day numbers (e.g. "1,3,5" for mon,wed,fri) + week: + oneOf: + - type: number + example: 2 + description: Week of the month (number, e.g. 2) + - type: string + example: '*/1' + description: cron expression (e.g. '*/1' for every week, '*/2' for every alternate week) hour: type: number example: 22 diff --git a/src/components/schemas/reminder.yaml b/src/components/schemas/reminder.yaml index fdf1c64ab..4565d1e49 100644 --- a/src/components/schemas/reminder.yaml +++ b/src/components/schemas/reminder.yaml @@ -77,7 +77,6 @@ reminder_in: - message - schedule_config - add_to_calendar - - send_mobile_notification - receiver_user_ids properties: id: From ab93138c1cf7eaaa20987342a2e679ac0fbc179c Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Wed, 19 Aug 2026 12:39:24 +0530 Subject: [PATCH 100/107] chore: update reminder amind reference file (#869) --- reference/admin.yaml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index c1ad2f953..ef8adcf63 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -24536,6 +24536,14 @@ components: pattern: ^[1-7](?:,[1-7])*$ example: 1,3,5 description: comma-separated day numbers (e.g. "1,3,5" for mon,wed,fri) + week: + oneOf: + - type: number + example: 2 + description: Week of the month (number, e.g. 2) + - type: string + example: '*/1' + description: cron expression (e.g. '*/1' for every week, '*/2' for every alternate week) hour: type: number example: 22 @@ -24632,7 +24640,6 @@ components: - message - schedule_config - add_to_calendar - - send_mobile_notification - receiver_user_ids properties: id: From a3c696151809a119c156edfdd72c05b446a1dadb Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Mon, 24 Aug 2026 15:50:39 +0530 Subject: [PATCH 101/107] fix: update schema (#870) --- reference/admin.yaml | 93 +++++++++++++++---- .../admin@statements@archived_cards.yaml | 4 +- ...admin@statements@missing_transactions.yaml | 4 +- ...min@statements@reconciliation_summary.yaml | 4 +- .../paths/admin@statements@rtf_stats.yaml | 4 +- .../admin@statements@suggest_mappings.yaml | 4 +- .../schemas/statement_mappings.yaml | 26 +++++- src/components/schemas/statements.yaml | 53 +++++++++-- 8 files changed, 148 insertions(+), 44 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index ef8adcf63..1d5996882 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -12539,9 +12539,7 @@ paths: offset: $ref: '#/components/schemas/offset' data: - type: object - items: - $ref: '#/components/schemas/statement_mappings_suggest_out' + $ref: '#/components/schemas/statement_mappings_suggest_out' '400': description: Bad request content: @@ -12702,9 +12700,7 @@ paths: - data properties: data: - type: array - items: - $ref: '#/components/schemas/reconciliation_summary_out' + $ref: '#/components/schemas/reconciliation_summary_out' '400': description: Bad request content: @@ -13022,9 +13018,7 @@ paths: - data properties: data: - type: object - items: - $ref: '#/components/schemas/rtf_missing_transaction_from_statement_out' + $ref: '#/components/schemas/rtf_missing_transaction_from_statement_out' '400': description: Bad Request content: @@ -13103,9 +13097,7 @@ paths: - data properties: data: - type: object - items: - $ref: '#/components/schemas/rtf_stats_out' + $ref: '#/components/schemas/rtf_stats_out' '400': description: Bad request content: @@ -13160,9 +13152,7 @@ paths: - data properties: data: - type: array - items: - $ref: '#/components/schemas/statement_archived_cards_out' + $ref: '#/components/schemas/statement_archived_cards_out' '400': description: Bad request content: @@ -33202,6 +33192,9 @@ components: type: array items: type: object + required: + - ids + - duplicate_line_item_statement_id properties: ids: type: array @@ -33385,30 +33378,34 @@ components: additionalProperties: false properties: id: - allOf: - - $ref: '#/components/schemas/id_string' + type: string + nullable: true example: stmpwownwrng bank_name: type: string description: | Specifies the bank name of the statement. example: American Express + nullable: true is_debit_positive: type: boolean description: | Specifies the representation of the the amount in the statement, if true then the amount represented by positive sign are debits, and if false then the amount represented by negative sign are debits. example: true + nullable: true transaction_date_column: type: string description: | Specifies the header name of the transaction date column in the statement. example: spent date + nullable: true merchant_column: type: string description: | Specifies the header name of the merchant column in the statement. example: merchant + nullable: true transaction_id_column: type: string description: | @@ -33420,11 +33417,13 @@ components: description: | Specifies the header name of the amount column in the statement. example: amount + nullable: true name: type: string description: | Specifies the mapping name. example: amex_mapping + nullable: true card_number_column: type: string description: | @@ -33465,6 +33464,17 @@ components: Specifies the credit card network used by the card example: VISA nullable: true + org_id: + type: string + nullable: true + created_at: + type: string + format: date-time + nullable: true + updated_at: + type: string + format: date-time + nullable: true required: - id - bank_name @@ -33481,6 +33491,9 @@ components: - post_date_column - is_auto_created - card_network + - org_id + - created_at + - updated_at preview_from_statement_in: type: object properties: @@ -34322,7 +34335,7 @@ components: Card network of the statement if the statement has atleast one card enrolled in RTF. example: VISA nullable: true - missing_corporate_card_details: + corporate_card_details: type: array items: type: object @@ -34356,6 +34369,7 @@ components: - missing_transactions_count - is_rtf_statement - rtf_card_network + - corporate_card_details matching_cards_out: type: object required: @@ -34371,6 +34385,14 @@ components: type: array items: type: object + required: + - id + - card_number + - is_visa_enrolled + - is_mastercard_enrolled + - nickname + - user + - is_archived properties: id: allOf: @@ -34397,6 +34419,11 @@ components: example: Business Card user: $ref: '#/components/schemas/user_out_embed_nullable' + is_archived: + type: boolean + description: | + If the card is archived in Sage Exp Mgmt + nullable: false rtf_missing_transaction_from_statement_out: type: object required: @@ -34417,9 +34444,24 @@ components: type: array items: type: object + required: + - amount + - bank_name + - card_number + - currency + - description + - foreign_amount + - foreign_currency + - merchant + - post_date + - statement_line_item_id + - transaction_date + - transaction_id + - transaction_type + - unique_id properties: amount: - type: number + type: string description: | Specifies the amount on the statement. example: 30 @@ -34653,9 +34695,13 @@ components: - rtf_confidence properties: last_uploaded_at: - $ref: '#/components/schemas/timestamptz_utc' + oneOf: + - $ref: '#/components/schemas/timestamptz_utc' + - type: string + maxLength: 0 description: | Timestamp of the last uploaded statement. + Either a date-time string or an empty string. rtf_confidence: type: string description: | @@ -34794,6 +34840,13 @@ components: type: array items: type: object + required: + - id + - card_number + - nickname + - user + - is_archived + - archived_at properties: id: allOf: diff --git a/src/admin/paths/admin@statements@archived_cards.yaml b/src/admin/paths/admin@statements@archived_cards.yaml index 09083e129..0057464d6 100644 --- a/src/admin/paths/admin@statements@archived_cards.yaml +++ b/src/admin/paths/admin@statements@archived_cards.yaml @@ -27,9 +27,7 @@ post: - data properties: data: - type: array - items: - $ref: '../../components/schemas/statements.yaml#/statement_archived_cards_out' + $ref: '../../components/schemas/statements.yaml#/statement_archived_cards_out' '400': description: Bad request content: diff --git a/src/admin/paths/admin@statements@missing_transactions.yaml b/src/admin/paths/admin@statements@missing_transactions.yaml index 75599a535..e040f7c39 100644 --- a/src/admin/paths/admin@statements@missing_transactions.yaml +++ b/src/admin/paths/admin@statements@missing_transactions.yaml @@ -66,9 +66,7 @@ get: - data properties: data: - type: object - items: - $ref: ../../components/schemas/statements.yaml#/rtf_missing_transaction_from_statement_out + $ref: ../../components/schemas/statements.yaml#/rtf_missing_transaction_from_statement_out '400': description: Bad Request content: diff --git a/src/admin/paths/admin@statements@reconciliation_summary.yaml b/src/admin/paths/admin@statements@reconciliation_summary.yaml index f6b325be4..720d339d1 100644 --- a/src/admin/paths/admin@statements@reconciliation_summary.yaml +++ b/src/admin/paths/admin@statements@reconciliation_summary.yaml @@ -27,9 +27,7 @@ post: - data properties: data: - type: array - items: - $ref: '../../components/schemas/statements.yaml#/reconciliation_summary_out' + $ref: '../../components/schemas/statements.yaml#/reconciliation_summary_out' '400': description: Bad request content: diff --git a/src/admin/paths/admin@statements@rtf_stats.yaml b/src/admin/paths/admin@statements@rtf_stats.yaml index 27bc34c6e..dc047fda3 100644 --- a/src/admin/paths/admin@statements@rtf_stats.yaml +++ b/src/admin/paths/admin@statements@rtf_stats.yaml @@ -17,9 +17,7 @@ get: - data properties: data: - type: object - items: - $ref: ../../components/schemas/statements.yaml#/rtf_stats_out + $ref: ../../components/schemas/statements.yaml#/rtf_stats_out '400': description: Bad request content: diff --git a/src/admin/paths/admin@statements@suggest_mappings.yaml b/src/admin/paths/admin@statements@suggest_mappings.yaml index 145589db5..c75dad7b8 100644 --- a/src/admin/paths/admin@statements@suggest_mappings.yaml +++ b/src/admin/paths/admin@statements@suggest_mappings.yaml @@ -39,9 +39,7 @@ post: offset: $ref: '../../components/schemas/offset.yaml' data: - type: object - items: - $ref: '../../components/schemas/statement_mappings.yaml#/statement_mappings_suggest_out' + $ref: '../../components/schemas/statement_mappings.yaml#/statement_mappings_suggest_out' '400': description: Bad request content: diff --git a/src/components/schemas/statement_mappings.yaml b/src/components/schemas/statement_mappings.yaml index 85c914c96..26de233c5 100644 --- a/src/components/schemas/statement_mappings.yaml +++ b/src/components/schemas/statement_mappings.yaml @@ -114,30 +114,34 @@ statement_mappings_suggest_out: additionalProperties: False properties: id: - allOf: - - $ref: './fields.yaml#/id_string' + type: string + nullable: true example: stmpwownwrng bank_name: type: string description: | Specifies the bank name of the statement. example: American Express + nullable: true is_debit_positive: type: boolean description: | Specifies the representation of the the amount in the statement, if true then the amount represented by positive sign are debits, and if false then the amount represented by negative sign are debits. example: true + nullable: true transaction_date_column: type: string description: | Specifies the header name of the transaction date column in the statement. example: spent date + nullable: true merchant_column: type: string description: | Specifies the header name of the merchant column in the statement. example: merchant + nullable: true transaction_id_column: type: string description: | @@ -149,11 +153,13 @@ statement_mappings_suggest_out: description: | Specifies the header name of the amount column in the statement. example: amount + nullable: true name: type: string description: | Specifies the mapping name. example: amex_mapping + nullable: true card_number_column: type: string description: | @@ -194,6 +200,17 @@ statement_mappings_suggest_out: Specifies the credit card network used by the card example: VISA nullable: true + org_id: + type: string + nullable: true + created_at: + type: string + format: date-time + nullable: true + updated_at: + type: string + format: date-time + nullable: true required: - id - bank_name @@ -209,4 +226,7 @@ statement_mappings_suggest_out: - description_column - post_date_column - is_auto_created - - card_network \ No newline at end of file + - card_network + - org_id + - created_at + - updated_at \ No newline at end of file diff --git a/src/components/schemas/statements.yaml b/src/components/schemas/statements.yaml index b22010bc4..c887d99c3 100644 --- a/src/components/schemas/statements.yaml +++ b/src/components/schemas/statements.yaml @@ -94,6 +94,9 @@ statements_out: type: array items: type: object + required: + - ids + - duplicate_line_item_statement_id properties: ids: type: array @@ -934,9 +937,24 @@ rtf_missing_transaction_from_statement_out: type: array items: type: object + required: + - amount + - bank_name + - card_number + - currency + - description + - foreign_amount + - foreign_currency + - merchant + - post_date + - statement_line_item_id + - transaction_date + - transaction_id + - transaction_type + - unique_id properties: amount: - type: number + type: string description: | Specifies the amount on the statement. example: 30 @@ -1041,9 +1059,13 @@ rtf_stats_out: - rtf_confidence properties: last_uploaded_at: - $ref: './fields.yaml#/timestamptz_utc' + oneOf: + - $ref: './fields.yaml#/timestamptz_utc' + - type: string + maxLength: 0 description: | Timestamp of the last uploaded statement. + Either a date-time string or an empty string. rtf_confidence: type: string description: | @@ -1264,7 +1286,7 @@ card_stats_out: Card network of the statement if the statement has atleast one card enrolled in RTF. example: VISA nullable: true - missing_corporate_card_details: + corporate_card_details: type: array items: type: object @@ -1298,6 +1320,7 @@ card_stats_out: - missing_transactions_count - is_rtf_statement - rtf_card_network + - corporate_card_details matching_cards_out: type: object required: @@ -1312,8 +1335,15 @@ matching_cards_out: matching_cards: type: array items: - type: - object + type: object + required: + - id + - card_number + - is_visa_enrolled + - is_mastercard_enrolled + - nickname + - user + - is_archived properties: id: allOf: @@ -1340,7 +1370,11 @@ matching_cards_out: example: 'Business Card' user: $ref: ./user.yaml#/user_out_embed_nullable - + is_archived: + type: boolean + description: | + If the card is archived in Sage Exp Mgmt + nullable: false unassigned_cards_from_statement_in: type: object properties: @@ -1373,6 +1407,13 @@ statement_archived_cards_out: type: array items: type: object + required: + - id + - card_number + - nickname + - user + - is_archived + - archived_at properties: id: allOf: From 400fadbbe5fc726f550a341a9d0df74994475a27 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Tue, 25 Aug 2026 17:06:09 +0530 Subject: [PATCH 102/107] fix: update schema (#872) --- reference/admin.yaml | 44 +++++++++++++++++----- src/components/schemas/spend_overview.yaml | 14 +++++++ src/components/schemas/statements.yaml | 30 ++++++++++----- 3 files changed, 68 insertions(+), 20 deletions(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 1d5996882..2b8100d69 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -30942,6 +30942,8 @@ components: - card_holder_name - card_nickname - user_id + - user_full_name + - user_email - amount - percentage - change_percentage @@ -30971,6 +30973,18 @@ components: description: | This id provided by Sage Exp Mgmt to identify a user. This can be null if the corporate card is not assigned to any user. example: sdfd2391 + user_full_name: + type: string + nullable: true + description: | + Full name of the user assigned to the corporate card. Can be null if card is not assigned. + example: John Doe + user_email: + type: string + nullable: true + description: | + Email of the user assigned to the corporate card. Can be null if card is not assigned. + example: john.doe@example.com amount: $ref: '#/components/schemas/amount' percentage: @@ -33504,6 +33518,12 @@ components: statement_mapping: type: object properties: + id: + type: string + nullable: true + description: | + Specifies the id of the statement mapping. + example: stmpabcd1234 description_column: type: string description: | @@ -33578,19 +33598,12 @@ components: example: VISA nullable: true required: - - description_column - transaction_date_column - - transaction_id_column - amount_column - card_number_column - merchant_column - - foreign_amount_column - - foreign_currency_column - - post_date_column - bank_name - is_debit_positive - - name - - card_network ignored_line_item_ids: type: array items: @@ -33604,10 +33617,17 @@ components: description: | Card number from statement can be passed to get transactions only from specific card example: xxx5-4543 + start_date: + $ref: '#/components/schemas/timestamptz_utc' + description: | + Start date of the statement period + end_date: + $ref: '#/components/schemas/timestamptz_utc' + description: | + End date of the statement period required: - id - statement_mapping - - ignored_line_item_ids preview_out: properties: no_of_debit: @@ -34060,6 +34080,12 @@ components: statement_mapping: type: object properties: + id: + type: string + nullable: true + description: | + Specifies the id of the statement mapping. + example: stmpabcd1234 description_column: type: string description: | @@ -34152,12 +34178,10 @@ components: $ref: '#/components/schemas/timestamptz_utc' description: | Start date of the statement period - nullable: true end_date: $ref: '#/components/schemas/timestamptz_utc' description: | End date of the statement period - nullable: true card_mapping: $ref: '#/components/schemas/card_mapping_in' reconciliation_method: diff --git a/src/components/schemas/spend_overview.yaml b/src/components/schemas/spend_overview.yaml index 163a1798a..939a8af83 100644 --- a/src/components/schemas/spend_overview.yaml +++ b/src/components/schemas/spend_overview.yaml @@ -131,6 +131,8 @@ spend_overview_by_corporate_card_data_out: - card_holder_name - card_nickname - user_id + - user_full_name + - user_email - amount - percentage - change_percentage @@ -160,6 +162,18 @@ spend_overview_by_corporate_card_data_out: description: | This id provided by Sage Exp Mgmt to identify a user. This can be null if the corporate card is not assigned to any user. example: 'sdfd2391' + user_full_name: + type: string + nullable: true + description: | + Full name of the user assigned to the corporate card. Can be null if card is not assigned. + example: John Doe + user_email: + type: string + nullable: true + description: | + Email of the user assigned to the corporate card. Can be null if card is not assigned. + example: john.doe@example.com amount: $ref: './fields.yaml#/amount' percentage: diff --git a/src/components/schemas/statements.yaml b/src/components/schemas/statements.yaml index c887d99c3..b05bc384d 100644 --- a/src/components/schemas/statements.yaml +++ b/src/components/schemas/statements.yaml @@ -288,6 +288,12 @@ preview_from_statement_in: statement_mapping: type: object properties: + id: + type: string + nullable: true + description: | + Specifies the id of the statement mapping. + example: stmpabcd1234 description_column: type: string description: | @@ -362,19 +368,12 @@ preview_from_statement_in: example: VISA nullable: true required: - - description_column - transaction_date_column - - transaction_id_column - amount_column - card_number_column - merchant_column - - foreign_amount_column - - foreign_currency_column - - post_date_column - bank_name - is_debit_positive - - name - - card_network ignored_line_item_ids: type: array items: @@ -388,10 +387,17 @@ preview_from_statement_in: description: | Card number from statement can be passed to get transactions only from specific card example: xxx5-4543 + start_date: + $ref: './fields.yaml#/timestamptz_utc' + description: | + Start date of the statement period + end_date: + $ref: './fields.yaml#/timestamptz_utc' + description: | + End date of the statement period required: - id - statement_mapping - - ignored_line_item_ids summary_from_statement_in: type: object @@ -789,6 +795,12 @@ reconcile_from_statement_in: statement_mapping: type: object properties: + id: + type: string + nullable: true + description: | + Specifies the id of the statement mapping. + example: stmpabcd1234 description_column: type: string description: | @@ -881,12 +893,10 @@ reconcile_from_statement_in: $ref: './fields.yaml#/timestamptz_utc' description: | Start date of the statement period - nullable: true end_date: $ref: './fields.yaml#/timestamptz_utc' description: | End date of the statement period - nullable: true card_mapping: $ref: '#/card_mapping_in' reconciliation_method: From 9db126169e0a9563cc6063e17f0637898534a31d Mon Sep 17 00:00:00 2001 From: Madan Gopal Date: Fri, 28 Aug 2026 20:44:35 +0530 Subject: [PATCH 103/107] feat: Add spender corporate cards rtf monthly enrollment usage api spec (#871) * feat: Add spender corporate cards rtf monthly enrollment usage api spec * Auto generate API docs --------- Co-authored-by: Madan Gopal --- reference/spender.yaml | 63 +++++++++++++++++++ src/components/schemas/corporate_card.yaml | 25 ++++++++ src/spender/openapi.yaml | 2 + ...te_cards@rtf_monthly_enrollment_usage.yaml | 39 ++++++++++++ 4 files changed, 129 insertions(+) create mode 100644 src/spender/paths/spender@corporate_cards@rtf_monthly_enrollment_usage.yaml diff --git a/reference/spender.yaml b/reference/spender.yaml index d8b8021a0..b954f87a1 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -2632,6 +2632,46 @@ paths: application/json: schema: $ref: '#/components/schemas/401' + /spender/corporate_cards/rtf_monthly_enrollment_usage: + get: + tags: + - Corporate Cards + summary: Get RTF monthly enrollment usage + description: | + This API returns the spender's current-month RTF corporate card enrollment usage, + including the number of cards enrolled, the configured monthly limit, and whether the limit has been reached. + operationId: corporate_cards_rtf_monthly_enrollment_usage + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '#/components/schemas/corporate_card_rtf_monthly_enrollment_usage_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/400' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '#/components/schemas/401' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/403' /spender/corporate_card_transactions: get: tags: @@ -13819,6 +13859,29 @@ components: - created_at - updated_at - corporate_card_id + corporate_card_rtf_monthly_enrollment_usage_out: + type: object + properties: + monthly_limit: + type: integer + default: 3 + description: | + The monthly limit for the RTF card enrollment usage. + example: 3 + enrolled_cards: + type: integer + description: | + The number of RTF cards enrolled in the current month. + example: 1 + is_limit_reached: + type: boolean + description: | + Indicates whether the monthly limit for RTF card enrollment usage has been reached. + example: false + required: + - monthly_limit + - enrolled_cards + - is_limit_reached string_detail: type: string description: Additional string details of the card transaction. Can hold details upto 256 characters in length. diff --git a/src/components/schemas/corporate_card.yaml b/src/components/schemas/corporate_card.yaml index 17f7754b1..fd6c2d3f4 100644 --- a/src/components/schemas/corporate_card.yaml +++ b/src/components/schemas/corporate_card.yaml @@ -955,3 +955,28 @@ corporate_card_archive_suggestion_dismiss_in: The ID of the archive suggestion to be dismissed required: - id + + +corporate_card_rtf_monthly_enrollment_usage_out: + type: object + properties: + monthly_limit: + type: integer + default: 3 + description: | + The monthly limit for the RTF card enrollment usage. + example: 3 + enrolled_cards: + type: integer + description: | + The number of RTF cards enrolled in the current month. + example: 1 + is_limit_reached: + type: boolean + description: | + Indicates whether the monthly limit for RTF card enrollment usage has been reached. + example: false + required: + - monthly_limit + - enrolled_cards + - is_limit_reached diff --git a/src/spender/openapi.yaml b/src/spender/openapi.yaml index ed6b41066..cfd945682 100644 --- a/src/spender/openapi.yaml +++ b/src/spender/openapi.yaml @@ -203,6 +203,8 @@ paths: $ref: paths/spender@corporate_cards.yaml /spender/corporate_cards/yodlee_accounts: $ref: paths/spender@corporate_cards@yodlee_accounts.yaml + /spender/corporate_cards/rtf_monthly_enrollment_usage: + $ref: paths/spender@corporate_cards@rtf_monthly_enrollment_usage.yaml /spender/corporate_card_transactions: $ref: paths/spender@corporate_card_transactions.yaml /spender/corporate_card_transactions/expenses/stats: diff --git a/src/spender/paths/spender@corporate_cards@rtf_monthly_enrollment_usage.yaml b/src/spender/paths/spender@corporate_cards@rtf_monthly_enrollment_usage.yaml new file mode 100644 index 000000000..8966ad16e --- /dev/null +++ b/src/spender/paths/spender@corporate_cards@rtf_monthly_enrollment_usage.yaml @@ -0,0 +1,39 @@ +get: + tags: + - Corporate Cards + summary: Get RTF monthly enrollment usage + description: | + This API returns the spender's current-month RTF corporate card enrollment usage, + including the number of cards enrolled, the configured monthly limit, and whether the limit has been reached. + operationId: corporate_cards_rtf_monthly_enrollment_usage + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + $ref: '../../components/schemas/corporate_card.yaml#/corporate_card_rtf_monthly_enrollment_usage_out' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '../../components/schemas/400.yaml' + '401': + description: Unauthorized request + content: + application/json: + schema: + $ref: '../../components/schemas/401.yaml' + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '../../components/schemas/403.yaml' From 24d8d85c8eaa4f9e9c3ca2b5d0a0c8067a225eeb Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Tue, 1 Sep 2026 12:58:59 +0530 Subject: [PATCH 104/107] feat: update any_type schema (#874) * feat: update any_type schema * Auto generate API docs --- reference/admin.yaml | 2 ++ reference/spender.yaml | 2 ++ src/components/schemas/fields.yaml | 2 ++ 3 files changed, 6 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 2b8100d69..12bb86312 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -35652,6 +35652,8 @@ components: items: $ref: '#/components/schemas/any_type' - type: object + additionalProperties: + $ref: '#/components/schemas/any_type' feature_config_out: type: object additionalProperties: false diff --git a/reference/spender.yaml b/reference/spender.yaml index b954f87a1..98647d410 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -19738,6 +19738,8 @@ components: items: $ref: '#/components/schemas/any_type' - type: object + additionalProperties: + $ref: '#/components/schemas/any_type' feature_config_out: type: object additionalProperties: false diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index b6beb7876..c13a7889e 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1898,6 +1898,8 @@ any_type: items: $ref: './fields.yaml#/any_type' - type: object + additionalProperties: + $ref: '#/components/schemas/any_type' commute_location: type: object From c2190785846ae9932a69448290d629f4fc982dc5 Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Tue, 1 Sep 2026 13:31:49 +0530 Subject: [PATCH 105/107] feat: Update any type schema to include unknown (#875) * wip * Auto generate API docs --- reference/admin.yaml | 1 + reference/spender.yaml | 1 + src/components/schemas/fields.yaml | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/reference/admin.yaml b/reference/admin.yaml index 12bb86312..0cd120834 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -35654,6 +35654,7 @@ components: - type: object additionalProperties: $ref: '#/components/schemas/any_type' + - {} feature_config_out: type: object additionalProperties: false diff --git a/reference/spender.yaml b/reference/spender.yaml index 98647d410..443636b1d 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -19740,6 +19740,7 @@ components: - type: object additionalProperties: $ref: '#/components/schemas/any_type' + - {} feature_config_out: type: object additionalProperties: false diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index c13a7889e..f748ee618 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1900,7 +1900,7 @@ any_type: - type: object additionalProperties: $ref: '#/components/schemas/any_type' - + - {} commute_location: type: object nullable: true From fe127d8e6b7ccd554684c4b1b911fd8856086948 Mon Sep 17 00:00:00 2001 From: Aniruddha Shriwant Date: Thu, 3 Sep 2026 10:21:37 +0530 Subject: [PATCH 106/107] chore: add dummy common operation (#879) --- reference/common.yaml | 29 +++++++++++++++++++++++++++++ src/common/openapi.yaml | 5 +++++ src/common/paths/common@dummy.yaml | 25 +++++++++++++++++++++++++ 3 files changed, 59 insertions(+) create mode 100644 src/common/paths/common@dummy.yaml diff --git a/reference/common.yaml b/reference/common.yaml index e4ca01c8b..3c1925f3c 100644 --- a/reference/common.yaml +++ b/reference/common.yaml @@ -16,10 +16,39 @@ tags: - name: Currencies description: | These APIs gives you list of currencies supported by Sage Exp Mgmt and their exchange rates. + - name: Miscellaneous + description: | + General common operations. - name: Places description: | These APIs gives the places suggestions and geographic data of a place. paths: + /common/dummy: + get: + tags: + - Miscellaneous + security: [] + x-internal: true + summary: Get dummy data + description: | + Returns a dummy response. + operationId: common_dummy_get + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: object + additionalProperties: false + '404': + description: Resource not found /common/places/autocomplete: get: tags: diff --git a/src/common/openapi.yaml b/src/common/openapi.yaml index 4d8aa455c..c766f2ecc 100644 --- a/src/common/openapi.yaml +++ b/src/common/openapi.yaml @@ -27,6 +27,9 @@ tags: - name: Currencies description: | These APIs gives you list of currencies supported by Sage Exp Mgmt and their exchange rates. + - name: Miscellaneous + description: | + General common operations. # - name: Data Extraction # description: | # These APIs gives the expense relevant data from the reciepts. @@ -35,6 +38,8 @@ tags: These APIs gives the places suggestions and geographic data of a place. paths: + /common/dummy: + $ref: 'paths/common@dummy.yaml' /common/places/autocomplete: $ref: 'paths/common@places@autocomplete.yaml' /common/places: diff --git a/src/common/paths/common@dummy.yaml b/src/common/paths/common@dummy.yaml new file mode 100644 index 000000000..5ad9e4e96 --- /dev/null +++ b/src/common/paths/common@dummy.yaml @@ -0,0 +1,25 @@ +get: + tags: + - Miscellaneous + security: [] + x-internal: true + summary: Get dummy data + description: | + Returns a dummy response. + operationId: common_dummy_get + responses: + '200': + description: OK + content: + application/json: + schema: + type: object + additionalProperties: false + required: + - data + properties: + data: + type: object + additionalProperties: false + '404': + description: Resource not found From d2da7a9f558707b351851cb0e868a7af597e998e Mon Sep 17 00:00:00 2001 From: Aditya Baddur Date: Thu, 3 Sep 2026 12:58:00 +0530 Subject: [PATCH 107/107] feat:update required fields for delegatees schema (#880) --- reference/admin.yaml | 8 ++++++++ reference/approver.yaml | 8 ++++++++ reference/manager.yaml | 8 ++++++++ reference/spender.yaml | 8 ++++++++ src/components/schemas/fields.yaml | 8 ++++++++ 5 files changed, 40 insertions(+) diff --git a/reference/admin.yaml b/reference/admin.yaml index 0cd120834..5326d394e 100644 --- a/reference/admin.yaml +++ b/reference/admin.yaml @@ -18622,6 +18622,14 @@ components: delegatees: type: object additionalProperties: false + required: + - id + - type + - user_id + - email + - full_name + - start_at + - scopes properties: id: allOf: diff --git a/reference/approver.yaml b/reference/approver.yaml index 45a898ed0..d06432234 100644 --- a/reference/approver.yaml +++ b/reference/approver.yaml @@ -10902,6 +10902,14 @@ components: delegatees: type: object additionalProperties: false + required: + - id + - type + - user_id + - email + - full_name + - start_at + - scopes properties: id: allOf: diff --git a/reference/manager.yaml b/reference/manager.yaml index fa1b6f47e..5a8677c34 100644 --- a/reference/manager.yaml +++ b/reference/manager.yaml @@ -1732,6 +1732,14 @@ components: delegatees: type: object additionalProperties: false + required: + - id + - type + - user_id + - email + - full_name + - start_at + - scopes properties: id: allOf: diff --git a/reference/spender.yaml b/reference/spender.yaml index 443636b1d..acfb3fc6d 100644 --- a/reference/spender.yaml +++ b/reference/spender.yaml @@ -15832,6 +15832,14 @@ components: delegatees: type: object additionalProperties: false + required: + - id + - type + - user_id + - email + - full_name + - start_at + - scopes properties: id: allOf: diff --git a/src/components/schemas/fields.yaml b/src/components/schemas/fields.yaml index f748ee618..77526d3de 100644 --- a/src/components/schemas/fields.yaml +++ b/src/components/schemas/fields.yaml @@ -1688,6 +1688,14 @@ ach_transfer_state: delegatees: type: object additionalProperties: False + required: + - id + - type + - user_id + - email + - full_name + - start_at + - scopes properties: id: allOf: