Leona
GitHubBlogs
  • Welcome to Leona!
  • Installation
    • Docker
    • Manual Setup
    • Log Collection
  • Tutorial
    • Quickstart
  • Configuration
    • Server Conf
    • Web Interface
    • Multi-Nodes
    • Index Model
    • Backup
    • The REST APIs
  • Security
    • Using ModSecurity
    • Logging User Activity
    • The URL Whitelist
    • Alerts And Events
  • Getting in
    • Log Sources
      • GELF
      • Beats
      • Ingest Logs Manually
        • Syslog
        • Journald
        • CEF
        • Raw or Plaintext
        • From Files
        • HTTP API
        • Application Data
      • Input
    • Sidecar
    • Forwarder
      • Forward Installation
      • Forward Configuration
  • Making sense
    • Pipelines
      • Rules
      • Functions
      • Use Cases
    • Streams
    • Enrichment
      • Lookup Tables
      • Geolocation
      • Data Adapters
  • Alerts & Notifications
    • Alerting By Example
    • Notifications
    • Leona Dashboard
  • Searching
    • Search Query Language
    • Time Frame Selector
  • Appendix
    • Support
    • License
    • Ecosystem
    • Contribute
    • Change Log
    • FAQs
Powered by GitBook
On this page
  • Navigate
  • Example
  1. Getting in
  2. Log Sources
  3. Ingest Logs Manually

HTTP API

The JSON path value from HTTP API input reads any JSON response of a REST resource and stores a field value as a leona message.

Navigate

Navigate to System / Inputs > Inputs and select Launch JSON path value from HTTP API. Then click Launch Input, set the significant field values, and save the input.

source = github, jsonpath = $.download_count, interval time unit = Minutes

Example

Let’s try to read the download count of a release package stored on GitHub for analysis in leona. The call looks like this:

$ curl -XGET https://api.github.com/repos/YourAccount/YourRepo/releases/assets/12345
{
  "url": "https://api.github.com/repos/YourAccount/YourRepo/releases/assets/12345",
  "id": 12345,
  "name": "somerelease.tgz",
  "label": "somerelease.tgz",
  "content_type": "application/octet-stream",
  "state": "uploaded",
  "size": 38179285,
  "download_count": 9937,
  "created_at": "2013-09-30T20:05:01Z",
  "updated_at": "2013-09-30T20:05:46Z"
}
PreviousFrom FilesNextApplication Data

Last updated 2 years ago