https://github.com/mschae/exauth
An omniauth wrapper for elixir.
https://github.com/mschae/exauth
Last synced: about 1 year ago
JSON representation
An omniauth wrapper for elixir.
- Host: GitHub
- URL: https://github.com/mschae/exauth
- Owner: mschae
- Created: 2014-07-03T14:45:54.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2014-09-24T10:44:55.000Z (over 11 years ago)
- Last Synced: 2025-03-24T18:12:21.749Z (about 1 year ago)
- Language: Elixir
- Size: 167 KB
- Stars: 6
- Watchers: 0
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Exauth
======
Elixir wrapper around the [Erlang OAuth](https://github.com/tim/erlang-oauth) library.
This gem is a duplicate of [Oauthex](https://github.com/marcelog/oauthex) with the difference that is adds a bit cleaner configuration possibility (using ETS) and it doesn't provide http endpoints. This project is only intended to sign requests to use with ones favorite HTTP library.
## Usage
Currenlty this library only supports signing of request for which a consumer key, consumer secret, token and token secret is already known.
Sign a request:
```elixir
Exauth.sign(method, url) # or
Exauth.sign(method, url, params)
```
If you are looking to construct Auth headers, a method is already provided:
```elixir
Exauth.sign_header(method, url) #or
Exauth.sign_header(method, url, params)
```
The latter will return the `OAuth ...` header that has to be used as the value of the `Authorization` header key.