Skip to content

Commit

Permalink
Merge 2157089 into 69e88b4
Browse files Browse the repository at this point in the history
  • Loading branch information
iMacTia committed Jul 29, 2022
2 parents 69e88b4 + 2157089 commit b62613c
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions docs/usage/customize.md
Expand Up @@ -77,6 +77,20 @@ serializes POST bodies.

The default encoder is `Faraday::NestedParamsEncoder`.

### Order of parameters

By default, paramters are sorted by name while being serialized.
Since this is really useful to provide better cache management and most servers don't really care about parameters order, this is the default behaviour.
However you might find yourself dealing with a server that requires parameters to be in a specific order.
When that happens, you can configure the encoder to skip sorting them.
This configuration is supported by both the default `Faraday::NestedParamsEncoder` and `Faraday::FlatParamsEncoder`:

```ruby
Faraday::NestedParamsEncoder.sort_params = false
# or
Faraday::FlatParamsEncoder.sort_params = false
```

## Proxy

Faraday will try to automatically infer the proxy settings from your system using [`URI#find_proxy`][ruby-find-proxy].
Expand Down

0 comments on commit b62613c

Please sign in to comment.