Search Options

Results per page
Sort
Preferred Languages
Advance

Results 91 - 100 of 1,675 for Responses (0.04 sec)

  1. src/main/config/openapi/openapi-user.yaml

            '400':
              $ref: '#/components/responses/BadRequest'
            '401':
              $ref: '#/components/responses/Unauthorized'
            '404':
              $ref: '#/components/responses/NotFound'
            '500':
              $ref: '#/components/responses/InternalServerError'
    
    components:
      responses:
        BadRequest:
          description: Bad request
          content:
    Registered: Sat Dec 20 09:19:18 UTC 2025
    - Last Modified: Thu May 09 06:31:27 UTC 2024
    - 21.6K bytes
    - Viewed (0)
  2. docs/de/docs/tutorial/handling-errors.md

    ```
    
    /// note | Technische Details
    
    Sie könnten auch `from starlette.requests import Request` und `from starlette.responses import JSONResponse` verwenden.
    
    **FastAPI** bietet dieselben `starlette.responses` auch via `fastapi.responses` an, nur als Annehmlichkeit für Sie, den Entwickler. Aber die meisten verfügbaren Responses kommen direkt von Starlette. Dasselbe gilt für `Request`.
    
    ///
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 20:41:43 UTC 2025
    - 10.4K bytes
    - Viewed (0)
  3. tests/test_tutorial/test_generate_clients/test_tutorial001.py

    
    def test_post_items(client: TestClient):
        response = client.post("/items/", json={"name": "Foo", "price": 5})
        assert response.status_code == 200, response.text
        assert response.json() == {"message": "item received"}
    
    
    def test_get_items(client: TestClient):
        response = client.get("/items/")
        assert response.status_code == 200, response.text
        assert response.json() == [
            {"name": "Plumbus", "price": 3},
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Fri Dec 26 10:43:02 UTC 2025
    - 5.2K bytes
    - Viewed (0)
  4. tests/test_tutorial/test_separate_openapi_schemas/test_tutorial002.py

    def test_create_item(client: TestClient) -> None:
        response = client.post("/items/", json={"name": "Foo"})
        assert response.status_code == 200, response.text
        assert response.json() == {"name": "Foo", "description": None}
    
    
    def test_read_items(client: TestClient) -> None:
        response = client.get("/items/")
        assert response.status_code == 200, response.text
        assert response.json() == [
            {
                "name": "Portal Gun",
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 20 15:55:38 UTC 2025
    - 5K bytes
    - Viewed (0)
  5. docs/features/caching.md

    received followed by a cache hit or miss.  Critically in the cache hit scenario the server won’t send the response body.
    
    The response will have non-null `cacheResponse` and `networkResponse`. The cacheResponse will be used as the top level
    response only if the response code is HTTP/1.1 304 Not Modified.
     
     - CallStart
     - **CacheConditionalHit**
     - ConnectionAcquired
     - ... Standard Events...
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Sun Feb 06 02:19:09 UTC 2022
    - 3.1K bytes
    - Viewed (1)
  6. tests/test_annotated.py

        client = TestClient(app)
        response = client.get("/test1")
        assert response.status_code == 200
        assert response.json() == {"foo": "bar"}
    
        response = client.get("/test1", params={"var": "baz"})
        assert response.status_code == 200
        assert response.json() == {"foo": "baz"}
    
        response = client.get("/test2")
        assert response.status_code == 200
        assert response.json() == {"foo": "bar"}
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 18:19:10 UTC 2025
    - 9.6K bytes
    - Viewed (0)
  7. docs/es/docs/advanced/middleware.md

    Si una request entrante no se valida correctamente, se enviará un response `400`.
    
    ## `GZipMiddleware` { #gzipmiddleware }
    
    Maneja responses GZip para cualquier request que incluya `"gzip"` en el header `Accept-Encoding`.
    
    El middleware manejará tanto responses estándar como en streaming.
    
    {* ../../docs_src/advanced_middleware/tutorial003_py39.py hl[2,6] *}
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 20:41:43 UTC 2025
    - 4.7K bytes
    - Viewed (0)
  8. internal/http/response-recorder.go

    	"time"
    
    	"github.com/klauspost/compress/gzip"
    )
    
    // ResponseRecorder - is a wrapper to trap the http response
    // status code and to record the response body
    type ResponseRecorder struct {
    	http.ResponseWriter
    	io.ReaderFrom
    	StatusCode int
    	// Log body of 4xx or 5xx responses
    	LogErrBody bool
    	// Log body of all responses
    	LogAllBody bool
    
    	ttfbHeader time.Duration
    	ttfbBody   time.Duration
    
    	StartTime time.Time
    Registered: Sun Dec 28 19:28:13 UTC 2025
    - Last Modified: Sun Mar 30 00:56:02 UTC 2025
    - 5.5K bytes
    - Viewed (0)
  9. tests/test_additional_responses_custom_validationerror.py

        responses={422: {"description": "Error", "model": JsonApiError}},
    )
    async def a(id):
        pass  # pragma: no cover
    
    
    client = TestClient(app)
    
    
    def test_openapi_schema():
        response = client.get("/openapi.json")
        assert response.status_code == 200, response.text
        assert response.json() == {
            "openapi": "3.1.0",
            "info": {"title": "FastAPI", "version": "0.1.0"},
            "paths": {
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 21:25:59 UTC 2025
    - 2.9K bytes
    - Viewed (0)
  10. docs_src/additional_responses/tutorial002_py39.py

    from typing import Union
    
    from fastapi import FastAPI
    from fastapi.responses import FileResponse
    from pydantic import BaseModel
    
    
    class Item(BaseModel):
        id: str
        value: str
    
    
    app = FastAPI()
    
    
    @app.get(
        "/items/{item_id}",
        response_model=Item,
        responses={
            200: {
                "content": {"image/png": {}},
                "description": "Return the JSON item or an image.",
            }
        },
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 20:41:43 UTC 2025
    - 628 bytes
    - Viewed (0)
Back to top