diff --git a/idn/sailpoint-api.v3.yaml b/idn/sailpoint-api.v3.yaml index dac21cb..5256acd 100644 --- a/idn/sailpoint-api.v3.yaml +++ b/idn/sailpoint-api.v3.yaml @@ -874,6 +874,14 @@ paths: $ref: "./v3/paths/sod-violations-check.yaml" /sod-violations/config: $ref: "./v3/paths/sod-violations-config.yaml" + /sod-violation-report/run: + $ref: './v3/paths/sod-all-report-run.yaml' + /sod-violation-report: + $ref: './v3/paths/sod-all-report-status.yaml' + /sod-violation-report/{reportResultId}/download: + $ref: './v3/paths/sod-download-default-report.yaml' + /sod-violation-report/{reportResultId}/download/{fileName}: + $ref: './v3/paths/sod-download-custom-report.yaml' /sources: $ref: "./v3/paths/sources.yaml" /sources/{id}: diff --git a/idn/v3/paths/sod-all-report-run.yaml b/idn/v3/paths/sod-all-report-run.yaml new file mode 100644 index 0000000..819b40f --- /dev/null +++ b/idn/v3/paths/sod-all-report-run.yaml @@ -0,0 +1,45 @@ +post: + security: + - oauth2: [idn:sod-violation:write] + operationId: startSodAllPoliciesForOrg + tags: + - SOD Policy + summary: Runs all policies for org + description: >- + Runs multi-policy report for the org. If a policy reports more than 5000 violations, the report mentions that the violation limit was exceeded for that policy. + If the request is empty, the report runs for all policies. Otherwise, the report runs for only the filtered policy list provided. + requestBody: + required: false + content: + application/json: + schema: + $ref: '../schemas/MultiPolicyRequest.yaml' + example: { + "filteredPolicyList": [ + "b868cd40-ffa4-4337-9c07-1a51846cfa94", + "63a07a7b-39a4-48aa-956d-50c827deba2a" + ] + } + responses: + '200': + description: Reference to the violation report run task. + content: + application/json: + schema: + $ref: '../schemas/ReportResultReference.yaml' + example: { + "status": "PENDING", + "type": "REPORT_RESULT", + "id": "37b3b32a-f394-46f8-acad-b5223969fa68", + "name": "Multi Query Report" + } + '400': + $ref: '../responses/400.yaml' + '401': + $ref: '../responses/401.yaml' + '403': + $ref: '../responses/403.yaml' + '429': + $ref: '../responses/429.yaml' + '500': + $ref: '../responses/500.yaml' diff --git a/idn/v3/paths/sod-all-report-status.yaml b/idn/v3/paths/sod-all-report-status.yaml new file mode 100644 index 0000000..4636c6f --- /dev/null +++ b/idn/v3/paths/sod-all-report-status.yaml @@ -0,0 +1,32 @@ +get: + security: + - oauth2: [idn:sod-violation:read] + operationId: getSodAllReportRunStatus + tags: + - SOD Policy + summary: Get multi-report run task status + description: >- + This endpoint gets the status for a violation report for all policy run. + responses: + '200': + description: Status of the violation report run task for all policy run. + content: + application/json: + schema: + $ref: '../schemas/ReportResultReference.yaml' + example: { + "status": "SUCCESS", + "type": "REPORT_RESULT", + "id": "37b3b32a-f394-46f8-acad-b5223969fa68", + "name": "Multi Query Report" + } + '400': + $ref: '../responses/400.yaml' + '401': + $ref: '../responses/401.yaml' + '403': + $ref: '../responses/403.yaml' + '429': + $ref: '../responses/429.yaml' + '500': + $ref: '../responses/500.yaml' diff --git a/idn/v3/paths/sod-download-custom-report.yaml b/idn/v3/paths/sod-download-custom-report.yaml new file mode 100644 index 0000000..9d1823b --- /dev/null +++ b/idn/v3/paths/sod-download-custom-report.yaml @@ -0,0 +1,44 @@ +get: + security: + - oauth2: [idn:sod-violation:read] + operationId: getCustomViolationReport + tags: + - SOD Policy + summary: Download custom violation report + description: >- + This allows to download a specified named violation report for a given report reference. + parameters: + - in: path + name: reportResultId + schema: + type: string + required: true + description: The ID of the report reference to download. + example: ef38f94347e94562b5bb8424a56397d8 + - in: path + name: fileName + schema: + type: string + required: true + description: Custom Name for the file. + example: custom-name + responses: + '200': + description: Returns the zip file with given custom name that contains the violation report file. + content: + application/zip: + schema: + type: string + format: binary + '400': + $ref: '../responses/400.yaml' + '401': + $ref: '../responses/401.yaml' + '403': + $ref: '../responses/403.yaml' + '404': + $ref: '../responses/404.yaml' + '429': + $ref: '../responses/429.yaml' + '500': + $ref: '../responses/500.yaml' diff --git a/idn/v3/paths/sod-download-default-report.yaml b/idn/v3/paths/sod-download-default-report.yaml new file mode 100644 index 0000000..3d137c2 --- /dev/null +++ b/idn/v3/paths/sod-download-default-report.yaml @@ -0,0 +1,37 @@ +get: + security: + - oauth2: [idn:sod-violation:read] + operationId: getDefaultViolationReport + tags: + - SOD Policy + summary: Download violation report + description: >- + This allows to download a violation report for a given report reference. + parameters: + - in: path + name: reportResultId + schema: + type: string + required: true + description: The ID of the report reference to download. + example: ef38f94347e94562b5bb8424a56397d8 + responses: + '200': + description: Returns the PolicyReport.zip that contains the violation report file. + content: + application/zip: + schema: + type: string + format: binary + '400': + $ref: '../responses/400.yaml' + '401': + $ref: '../responses/401.yaml' + '403': + $ref: '../responses/403.yaml' + '404': + $ref: '../responses/404.yaml' + '429': + $ref: '../responses/429.yaml' + '500': + $ref: '../responses/500.yaml' diff --git a/idn/v3/schemas/MultiPolicyRequest.yaml b/idn/v3/schemas/MultiPolicyRequest.yaml new file mode 100644 index 0000000..4af2671 --- /dev/null +++ b/idn/v3/schemas/MultiPolicyRequest.yaml @@ -0,0 +1,11 @@ +type: object +properties: + filteredPolicyList: + type: array + description: Multi-policy report will be run for this list of ids + items: + type: string + example: [ + "b868cd40-ffa4-4337-9c07-1a51846cfa94", + "63a07a7b-39a4-48aa-956d-50c827deba2a" + ]