diff --git a/javascript/sentry-conventions/src/attributes.ts b/javascript/sentry-conventions/src/attributes.ts index 28e62d02..1e1ff640 100644 --- a/javascript/sentry-conventions/src/attributes.ts +++ b/javascript/sentry-conventions/src/attributes.ts @@ -7525,6 +7525,29 @@ export const HTTP_REQUEST_RESPONSE_START = 'http.request.response_start'; */ export type HTTP_REQUEST_RESPONSE_START_TYPE = number; +// Path: model/attributes/http/http__request__same_origin.json + +/** + * Indicates that a URL has the same origin as the current page's origin in the browser. `http.request.same_origin` + * + * Attribute Value Type: `boolean` {@link HTTP_REQUEST_SAME_ORIGIN_TYPE} + * + * Apply Scrubbing: manual + * + * Attribute defined in OTEL: No + * Visibility: public + * + * Aliases: {@link URL_SAME_ORIGIN} `url.same_origin` + * + * @example true + */ +export const HTTP_REQUEST_SAME_ORIGIN = 'http.request.same_origin'; + +/** + * Type for {@link HTTP_REQUEST_SAME_ORIGIN} http.request.same_origin + */ +export type HTTP_REQUEST_SAME_ORIGIN_TYPE = boolean; + // Path: model/attributes/http/http__request__secure_connection_start.json /** @@ -13624,6 +13647,30 @@ export const URL_QUERY = 'url.query'; */ export type URL_QUERY_TYPE = string; +// Path: model/attributes/url/url__same_origin.json + +/** + * Indicates that a URL has the same origin as the current page's origin in the browser. `url.same_origin` + * + * Attribute Value Type: `boolean` {@link URL_SAME_ORIGIN_TYPE} + * + * Apply Scrubbing: manual + * + * Attribute defined in OTEL: No + * Visibility: public + * + * Aliases: {@link HTTP_REQUEST_SAME_ORIGIN} `http.request.same_origin` + * + * @deprecated Use {@link HTTP_REQUEST_SAME_ORIGIN} (http.request.same_origin) instead - This attribute is being deprecated in favor of http.request.same_origin. + * @example true + */ +export const URL_SAME_ORIGIN = 'url.same_origin'; + +/** + * Type for {@link URL_SAME_ORIGIN} url.same_origin + */ +export type URL_SAME_ORIGIN_TYPE = boolean; + // Path: model/attributes/url/url__scheme.json /** @@ -15100,6 +15147,7 @@ export const ATTRIBUTE_TYPE: Record = { 'http.request.resend_count': 'integer', 'http.request.response_end': 'double', 'http.request.response_start': 'double', + 'http.request.same_origin': 'boolean', 'http.request.secure_connection_start': 'double', 'http.request.time_to_first_byte': 'double', 'http.request.worker_start': 'double', @@ -15378,6 +15426,7 @@ export const ATTRIBUTE_TYPE: Record = { 'url.path.parameter.': 'string', 'url.port': 'integer', 'url.query': 'string', + 'url.same_origin': 'boolean', 'url.scheme': 'string', 'url.template': 'string', 'user_agent.original': 'string', @@ -15771,6 +15820,7 @@ export type AttributeName = | typeof HTTP_REQUEST_RESEND_COUNT | typeof HTTP_REQUEST_RESPONSE_END | typeof HTTP_REQUEST_RESPONSE_START + | typeof HTTP_REQUEST_SAME_ORIGIN | typeof HTTP_REQUEST_SECURE_CONNECTION_START | typeof HTTP_REQUEST_TIME_TO_FIRST_BYTE | typeof HTTP_REQUEST_WORKER_START @@ -16049,6 +16099,7 @@ export type AttributeName = | typeof URL_PATH_PARAMETER_KEY | typeof URL_PORT | typeof URL_QUERY + | typeof URL_SAME_ORIGIN | typeof URL_SCHEME | typeof URL_TEMPLATE | typeof USER_AGENT_ORIGINAL @@ -20755,6 +20806,18 @@ export const ATTRIBUTE_METADATA: Record = { example: 1732829555.7, changelog: [{ version: '0.4.0', prs: [228] }, { version: '0.1.0', prs: [134] }, { version: '0.0.0' }], }, + 'http.request.same_origin': { + brief: "Indicates that a URL has the same origin as the current page's origin in the browser.", + type: 'boolean', + applyScrubbing: { + key: 'manual', + }, + isInOtel: false, + visibility: 'public', + example: true, + aliases: ['url.same_origin'], + changelog: [{ version: 'next', prs: [456], description: 'Added http.request.same_origin attribute' }], + }, 'http.request.secure_connection_start': { brief: 'The UNIX timestamp representing the time immediately before the browser starts the handshake process to secure the current connection. If a secure connection is not used, the property returns zero.', @@ -24370,6 +24433,28 @@ export const ATTRIBUTE_METADATA: Record = { example: 'foo=bar&bar=baz', changelog: [{ version: '0.0.0' }], }, + 'url.same_origin': { + brief: "Indicates that a URL has the same origin as the current page's origin in the browser.", + type: 'boolean', + applyScrubbing: { + key: 'manual', + }, + isInOtel: false, + visibility: 'public', + example: true, + deprecation: { + replacement: 'http.request.same_origin', + reason: 'This attribute is being deprecated in favor of http.request.same_origin.', + }, + aliases: ['http.request.same_origin'], + changelog: [ + { + version: 'next', + prs: [456], + description: 'Added url.same_origin attribute, deprecated in favor of http.request.same_origin', + }, + ], + }, 'url.scheme': { brief: 'The URI scheme component identifying the used protocol.', type: 'string', @@ -25289,6 +25374,7 @@ export type Attributes = { [HTTP_REQUEST_RESEND_COUNT]?: HTTP_REQUEST_RESEND_COUNT_TYPE; [HTTP_REQUEST_RESPONSE_END]?: HTTP_REQUEST_RESPONSE_END_TYPE; [HTTP_REQUEST_RESPONSE_START]?: HTTP_REQUEST_RESPONSE_START_TYPE; + [HTTP_REQUEST_SAME_ORIGIN]?: HTTP_REQUEST_SAME_ORIGIN_TYPE; [HTTP_REQUEST_SECURE_CONNECTION_START]?: HTTP_REQUEST_SECURE_CONNECTION_START_TYPE; [HTTP_REQUEST_TIME_TO_FIRST_BYTE]?: HTTP_REQUEST_TIME_TO_FIRST_BYTE_TYPE; [HTTP_REQUEST_WORKER_START]?: HTTP_REQUEST_WORKER_START_TYPE; @@ -25567,6 +25653,7 @@ export type Attributes = { [URL_PATH_PARAMETER_KEY]?: URL_PATH_PARAMETER_KEY_TYPE; [URL_PORT]?: URL_PORT_TYPE; [URL_QUERY]?: URL_QUERY_TYPE; + [URL_SAME_ORIGIN]?: URL_SAME_ORIGIN_TYPE; [URL_SCHEME]?: URL_SCHEME_TYPE; [URL_TEMPLATE]?: URL_TEMPLATE_TYPE; [USER_AGENT_ORIGINAL]?: USER_AGENT_ORIGINAL_TYPE; diff --git a/model/attributes/http/http__request__same_origin.json b/model/attributes/http/http__request__same_origin.json new file mode 100644 index 00000000..d4568168 --- /dev/null +++ b/model/attributes/http/http__request__same_origin.json @@ -0,0 +1,19 @@ +{ + "key": "http.request.same_origin", + "brief": "Indicates that a URL has the same origin as the current page's origin in the browser.", + "type": "boolean", + "apply_scrubbing": { + "key": "manual" + }, + "is_in_otel": false, + "example": true, + "alias": ["url.same_origin"], + "visibility": "public", + "changelog": [ + { + "version": "next", + "prs": [456], + "description": "Added http.request.same_origin attribute" + } + ] +} diff --git a/model/attributes/url/url__same_origin.json b/model/attributes/url/url__same_origin.json new file mode 100644 index 00000000..74ea7c28 --- /dev/null +++ b/model/attributes/url/url__same_origin.json @@ -0,0 +1,24 @@ +{ + "key": "url.same_origin", + "brief": "Indicates that a URL has the same origin as the current page's origin in the browser.", + "type": "boolean", + "apply_scrubbing": { + "key": "manual" + }, + "is_in_otel": false, + "example": true, + "alias": ["http.request.same_origin"], + "deprecation": { + "_status": "backfill", + "replacement": "http.request.same_origin", + "reason": "This attribute is being deprecated in favor of http.request.same_origin." + }, + "visibility": "public", + "changelog": [ + { + "version": "next", + "prs": [456], + "description": "Added url.same_origin attribute, deprecated in favor of http.request.same_origin" + } + ] +} diff --git a/python/src/sentry_conventions/attributes.py b/python/src/sentry_conventions/attributes.py index c410a509..eb92ccaf 100644 --- a/python/src/sentry_conventions/attributes.py +++ b/python/src/sentry_conventions/attributes.py @@ -276,6 +276,7 @@ class _AttributeNamesMeta(type): "TRANSACTION", "TTFB_REQUESTTIME", "TTFB", + "URL_SAME_ORIGIN", "URL", } @@ -4513,6 +4514,20 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Example: 1732829555.7 """ + # Path: model/attributes/http/http__request__same_origin.json + HTTP_REQUEST_SAME_ORIGIN: Literal["http.request.same_origin"] = ( + "http.request.same_origin" + ) + """Indicates that a URL has the same origin as the current page's origin in the browser. + + Type: bool + Apply Scrubbing: manual + Defined in OTEL: No + Visibility: public + Aliases: url.same_origin + Example: true + """ + # Path: model/attributes/http/http__request__secure_connection_start.json HTTP_REQUEST_SECURE_CONNECTION_START: Literal[ "http.request.secure_connection_start" @@ -7873,6 +7888,19 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Example: "foo=bar&bar=baz" """ + # Path: model/attributes/url/url__same_origin.json + URL_SAME_ORIGIN: Literal["url.same_origin"] = "url.same_origin" + """Indicates that a URL has the same origin as the current page's origin in the browser. + + Type: bool + Apply Scrubbing: manual + Defined in OTEL: No + Visibility: public + Aliases: http.request.same_origin + DEPRECATED: Use http.request.same_origin instead - This attribute is being deprecated in favor of http.request.same_origin. + Example: true + """ + # Path: model/attributes/url/url__scheme.json URL_SCHEME: Literal["url.scheme"] = "url.scheme" """The URI scheme component identifying the used protocol. @@ -13505,6 +13533,22 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): ChangelogEntry(version="0.0.0"), ], ), + "http.request.same_origin": AttributeMetadata( + brief="Indicates that a URL has the same origin as the current page's origin in the browser.", + type=AttributeType.BOOLEAN, + apply_scrubbing=ApplyScrubbingInfo(key=ApplyScrubbing.MANUAL), + is_in_otel=False, + visibility=Visibility.PUBLIC, + example=True, + aliases=["url.same_origin"], + changelog=[ + ChangelogEntry( + version="next", + prs=[456], + description="Added http.request.same_origin attribute", + ), + ], + ), "http.request.secure_connection_start": AttributeMetadata( brief="The UNIX timestamp representing the time immediately before the browser starts the handshake process to secure the current connection. If a secure connection is not used, the property returns zero.", type=AttributeType.DOUBLE, @@ -17296,6 +17340,27 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): ChangelogEntry(version="0.0.0"), ], ), + "url.same_origin": AttributeMetadata( + brief="Indicates that a URL has the same origin as the current page's origin in the browser.", + type=AttributeType.BOOLEAN, + apply_scrubbing=ApplyScrubbingInfo(key=ApplyScrubbing.MANUAL), + is_in_otel=False, + visibility=Visibility.PUBLIC, + example=True, + deprecation=DeprecationInfo( + replacement="http.request.same_origin", + reason="This attribute is being deprecated in favor of http.request.same_origin.", + status=DeprecationStatus.BACKFILL, + ), + aliases=["http.request.same_origin"], + changelog=[ + ChangelogEntry( + version="next", + prs=[456], + description="Added url.same_origin attribute, deprecated in favor of http.request.same_origin", + ), + ], + ), "url.scheme": AttributeMetadata( brief="The URI scheme component identifying the used protocol.", type=AttributeType.STRING, @@ -18229,6 +18294,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): "http.request.resend_count": int, "http.request.response_end": float, "http.request.response_start": float, + "http.request.same_origin": bool, "http.request.secure_connection_start": float, "http.request.time_to_first_byte": float, "http.request.worker_start": float, @@ -18507,6 +18573,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): "url.path.parameter.": str, "url.port": int, "url.query": str, + "url.same_origin": bool, "url.scheme": str, "url.template": str, "url": str,