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

Fetching alerts using custom parameters #919

Closed
7 tasks done
jesusgn90 opened this issue Sep 27, 2018 · 0 comments
Closed
7 tasks done

Fetching alerts using custom parameters #919

jesusgn90 opened this issue Sep 27, 2018 · 0 comments
Assignees

Comments

@jesusgn90
Copy link
Contributor

jesusgn90 commented Sep 27, 2018

Hi team, we need a custom backend route which accepts agent.id, cluster/manager.name, date.from, date.to and rule.group as parameter.

In front-side there is no need to create new code, just use genericReq service.

POST /elastic/alerts
{
   "agent.id": 100 ,
   "cluster.name": "wazuh",
   "date.from": "now-1d/timestamp/standard date",
   "date.to": "now/timestamp/standard date",
   "rule.group": "onegroup"
   "size": 5 // Optional parameter
}

result = [alert1, alert2, alert3...]

Tasks:

  • Add the new route as a POST in our server
    • /elastic/alerts
  • The route must return an array of alerts.
    • If there are no results, an empty array.
    • If there is an error, the error in the same way other routes are doing.
  • Mocha test (done fd1ca2b)
  • Manual test

Regards!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants