I agree that the percent encoding/decoding functions are broadly applicable, but the oauth_uri module (and most of the others) aren't really meant to be part of the "official API", so i don't want to encourage external use of them.
Personally i think URI encoding/decoding should be in the Erlang stdlib; it's well defined, often used [in the web world], and not something you want to keep re-implementing. I posted this suggestion to the mailing list a while back:
A more complete library for dealing with URIs (along the lines of Ruby's "addressable" project) might be a better fit for inclusion into the stdlib, but no-one has put something like that together yet. I've started on some of the components of this (URI templates, IDNA), but it would take some work to bring it all together.
In the meantime i would recommend just copying and pasting the encode/decode functions into your project. I've just pushed a better implementation of them, based upon my erlang-percent-encoding repo.
I agree that the percent encoding/decoding functions are broadly applicable, but the oauth_uri module (and most of the others) aren't really meant to be part of the "official API", so i don't want to encourage external use of them.
Personally i think URI encoding/decoding should be in the Erlang stdlib; it's well defined, often used [in the web world], and not something you want to keep re-implementing. I posted this suggestion to the mailing list a while back:
http://erlang.org/pipermail/erlang-questions/2009-January/041284.html
A more complete library for dealing with URIs (along the lines of Ruby's "addressable" project) might be a better fit for inclusion into the stdlib, but no-one has put something like that together yet. I've started on some of the components of this (URI templates, IDNA), but it would take some work to bring it all together.
In the meantime i would recommend just copying and pasting the encode/decode functions into your project. I've just pushed a better implementation of them, based upon my erlang-percent-encoding repo.
Hope that helps.