qiniu v0.3.4 Qiniu.Auth

Module about authorization.

See http://developer.qiniu.com/docs/v6/api/reference/security/

Summary

Functions

Get authorized download url from plain url(host + key)

Get authorized download url from host and key

Generate token for uploading, which can be used in client or just server

Functions

access_token(url, body \\ "")

Get access token

Fields

authorize_download_url(url, expires_in)

Get authorized download url from plain url(host + key)

Fields

authorize_download_url(host, key, expires_in)

Get authorized download url from host and key

Fields

generate_uptoken(put_policy)

Specs

generate_uptoken(Qiniu.PutPolicy.t) :: String.t

Generate token for uploading, which can be used in client or just server.

See http://developer.qiniu.com/docs/v6/api/reference/security/upload-token.html

Examples

policy = Qiniu.PutPolicy.build("scope")
uptoken = Qiniu.Auth.generate_uptoken(policy)