Skip to content

Featherweight API libraries for connecting to popular third-party cloud services

License

Notifications You must be signed in to change notification settings

http4k/http4k-connect

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

http4k connect logo

build download

http4k Connect is a lightweight API Client toolkit which includes libraries for connecting to popular third-party cloud services and AI backends using http4k compatible APIs, along with Fake implementations for usage during local testing. These are all underpinned by a variation on the uniform Server as a Function model powered by the HttpHandler interface exposed by http4k Core, so you can:

  1. Take advantage of the simple and powerful SaaF model and APIs used in http4k.
  2. Plug everything together completely in-memory and take advantage of this powerful model.
  3. Have access to the underlying HTTP clients (and hence add metrics or logging).
  4. Run stateful Fake implementations of 3rd party systems locally or in test environments.

Although centered around usage in http4k-based projects, http4k-connect does not require this and the libraries are usable from any JVM application.

Rationale

Although convenient, many API Client libraries introduce many heavyweight dependencies or contain a plethora of non-required functionality, which can have a large effect on binary size. As an alternative, http4k-connect provides lightweight versions of popular APIs covering standard use-cases.

Installation

dependencies {
    // install the platform...
    implementation(platform("org.http4k:http4k-connect-bom:5.25.1.0"))

    // ...then choose an API Client
    implementation("org.http4k:http4k-connect-amazon-s3")

    // ...and a storage backend (optional)
    implementation("org.http4k:http4k-connect-storage-redis")

    // ...a fake for testing (optional)
    testImplementation("org.http4k:http4k-connect-amazon-s3-fake")
}
## About the docs

The main documentation has moved to the main http4k site site The content for the documentation is now hosted alongside the main site in the repo http4k/www