cowbird.api.schemas
Attributes
Classes
Valid values as webhook event. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
|
Fundamental building block of schemas. |
Functions
|
|
|
Employed to simplify Pyramid route and view config definitions from same schema objects. |
|
Return JSON Swagger specifications of Cowbird REST API. |
Module Contents
- cowbird.api.schemas.get_security(service: cornice.Service, method: cowbird.typedefs.HTTPMethod) cowbird.typedefs.JSON [source]
- cowbird.api.schemas.service_api_route_info(service_api: cornice.Service, **kwargs: Any) Dict[str, Any] [source]
Employed to simplify Pyramid route and view config definitions from same schema objects.
- class cowbird.api.schemas.ValidOperations[source]
Bases:
cowbird.utils.ExtendedEnum
Valid values as webhook event.
- cowbird.api.schemas.generate_api_schema(swagger_base_spec: cowbird.typedefs.JSON) cowbird.typedefs.JSON [source]
Return JSON Swagger specifications of Cowbird REST API.
Uses Cornice Services and Schemas to return swagger specification.
- Parameters:
swagger_base_spec – dictionary that specifies the ‘host’ and list of HTTP ‘schemes’ to employ.
- class cowbird.api.schemas.Handler_RequestPathSchema(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.AcceptType(*arg, **kw)[source]
Bases:
colander.SchemaNode
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.ContentType(*arg, **kw)[source]
Bases:
colander.SchemaNode
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.RequestHeaderSchemaAPI(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.RequestHeaderSchemaUI(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.QueryRequestSchemaAPI(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.BaseRequestSchemaAPI(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.HeaderResponseSchema(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.BaseResponseSchemaAPI(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.BaseResponseBodySchema(code: int, description: str, **kw: Any)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.ErrorVerifyParamConditions(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.ErrorVerifyParamBodySchema(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.ErrorFallbackBodySchema(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.ErrorCallBodySchema(*arg, **kw)[source]
Bases:
ErrorFallbackBodySchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.ErrorResponseBodySchema(code: int, description: str, **kw: Any)[source]
Bases:
BaseResponseBodySchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.InternalServerErrorResponseBodySchema(**kw: Any)[source]
Bases:
ErrorResponseBodySchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.BadRequestResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.UnauthorizedResponseBodySchema(**kw: Any)[source]
Bases:
ErrorResponseBodySchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.UnauthorizedResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.HTTPForbiddenResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.NotFoundResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.MethodNotAllowedResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.NotAcceptableResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.UnprocessableEntityResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.InternalServerErrorResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.PermissionSchema(*arg, **kw)[source]
Bases:
colander.SchemaNode
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.PermissionListSchema(*args, **kw)[source]
Bases:
colander.SequenceSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.ResourceSchema(*arg, **kw)[source]
Bases:
colander.SchemaNode
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.ResourceListSchema(*args, **kw)[source]
Bases:
colander.SequenceSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.HandlerSummarySchema(*arg, **kw)[source]
Bases:
colander.SchemaNode
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.HandlerListSchema(*args, **kw)[source]
Bases:
colander.SequenceSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.HandlerConfigurationSchema(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.HandlerDetailSchema(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_GET_RequestSchema(*arg, **kw)[source]
Bases:
BaseRequestSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_GET_ResponseBodySchema(code: int, description: str, **kw: Any)[source]
Bases:
BaseResponseBodySchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_GET_OkResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_GET_BadRequestResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_POST_RequestBodySchema(*arg, **kw)[source]
Bases:
HandlerDetailSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_POST_RequestSchema(*arg, **kw)[source]
Bases:
BaseRequestSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_POST_CreatedResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_POST_BadRequestResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_SummaryBodyResponseSchema(code: int, description: str, **kw: Any)[source]
Bases:
BaseResponseBodySchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_GET_RequestSchema(*arg, **kw)[source]
Bases:
BaseRequestSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_GET_ResponseBodySchema(code: int, description: str, **kw: Any)[source]
Bases:
BaseResponseBodySchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_GET_OkResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_Check_NotFoundResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.HandlerResync_PUT_RequestSchema(*arg, **kw)[source]
Bases:
BaseRequestSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.HandlerResync_PUT_OkResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_POST_ForbiddenResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_POST_ConflictResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_POST_UnprocessableEntityResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handlers_POST_InternalServerErrorResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_PATCH_RequestBodySchema(*arg, **kw)[source]
Bases:
HandlerDetailSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_PATCH_RequestSchema(*arg, **kw)[source]
Bases:
BaseRequestSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_PATCH_ResponseBodySchema(code: int, description: str, **kw: Any)[source]
Bases:
Handler_GET_ResponseBodySchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_PATCH_OkResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_PATCH_BadRequestResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_PATCH_ForbiddenResponseSchema_ReservedKeyword(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_PATCH_ForbiddenResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Handler_PATCH_UnprocessableEntityResponseSchema(*arg, **kw)[source]
Bases:
Handlers_POST_UnprocessableEntityResponseSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.UserWebhook_POST_RequestBodySchema(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.UserWebhook_POST_RequestSchema(*arg, **kw)[source]
Bases:
BaseRequestSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.UserWebhook_POST_BadRequestResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.UserWebhook_POST_OkResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.UserWebhook_POST_InternalServerErrorResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.PermissionWebhook_POST_RequestBodySchema(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.PermissionWebhook_POST_RequestSchema(*arg, **kw)[source]
Bases:
BaseRequestSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.PermissionWebhook_POST_BadRequestResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.PermissionWebhook_POST_OkResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Version_GET_ResponseBodySchema(code: int, description: str, **kw: Any)[source]
Bases:
BaseResponseBodySchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Version_GET_OkResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.FailedDependencyErrorResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.Homepage_GET_OkResponseSchema(*arg, **kw)[source]
Bases:
BaseResponseSchemaAPI
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.
- class cowbird.api.schemas.SwaggerAPI_GET_OkResponseSchema(*arg, **kw)[source]
Bases:
colander.MappingSchema
Fundamental building block of schemas.
The constructor accepts these positional arguments:
typ
: The ‘type’ for this node. It should be an instance of a class that implements thecolander.interfaces.Type
interface. Iftyp
is not passed, a call to theschema_type()
method on this class is made to get a default type. (When subclassing,schema_type()
should be overridden to provide a reasonable default type).*children
: a sequence of subnodes. If the subnodes of this node are not known at construction time, they can later be added via theadd
method.
The constructor accepts these keyword arguments:
name
: The name of this node.typ
: The ‘type’ for this node can optionally be passed in as a keyword argument. See the documentation for the positional arg above.default
: The default serialization value for this node when not set. Ifdefault
iscolander.drop
, the node will be dropped from schema serialization. If not provided, the node will be serialized tocolander.null
.missing
: The default deserialization value for this node. If it is not provided, the missing value of this node will be the special marker valuecolander.required
, indicating that it is considered ‘required’. Whenmissing
iscolander.required
, therequired
computed attribute will beTrue
. Whenmissing
iscolander.drop
, the node is dropped from the schema if it isn’t set during deserialization.missing_msg
: Optional error message to be used if the value is required and missing.preparer
: Optional preparer for this node. It should be an object that implements thecolander.interfaces.Preparer
interface.validator
: Optional validator for this node. It should be an object that implements thecolander.interfaces.Validator
interface.after_bind
: A callback which is called after a clone of this node has ‘bound’ all of its values successfully. This callback is useful for performing arbitrary actions to the cloned node, or direct children of the cloned node (such as removing or adding children) at bind time. A ‘binding’ is the result of an execution of thebind
method of the clone’s prototype node, or one of the parents of the clone’s prototype nodes. The deepest nodes in the node tree are bound first, so theafter_bind
methods of the deepest nodes are called before the shallowest. Theafter_bind
callback should accept two values:node
andkw
.node
will be a clone of the bound node object,kw
will be the set of keywords passed to thebind
method.title
: The title of this node. Defaults to a titleization of thename
(underscores replaced with empty strings and the first letter of every resulting word capitalized). The title is used by higher-level systems (not by Colander itself).description
: The description for this node. Defaults to''
(the empty string). The description is used by higher-level systems (not by Colander itself).widget
: The ‘widget’ for this node. Defaults toNone
. The widget attribute is not interpreted by Colander itself, it is only meaningful to higher-level systems such as Deform.insert_before
: if supplied, it names a sibling defined by a superclass for its parent node; the current node will be inserted before the named node. It is not useful unless a mapping schema is inherited from another mapping schema, and you need to control the ordering of the resulting nodes.
Arbitrary keyword arguments remaining will be attached to the node object unmolested.