Ejemplo n.º 1
0
class ReportGetSchema(ma.Schema):
    """Schema for querying for a report"""

    id = ma.Integer(required=True)

    class Meta:
        strict = True
Ejemplo n.º 2
0
class HashGetSchema(ma.Schema):
    """Schema for fetching a hash, it can use any one of the three shown below"""

    id = ma.Integer(required=False)
    password = ma.String(required=False)

    class Meta:
        strict = True
Ejemplo n.º 3
0
class JobPostSchema(ma.Schema):
    """Schema for finishing a job"""

    id = ma.Integer(required=True)
    password = ma.String(required=True)

    class Meta:
        strict = True
Ejemplo n.º 4
0
class ReportPostSchema(ma.Schema):
    """Schema for adding a report"""

    hash_id = ma.Integer(required=True)
    info = ma.String(required=False)

    class Meta:
        strict = True
Ejemplo n.º 5
0
class ClientGetSchema(ma.Schema):
    """Schema for querying for a client"""

    id = ma.Integer(required=False)
    username = ma.String(required=False)

    class Meta:
        strict = True
Ejemplo n.º 6
0
class HashDeleteSchema(ma.Schema):
    """Schema for deleting a hash, it can use any one of the three shown below,
    similar to HashGetSchema"""

    id = ma.Integer(required=False)
    password = ma.String(required=False)

    class Meta:
        strict = True