[FIX]
#114 Correctly parse query string in the path which doesn't start with '/', e.g.fb.Get("me?fields=name,email", nil)
.
[FIX]
#114 Query string in the path, e.g.fb.Get("/me?fields=name,email", nil)
, works as expected now. Thanks, @AsifArko.
[FIX]
#110 Use HTTP GET to send request in which the method isGET
. Thank @nayakravi for raising this issue, and Thank @AlphaB and @robbiet480 for your valuable inputs.
[NEW]
#103 AddRFC3339Timestamps
flag to setdate_format
on every API request. If this flag is set, all date value returned by facebook will be encoded with a format supported byjson.Unmarshal
. Thanks, @robbiet480.[NEW]
#105 Added ability to overrideSession
base URL. It's designed for unit testing. All session requests can be redirected to a test server by settingSession#BaseURL
to a test URL. Thanks, @vania-pooh.
[NEW]
#86 ParseX-App-Usage
andX-Page-Usage
in response header and store the usage information inResult
. UseResult#UsageInfo()
to read it. Thanks, @robbiet480.
[NEW]
#81 Compatible with the struct field's tag used byjson.Unmarshal
. The "json" key works as expected now. If both the "facebook" key and the "json" key exist, use "facebook".
[NEW]
#80 #71 AllSession
API, which sends requests to Facebook, supportContext
now. Thanks, @sebnow for your thoughts and reminder.[NEW]
#79 Add some number types which can be decoded from a string implicitly.[NEW]
#78 #57 Deprecate FQL and remove all related code.[FIX]
#73 Fix regular expression for video post. Thanks, @acochrane.[FIX]
#62 Usebase64.RawURLEncoding
to decode signed request data. Thanks,@zonr.[FIX]
Fix some typos in README and test cases. Thank @nick3399, @J-P-77, @smasher164, @enm10k and many others.[FIX]
Clean up code for readability.
[FIX]
#59 Guess content type for binary params by filename extension or an arbitrary value. Thanks,@panki.
[FIX]
Fix a tiny bug which slightly affects performance when decoding anonymous field.
[NEW]
#50Result
can decode embedded struct field now.[NEW]
Add a new field tagfacebook:"-"
to omit the field when decoding. It can improve decoding performance slightly.
[NEW]
#42 Support custom JSON unmarshaling andjson.Unmarshaler
interface in decoding.
[NEW]
#40Session
works with http client created by packagegolang.org/x/oauth2
. README is updated with a sample.
[FIX]
#39 When/oauth/access_token
returns a query string, this package can parseexpires
orexpires_in
field correctly.
[FIX]
#37 Add missingclient_secret
in query string when parsing client code.
[FIX]
#34 Useexpires
instead ofexpires_in
if possible when exchanging token or parsing code.
[FIX]
#32 BatchApi/Batch returns facebook error when access token is not valid.
[FIX]
#31 When/oauth/access_token
returns a query string instead of json, this package can correctly handle it.
[NEW]
#28 Support debug mode introduced by facebook graph API v2.3.[FIX]
Removed all test cases depending on facebook graph API v1.0.
[NEW]
#27 Timestamp value in Graph API response can be decoded as atime.Time
value now. Thanks, @Lazyshot.
[FIX]
#23 Algorithm change: Camel case string to underscore string supports abbreviation
Fix for #23 could be a breaking change. Camel case string HTTPServer
will be converted to http_server
instead of h_t_t_p_server
. See issue description for detail.
[NEW]
#22 Add a new helper structBatchResult
to hold batch request responses.
[NEW]
#20 Add Decode functionality for paging results. Thanks, @cbroglie.[FIX]
#21Session#Inspect
cannot return error if access token is invalid.
Fix for #21 will result a possible breaking change in Session#Inspect
. It was return whole result returned by facebook inspect api. Now it only return its "data" sub-tree. As facebook puts everything including error message in "data" sub-tree, I believe it's reasonable to make this change.
[FIX]
#19 Any valid int64 number larger than 2^53 or smaller than -2^53 can be correctly decoded without precision lost.
Fix for #19 will result a possible breaking change in Result#Get
and Result#GetField
. If a JSON field is a number, these two functions will return json.Number
instead of float64
.
The fix also introduces a side effect in Result#Decode
and Result#DecodeField
. A number field (int*
and float*
) can be decoded to a string. It was not allowed in previous version.
Initial tag. Library is stable enough for all features mentioned in README.md.