Ecosyste.ms: OpenCollective

An open API service for software projects hosted on Open Collective.

github.com/casbin/go-json-rest

A quick and easy way to setup a RESTful JSON API
https://github.com/casbin/go-json-rest

Add Header X-Powered-By: go-json-rest

2533a66fc2ffaf50bb20f4788dbedbbd24526c3b authored almost 11 years ago by antoine <[email protected]>
Add example to the README

206d88886a28bef5c1870367900745d81d8d2df1 authored almost 11 years ago by antoine <[email protected]>
docstring

c9fa83465c8b1069a367c0dfd51360f01579f10d authored almost 11 years ago by antoine <[email protected]>
Tentative of Flush() support (need tests)

The ResponseWriter provided by the server implementation of net/http
has a Flush() method. This ...

922c77e4c8b401d04615c5931439b1363f308f36 authored almost 11 years ago by antoine <[email protected]>
Color logging

2ebc7140749543779a5cbdb1a1d325615330532d authored almost 11 years ago by antoine <[email protected]>
Make Go 1.0 happy

ec2b3ec862baa5c05ed3112cafebabe2f7832112 authored almost 11 years ago by antoine <[email protected]>
Rewrite the gzip wrapper to always set Vary: Accept-Encoding

300af0d31833f19ef1bbf569eaddc643b10df2b5 authored almost 11 years ago by antoine <[email protected]>
Add the header Vary: Accept-Encoding for the gzipped responses

38ef40eaa0aac53a8741e075c6543f4d1291caff authored almost 11 years ago by antoine <[email protected]>
happy new year!

a6396a924a69ca86f6ea7c5318b2ce8f1da7d3a1 authored about 11 years ago by antoine <[email protected]>
Move this badge down

04fc8017d6ba0b367ee2e581d4da6806082f718a authored about 11 years ago by antoine <[email protected]>
Trying GA integration

41a0914366bd609c1392964fd6fdd41af2a021bd authored about 11 years ago by antoine <[email protected]>
New example demoing GORM

112b837b0c4d6748be1eb7ebe9c0ad791232e6e6 authored about 11 years ago by antoine <[email protected]>
Merge branch 'master' of github.com:ant0ine/go-json-rest

9c44224db08cfa0f4a9981d37e265f323e50f6e3 authored about 11 years ago by antoine <[email protected]>
Move the examples to https://github.com/ant0ine/go-json-rest-examples

6c1d96af9ab93634ef182e6fb7edffbf0c061983 authored about 11 years ago by antoine <[email protected]>
Update the README to point to the new examples repo

2a4ec9e48068a3be89e9b3c3f6955a1bffa02c10 authored about 11 years ago by antoine <[email protected]>
Merge pull request #36 from suin/utf8

Allow lowercase charset "utf-8"

d6a6131e82caf5d4d5a744c5e4b3136cadef251c authored about 11 years ago by Antoine Imbert <[email protected]>
Allow lowercase charset "utf-8"

2d60eea38f3d7d23e13f405533d8977b777680d1 authored about 11 years ago by suin <[email protected]>
Probably too early for 1.2 but lets see

460974419b715cb7e966209ca78b13c24e17019b authored about 11 years ago by antoine <[email protected]>
Add the sourcegraph button

10ed59c1bb069c589eccd307717eca1b46fe3c54 authored about 11 years ago by antoine <[email protected]>
go fmt

da2a6733d66a38a8a2141d551c57e645c19d9d06 authored over 11 years ago by antoine <[email protected]>
Fix the Content-Encoding Header when EnableGzip is true.

The WriteHeader method of the "recorder" middleware was called before the
Write method of the "g...

aa33bab62860572b96358b47aa647b2462b29720 authored over 11 years ago by antoine <[email protected]>
Suggest 'application/json'

instead of 'application/json; charset=UTF-8'

dc86f5265f68c5a847477045cc0a58d4ec964753 authored over 11 years ago by antoine <[email protected]>
Merge pull request #30 from yannk/master

Don't die if a charset param exists along w/ mediatype

69f3748998ec46580703a494acaaa3f80381e51a authored over 11 years ago by Antoine Imbert <[email protected]>
Don't die if a charset param exists along w/ mediatype

`application/json; charset=UTF-8` would fail despite being what the library
implicitely expects....

980f1e60e79256b41505c276d12b1d80c354e7f4 authored over 11 years ago by Yann Kerherve <[email protected]>
Docstring for this example

178a01017a594a4f56837b3927e26cad65c1601f authored over 11 years ago by antoine <[email protected]>
Add tests for the /.status endpoint

fcb3dfd11c5b322d8b9b994c589c6705eda9b5d3 authored over 11 years ago by antoine <[email protected]>
Move the /.status route definition in status.go

7cee177133aea3c038f7b1dcb8714619b8c999b5 authored over 11 years ago by antoine <[email protected]>
Provide a helper to decode the JSON response payload

6210890ee26a5a4b2d2466e10ba3c2ab470bdb26 authored over 11 years ago by antoine <[email protected]>
Disable the logger during the "user error" test

this hides the stack trace and make the test output more useful

ceb15560859b1eb036c5c88164bf113a40fa256a authored over 11 years ago by antoine <[email protected]>
Merge pull request #29 from ant0ine/middlewareRefactor

Middleware refactor

127ab84b4b02063ad4ef9a1b481351c22d297e39 authored over 11 years ago by Antoine Imbert <[email protected]>
go fmt

fae56342c3dc40ad1a0967332b7b1e3b65f05b2c authored over 11 years ago by antoine <[email protected]>
Move the statusCode recording in its own middleware

9530b2c5d0d4203bd7e06a91726d5990b6ddc310 authored over 11 years ago by antoine <[email protected]>
move the gzip test in a dedicated file

2a24df83b15f08539ac3ecfa386009a12df0c72b authored over 11 years ago by antoine <[email protected]>
Move the gzip feature in its own middleware

c1bb041bdedb95e6af9084d89fb5c0cd6190baac authored over 11 years ago by antoine <[email protected]>
Tentative of refactoring ...

... using internal (private) middlewares.

aab4995b4eaf6539a8d9af2f96fcece6990b9041 authored over 11 years ago by antoine <[email protected]>
Return "errors" instead of using "panic"

9b270e4d7a349bcc246e89ccfd4dd15b5c7db4c4 authored over 11 years ago by antoine <[email protected]>
Set EnableRelaxedContentType on the examples

This way the "curl" commands are shorter to type.

7c2b4bd4568f0840f96831067982059a6d326b74 authored over 11 years ago by antoine <[email protected]>
Confiure Travis to test Go1.1 too

c4a3db61300a56936aae4119b2b658447fef4df3 authored over 11 years ago by antoine <[email protected]>
Add a new contributor!

335ad27fc194604777425f9949875980c4d75756 authored over 11 years ago by antoine <[email protected]>
Merge pull request #27 from yannk/master

Harden the router for edge cases: duplicated :id in the same route or across equivalent TRIE nodes

d7d8dcfd18802f70719d6471abc0158aaad9a672 authored over 11 years ago by Antoine Imbert <[email protected]>
Add early detection of duplicated param names

/r/:id/o/:id is invalid, rather than fail hard at request time, the router
now bails when the ro...

cbc0f38cb05b930654728107971a90e899796b9f authored over 11 years ago by Yann Kerherve <[email protected]>
Disallow inconsistent splat or ph names in tree

Routes of the form:
/r/:id
/r/:key/other

Should be written
/r/:id
/r/:id/other
...

67bac6ddce293fc24ec745fc557854d01f9c4823 authored over 11 years ago by Yann Kerherve <[email protected]>
test.MakeSimpleRequest now does the JSON marshaling itself.

31f23caa2f30bb8f3105de421ff08ad773dd6482 authored over 11 years ago by antoine <[email protected]>
Introduce the EnableRelaxedContentType option

By default the Content-Type is now validated, and the option
EnableRelaxedContentType can be set...

1eeb2c35733442465594d92abedce4136c1c1315 authored over 11 years ago by antoine <[email protected]>
Make it easier to write POST test requests.

bd70887dce5822307db9cdd79668794801b22b73 authored over 11 years ago by antoine <[email protected]>
Fix issue #23 where the query string was passed to the trie query.

aa4b9394938dc66c5102f2016a69c49e0f4ea5ed authored over 11 years ago by antoine <[email protected]>
Add a test to reproduce the issue #23

ffb76f0b8da63b88d474509edc7dad23cfef6677 authored over 11 years ago by antoine <[email protected]>
Bug fix: make the *splat notation work with encoded URLs

f9e9207fc7f81be7edfe2cf9000a9e9cc0db6978 authored over 11 years ago by antoine <[email protected]>
Work with the PathExp urlencoded.

That way, regarless of how is written the Route and how is written
the Find query, the router en...

0b86a0a5c4d4e471bb97d8df234e9847fbe87e24 authored over 11 years ago by Antoine Imbert <[email protected]>
add route PathExp validation when the router is started.

c1244957665b363be12478af45ae2f6084ad8d66 authored over 11 years ago by Antoine Imbert <[email protected]>
Description for this package.

35734651ed3059964f8771a8ea4bf6d99c7b06ba authored over 11 years ago by Antoine Imbert <[email protected]>
Move the test request constructor on the test package.

9121bfc0b038cef60511c3e89166ab4a7078134f authored over 11 years ago by Antoine Imbert <[email protected]>
list the new feature

098da730ddbac865eb4646781b7e5e8501b3ca84 authored over 11 years ago by antoine <[email protected]>
Utils to write tests for a Go-Json-Rest app.

Extract the utility functions used to write the handler tests to a
dedicated package. Users of t...

7d567acc6a0c4820aa81c9560dbe97e4037176f0 authored over 11 years ago by antoine <[email protected]>
fix indent

f69c66457493fc5b8a2b99b17aeab37c1f2e622d authored over 11 years ago by antoine <[email protected]>
Fix a missing "rest." in the doc example.

f6287f3f362e0f3348d35b344794dedf57d88ba8 authored over 11 years ago by antoine <[email protected]>
Return 405 on missing HTTP methods

40cf9673caba1ff2c396245cf64b0cc5b063a284 authored over 11 years ago by antoine <[email protected]>
s/results/matches/g

56e53420efa5088127ce8a4d938583de3da5d731 authored over 11 years ago by antoine <[email protected]>
syntax error

1ca50da87d3a5c88c419622ed94a6fdfd7a24721 authored over 11 years ago by antoine <[email protected]>
new method FindRoutesAndPathMatched

Will be useful to return 405.

f08fb5fc4ccc6a14f4e81ace84fc8d52d6200bb6 authored over 11 years ago by antoine <[email protected]>
Use the closure as the context for the data that ...

... are not directly tied to the recursive method.

5db830256eacd4b00d1d9eb9e18da4d047d58bd6 authored over 11 years ago by antoine <[email protected]>
rename findContext.asMap to findContext.paramsAsMap

(this returns only the params, not the full context)

0fa46edf933ed4307a41fe38f3cefdef6bb8db55 authored over 11 years ago by antoine <[email protected]>
introduce the trie.FindRoutesForPath method

demondtrate a custom Find* method, and will be useful for routing introspection.

a3a639e8e30237c9337e0b8a4db3fe71adde28d5 authored over 11 years ago by antoine <[email protected]>
offer a more flexible "find" method on the Trie

The find method is now able to execute an arbitrary function when
a match is found. (A match on ...

f5173b1a00e24287651b100bc8c9a03b2dd8d9a4 authored over 11 years ago by antoine <[email protected]>
additional doc link

bf9077698da3cc6cf9675448f4d78255c17216a3 authored over 11 years ago by antoine <[email protected]>
minor doc changes

e25a6c8498b9692e73df29c6929e37c9cc160d42 authored over 11 years ago by antoine <[email protected]>
smaller more reusable methods for the router

6bb7c5e80a09aff75920fd27b5ee88d07bccfa9c authored over 11 years ago by antoine <[email protected]>
even better short cuts

ecd3d37dc87d24927f72f95d5f7ddcd9e1543e95 authored over 11 years ago by antoine <[email protected]>
don't try to find the first of the matched routes when there is only one.

8de84cd096669f3b9e7f10cb4aebc8403af72030 authored over 11 years ago by antoine <[email protected]>
directly pass the routes arg to the router...

...and save a useless for loop

7df38cb57cb0006f1217c424e98ddb820d370cfe authored over 11 years ago by antoine <[email protected]>
remove the reference to go-urlrouter in the description.

fb20d1a778baf7f7638dc893c63a834e61b781fc authored over 11 years ago by antoine <[email protected]>
s/Routes/routes in the private router struct

fae60011e9e4d77e3caa99aa2add935e1cca2899 authored over 11 years ago by antoine <[email protected]>
Thanks the contributors :)

30ccfbcb66d91db7126f9c36035c49ca1935264b authored over 11 years ago by antoine <[email protected]>
fix build

97bad1bfb07cbd8ba7fe851a8dd007ea6ef28511 authored over 11 years ago by antoine <[email protected]>
Merge pull request #19 from franckcuny/fc-uris

Helpers for creating URIs

4c28d888b18b67fdf11a6faf6628c2b3da4e75c0 authored over 11 years ago by Antoine Imbert <[email protected]>
Add tests for Request and change the type of parameters for

UriForWithParams.

The argument "parameters" was a hash of string, but since a query string
can c...

e402ee1b4ab349fed81e386ba02ffac70927939f authored over 11 years ago by Franck Cuny <[email protected]>
Use the new HTTP Method aware Trie

Instead of one router per method, there is now one router that is
HTTP Method aware (thanks to t...

ab17f374729bc62cdcc903b07a805721c238a950 authored over 11 years ago by antoine <[email protected]>
Make the trie support the notion of HTTP Method.

The leaf nodes now contain a map of HTTP methods to the Routes.
The Recursive findRoute method h...

4504f99bb05d11d1f5bb3e5afbf40bbbff47c227 authored over 11 years ago by antoine <[email protected]>
When constructing the URI base, simplify the lookup for the trailing /

03d41bff5c80596dc404f168fd25d0b7c598709f authored over 11 years ago by Franck Cuny <[email protected]>
Add a few convenient functions to create URLs to the Request type.

The three added functions allow an easier creation of URLs. This can be
useful when, in the app...

2d7bb5411ade8efd7b6531bf3ad48373bc6fb2e8 authored over 11 years ago by Franck Cuny <[email protected]>
Link to blog post

4743ee45e0d5654a9a7a8f65bd46863ae19ef3de authored over 11 years ago by antoine <[email protected]>
Make Router a private object

441ca9cae25dbdf2b886fdd98d95f0d273af44f2 authored over 11 years ago by antoine <[email protected]>
reorg of the docstrings

9f47ce631ec65de65093df71e20f5cf860dd265f authored over 11 years ago by antoine <[email protected]>
Make the router methods private

504646ad0d5bc6b93b745fb798468fe9771a1087 authored over 11 years ago by antoine <[email protected]>
Use the new Trie API

50769028cc325126453aba54e78f9ce4d3e1ef2b authored over 11 years ago by antoine <[email protected]>
Rename Route to RouteValue in the trie implementation

That makes it clear that Route is not necessary a rest.Route.
I expected this value to become a ...

a56abff0156bb6f522ce8cd41f558c1c3dfd927e authored over 11 years ago by antoine <[email protected]>
Merge Go-UrlRouter into Go-Json-Rest

This is big change, it does not change the API, but will allow
more improvements in the future....

8fe7a927e025e879afd682df9ee55fb132f9b64f authored over 11 years ago by antoine <[email protected]>
small optimization in the examples.

don't use append when the size of the slice is known in advance.

9db59ab2669391293f83d668926884835ede710a authored almost 12 years ago by antoine <[email protected]>
Make a better use of Go-UrlRouter

Instead of concatenating the http method and the path,
maintain one router per method.
This keep...

b3ca9f14bc3dfee2bd229f2e958a9eee7fc9f2e3 authored almost 12 years ago by antoine <[email protected]>
make the examples use rest.Error instead of http.Error

dc75cba892ded0ea384634bc9df9971e78edc190 authored almost 12 years ago by antoine <[email protected]>
[doc] placeholder names should be unique per route

fdadeb5884d6bf5dd07f170117466d0507f386b7 authored almost 12 years ago by antoine <[email protected]>
convert private _ var to camelcase.

5238dec4f2b686987c48af797340569be979bca7 authored almost 12 years ago by antoine <[email protected]>
Fix Gzip encoding support

Make sure that the response code is recorded when Gzip is enabled.
Add unit test.

9bb0615dabc0622f2e554564c6594a4130b90719 authored almost 12 years ago by antoine <[email protected]>
Merge pull request #16 from abh/gzip

Fix Content-Encoding header on gzip responses

101493dda60eb19c401717993ff8b3f3c8ba1876 authored almost 12 years ago by Antoine Imbert <[email protected]>
Fix Content-Encoding header on gzip responses

994f6d36ca16b34aac00638050a87cfb605f57f2 authored almost 12 years ago by Ask Bjørn Hansen <[email protected]>
Add a Google App Engine example

(the examples dirs are annoying. Is there an option to not build everything recursively ?)

95685ea180b2276c69701a14b6a51e22b938d296 authored almost 12 years ago by antoine <[email protected]>
More tests

a0e86e326db6f0833195dcec29975e32164f1e5d authored almost 12 years ago by antoine <[email protected]>
Capitable E, for Error.

This will be consistent with most of the JSON output given the
default of json.Marshal.

e9cc59db2d1854a5f381a4ab606ba1b3f8b05f09 authored almost 12 years ago by antoine <[email protected]>
Document some options

424274d554fb36ccedb30cbd9294dccfcf1bd3c0 authored almost 12 years ago by antoine <[email protected]>
List some features

7044a036504629b8d9d2597e9b5fa45ba8478d2a authored almost 12 years ago by antoine <[email protected]>