The flexible HTTP client library for Elixir, with support for middleware and multiple adapters. Tesla is an HTTP client loosely based on Faraday. It embraces the concept of middleware when processing the request/response cycle. Define module with use Tesla and choose from a variety of middleware. Tesla is built around the concept of composable middlewares. This is very similar to how Plug Router works. All HTTP functions, such as Tesla.get/3 and Tesla.post/4, can take a dynamic client as the first argument. This allows using convenient syntax for modifying the behavior in runtime. Tesla supports multiple HTTP adapter that do the actual HTTP request processing. Each piece of the stream will be encoded as JSON and sent as a new line (conforming to JSON stream format). You can set the adapter to Tesla.Mock in tests.

Features

  • Define module with use Tesla and choose from a variety of middleware
  • Configure default adapter in config/config.exs (optional)
  • Tesla uses Semantic Versioning 2.0
  • Tesla is built around the concept of composable middlewares
  • Runtime middleware
  • Tesla supports multiple HTTP adapter that do the actual HTTP request processing

Project Samples

Project Activity

See All Activity >

License

MIT License

Follow Tesla

Tesla Web Site

Other Useful Business Software
Full-stack observability with actually useful AI | Grafana Cloud Icon
Full-stack observability with actually useful AI | Grafana Cloud

Our generous forever free tier includes the full platform, including the AI Assistant, for 3 users with 10k metrics, 50GB logs, and 50GB traces.

Built on open standards like Prometheus and OpenTelemetry, Grafana Cloud includes Kubernetes Monitoring, Application Observability, Incident Response, plus the AI-powered Grafana Assistant. Get started with our generous free tier today.
Create free account
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Tesla!

Additional Project Details

Programming Language

Elixir

Related Categories

Elixir HTML XHTML, Elixir Libraries, Elixir HTTP Clients

Registered

2022-10-07