Commit 3100530e authored by Joel Collins's avatar Joel Collins
Browse files

Fixed leftover decorator references

parent 9ae2ae06
Loading
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -38,7 +38,7 @@ class ExampleIdentifyView(View):
        microscope = find_component("org.openflexure.microscope")

        # Return our microscope object,
        # let @marshal_with handle formatting the output
        # let schema handle formatting the output
        return microscope


@@ -59,7 +59,7 @@ class ExampleRenameView(View):
        rename(microscope, new_name)

        # Return our microscope object,
        # let @marshal_with handle formatting the output
        # let schema handle formatting the output
        return microscope


+1 −1
Original line number Diff line number Diff line
@@ -45,7 +45,7 @@ For example, if you are creating an API route, in which you expect parameters ``
        age = fields.Integer(required=True)
        job = fields.String(required=False, missing="Unknown")

To inform your POST method to expect these arguments, use the ``@use_args`` decorator:
To inform your POST method to expect these arguments, use the ``args`` class attribute:

.. code-block:: python

+1 −1
Original line number Diff line number Diff line
@@ -31,4 +31,4 @@ Swagger documentation

At this point, it is useful to introduce the automatically generated Swagger documentation. From any web browser, go to ``http://microscope.local/api/v2/swagger-ui`` (or replace ``microscope.local`` with your microscope's IP address if ``microscope.local`` doesn't work for your system).

This page uses `SwaggerUI <https://swagger.io/tools/swagger-ui/>`_ to provide visual, interactive API documentation. Find your extensions URL in the documentation under the ``extensions`` group. Basic documentation about the parameters required for your POST method should be visible, as well as an interactive example filled out with the example request given in ``@use_body``.
This page uses `SwaggerUI <https://swagger.io/tools/swagger-ui/>`_ to provide visual, interactive API documentation. Find your extensions URL in the documentation under the ``extensions`` group. Basic documentation about the parameters required for your POST method should be visible, as well as an interactive example filled out with the example request given in the view ``schema``.