WeaviateEx.Protocol behaviour (WeaviateEx v0.7.4)

View Source

Protocol behavior for HTTP and gRPC implementations.

Summary

Types

body()

@type body() :: map() | list() | nil

method()

@type method() :: :get | :post | :put | :patch | :delete | :head

opts()

@type opts() :: keyword()

path()

@type path() :: String.t()

response()

@type response() :: {:ok, map() | list()} | {:error, WeaviateEx.Error.t()}

Callbacks

request(client, method, path, body, opts)

@callback request(client :: term(), method(), path(), body(), opts()) :: response()