{ "info": { "author": "Sassoo", "author_email": "noreply@devnull.seriously", "bugtrack_url": null, "classifiers": [ "Intended Audience :: Developers", "Intended Audience :: System Administrators", "Programming Language :: Python", "Programming Language :: Python :: 2.7", "Topic :: Internet :: WWW/HTTP :: WSGI", "Topic :: Software Development :: Libraries :: Application Frameworks" ], "description": "# Goldman\n\nGoldman is an opinionated WSGI framework built on [Falcon](https://github.com/falconry/falcon) with batteries included.\n\nIt is [JSON API 1.0](http://jsonapi.org/format/) compliant & most compliments a [CRUD+L](https://en.wikipedia.org/wiki/Create,_read,_update_and_delete) type application currently using a postgres database (referred to as a store), however additional stores are on the roadmap. The framework can be used simply by defining your models with validations & you automatically get:\n\n * Content negotiation\n * JSON API query parameters including pagination\n * Model based routing\n * Serialization / Deserialization to & from REST endpoints\n * Serialization / Deserialization to & from the store\n * signalling using [Blinker](https://github.com/jek/blinker)\n * much much more\n\n### Resource Examples:\n\nNeed some examples? How about a few resources like an American & their Truck, you would define your resources like:\n\n```python\nimport goldman\n\nfrom app.models import American, Truck\n\n\nclass API(goldman.API):\n \"\"\" Subclass the goldman.API object & define resources \"\"\"\n\n RESOURCES = [\n goldman.ModelResource(Truck),\n goldman.ModelsResource(Truck),\n goldman.RelatedResource(Truck),\n\n goldman.ModelResource(American),\n goldman.ModelsResource(American),\n goldman.RelatedResource(American),\n ]\n```\n\nThe above creates API end points supporing all CRUD+L type operations for the American & Truck models. This includes complex query parameters as documented in the JSON API specification. Pagination as well. The `goldman.RelatedResource` is for handling a models relationships if present.\n\n### Model Examples:\n\nTo define a model we leverage & extend the awesome [Schematics](https://github.com/schematics/schematics) framework for serialization/deserialization & validation. This is different than (de)serialization over the wire which goldman does as well. From the same examples above the models could look like:\n\n```python\n\nimport goldman\n\nfrom goldman.types import PhoneNumberType, ResourceType, ToManyType, ToOneType\nfrom schematics.types import BooleanType, IntType, StringType\n\n\nclass American(goldman.BaseModel):\n \"\"\" American model \"\"\"\n\n RTYPE = 'americans'\n\n \"\"\"\n The attrs below are the models fields\n \"\"\"\n \n rid = IntType(\n from_rest=False,\n rid=True,\n )\n rtype = ResourceType(RTYPE)\n\n first_name = StringType(\n max_length=150,\n required=True,\n )\n last_name = StringType(\n max_length=150,\n required=True,\n )\n\n balding = BooleanType(default=True)\n loves_freedom = BooleanType(default=True)\n weight = IntType(min_value=250)\n \n # relationships\n trucks = ToManyType(\n field='owner',\n rtype='trucks',\n )\n \n \nclass Truck(goldman.BaseModel):\n \"\"\" Truck model \"\"\"\n\n RTYPE = 'trucks'\n\n \"\"\"\n The attrs below are the models fields\n \"\"\"\n \n rid = IntType(\n from_rest=False,\n rid=True,\n )\n rtype = ResourceType(RTYPE)\n \n color = StringType(required=True)\n mpg = IntType(max_value=10)\n \n truck_bed_for_lovin = BooleanType(default=True)\n \n # relationships\n owner = ToOneType(rtype='americans')\n```\n\n\nThe models fields will be cast to the appropriate data types for extra business logic, storage, & transport over the wire. Additionally, validations will be run with JSON API compliant exceptions. An enormous amount of work has been done to ensure strong exception handling with meaningful errors.\n\n### Stuff used to make this:\n\n * [Faclon](https://github.com/falconry/falcon) core WSGI capability\n * [Psycopg2](http://initd.org/psycopg/) for postgres integration\n * [Blinker](https://github.com/jek/blinker) for signalling events\n * [Schematics](http://codemirror.net/) for the awesome object schema layer with validations & a bunch more\n * [Python-PhoneNumbers](https://github.com/daviddrysdale/python-phonenumbers) for phone number validations\n * [Python-US](https://github.com/unitedstates/python-us) for state validations\n", "description_content_type": null, "docs_url": null, "download_url": "https://github.com/sassoo/goldman/tarball/0.1.9", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/sassoo/goldman", "keywords": "framework,http,jsonapi,rest,web,wsgi", "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "goldman", "package_url": "https://pypi.org/project/goldman/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/goldman/", "project_urls": { "Download": "https://github.com/sassoo/goldman/tarball/0.1.9", "Homepage": "https://github.com/sassoo/goldman" }, "release_url": "https://pypi.org/project/goldman/0.1.9/", "requires_dist": null, "requires_python": null, "summary": "An opinionated WSGI web framework", "version": "0.1.9" }, "last_serial": 1898416, "releases": { "0.1.1": [], "0.1.5": [ { "comment_text": "", "digests": { "md5": "8171c0752c07e071913c9441436d7625", "sha256": "2780d543b0c7d6ae20129d70c72862eb1c1704aafdc3c40e3810f92d260f429f" }, "downloads": -1, "filename": "goldman-0.1.5.tar.gz", "has_sig": false, "md5_digest": "8171c0752c07e071913c9441436d7625", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 47303, "upload_time": "2015-12-31T02:05:39", "url": "https://files.pythonhosted.org/packages/6c/bc/d0699e4a3f36edde1eb166c195270eadeb7599c721afa13b5a782b476f9d/goldman-0.1.5.tar.gz" } ], "0.1.6": [ { "comment_text": "", "digests": { "md5": "bc5d43b2b40d6cf4e2037cac378392d4", "sha256": "844780af0334aba3838055d1f4c1a984fc904037c8e4e53fc356c64ef2947d40" }, "downloads": -1, "filename": "goldman-0.1.6.tar.gz", "has_sig": false, "md5_digest": "bc5d43b2b40d6cf4e2037cac378392d4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 47312, "upload_time": "2015-12-31T02:08:01", "url": "https://files.pythonhosted.org/packages/b0/f1/a0ee94b1aa14f08a3d50ebceedfb1edf756413a11f0cbd2aa8014ce7244f/goldman-0.1.6.tar.gz" } ], "0.1.7": [ { "comment_text": "", "digests": { "md5": "a101a9afd90808760b565bb5c0ae897c", "sha256": "82e334d609a2ef37f4e5e4c18142034066b5868c7ce0504b040a7454c624e393" }, "downloads": -1, "filename": "goldman-0.1.7.tar.gz", "has_sig": false, "md5_digest": "a101a9afd90808760b565bb5c0ae897c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 52502, "upload_time": "2016-01-10T23:55:57", "url": "https://files.pythonhosted.org/packages/24/d9/65fd7bd7fc0f3a8d988055dc4fae404f3614fa8ae8648a498046618616d4/goldman-0.1.7.tar.gz" } ], "0.1.9": [ { "comment_text": "", "digests": { "md5": "52f6efa5fa3e628f2bb491a3c708c581", "sha256": "aaff11b6fad110d2c35e6c5ec5892e0d65f4381ddfbaa3cb1010d99837ae6bd9" }, "downloads": -1, "filename": "goldman-0.1.9.tar.gz", "has_sig": false, "md5_digest": "52f6efa5fa3e628f2bb491a3c708c581", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 52630, "upload_time": "2016-01-11T01:43:39", "url": "https://files.pythonhosted.org/packages/c2/50/3cb235f38c0392245ba530fa77bdb4454a0cf4fc3ba779b5140a8bc897da/goldman-0.1.9.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "52f6efa5fa3e628f2bb491a3c708c581", "sha256": "aaff11b6fad110d2c35e6c5ec5892e0d65f4381ddfbaa3cb1010d99837ae6bd9" }, "downloads": -1, "filename": "goldman-0.1.9.tar.gz", "has_sig": false, "md5_digest": "52f6efa5fa3e628f2bb491a3c708c581", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 52630, "upload_time": "2016-01-11T01:43:39", "url": "https://files.pythonhosted.org/packages/c2/50/3cb235f38c0392245ba530fa77bdb4454a0cf4fc3ba779b5140a8bc897da/goldman-0.1.9.tar.gz" } ] }