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

[Security Assistant] Add Knowledge Base entries API #206407

Merged
merged 22 commits into from
Jan 28, 2025

Conversation

patrykkopycinski
Copy link
Contributor

@patrykkopycinski patrykkopycinski commented Jan 13, 2025

Summary

Expose Knowledge Base entries API

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@patrykkopycinski
Copy link
Contributor Author

/ci

@elasticmachine
Copy link
Contributor

elasticmachine commented Jan 28, 2025

💔 Build Failed

Failed CI Steps

History

const documentsFilter = documentIds.map((id) => `_id:${id}`).join(' OR ');
const entries = await kbDataClient?.findDocuments<EsKnowledgeBaseEntrySchema>({
page: 1,
perPage: 100,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wondering if we should worry about this search at some point. If users will be adding lots of entries etc.

@patrykkopycinski patrykkopycinski marked this pull request as ready for review January 28, 2025 14:47
@patrykkopycinski patrykkopycinski requested review from a team as code owners January 28, 2025 14:47
Copy link
Contributor

@szwarckonrad szwarckonrad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DW changes LGTM!

@patrykkopycinski patrykkopycinski changed the title Make KB API public [Security Assistant] Add Knowledge Base entries API Jan 28, 2025
Copy link
Contributor

@e40pud e40pud left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Thank you!

@patrykkopycinski patrykkopycinski merged commit b128cee into elastic:main Jan 28, 2025
8 checks passed
@patrykkopycinski patrykkopycinski deleted the kb-public-api branch January 28, 2025 19:19
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.x

https://github.com/elastic/kibana/actions/runs/13017926060

kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jan 28, 2025
## Summary

Expose Knowledge Base entries API

---------

Co-authored-by: kibanamachine <[email protected]>
(cherry picked from commit b128cee)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.x

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Jan 28, 2025
…208610)

# Backport

This will backport the following commits from `main` to `8.x`:
- [[Security Assistant] Add Knowledge Base entries API
(#206407)](#206407)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Patryk
Kopyciński","email":"[email protected]"},"sourceCommit":{"committedDate":"2025-01-28T19:19:55Z","message":"[Security
Assistant] Add Knowledge Base entries API (#206407)\n\n##
Summary\r\n\r\nExpose Knowledge Base entries
API\r\n\r\n---------\r\n\r\nCo-authored-by: kibanamachine
<[email protected]>","sha":"b128cee4ee7ccc367e8acf159dbf58a75f081867","branchLabelMapping":{"^v9.0.0$":"main","^v8.18.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:enhancement","v9.0.0","Feature:Security
Assistant","Team:Security Generative
AI","backport:version","v8.18.0"],"title":"[Security Assistant] Add
Knowledge Base entries
API","number":206407,"url":"https://github.com/elastic/kibana/pull/206407","mergeCommit":{"message":"[Security
Assistant] Add Knowledge Base entries API (#206407)\n\n##
Summary\r\n\r\nExpose Knowledge Base entries
API\r\n\r\n---------\r\n\r\nCo-authored-by: kibanamachine
<[email protected]>","sha":"b128cee4ee7ccc367e8acf159dbf58a75f081867"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/206407","number":206407,"mergeCommit":{"message":"[Security
Assistant] Add Knowledge Base entries API (#206407)\n\n##
Summary\r\n\r\nExpose Knowledge Base entries
API\r\n\r\n---------\r\n\r\nCo-authored-by: kibanamachine
<[email protected]>","sha":"b128cee4ee7ccc367e8acf159dbf58a75f081867"}},{"branch":"8.x","label":"v8.18.0","branchLabelMappingKey":"^v8.18.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

---------

Co-authored-by: Patryk Kopyciński <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants