Package

com.snowplowanalytics.snowplow.enrich.common.enrichments.registry

apirequest

Permalink

package apirequest

Visibility
  1. Public
  2. All

Type Members

  1. sealed trait ApiOutput[A] extends AnyRef

    Permalink

    Common trait for all API output formats

    Common trait for all API output formats

    A

    type of API response (XML, JSON, etc)

  2. case class ApiRequestEnrichment(inputs: List[Input], api: HttpApi, outputs: List[Output], cache: Cache) extends Enrichment with Product with Serializable

    Permalink
  3. case class Authentication(httpBasic: Option[HttpBasic]) extends Product with Serializable

    Permalink

    Helper class to configure authentication for HTTP API

    Helper class to configure authentication for HTTP API

    httpBasic

    single possible auth type is http-basic

  4. case class Cache(size: Int, ttl: Int) extends Product with Serializable

    Permalink

    Just LRU cache

    Just LRU cache

    size

    amount of objects

    ttl

    time in seconds to live

  5. case class HttpApi(method: String, uri: String, timeout: Int, authentication: Authentication) extends Product with Serializable

    Permalink

    API client able to make HTTP requests

    API client able to make HTTP requests

    method

    HTTP method

    uri

    URI template

    timeout

    time in milliseconds after which request can be considered failed

    authentication

    auth preferences

  6. case class HttpBasic(username: Option[String], password: Option[String]) extends Product with Serializable

    Permalink

    Container for HTTP Basic auth credentials

  7. case class Input(key: String, pojo: Option[PojoInput], json: Option[JsonInput]) extends Product with Serializable

    Permalink

    Container for key with one (and only one) of possible input sources Basically, represents a key for future template context and way to get value out of EnrichedEvent, custom context, derived event or unstruct event.

    Container for key with one (and only one) of possible input sources Basically, represents a key for future template context and way to get value out of EnrichedEvent, custom context, derived event or unstruct event.

    key

    extracted key

    pojo

    optional POJO source to take stright from EnrichedEvent

    json

    optional JSON source to take from context or unstruct event

  8. case class InvalidStateException(message: String) extends Throwable with Product with Serializable

    Permalink
  9. case class JsonInput(field: String, schemaCriterion: String, jsonPath: String) extends Product with Serializable

    Permalink

    field

    where to get this JSON, one of unstruct_event, contexts or derived_contexts

    schemaCriterion

    self-describing JSON you are looking for in the given JSON field. You can specify only the SchemaVer MODEL (e.g. 1-), MODEL plus REVISION (e.g. 1-1-) etc

    jsonPath

    JSONPath statement to navigate to the field inside the JSON that you want to use as the input

  10. case class JsonOutput(jsonPath: String) extends ApiOutput[JValue] with Product with Serializable

    Permalink

    Preference for extracting JSON from API output

    Preference for extracting JSON from API output

    jsonPath

    JSON Path to required value

  11. case class JsonPathException(message: String) extends Throwable with Product with Serializable

    Permalink
  12. case class Output(schema: String, json: Option[JsonOutput]) extends Product with Serializable

    Permalink

    Base trait for API output format Primary intention of these classes is to perform transformation of API raw output to self-describing JSON instance

  13. case class PojoInput(field: String) extends Product with Serializable

    Permalink

    Describes how to take key from POJO source

    Describes how to take key from POJO source

    field

    EnrichedEvent object field

  14. case class ValueNotFoundException(message: String) extends Throwable with Product with Serializable

    Permalink

Value Members

  1. object ApiRequestEnrichment extends Serializable

    Permalink

    Companion object containing common methods for requests and manipulating data

  2. object ApiRequestEnrichmentConfig extends ParseableEnrichment

    Permalink

    Lets us create an ApiRequestEnrichmentConfig from a JValue

  3. object HttpApi extends Serializable

    Permalink
  4. object Input extends Serializable

    Permalink

    Companion object, containing common methods for input data manipulation and template context building

Ungrouped