diff options
author | lain <lain@soykaf.club> | 2020-05-16 17:07:09 +0000 |
---|---|---|
committer | lain <lain@soykaf.club> | 2020-05-16 17:07:09 +0000 |
commit | d15aa9d9503e59b3cd0731394855781f435ec63c (patch) | |
tree | 844810415def046a2fc886d0bc1baeb1ff9afb21 /lib/pleroma/http/request.ex | |
parent | 9cf4c4fa73e68f03791c5cc70505b710be39b677 (diff) | |
parent | 3bc1138dd9beec03d2336fa1ad45dd23816f5285 (diff) | |
download | pleroma-d15aa9d9503e59b3cd0731394855781f435ec63c.tar.gz |
Merge branch 'develop' into 'remove-twitter-api'
# Conflicts:
# lib/pleroma/web/nodeinfo/nodeinfo_controller.ex
Diffstat (limited to 'lib/pleroma/http/request.ex')
-rw-r--r-- | lib/pleroma/http/request.ex | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/lib/pleroma/http/request.ex b/lib/pleroma/http/request.ex new file mode 100644 index 000000000..761bd6ccf --- /dev/null +++ b/lib/pleroma/http/request.ex @@ -0,0 +1,23 @@ +# Pleroma: A lightweight social networking server +# Copyright © 2017-2020 Pleroma Authors <https://pleroma.social/> +# SPDX-License-Identifier: AGPL-3.0-only + +defmodule Pleroma.HTTP.Request do + @moduledoc """ + Request struct. + """ + defstruct method: :get, url: "", query: [], headers: [], body: "", opts: [] + + @type method :: :head | :get | :delete | :trace | :options | :post | :put | :patch + @type url :: String.t() + @type headers :: [{String.t(), String.t()}] + + @type t :: %__MODULE__{ + method: method(), + url: url(), + query: keyword(), + headers: headers(), + body: String.t(), + opts: keyword() + } +end |