Skip to content

Commit 12fd134

Browse files
committed
feat: Project resource supports client security settings
1 parent 00691a1 commit 12fd134

File tree

5 files changed

+329
-127
lines changed

5 files changed

+329
-127
lines changed

docs/resources/project.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ resource "sentry_project" "default" {
5858

5959
### Optional
6060

61+
- `client_security` (Block, Optional) Configure origin URLs which Sentry should accept events from. This is used for communication with clients like [sentry-javascript](https://github.com/getsentry/sentry-javascript). (see [below for nested schema](#nestedblock--client_security))
6162
- `default_key` (Boolean) Whether to create a default key. By default, Sentry will create a key for you. If you wish to manage keys manually, set this to false and create keys using the `sentry_key` resource.
6263
- `default_rules` (Boolean) Whether to create a default issue alert. Defaults to true where the behavior is to alert the user on every new issue.
6364
- `digests_max_delay` (Number) The maximum amount of time (in seconds) to wait between scheduling digests for delivery.
@@ -75,6 +76,18 @@ resource "sentry_project" "default" {
7576
- `id` (String) The ID of this resource.
7677
- `internal_id` (String) The internal ID for this project.
7778

79+
<a id="nestedblock--client_security"></a>
80+
### Nested Schema for `client_security`
81+
82+
Optional:
83+
84+
- `allowed_domains` (Set of String) A list of allowed domains. Examples: https://example.com, *, *.example.com, *:80.
85+
- `scrape_javascript` (Boolean) Enable JavaScript source fetching. Allow Sentry to scrape missing JavaScript source context when possible.
86+
- `security_token` (String) Security Token. Outbound requests matching Allowed Domains will have the header "{security_token_header}: {security_token}" appended.
87+
- `security_token_header` (String) Security Token Header. Outbound requests matching Allowed Domains will have the header "{security_token_header}: {security_token}" appended.
88+
- `verify_tls_ssl` (Boolean) Verify TLS/SSL. Outbound requests will verify TLS (sometimes known as SSL) connections.
89+
90+
7891
<a id="nestedatt--filters"></a>
7992
### Nested Schema for `filters`
8093

internal/apiclient/api.yaml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,18 @@ paths:
113113
type: string
114114
options:
115115
type: object
116+
allowedDomains:
117+
type: array
118+
items:
119+
type: string
120+
scrapeJavaScript:
121+
type: boolean
122+
securityToken:
123+
type: string
124+
securityTokenHeader:
125+
type: string
126+
verifySSL:
127+
type: boolean
116128
responses:
117129
"200":
118130
description: OK
@@ -407,6 +419,11 @@ components:
407419
- resolveAge
408420
- fingerprintingRules
409421
- groupingEnhancements
422+
- allowedDomains
423+
- scrapeJavaScript
424+
- securityToken
425+
- securityTokenHeader
426+
- verifySSL
410427
properties:
411428
organization:
412429
$ref: "#/components/schemas/Organization"
@@ -449,6 +466,19 @@ components:
449466
type: string
450467
groupingEnhancements:
451468
type: string
469+
allowedDomains:
470+
type: array
471+
items:
472+
type: string
473+
scrapeJavaScript:
474+
type: boolean
475+
securityToken:
476+
type: string
477+
securityTokenHeader:
478+
type: string
479+
nullable: true
480+
verifySSL:
481+
type: boolean
452482
ProjectKey:
453483
type: object
454484
required:

internal/apiclient/apiclient.gen.go

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)