Skip to content

basic docs on URL formats #80

@dcsan

Description

@dcsan

hi! I haven't used the Django framework before, so I'm new to this... but i've used a lot of frameworks. I'm trying to figure out the basics here.
I'm guessing there are minimal docs since this is meant to emulate Django?

how to read query params

looking here
http://www.django-rest-framework.org/api-guide/requests/#query_params

@app.route('/parse/', methods=['GET', 'POST'])
def parse():
    text = request.data.get('sent', '')
    blob = {
        'data': request.data,
        'params': request.query_params,
        'hello': 'world',
        'text': text
    }
    print('blob', blob)
    return blob

app.run(debug=True)

gives error:

AttributeError: 'APIRequest' object has no attribute 'query_params'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions