Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[EDR Workflows] Osquery OpenApi Spec #162955

Merged
merged 10 commits into from
Aug 31, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fleet wrapper
  • Loading branch information
tomsonpl committed Aug 31, 2023
commit fe7d78459aa01be48035f6ae5e9b70dc8a456bbe
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
openapi: 3.0.0
info:
title: Fleet wrapper schema
version: 8.11.0
paths:
/internal/osquery/fleet_wrapper/agents:
get:
summary: Get agents
parameters:
- $ref: './get_agents.schema.yaml#/components/parameters/GetAgentsRequestQueryParameter'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: './get_agents.schema.yaml#/components/schemas/SuccessResponse'

/internal/osquery/fleet_wrapper/agents/{id}:
get:
summary: Get Agent details
parameters:
- $ref: './get_agent_details.schema.yaml#/components/parameters/GetAgentDetailsRequestQueryParameter'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: './get_agent_details.schema.yaml#/components/schemas/SuccessResponse'

/internal/osquery/fleet_wrapper/agent_policies:
get:
summary: Get Agent policies
parameters:
- $ref: './get_agent_policies.schema.yaml#/components/parameters/GetAgentPoliciesRequestParameter'
- $ref: './get_agent_policies.schema.yaml#/components/parameters/GetAgentPoliciesRequestQueryParameter'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: './get_agent_policies.schema.yaml#/components/schemas/SuccessResponse'

/internal/osquery/fleet_wrapper/agent_policies/{id}:
get:
summary: Get Agent policy
parameters:
- $ref: './get_agent_policy.schema.yaml#/components/parameters/GetAgentPolicyRequestParameter'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: './get_agent_policy.schema.yaml#/components/schemas/SuccessResponse'

/internal/osquery/fleet_wrapper/package_policies:
get:
summary: Get Agent policy
parameters:
- $ref: './get_package_policies.schema.yaml#/components/parameters/GetPackagePoliciesRequestQueryParameter'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: './get_package_policies.schema.yaml#/components/schemas/SuccessResponse'
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
openapi: 3.0.0
info:
title: Get agent details schema
version: 8.11.0
paths: { }
components:
parameters:
GetAgentDetailsRequestQueryParameter:
name: query
in: path
required: true
schema:
$ref: '#/components/schemas/GetAgentDetailsRequestParams'
schemas:
GetAgentDetailsRequestParams:
type: object
SuccessResponse:
type: object
properties: {}
# Define properties for the success response if needed
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
openapi: 3.0.0
info:
title: Get agent policies schema
version: 8.11.0
paths: { }
components:
parameters:
GetAgentPoliciesRequestQueryParameter:
name: query
in: query
required: true
schema:
$ref: '#/components/schemas/GetAgentPoliciesRequestParams'
GetAgentPoliciesRequestParameter:
name: query
in: path
required: true
schema:
$ref: '#/components/schemas/GetAgentPoliciesRequestParams'
schemas:
GetAgentPoliciesRequestParams:
type: object
SuccessResponse:
type: object
properties: {}
# Define properties for the success response if needed
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
openapi: 3.0.0
info:
title: Get agent policy schema
version: 8.11.0
paths: { }
components:
parameters:
GetAgentPolicyRequestParameter:
name: query
in: path
required: true
schema:
$ref: '#/components/schemas/GetAgentPolicyRequestParams'
schemas:
GetAgentPolicyRequestParams:
type: object
properties:
id:
$ref: '../model/schema/common_attributes.schema.yaml#/components/schemas/Id'
SuccessResponse:
type: object
properties: {}
# Define properties for the success response if needed
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
openapi: 3.0.0
info:
title: Get agent status schema
version: 8.11.0
paths: { }
components:
parameters:
GetAgentStatusRequestQueryParameter:
name: query
in: query
required: true
schema:
$ref: '#/components/schemas/GetAgentStatusRequestQueryParams'
GetAgentStatusRequestParameter:
name: query
in: path
required: true
schema:
$ref: '#/components/schemas/GetAgentStatusRequestParams'
schemas:
GetAgentStatusRequestParams:
type: object
GetAgentStatusRequestQueryParams:
type: object
properties:
kuery:
$ref: '../model/schema/common_attributes.schema.yaml#/components/schemas/KueryOrUndefined'
policyId:
$ref: '../model/schema/common_attributes.schema.yaml#/components/schemas/Id'
SuccessResponse:
type: object
properties: {}
# Define properties for the success response if needed
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
openapi: 3.0.0
info:
title: Get agents schema
version: 8.11.0
paths: { }
components:
parameters:
GetAgentsRequestQueryParameter:
name: query
in: path
required: true
schema:
$ref: '#/components/schemas/GetAgentsRequestParams'
schemas:
GetAgentsRequestParams:
type: object
SuccessResponse:
type: object
properties: {}
# Define properties for the success response if needed
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
openapi: 3.0.0
info:
title: Get package policies schema
version: 8.11.0
paths: { }
components:
parameters:
GetPackagePoliciesRequestQueryParameter:
name: query
in: path
required: true
schema:
$ref: '#/components/schemas/GetPackagePoliciesRequestParams'
schemas:
GetPackagePoliciesRequestParams:
type: object
SuccessResponse:
type: object
properties: {}
# Define properties for the success response if needed
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ components:
$ref: '#/components/schemas/Queries'
nullable: true


KueryOrUndefined:
type: string
nullable: true
Expand Down