Custom Query (2152 matches)
Results (1138 - 1140 of 2152)
Ticket | Resolution | Summary | Owner | Reporter |
---|---|---|---|---|
#1206 | fixed | "Content-Type json" header scuppers package POST | wwaites | dread |
Description |
Compare these two requests to create a package: curl http://test.ckan.net/api/rest/package -d '{name:"test"}' -H 'Content-Type: application/json' -H 'X-CKAN-API-KEY: tester' curl http://test.ckan.net/api/rest/package -d '{name:"test"}' -H 'X-CKAN-API-KEY: tester' The second one gets the payload through (ckan log): Retrieving request params: UnicodeMultiDict([('{name:"test"}', u'')]) But the first one causes a ServerError? because the payload (name:"test") doesn't make it to request.POST or request.params: Retrieving request params: UnicodeMultiDict([]) The only difference is the "ContentType?: application/json" header, which seems a reasonable thing to include. Javascript lib backbone.js (for example) inserts this automatically. So why does this header cause the payload to not get through to the request object? |
|||
#1207 | fixed | ckanclient.package_entity_get should raise more specific exception | dread | dread |
Description |
When package does not exist in ckan catalogue, ckanclient.package_entity_get should raise more specific exception, such as CkanNotFoundError? instead of generic CkanApiError?. |
|||
#1208 | fixed | Webstore: a datastore with web API | rgrp | rgrp |
Description |
Current code is here: https://github.com/okfn/webstore. API SpecReadTwo basic ways to query:: GET: /{owner}/{db-name}/?sql=... GET: /{owner}/{db-name}/?table=...&attr=value&attr=value&limit=... Returns:: { u'keys': [u'id', u'name'], u'data': [ [1, u'jones'], [u'aaa', u'jones'] ] } WritePOST to::
Payload is json data structured as follows::
Authentication and AuthorizationAuthentication: use basic auth header. Authorization:
Possible future: config file can specify a python method (TODO: method signature) Integration with Other SystemsTODO: Specify how to delegate authenatication to user database in some other system. |