Skip to main content

Redis Resource for Tastypie

Allows you to create delicious APIs for Redis.

Settings

REDIS_HOST = localhost
REDIS_PORT = 6379
REDIS_DATABASE = "database_name"

Example of Usage

from tastypie import fields
from tastypie.authorization import Authorization

from tastypie_redis.resources import RedisResource, Document

class DocumentResource(RedisResource):
    id = fields.CharField(attribute="_id")
    title = fields.CharField(attribute="title", null=True)
    entities = fields.ListField(attribute="entities", null=True)

    class Meta:
        resource_name = "documents"
        list_allowed_methods = ["delete", "get", "post"]
        authorization = Authorization()
        object_class = Document
        collection = "documents" # collection name

Release files for tastypie-redis-resource 0.0.9

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for tastypie-redis-resource 0.0.9
File Size Uploaded
tastypie-redis-resource-0.0.9.tar.gz 3.0 kB Details

Release files / tastypie-redis-resource-0.0.9.tar.gz

Download URL tastypie-redis-resource-0.0.9.tar.gz
Size 3.0 kB
Tags Source
SHA-256 checksum
How to use checksums
6f3515e81c2325e86e03ae8a0236abedaee2a40587688dddee56c155b849bf36
BLAKE2b-256 checksum
How to use checksums
2d49e74d003eb10f344b46e6ae56de7fd489fd42a6063de19e57d130d677236d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.0.9 This release

1 release file

0.0.8

1 release file

0.0.7

1 release file

0.0.6

1 release file

0.0.5

1 release file

0.0.4

1 release file

0.0.3

1 release file

0.0.2

1 release file

0.0.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page