Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 155 for Messages (0.14 sec)

  1. docs/en/docs/advanced/websockets.md

        **FastAPI** provides the same `WebSocket` directly just as a convenience for you, the developer. But it comes directly from Starlette.
    
    ## Await for messages and send messages
    
    In your WebSocket route you can `await` for messages and send messages.
    
    ```Python hl_lines="48-52"
    {!../../../docs_src/websockets/tutorial001.py!}
    ```
    
    You can receive and send binary, text, and JSON data.
    
    ## Try it
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu May 02 22:37:31 GMT 2024
    - 6.2K bytes
    - Viewed (0)
  2. docs/em/docs/advanced/openapi-callbacks.md

    ```
    
    !!! tip
         `callback_url` ๐Ÿ”ข ๐Ÿ”ข โš™๏ธ Pydantic <a href="https://docs.pydantic.dev/latest/concepts/types/#urls" class="external-link" target="_blank">๐Ÿ“›</a> ๐Ÿ†Ž.
    
    ๐Ÿ•ด ๐Ÿ†• ๐Ÿ‘œ `callbacks=messages_callback_router.routes` โŒ *โžก ๐Ÿ› ๏ธ ๐Ÿ‘จโ€๐ŸŽจ*. ๐Ÿ‘ฅ ๐Ÿ”œ ๐Ÿ‘€ โšซ๏ธโ” ๐Ÿ‘ˆ โญ.
    
    ## ๐Ÿ”ฌ โฒ
    
    โ˜‘ โฒ ๐Ÿ“Ÿ ๐Ÿ”œ ๐Ÿช€ ๐Ÿ™‡ ๐Ÿ”› ๐Ÿ‘† ๐Ÿ‘ ๐Ÿ› ๏ธ ๐Ÿ“ฑ.
    
    &amp; โšซ๏ธ ๐Ÿ”œ ๐ŸŽฒ ๐Ÿช€ ๐Ÿ“š โšช๏ธโžก๏ธ 1๏ธโƒฃ ๐Ÿ“ฑ โญ.
    
    โšซ๏ธ ๐Ÿ’ช 1๏ธโƒฃ โš–๏ธ 2๏ธโƒฃ โธ ๐Ÿ“Ÿ, ๐Ÿ’–:
    
    ```Python
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 6.6K bytes
    - Viewed (0)
  3. docs/fr/docs/advanced/additional-responses.md

    ```JSON hl_lines="4-16"
    {
        "components": {
            "schemas": {
                "Message": {
                    "title": "Message",
                    "required": [
                        "message"
                    ],
                    "type": "object",
                    "properties": {
                        "message": {
                            "title": "Message",
                            "type": "string"
                        }
                    }
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 9.6K bytes
    - Viewed (0)
  4. docs/en/docs/advanced/behind-a-proxy.md

    ### Checking the current `root_path`
    
    You can get the current `root_path` used by your application for each request, it is part of the `scope` dictionary (that's part of the ASGI spec).
    
    Here we are including it in the message just for demonstration purposes.
    
    ```Python hl_lines="8"
    {!../../../docs_src/behind_a_proxy/tutorial001.py!}
    ```
    
    Then, if you start Uvicorn with:
    
    <div class="termy">
    
    ```console
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu May 02 22:37:31 GMT 2024
    - 11.6K bytes
    - Viewed (2)
  5. docs/zh/docs/advanced/wsgi.md

    ```txt
    Hello, World from Flask!
    ```
    
    ๅนถไธ”ๅฆ‚ๆžœๆ‚จ่ฎฟ้—ฎ <a href="http://localhost:8000/v2" class="external-link" target="_blank">http://localhost:8000/v2</a>๏ผŒๆ‚จๅฐ†ไผš็œ‹ๅˆฐ็”ฑ FastAPI ่ฟ”ๅ›ž็š„ๅ“ๅบ”๏ผš
    
    ```JSON
    {
        "message": "Hello World"
    }
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 1.2K bytes
    - Viewed (0)
  6. tests/test_tutorial/test_header_params/test_tutorial003.py

                                "items": {
                                    "anyOf": [{"type": "string"}, {"type": "integer"}]
                                },
                            },
                            "msg": {"title": "Message", "type": "string"},
                            "type": {"title": "Error Type", "type": "string"},
                        },
                    },
                }
            },
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri Jan 12 14:52:00 GMT 2024
    - 4.1K bytes
    - Viewed (0)
  7. tests/test_tutorial/test_handling_errors/test_tutorial005.py

                                "items": {
                                    "anyOf": [{"type": "string"}, {"type": "integer"}]
                                },
                            },
                            "msg": {"title": "Message", "type": "string"},
                            "type": {"title": "Error Type", "type": "string"},
                        },
                    },
                }
            },
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 4.3K bytes
    - Viewed (0)
  8. tests/test_tutorial/test_bigger_applications/test_main_an.py

                ]
            }
        )
    
    
    def test_root_token_jessica(client: TestClient):
        response = client.get("/?token=jessica")
        assert response.status_code == 200
        assert response.json() == {"message": "Hello Bigger Applications!"}
    
    
    def test_root_with_no_token(client: TestClient):
        response = client.get("/")
        assert response.status_code == 422
        assert response.json() == IsDict(
            {
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 24.6K bytes
    - Viewed (0)
  9. tests/test_tutorial/test_bigger_applications/test_main_an_py39.py

            }
        )
    
    
    @needs_py39
    def test_root_token_jessica(client: TestClient):
        response = client.get("/?token=jessica")
        assert response.status_code == 200
        assert response.json() == {"message": "Hello Bigger Applications!"}
    
    
    @needs_py39
    def test_root_with_no_token(client: TestClient):
        response = client.get("/")
        assert response.status_code == 422
        assert response.json() == IsDict(
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 24.9K bytes
    - Viewed (0)
  10. tests/test_tutorial/test_query_params/test_tutorial006_py310.py

                                "items": {
                                    "anyOf": [{"type": "string"}, {"type": "integer"}]
                                },
                            },
                            "msg": {"title": "Message", "type": "string"},
                            "type": {"title": "Error Type", "type": "string"},
                        },
                    },
                    "HTTPValidationError": {
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 6.2K bytes
    - Viewed (0)
Back to top