openapi: 3.0.3 info: title: Snyk AccessRequests Audit Logs API version: REST servers: - description: Snyk REST API url: https://api.snyk.io/rest security: - APIToken: [] - BearerAuth: [] tags: - name: Audit Logs paths: /groups/{group_id}/audit_logs/search: get: description: "Search audit logs for a Group. \"api.access\" events are omitted from results unless explicitly requested using the events parameter. Some Organization level events are supported as well as the following\nGroup level events:\n - api.access\n - group.cloud_config.settings.edit\n - group.create\n - group.delete\n - group.edit\n - group.notification_settings.edit\n - group.org.add\n - group.org.remove\n - group.policy.create\n - group.policy.delete\n - group.policy.edit\n - group.request_access_settings.edit\n - group.role.create\n - group.role.delete\n - group.role.edit\n - group.service_account.create\n - group.service_account.delete\n - group.service_account.edit\n - group.settings.edit\n - group.settings.feature_flag.edit\n - group.sso.add\n - group.sso.auth0_connection.create\n - group.sso.auth0_connection.edit\n - group.sso.create\n - group.sso.delete\n - group.sso.edit\n - group.sso.membership.sync\n - group.sso.remove\n - group.tag.create\n - group.tag.delete\n - group.user.add\n - group.user.remove\n - group.user.role.edit\n\n#### Required permissions\n\n- `View Audit Logs (group.audit.read)`" operationId: listGroupAuditLogs parameters: - $ref: '#/components/parameters/Version' - $ref: '#/components/parameters/GroupId' - $ref: '#/components/parameters/Cursor' - $ref: '#/components/parameters/From' - $ref: '#/components/parameters/To' - $ref: '#/components/parameters/Size' - $ref: '#/components/parameters/SortOrder' - $ref: '#/components/parameters/UserId' - $ref: '#/components/parameters/ProjectId' - $ref: '#/components/parameters/Events' - $ref: '#/components/parameters/ExcludeEvents' responses: '200': content: application/vnd.api+json: schema: additionalProperties: false properties: data: $ref: '#/components/schemas/AuditLogSearch' jsonapi: $ref: '#/components/schemas/JsonApi' links: $ref: '#/components/schemas/Links' required: - jsonapi - data type: object description: Group Audit Logs. headers: deprecation: $ref: '#/components/headers/DeprecationHeader' location: schema: type: string snyk-request-id: $ref: '#/components/headers/RequestIdResponseHeader' snyk-version-lifecycle-stage: $ref: '#/components/headers/VersionStageResponseHeader' snyk-version-requested: $ref: '#/components/headers/VersionRequestedResponseHeader' snyk-version-served: $ref: '#/components/headers/VersionServedResponseHeader' sunset: $ref: '#/components/headers/SunsetHeader' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '500': $ref: '#/components/responses/500' summary: Search Group audit logs. tags: - Audit Logs x-snyk-api-lifecycle: released x-snyk-api-releases: - '2023-09-11' - '2024-04-29' x-snyk-api-resource: audit-logs x-snyk-api-stability: ga x-snyk-api-version: '2024-04-29' x-stability-level: stable /orgs/{org_id}/audit_logs/search: get: description: "Search audit logs for an Organization. \"api.access\" events are omitted from results unless explicitly requested using the events parameter. Supported event types:\n - api.access\n - org.app_bot.create\n - org.app.create\n - org.app.delete\n - org.app.edit\n - org.cloud_config.settings.edit\n - org.collection.create\n - org.collection.delete\n - org.collection.edit\n - org.create\n - org.delete\n - org.edit\n - org.ignore_policy.edit\n - org.integration.create\n - org.integration.delete\n - org.integration.edit\n - org.integration.settings.edit\n - org.language_settings.edit\n - org.notification_settings.edit\n - org.org_source.create\n - org.org_source.delete\n - org.org_source.edit\n - org.policy.create\n - org.policy.edit\n - org.policy.delete\n - org.project_filter.create\n - org.project_filter.delete\n - org.project.add\n - org.project.attributes.edit\n - org.project.delete\n - org.project.edit\n - org.project.fix_pr.auto_open\n - org.project.fix_pr.manual_open\n - org.project.ignore.create\n - org.project.ignore.delete\n - org.project.ignore.edit\n - org.project.monitor\n - org.project.pr_check.edit\n - org.project.remove\n - org.project.settings.delete\n - org.project.settings.edit\n - org.project.stop_monitor\n - org.project.tag.add\n - org.project.tag.remove\n - org.project.test\n - org.request_access_settings.edit\n - org.sast_settings.edit\n - org.service_account.create\n - org.service_account.delete\n - org.service_account.edit\n - org.settings.feature_flag.edit\n - org.target.create\n - org.target.delete\n - org.user.add\n - org.user.invite\n - org.user.invite.accept\n - org.user.invite.revoke\n - org.user.invite_link.accept\n - org.user.invite_link.create\n - org.user.invite_link.revoke\n - org.user.leave\n - org.user.provision.accept\n - org.user.provision.create\n - org.user.provision.delete\n - org.user.remove\n - org.user.role.create\n - org.user.role.delete\n - org.user.role.details.edit\n - org.user.role.edit\n - org.user.role.permissions.edit\n - org.webhook.add\n - org.webhook.delete\n - user.org.notification_settings.edit\n\n#### Required permissions\n\n- `View audit logs (org.audit_log.read)`" operationId: listOrgAuditLogs parameters: - $ref: '#/components/parameters/Version' - $ref: '#/components/parameters/OrgId' - $ref: '#/components/parameters/Cursor' - $ref: '#/components/parameters/From' - $ref: '#/components/parameters/To' - $ref: '#/components/parameters/Size' - $ref: '#/components/parameters/SortOrder' - $ref: '#/components/parameters/UserId' - $ref: '#/components/parameters/ProjectId' - $ref: '#/components/parameters/Events' - $ref: '#/components/parameters/ExcludeEvents' responses: '200': content: application/vnd.api+json: schema: additionalProperties: false properties: data: $ref: '#/components/schemas/AuditLogSearch' jsonapi: $ref: '#/components/schemas/JsonApi' links: $ref: '#/components/schemas/Links' required: - jsonapi - data type: object description: Organization Audit Logs. headers: deprecation: $ref: '#/components/headers/DeprecationHeader' location: schema: type: string snyk-request-id: $ref: '#/components/headers/RequestIdResponseHeader' snyk-version-lifecycle-stage: $ref: '#/components/headers/VersionStageResponseHeader' snyk-version-requested: $ref: '#/components/headers/VersionRequestedResponseHeader' snyk-version-served: $ref: '#/components/headers/VersionServedResponseHeader' sunset: $ref: '#/components/headers/SunsetHeader' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '500': $ref: '#/components/responses/500' summary: Search Organization audit logs. tags: - Audit Logs x-snyk-api-lifecycle: released x-snyk-api-releases: - '2023-09-11' - '2024-04-29' x-snyk-api-resource: audit-logs x-snyk-api-stability: ga x-snyk-api-version: '2024-04-29' x-stability-level: stable components: headers: SunsetHeader: description: 'A header containing the date of when the underlying endpoint will be removed. This header is only present if the endpoint has been deprecated. For information purposes only. Returned as a date in the format: YYYY-MM-DD' example: '2021-08-02' schema: format: date type: string VersionRequestedResponseHeader: description: A header containing the version of the endpoint requested by the caller. example: '2026-03-25' schema: $ref: '#/components/schemas/QueryVersion' VersionServedResponseHeader: description: A header containing the version of the endpoint that was served by the API. example: '2026-03-25' schema: $ref: '#/components/schemas/ActualVersion' VersionStageResponseHeader: description: 'A header containing the version stage of the endpoint. This stage describes the guarantees snyk provides surrounding stability of the endpoint. ' schema: enum: - wip - experimental - beta - ga - deprecated - sunset example: ga type: string RequestIdResponseHeader: description: 'A header containing a unique id used for tracking this request. If you are reporting an issue to Snyk it''s very helpful to provide this ID. ' example: 4b58e274-ec62-4fab-917b-1d2c48d6bdef schema: format: uuid type: string DeprecationHeader: description: 'A header containing the deprecation date of the underlying endpoint. For more information, please refer to the deprecation header RFC: https://tools.ietf.org/id/draft-dalal-deprecation-header-01.html ' example: '2021-07-01T00:00:00Z' schema: format: date-time type: string schemas: ActualVersion: description: Resolved API version example: '2026-03-25' pattern: ^((([0-9]{4})-([0-1][0-9]))-((3[01])|(0[1-9])|([12][0-9]))(~(wip|work-in-progress|experimental|beta))?)$ type: string AuditLogSearch: properties: items: items: properties: content: type: object created: example: '2021-07-01T00:00:00Z' format: date-time type: string event: example: org.create type: string group_id: example: 0d3728ec-eebf-484d-9907-ba238019f10b type: string org_id: example: 0d3728ec-eebf-484d-9907-ba238019f10b type: string project_id: example: 0d3728ec-eebf-484d-9907-ba238019f10b type: string required: - created - event type: object type: array type: type: string type: object JsonApi: additionalProperties: false example: version: '1.0' properties: version: description: Version of the JSON API specification this server supports. example: '1.0' pattern: ^(0|[1-9]\d*)\.(0|[1-9]\d*)$ type: string required: - version type: object QueryVersion: description: Requested API version example: '2026-03-25' pattern: ^(wip|work-in-progress|experimental|beta|((([0-9]{4})-([0-1][0-9]))-((3[01])|(0[1-9])|([12][0-9]))(~(wip|work-in-progress|experimental|beta))?))$ type: string ErrorDocument: additionalProperties: false example: errors: - detail: Permission denied for this resource status: '403' jsonapi: version: '1.0' properties: errors: example: - detail: Permission denied for this resource status: '403' items: additionalProperties: false example: detail: Not Found status: '404' properties: code: description: An application-specific error code, expressed as a string value. example: entity-not-found type: string detail: description: A human-readable explanation specific to this occurrence of the problem. example: 'The request was missing these required fields: ...' type: string id: description: A unique identifier for this particular occurrence of the problem. example: f16c31b5-6129-4571-add8-d589da9be524 format: uuid type: string links: additionalProperties: false description: A link that leads to further details about this particular occurrance of the problem. example: about: https://example.com/about_this_error properties: about: example: https://example.com/api/resource oneOf: - description: A string containing the link’s URL. example: https://example.com/api/resource type: string - additionalProperties: false example: href: https://example.com/api/resource properties: href: description: A string containing the link’s URL. example: https://example.com/api/resource type: string meta: additionalProperties: true description: Free-form object that may contain non-standard information. example: key1: value1 key2: sub_key: sub_value key3: - array_value1 - array_value2 type: object required: - href type: object type: object meta: additionalProperties: true example: key: value type: object source: additionalProperties: false example: pointer: /data/attributes properties: parameter: description: A string indicating which URI query parameter caused the error. example: param1 type: string pointer: description: A JSON Pointer [RFC6901] to the associated entity in the request document. example: /data/attributes type: string type: object status: description: The HTTP status code applicable to this problem, expressed as a string value. example: '400' pattern: ^[45]\d\d$ type: string title: description: A short, human-readable summary of the problem that SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization. example: Bad request type: string required: - status - detail type: object minItems: 1 type: array jsonapi: additionalProperties: false example: version: '1.0' properties: version: description: Version of the JSON API specification this server supports. example: '1.0' pattern: ^(0|[1-9]\d*)\.(0|[1-9]\d*)$ type: string required: - version type: object required: - jsonapi - errors type: object Links: additionalProperties: false properties: first: $ref: '#/components/schemas/LinkProperty' last: $ref: '#/components/schemas/LinkProperty' next: $ref: '#/components/schemas/LinkProperty' prev: $ref: '#/components/schemas/LinkProperty' related: $ref: '#/components/schemas/LinkProperty' self: $ref: '#/components/schemas/LinkProperty' type: object LinkProperty: example: https://example.com/api/resource oneOf: - description: A string containing the link’s URL. example: https://example.com/api/resource type: string - additionalProperties: false example: href: https://example.com/api/resource properties: href: description: A string containing the link’s URL. example: https://example.com/api/resource type: string meta: additionalProperties: true description: Free-form object that may contain non-standard information. example: key1: value1 key2: sub_key: sub_value key3: - array_value1 - array_value2 type: object required: - href type: object parameters: SortOrder: description: Order in which results are returned. example: ASC in: query name: sort_order schema: default: DESC enum: - ASC - DESC type: string Size: description: Number of results to return per page. example: 10 in: query name: size schema: default: 100 format: int32 maximum: 100 minimum: 1 multipleOf: 1 type: integer Cursor: description: The ID for the next page of results. in: query name: cursor schema: type: string UserId: description: Filter logs by user ID. example: 0d3728ec-eebf-484d-9907-ba238019f10b in: query name: user_id schema: format: uuid type: string Version: description: The requested version of the endpoint to process the request example: '2026-03-25' in: query name: version required: true schema: $ref: '#/components/schemas/QueryVersion' GroupId: description: The ID of the Group. example: 0d3728ec-eebf-484d-9907-ba238019f10b in: path name: group_id required: true schema: format: uuid type: string To: description: 'The end date (exclusive) of the audit logs search. Dates should be formatted as RFC3339, e.g. 2024-01-02T16:30:00Z. ' in: query name: to schema: format: date-time type: string OrgId: description: The ID of the organization. example: 0d3728ec-eebf-484d-9907-ba238019f10b in: path name: org_id required: true schema: format: uuid type: string Events: description: Filter logs by event types, cannot be used in conjunction with exclude_events parameter. in: query name: events schema: items: type: string type: array ProjectId: description: Filter logs by project ID. example: 0d3728ec-eebf-484d-9907-ba238019f10b in: query name: project_id schema: format: uuid type: string From: description: 'The start date (inclusive) of the audit logs search. If not specified, the start of yesterday is used. Dates should be formatted as RFC3339, e.g. 2024-01-02T16:30:00Z. ' in: query name: from schema: format: date-time type: string ExcludeEvents: description: Exclude event types from results, cannot be used in conjunctions with events parameter. in: query name: exclude_events schema: items: type: string type: array responses: '400': content: application/vnd.api+json: schema: $ref: '#/components/schemas/ErrorDocument' description: 'Bad Request: A parameter provided as a part of the request was invalid.' headers: deprecation: $ref: '#/components/headers/DeprecationHeader' snyk-request-id: $ref: '#/components/headers/RequestIdResponseHeader' snyk-version-lifecycle-stage: $ref: '#/components/headers/VersionStageResponseHeader' snyk-version-requested: $ref: '#/components/headers/VersionRequestedResponseHeader' snyk-version-served: $ref: '#/components/headers/VersionServedResponseHeader' sunset: $ref: '#/components/headers/SunsetHeader' '500': content: application/vnd.api+json: schema: $ref: '#/components/schemas/ErrorDocument' description: 'Internal Server Error: An error was encountered while attempting to process the request.' headers: deprecation: $ref: '#/components/headers/DeprecationHeader' snyk-request-id: $ref: '#/components/headers/RequestIdResponseHeader' snyk-version-lifecycle-stage: $ref: '#/components/headers/VersionStageResponseHeader' snyk-version-requested: $ref: '#/components/headers/VersionRequestedResponseHeader' snyk-version-served: $ref: '#/components/headers/VersionServedResponseHeader' sunset: $ref: '#/components/headers/SunsetHeader' '403': content: application/vnd.api+json: schema: $ref: '#/components/schemas/ErrorDocument' description: 'Forbidden: the request requires an authentication token with more or different permissions.' headers: deprecation: $ref: '#/components/headers/DeprecationHeader' snyk-request-id: $ref: '#/components/headers/RequestIdResponseHeader' snyk-version-lifecycle-stage: $ref: '#/components/headers/VersionStageResponseHeader' snyk-version-requested: $ref: '#/components/headers/VersionRequestedResponseHeader' snyk-version-served: $ref: '#/components/headers/VersionServedResponseHeader' sunset: $ref: '#/components/headers/SunsetHeader' '404': content: application/vnd.api+json: schema: $ref: '#/components/schemas/ErrorDocument' description: 'Not Found: The resource being operated on could not be found.' headers: deprecation: $ref: '#/components/headers/DeprecationHeader' snyk-request-id: $ref: '#/components/headers/RequestIdResponseHeader' snyk-version-lifecycle-stage: $ref: '#/components/headers/VersionStageResponseHeader' snyk-version-requested: $ref: '#/components/headers/VersionRequestedResponseHeader' snyk-version-served: $ref: '#/components/headers/VersionServedResponseHeader' sunset: $ref: '#/components/headers/SunsetHeader' '401': content: application/vnd.api+json: schema: $ref: '#/components/schemas/ErrorDocument' description: 'Unauthorized: the request requires an authentication token.' headers: deprecation: $ref: '#/components/headers/DeprecationHeader' snyk-request-id: $ref: '#/components/headers/RequestIdResponseHeader' snyk-version-lifecycle-stage: $ref: '#/components/headers/VersionStageResponseHeader' snyk-version-requested: $ref: '#/components/headers/VersionRequestedResponseHeader' snyk-version-served: $ref: '#/components/headers/VersionServedResponseHeader' sunset: $ref: '#/components/headers/SunsetHeader' securitySchemes: APIToken: description: API key value must be prefixed with \"Token \". in: header name: Authorization type: apiKey BearerAuth: scheme: bearer type: http x-snyk-api-version: '2024-10-15'