diff --git a/docs/platforms/python/integrations/django/index.mdx b/docs/platforms/python/integrations/django/index.mdx
index 5e16739a1a3cc..286619a822292 100644
--- a/docs/platforms/python/integrations/django/index.mdx
+++ b/docs/platforms/python/integrations/django/index.mdx
@@ -116,6 +116,7 @@ sentry_sdk.init(
django.db.models.signals.post_init,
],
cache_spans=False,
+ http_methods_to_capture=("GET",),
),
],
)
@@ -156,6 +157,18 @@ You can pass the following keyword arguments to `DjangoIntegration()`:
The default is `False`.
+- `http_methods_to_capture`:
+
+ A tuple containing all the HTTP methods that should create a transaction in Sentry.
+
+ The default is `("CONNECT", "DELETE", "GET", "PATCH", "POST", "PUT", "TRACE",)`.
+
+ (Note that `OPTIONS` and `HEAD` are missing by default.)
+
+
+ The `http_methods_to_capture` option.
+
+
## Supported Versions
- Django 1.11+
diff --git a/docs/platforms/python/integrations/flask/index.mdx b/docs/platforms/python/integrations/flask/index.mdx
index 135cc7e8af1f5..4441173e451d7 100644
--- a/docs/platforms/python/integrations/flask/index.mdx
+++ b/docs/platforms/python/integrations/flask/index.mdx
@@ -67,6 +67,7 @@ sentry_sdk.init(
integrations = [
FlaskIntegration(
transaction_style="url",
+ http_methods_to_capture=("GET",),
),
],
)
@@ -76,6 +77,9 @@ You can pass the following keyword arguments to `FlaskIntegration()`:
- `transaction_style`:
+ Sets the format or style that transactions are named.
+
+
```python
@app.route("/myurl/")
def myendpoint():
@@ -85,10 +89,22 @@ You can pass the following keyword arguments to `FlaskIntegration()`:
In the above code, you would set the transaction to:
- `/myurl/` if you set `transaction_style="url"`.
- - `myendpoint` if you set `transaction_style="endpoint"`
+ - `myendpoint` if you set `transaction_style="endpoint"`.
The default is `"endpoint"`.
+- `http_methods_to_capture`:
+
+ A tuple containing all the HTTP methods that should create a transaction in Sentry.
+
+ The default is `("CONNECT", "DELETE", "GET", "PATCH", "POST", "PUT", "TRACE",)`.
+
+ (Note that `OPTIONS` and `HEAD` are missing by default.)
+
+
+ The `http_methods_to_capture` option.
+
+
## Supported Versions
- Flask: 1.0+