diff --git a/internal/provider/resource_auth0_hook.go b/internal/provider/resource_auth0_hook.go index 74482c70d..0909742e6 100644 --- a/internal/provider/resource_auth0_hook.go +++ b/internal/provider/resource_auth0_hook.go @@ -12,6 +12,8 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/v2/diag" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/validation" + + "github.com/auth0/terraform-provider-auth0/internal/value" ) func newHook() *schema.Resource { @@ -79,8 +81,9 @@ func newHook() *schema.Resource { } func createHook(ctx context.Context, d *schema.ResourceData, m interface{}) diag.Diagnostics { - hook := expandHook(d) api := m.(*management.Management) + + hook := expandHook(d) if err := api.Hook.Create(hook); err != nil { return diag.FromErr(err) } @@ -181,42 +184,36 @@ func checkForUntrackedHookSecrets(ctx context.Context, d *schema.ResourceData, m func upsertHookSecrets(ctx context.Context, d *schema.ResourceData, m interface{}) error { if d.IsNewResource() || d.HasChange("secrets") { - hookSecrets := expandHookSecrets(d) api := m.(*management.Management) - return api.Hook.ReplaceSecrets(d.Id(), hookSecrets) + + hookSecrets := value.MapOfStrings(d.GetRawConfig().GetAttr("secrets")) + if hookSecrets == nil { + return nil + } + + return api.Hook.ReplaceSecrets(d.Id(), *hookSecrets) } return nil } func expandHook(d *schema.ResourceData) *management.Hook { + config := d.GetRawConfig() + hook := &management.Hook{ - Name: String(d, "name"), - Script: String(d, "script"), - TriggerID: String(d, "trigger_id", IsNewResource()), - Enabled: Bool(d, "enabled"), + Name: value.String(config.GetAttr("name")), + Script: value.String(config.GetAttr("script")), + Enabled: value.Bool(config.GetAttr("enabled")), + Dependencies: value.MapOfStrings(config.GetAttr("dependencies")), } - if deps := Map(d, "dependencies"); deps != nil { - hook.Dependencies = &deps + if d.IsNewResource() { + hook.TriggerID = value.String(config.GetAttr("trigger_id")) } return hook } -func expandHookSecrets(d *schema.ResourceData) management.HookSecrets { - hookSecrets := management.HookSecrets{} - secrets := Map(d, "secrets") - - for key, value := range secrets { - if strVal, ok := value.(string); ok { - hookSecrets[key] = strVal - } - } - - return hookSecrets -} - func validateHookName() schema.SchemaValidateDiagFunc { hookNameValidation := validation.StringMatch( regexp.MustCompile(`^[^\s-][\w -]+[^\s-]$`), diff --git a/internal/provider/resource_auth0_hook_test.go b/internal/provider/resource_auth0_hook_test.go index 15efafa07..170914cfd 100644 --- a/internal/provider/resource_auth0_hook_test.go +++ b/internal/provider/resource_auth0_hook_test.go @@ -17,6 +17,17 @@ func TestAccHook(t *testing.T) { resource.Test(t, resource.TestCase{ ProviderFactories: testProviders(httpRecorder), Steps: []resource.TestStep{ + { + Config: testAccHookEmpty, + Check: resource.ComposeTestCheckFunc( + resource.TestCheckResourceAttr("auth0_hook.my_hook", "name", "pre-user-reg-hook"), + resource.TestCheckResourceAttr("auth0_hook.my_hook", "script", "function (user, context, callback) { callback(null, { user }); }"), + resource.TestCheckResourceAttr("auth0_hook.my_hook", "trigger_id", "pre-user-registration"), + resource.TestCheckResourceAttrSet("auth0_hook.my_hook", "enabled"), + resource.TestCheckNoResourceAttr("auth0_hook.my_hook", "secrets"), + resource.TestCheckNoResourceAttr("auth0_hook.my_hook", "dependencies"), + ), + }, { Config: fmt.Sprintf(testAccHookCreate, ""), Check: resource.ComposeTestCheckFunc( @@ -30,6 +41,14 @@ func TestAccHook(t *testing.T) { }) } +const testAccHookEmpty = ` +resource "auth0_hook" "my_hook" { + name = "pre-user-reg-hook" + script = "function (user, context, callback) { callback(null, { user }); }" + trigger_id = "pre-user-registration" +} +` + const testAccHookCreate = ` resource "auth0_hook" "my_hook" { name = "pre-user-reg-hook" @@ -81,6 +100,17 @@ func TestAccHookSecrets(t *testing.T) { resource.TestCheckNoResourceAttr("auth0_hook.my_hook", "secrets.bar"), ), }, + { + Config: fmt.Sprintf(testAccHookCreate, testAccHookSecretsEmpty), + Check: resource.ComposeTestCheckFunc( + resource.TestCheckResourceAttr("auth0_hook.my_hook", "name", "pre-user-reg-hook"), + resource.TestCheckResourceAttr("auth0_hook.my_hook", "script", "function (user, context, callback) { callback(null, { user }); }"), + resource.TestCheckResourceAttr("auth0_hook.my_hook", "trigger_id", "pre-user-registration"), + resource.TestCheckResourceAttr("auth0_hook.my_hook", "enabled", "true"), + resource.TestCheckResourceAttr("auth0_hook.my_hook", "secrets.%", "0"), + resource.TestCheckResourceAttr("auth0_hook.my_hook", "dependencies.%", "0"), + ), + }, }, }) } @@ -113,6 +143,11 @@ const testAccHookSecretsUpdateAndRemoval = ` } ` +const testAccHookSecretsEmpty = ` + dependencies = {} + secrets = {} +` + func TestHookNameRegexp(t *testing.T) { for givenHookName, expectedError := range map[string]bool{ "my-hook-1": false, diff --git a/internal/provider/resource_auth0_log_stream.go b/internal/provider/resource_auth0_log_stream.go index e4e89390d..38310e849 100644 --- a/internal/provider/resource_auth0_log_stream.go +++ b/internal/provider/resource_auth0_log_stream.go @@ -6,10 +6,13 @@ import ( "net/http" "github.com/auth0/go-auth0/management" + "github.com/hashicorp/go-cty/cty" "github.com/hashicorp/go-multierror" "github.com/hashicorp/terraform-plugin-sdk/v2/diag" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/validation" + + "github.com/auth0/terraform-provider-auth0/internal/value" ) func newLogStream() *schema.Resource { @@ -223,21 +226,21 @@ func newLogStream() *schema.Resource { } func createLogStream(ctx context.Context, d *schema.ResourceData, m interface{}) diag.Diagnostics { - logStream := expandLogStream(d) - api := m.(*management.Management) + + logStream := expandLogStream(d) if err := api.LogStream.Create(logStream); err != nil { return diag.FromErr(err) } d.SetId(logStream.GetID()) - // The Management API only allows updating a log stream's status. Therefore, - // if the status field was present in the configuration, we perform an - // additional operation to modify it. - status := String(d, "status") - if status != nil && status != logStream.Status { - if err := api.LogStream.Update(logStream.GetID(), &management.LogStream{Status: status}); err != nil { + // The Management API only allows updating a log stream's status. + // Therefore, if the status field was present in the configuration, + // we perform an additional operation to modify it. + status := d.Get("status").(string) + if status != "" && status != logStream.GetStatus() { + if err := api.LogStream.Update(logStream.GetID(), &management.LogStream{Status: &status}); err != nil { return diag.FromErr(err) } } @@ -247,21 +250,20 @@ func createLogStream(ctx context.Context, d *schema.ResourceData, m interface{}) func readLogStream(ctx context.Context, d *schema.ResourceData, m interface{}) diag.Diagnostics { api := m.(*management.Management) + logStream, err := api.LogStream.Read(d.Id()) if err != nil { - if mErr, ok := err.(management.Error); ok { - if mErr.Status() == http.StatusNotFound { - d.SetId("") - return nil - } + if mErr, ok := err.(management.Error); ok && mErr.Status() == http.StatusNotFound { + d.SetId("") + return nil } return diag.FromErr(err) } result := multierror.Append( - d.Set("name", logStream.Name), - d.Set("status", logStream.Status), - d.Set("type", logStream.Type), + d.Set("name", logStream.GetName()), + d.Set("status", logStream.GetStatus()), + d.Set("type", logStream.GetType()), d.Set("filters", logStream.Filters), d.Set("sink", flattenLogStreamSink(logStream.Sink)), ) @@ -270,8 +272,9 @@ func readLogStream(ctx context.Context, d *schema.ResourceData, m interface{}) d } func updateLogStream(ctx context.Context, d *schema.ResourceData, m interface{}) diag.Diagnostics { - logStream := expandLogStream(d) api := m.(*management.Management) + + logStream := expandLogStream(d) if err := api.LogStream.Update(d.Id(), logStream); err != nil { return diag.FromErr(err) } @@ -281,15 +284,15 @@ func updateLogStream(ctx context.Context, d *schema.ResourceData, m interface{}) func deleteLogStream(ctx context.Context, d *schema.ResourceData, m interface{}) diag.Diagnostics { api := m.(*management.Management) + if err := api.LogStream.Delete(d.Id()); err != nil { - if mErr, ok := err.(management.Error); ok { - if mErr.Status() == http.StatusNotFound { - d.SetId("") - return nil - } + if mErr, ok := err.(management.Error); ok && mErr.Status() == http.StatusNotFound { + d.SetId("") + return nil } } + d.SetId("") return nil } @@ -363,86 +366,120 @@ func flattenLogStreamSinkSumo(o *management.LogStreamSinkSumo) interface{} { } } -func expandLogStream(d ResourceData) *management.LogStream { +func expandLogStream(d *schema.ResourceData) *management.LogStream { + config := d.GetRawConfig() + logStream := &management.LogStream{ - Name: String(d, "name"), - Type: String(d, "type", IsNewResource()), - Status: String(d, "status", Not(IsNewResource())), - Filters: List(d, "filters").List(), + Name: value.String(config.GetAttr("name")), } - streamType := d.Get("type").(string) - List(d, "sink").Elem(func(d ResourceData) { - switch streamType { + logStreamType := value.String(config.GetAttr("type")) + if d.IsNewResource() { + logStream.Type = logStreamType + } + + if !d.IsNewResource() { + logStream.Status = value.String(config.GetAttr("status")) + } + + filtersConfig := config.GetAttr("filters") + if !filtersConfig.IsNull() { + filters := make([]map[string]string, 0) + + filtersConfig.ForEachElement(func(_ cty.Value, filter cty.Value) (stop bool) { + filters = append(filters, *value.MapOfStrings(filter)) + return stop + }) + + logStream.Filters = &filters + } + + config.GetAttr("sink").ForEachElement(func(_ cty.Value, sink cty.Value) (stop bool) { + switch *logStreamType { case management.LogStreamTypeAmazonEventBridge: // LogStreamTypeAmazonEventBridge cannot be updated. if d.IsNewResource() { - logStream.Sink = expandLogStreamSinkAmazonEventBridge(d) + logStream.Sink = expandLogStreamSinkAmazonEventBridge(sink) } case management.LogStreamTypeAzureEventGrid: // LogStreamTypeAzureEventGrid cannot be updated. if d.IsNewResource() { - logStream.Sink = expandLogStreamSinkAzureEventGrid(d) + logStream.Sink = expandLogStreamSinkAzureEventGrid(sink) } case management.LogStreamTypeHTTP: - logStream.Sink = expandLogStreamSinkHTTP(d) + logStream.Sink = expandLogStreamSinkHTTP(sink) case management.LogStreamTypeDatadog: - logStream.Sink = expandLogStreamSinkDatadog(d) + logStream.Sink = expandLogStreamSinkDatadog(sink) case management.LogStreamTypeSplunk: - logStream.Sink = expandLogStreamSinkSplunk(d) + logStream.Sink = expandLogStreamSinkSplunk(sink) case management.LogStreamTypeSumo: - logStream.Sink = expandLogStreamSinkSumo(d) + logStream.Sink = expandLogStreamSinkSumo(sink) default: - log.Printf("[WARN]: Unsupported log stream sink %s", streamType) + log.Printf("[WARN]: Unsupported log stream sink %s", logStream.GetType()) log.Printf("[WARN]: Raise an issue with the auth0 provider in order to support it:") log.Printf("[WARN]: https://github.com/auth0/terraform-provider-auth0/issues/new") } + + return stop }) return logStream } -func expandLogStreamSinkAmazonEventBridge(d ResourceData) *management.LogStreamSinkAmazonEventBridge { +func expandLogStreamSinkAmazonEventBridge(config cty.Value) *management.LogStreamSinkAmazonEventBridge { return &management.LogStreamSinkAmazonEventBridge{ - AccountID: String(d, "aws_account_id"), - Region: String(d, "aws_region"), + AccountID: value.String(config.GetAttr("aws_account_id")), + Region: value.String(config.GetAttr("aws_region")), } } -func expandLogStreamSinkAzureEventGrid(d ResourceData) *management.LogStreamSinkAzureEventGrid { +func expandLogStreamSinkAzureEventGrid(config cty.Value) *management.LogStreamSinkAzureEventGrid { return &management.LogStreamSinkAzureEventGrid{ - SubscriptionID: String(d, "azure_subscription_id"), - ResourceGroup: String(d, "azure_resource_group"), - Region: String(d, "azure_region"), - PartnerTopic: String(d, "azure_partner_topic"), + SubscriptionID: value.String(config.GetAttr("azure_subscription_id")), + ResourceGroup: value.String(config.GetAttr("azure_resource_group")), + Region: value.String(config.GetAttr("azure_region")), + PartnerTopic: value.String(config.GetAttr("azure_partner_topic")), } } -func expandLogStreamSinkHTTP(d ResourceData) *management.LogStreamSinkHTTP { - return &management.LogStreamSinkHTTP{ - ContentFormat: String(d, "http_content_format"), - ContentType: String(d, "http_content_type"), - Endpoint: String(d, "http_endpoint"), - Authorization: String(d, "http_authorization"), - CustomHeaders: List(d, "http_custom_headers").List(), +func expandLogStreamSinkHTTP(config cty.Value) *management.LogStreamSinkHTTP { + httpSink := &management.LogStreamSinkHTTP{ + ContentFormat: value.String(config.GetAttr("http_content_format")), + ContentType: value.String(config.GetAttr("http_content_type")), + Endpoint: value.String(config.GetAttr("http_endpoint")), + Authorization: value.String(config.GetAttr("http_authorization")), + } + + customHeadersConfig := config.GetAttr("http_custom_headers") + if !customHeadersConfig.IsNull() { + customHeaders := make([]map[string]string, 0) + + customHeadersConfig.ForEachElement(func(_ cty.Value, httpHeader cty.Value) (stop bool) { + customHeaders = append(customHeaders, *value.MapOfStrings(httpHeader)) + return stop + }) + + httpSink.CustomHeaders = &customHeaders } + + return httpSink } -func expandLogStreamSinkDatadog(d ResourceData) *management.LogStreamSinkDatadog { +func expandLogStreamSinkDatadog(config cty.Value) *management.LogStreamSinkDatadog { return &management.LogStreamSinkDatadog{ - Region: String(d, "datadog_region"), - APIKey: String(d, "datadog_api_key"), + Region: value.String(config.GetAttr("datadog_region")), + APIKey: value.String(config.GetAttr("datadog_api_key")), } } -func expandLogStreamSinkSplunk(d ResourceData) *management.LogStreamSinkSplunk { +func expandLogStreamSinkSplunk(config cty.Value) *management.LogStreamSinkSplunk { return &management.LogStreamSinkSplunk{ - Domain: String(d, "splunk_domain"), - Token: String(d, "splunk_token"), - Port: String(d, "splunk_port"), - Secure: Bool(d, "splunk_secure"), + Domain: value.String(config.GetAttr("splunk_domain")), + Token: value.String(config.GetAttr("splunk_token")), + Port: value.String(config.GetAttr("splunk_port")), + Secure: value.Bool(config.GetAttr("splunk_secure")), } } -func expandLogStreamSinkSumo(d ResourceData) *management.LogStreamSinkSumo { +func expandLogStreamSinkSumo(config cty.Value) *management.LogStreamSinkSumo { return &management.LogStreamSinkSumo{ - SourceAddress: String(d, "sumo_source_address"), + SourceAddress: value.String(config.GetAttr("sumo_source_address")), } } diff --git a/internal/provider/resource_auth0_log_stream_test.go b/internal/provider/resource_auth0_log_stream_test.go index b50381219..a54a18285 100644 --- a/internal/provider/resource_auth0_log_stream_test.go +++ b/internal/provider/resource_auth0_log_stream_test.go @@ -115,6 +115,18 @@ func TestAccLogStreamHTTP(t *testing.T) { resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "sink.0.http_custom_headers.1.value", "foo"), ), }, + { + Config: template.ParseTestName(testAccLogStreamHTTPConfigEmptyCustomHTTPHeaders, t.Name()), + Check: resource.ComposeTestCheckFunc( + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "name", fmt.Sprintf("Acceptance-Test-LogStream-http-new-%s", t.Name())), + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "type", "http"), + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "sink.0.http_endpoint", "https://example.com/logs"), + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "sink.0.http_content_type", "application/json"), + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "sink.0.http_content_format", "JSONLINES"), + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "sink.0.http_authorization", "AKIAXXXXXXXXXXXXXXXX"), + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "sink.0.http_custom_headers.#", "0"), + ), + }, }, }) } @@ -195,6 +207,20 @@ resource "auth0_log_stream" "my_log_stream" { } ` +const testAccLogStreamHTTPConfigEmptyCustomHTTPHeaders = ` +resource "auth0_log_stream" "my_log_stream" { + name = "Acceptance-Test-LogStream-http-new-{{.testName}}" + type = "http" + sink { + http_endpoint = "https://example.com/logs" + http_content_type = "application/json" + http_content_format = "JSONLINES" + http_authorization = "AKIAXXXXXXXXXXXXXXXX" + http_custom_headers = [] + } +} +` + func TestAccLogStreamEventBridge(t *testing.T) { httpRecorder := recorder.New(t) @@ -511,6 +537,15 @@ func TestAccLogStreamSumo(t *testing.T) { resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "sink.0.sumo_source_address", "prod.sumo.com"), ), }, + { + Config: template.ParseTestName(logStreamSumoConfigUpdateWithEmptyFilters, t.Name()), + Check: resource.ComposeTestCheckFunc( + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "name", fmt.Sprintf("Acceptance-Test-LogStream-sumo-%s", t.Name())), + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "type", "sumo"), + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "filters.#", "0"), + resource.TestCheckResourceAttr("auth0_log_stream.my_log_stream", "sink.0.sumo_source_address", "prod.sumo.com"), + ), + }, }, }) } @@ -533,10 +568,12 @@ resource "auth0_log_stream" "my_log_stream" { } } ` + const logStreamSumoConfigUpdateWithFilters = ` resource "auth0_log_stream" "my_log_stream" { name = "Acceptance-Test-LogStream-sumo-{{.testName}}" type = "sumo" + filters = [ { type = "category" @@ -547,8 +584,22 @@ resource "auth0_log_stream" "my_log_stream" { name = "auth.signup.fail" } ] + sink { - sumo_source_address = "prod.sumo.com" + sumo_source_address = "prod.sumo.com" + } +} +` + +const logStreamSumoConfigUpdateWithEmptyFilters = ` +resource "auth0_log_stream" "my_log_stream" { + name = "Acceptance-Test-LogStream-sumo-{{.testName}}" + type = "sumo" + + filters = [ ] + + sink { + sumo_source_address = "prod.sumo.com" } } ` diff --git a/internal/provider/resource_auth0_prompt.go b/internal/provider/resource_auth0_prompt.go index 9be4c42b4..9306fbd63 100644 --- a/internal/provider/resource_auth0_prompt.go +++ b/internal/provider/resource_auth0_prompt.go @@ -4,11 +4,14 @@ import ( "context" "github.com/auth0/go-auth0/management" + "github.com/hashicorp/go-cty/cty" "github.com/hashicorp/go-multierror" "github.com/hashicorp/terraform-plugin-sdk/v2/diag" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/validation" + + "github.com/auth0/terraform-provider-auth0/internal/value" ) func newPrompt() *schema.Resource { @@ -26,6 +29,7 @@ func newPrompt() *schema.Resource { "universal_login_experience": { Type: schema.TypeString, Optional: true, + Computed: true, ValidateFunc: validation.StringInSlice([]string{ "new", "classic", }, false), @@ -40,6 +44,7 @@ func newPrompt() *schema.Resource { "webauthn_platform_first_factor": { Type: schema.TypeBool, Optional: true, + Computed: true, Description: "Determines if the login screen uses identifier and biometrics first.", }, }, @@ -71,7 +76,7 @@ func readPrompt(ctx context.Context, d *schema.ResourceData, m interface{}) diag func updatePrompt(ctx context.Context, d *schema.ResourceData, m interface{}) diag.Diagnostics { api := m.(*management.Management) - prompt := expandPrompt(d) + prompt := expandPrompt(d.GetRawConfig()) if err := api.Prompt.Update(prompt); err != nil { return diag.FromErr(err) } @@ -84,10 +89,16 @@ func deletePrompt(ctx context.Context, d *schema.ResourceData, m interface{}) di return nil } -func expandPrompt(d *schema.ResourceData) *management.Prompt { - return &management.Prompt{ - UniversalLoginExperience: d.Get("universal_login_experience").(string), - IdentifierFirst: Bool(d, "identifier_first"), - WebAuthnPlatformFirstFactor: Bool(d, "webauthn_platform_first_factor"), +func expandPrompt(d cty.Value) *management.Prompt { + prompt := management.Prompt{ + IdentifierFirst: value.Bool(d.GetAttr("identifier_first")), + WebAuthnPlatformFirstFactor: value.Bool(d.GetAttr("webauthn_platform_first_factor")), + } + + ule := d.GetAttr("universal_login_experience") + if !ule.IsNull() { + prompt.UniversalLoginExperience = ule.AsString() } + + return &prompt } diff --git a/internal/provider/resource_auth0_prompt_test.go b/internal/provider/resource_auth0_prompt_test.go index 800075627..13b214ad5 100644 --- a/internal/provider/resource_auth0_prompt_test.go +++ b/internal/provider/resource_auth0_prompt_test.go @@ -8,6 +8,12 @@ import ( "github.com/auth0/terraform-provider-auth0/internal/recorder" ) +const testAccPromptEmpty = ` +resource "auth0_prompt" "prompt" { + identifier_first = false # Required by API to include at least one property +} +` + const testAccPromptCreate = ` resource "auth0_prompt" "prompt" { universal_login_experience = "classic" @@ -38,6 +44,14 @@ func TestAccPrompt(t *testing.T) { resource.Test(t, resource.TestCase{ ProviderFactories: testProviders(httpRecorder), Steps: []resource.TestStep{ + { + Config: testAccPromptEmpty, + Check: resource.ComposeTestCheckFunc( + resource.TestCheckResourceAttrSet("auth0_prompt.prompt", "universal_login_experience"), + resource.TestCheckResourceAttr("auth0_prompt.prompt", "identifier_first", "false"), + resource.TestCheckResourceAttrSet("auth0_prompt.prompt", "webauthn_platform_first_factor"), + ), + }, { Config: testAccPromptCreate, Check: resource.ComposeTestCheckFunc( @@ -62,6 +76,14 @@ func TestAccPrompt(t *testing.T) { resource.TestCheckResourceAttr("auth0_prompt.prompt", "webauthn_platform_first_factor", "true"), ), }, + { + Config: testAccPromptEmpty, + Check: resource.ComposeTestCheckFunc( + resource.TestCheckResourceAttr("auth0_prompt.prompt", "universal_login_experience", "new"), + resource.TestCheckResourceAttr("auth0_prompt.prompt", "identifier_first", "false"), + resource.TestCheckResourceAttr("auth0_prompt.prompt", "webauthn_platform_first_factor", "true"), + ), + }, }, }) } diff --git a/test/data/recordings/TestAccHook.yaml b/test/data/recordings/TestAccHook.yaml index 4d2b59d6e..cc76a0928 100644 --- a/test/data/recordings/TestAccHook.yaml +++ b/test/data/recordings/TestAccHook.yaml @@ -6,20 +6,20 @@ interactions: proto: HTTP/1.1 proto_major: 1 proto_minor: 1 - content_length: 156 + content_length: 141 transfer_encoding: [ ] trailer: { } host: terraform-provider-auth0-dev.eu.auth0.com remote_addr: "" request_uri: "" body: | - {"name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","triggerId":"pre-user-registration","enabled":true} + {"name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","triggerId":"pre-user-registration"} form: { } headers: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks method: POST response: @@ -28,9 +28,9 @@ interactions: proto_minor: 0 transfer_encoding: [ ] trailer: { } - content_length: -1 + content_length: 208 uncompressed: false - body: '{"id":"01GBPZWEFDT9RFR6PN6939RZZE","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"triggerId":"pre-user-registration","enabled":true}' + body: '{"id":"01GEPVQEH9SX3RSTYY561TR92N","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"triggerId":"pre-user-registration","enabled":false}' headers: Content-Type: - application/json; charset=utf-8 @@ -55,8 +55,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWEFDT9RFR6PN6939RZZE/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N method: GET response: proto: HTTP/2.0 @@ -66,7 +66,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{}' + body: '{"id":"01GEPVQEH9SX3RSTYY561TR92N","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"enabled":false,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 @@ -91,8 +91,44 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWEFDT9RFR6PN6939RZZE + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N/secrets + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: 2 + uncompressed: false + body: '{}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 3 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N method: GET response: proto: HTTP/2.0 @@ -102,14 +138,14 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWEFDT9RFR6PN6939RZZE","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"enabled":true,"triggerId":"pre-user-registration"}' + body: '{"id":"01GEPVQEH9SX3RSTYY561TR92N","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"enabled":false,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 status: 200 OK code: 200 duration: 1ms - - id: 3 + - id: 4 request: proto: HTTP/1.1 proto_major: 1 @@ -127,8 +163,44 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWEFDT9RFR6PN6939RZZE/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N/secrets + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: 2 + uncompressed: false + body: '{}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 5 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N method: GET response: proto: HTTP/2.0 @@ -138,6 +210,42 @@ interactions: trailer: { } content_length: -1 uncompressed: true + body: '{"id":"01GEPVQEH9SX3RSTYY561TR92N","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"enabled":false,"triggerId":"pre-user-registration"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 6 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N/secrets + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: 2 + uncompressed: false body: '{}' headers: Content-Type: @@ -145,7 +253,43 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 4 + - id: 7 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 120 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","enabled":true} + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N + method: PATCH + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"01GEPVQEH9SX3RSTYY561TR92N","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"triggerId":"pre-user-registration","enabled":true}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 8 request: proto: HTTP/1.1 proto_major: 1 @@ -163,8 +307,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWEFDT9RFR6PN6939RZZE + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N method: GET response: proto: HTTP/2.0 @@ -174,14 +318,50 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWEFDT9RFR6PN6939RZZE","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"enabled":true,"triggerId":"pre-user-registration"}' + body: '{"id":"01GEPVQEH9SX3RSTYY561TR92N","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"enabled":true,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 status: 200 OK code: 200 duration: 1ms - - id: 5 + - id: 9 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N/secrets + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: 2 + uncompressed: false + body: '{}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 10 request: proto: HTTP/1.1 proto_major: 1 @@ -199,8 +379,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWEFDT9RFR6PN6939RZZE/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N method: GET response: proto: HTTP/2.0 @@ -210,6 +390,42 @@ interactions: trailer: { } content_length: -1 uncompressed: true + body: '{"id":"01GEPVQEH9SX3RSTYY561TR92N","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"enabled":true,"triggerId":"pre-user-registration"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 11 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N/secrets + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: 2 + uncompressed: false body: '{}' headers: Content-Type: @@ -217,7 +433,7 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 6 + - id: 12 request: proto: HTTP/1.1 proto_major: 1 @@ -234,8 +450,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWEFDT9RFR6PN6939RZZE + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQEH9SX3RSTYY561TR92N method: DELETE response: proto: HTTP/2.0 diff --git a/test/data/recordings/TestAccHookSecrets.yaml b/test/data/recordings/TestAccHookSecrets.yaml index c45657b22..7e5a507ad 100644 --- a/test/data/recordings/TestAccHookSecrets.yaml +++ b/test/data/recordings/TestAccHookSecrets.yaml @@ -19,7 +19,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks method: POST response: @@ -28,9 +28,9 @@ interactions: proto_minor: 0 transfer_encoding: [ ] trailer: { } - content_length: -1 + content_length: 223 uncompressed: false - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"triggerId":"pre-user-registration","enabled":true}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"triggerId":"pre-user-registration","enabled":true}' headers: Content-Type: - application/json; charset=utf-8 @@ -55,8 +55,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -64,8 +64,8 @@ interactions: proto_minor: 0 transfer_encoding: [ ] trailer: { } - content_length: -1 - uncompressed: true + content_length: 2 + uncompressed: false body: '{}' headers: Content-Type: @@ -91,8 +91,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: POST response: proto: HTTP/2.0 @@ -100,7 +100,7 @@ interactions: proto_minor: 0 transfer_encoding: [ ] trailer: { } - content_length: -1 + content_length: 2 uncompressed: false body: '{}' headers: @@ -127,8 +127,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: GET response: proto: HTTP/2.0 @@ -138,7 +138,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 @@ -163,8 +163,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -199,8 +199,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: GET response: proto: HTTP/2.0 @@ -210,7 +210,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 @@ -235,8 +235,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -271,8 +271,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: GET response: proto: HTTP/2.0 @@ -282,7 +282,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 @@ -307,8 +307,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -343,8 +343,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: PATCH response: proto: HTTP/2.0 @@ -354,7 +354,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"triggerId":"pre-user-registration","enabled":true}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"triggerId":"pre-user-registration","enabled":true}' headers: Content-Type: - application/json; charset=utf-8 @@ -379,8 +379,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -415,8 +415,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: POST response: proto: HTTP/2.0 @@ -424,7 +424,7 @@ interactions: proto_minor: 0 transfer_encoding: [ ] trailer: { } - content_length: -1 + content_length: 2 uncompressed: false body: '{}' headers: @@ -451,8 +451,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: PATCH response: proto: HTTP/2.0 @@ -460,7 +460,7 @@ interactions: proto_minor: 0 transfer_encoding: [ ] trailer: { } - content_length: -1 + content_length: 2 uncompressed: false body: '{}' headers: @@ -487,8 +487,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: GET response: proto: HTTP/2.0 @@ -498,7 +498,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 @@ -523,8 +523,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -559,8 +559,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: GET response: proto: HTTP/2.0 @@ -570,7 +570,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 @@ -595,8 +595,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -631,8 +631,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: GET response: proto: HTTP/2.0 @@ -642,7 +642,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 @@ -667,8 +667,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -703,8 +703,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: PATCH response: proto: HTTP/2.0 @@ -714,7 +714,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"triggerId":"pre-user-registration","enabled":true}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"triggerId":"pre-user-registration","enabled":true}' headers: Content-Type: - application/json; charset=utf-8 @@ -739,8 +739,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -775,8 +775,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: PATCH response: proto: HTTP/2.0 @@ -784,7 +784,7 @@ interactions: proto_minor: 0 transfer_encoding: [ ] trailer: { } - content_length: -1 + content_length: 2 uncompressed: false body: '{}' headers: @@ -811,8 +811,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: DELETE response: proto: HTTP/2.0 @@ -847,8 +847,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: GET response: proto: HTTP/2.0 @@ -858,7 +858,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 @@ -883,8 +883,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -919,8 +919,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: GET response: proto: HTTP/2.0 @@ -930,7 +930,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"01GBPZWHNHPCQJB116XTN9AX84","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' headers: Content-Type: - application/json; charset=utf-8 @@ -955,8 +955,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84/secrets + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets method: GET response: proto: HTTP/2.0 @@ -974,6 +974,330 @@ interactions: code: 200 duration: 1ms - id: 27 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{"auth0":"2.30.0"},"enabled":true,"triggerId":"pre-user-registration"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 28 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"foo":"_VALUE_NOT_SHOWN_"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 29 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 138 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"enabled":true} + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 + method: PATCH + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"triggerId":"pre-user-registration","enabled":true}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 30 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"foo":"_VALUE_NOT_SHOWN_"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 31 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 8 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + ["foo"] + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets + method: DELETE + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: 0 + uncompressed: false + body: "" + headers: + Content-Type: + - application/json; charset=utf-8 + status: 204 No Content + code: 204 + duration: 1ms + - id: 32 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"enabled":true,"triggerId":"pre-user-registration"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 33 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: 2 + uncompressed: false + body: '{}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 34 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"01GEPVQNVSHW1ZVB7WVPRYKX18","name":"pre-user-reg-hook","script":"function (user, context, callback) { callback(null, { user }); }","dependencies":{},"enabled":true,"triggerId":"pre-user-registration"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 35 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18/secrets + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: 2 + uncompressed: false + body: '{}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 36 request: proto: HTTP/1.1 proto_major: 1 @@ -990,8 +1314,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GBPZWHNHPCQJB116XTN9AX84 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/hooks/01GEPVQNVSHW1ZVB7WVPRYKX18 method: DELETE response: proto: HTTP/2.0 diff --git a/test/data/recordings/TestAccLogStreamHTTP.yaml b/test/data/recordings/TestAccLogStreamHTTP.yaml index 48960ecf7..a3487fcb7 100644 --- a/test/data/recordings/TestAccLogStreamHTTP.yaml +++ b/test/data/recordings/TestAccLogStreamHTTP.yaml @@ -19,7 +19,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams method: POST response: @@ -30,7 +30,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"active","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"active","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -55,8 +55,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: PATCH response: proto: HTTP/2.0 @@ -66,7 +66,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -91,8 +91,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -102,7 +102,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -127,8 +127,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -138,7 +138,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -163,8 +163,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -174,7 +174,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -186,21 +186,21 @@ interactions: proto: HTTP/1.1 proto_major: 1 proto_minor: 1 - content_length: 267 + content_length: 249 transfer_encoding: [ ] trailer: { } host: terraform-provider-auth0-dev.eu.auth0.com remote_addr: "" request_uri: "" body: | - {"name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","status":"paused","sink":{"httpContentFormat":"JSONARRAY","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs","httpAuthorization":"AKIAXXXXXXXXXXXXXXXX"}} + {"name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","sink":{"httpContentFormat":"JSONARRAY","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs","httpAuthorization":"AKIAXXXXXXXXXXXXXXXX"}} form: { } headers: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: PATCH response: proto: HTTP/2.0 @@ -210,7 +210,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONARRAY","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONARRAY","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -235,8 +235,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -246,7 +246,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONARRAY","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONARRAY","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -271,8 +271,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -282,7 +282,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONARRAY","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONARRAY","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -307,8 +307,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -318,7 +318,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONARRAY","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONARRAY","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -330,21 +330,21 @@ interactions: proto: HTTP/1.1 proto_major: 1 proto_minor: 1 - content_length: 268 + content_length: 250 transfer_encoding: [ ] trailer: { } host: terraform-provider-auth0-dev.eu.auth0.com remote_addr: "" request_uri: "" body: | - {"name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","status":"paused","sink":{"httpContentFormat":"JSONOBJECT","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs","httpAuthorization":"AKIAXXXXXXXXXXXXXXXX"}} + {"name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","sink":{"httpContentFormat":"JSONOBJECT","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs","httpAuthorization":"AKIAXXXXXXXXXXXXXXXX"}} form: { } headers: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: PATCH response: proto: HTTP/2.0 @@ -354,7 +354,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONOBJECT","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONOBJECT","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -379,8 +379,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -390,7 +390,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONOBJECT","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONOBJECT","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -415,8 +415,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -426,7 +426,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONOBJECT","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONOBJECT","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -451,8 +451,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -462,7 +462,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONOBJECT","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONOBJECT","httpContentType":"application/json; charset=utf-8","httpEndpoint":"https://example.com/webhook/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -474,21 +474,21 @@ interactions: proto: HTTP/1.1 proto_major: 1 proto_minor: 1 - content_length: 248 + content_length: 230 transfer_encoding: [ ] trailer: { } host: terraform-provider-auth0-dev.eu.auth0.com remote_addr: "" request_uri: "" body: | - {"name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","status":"paused","sink":{"httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpAuthorization":"AKIAXXXXXXXXXXXXXXXX"}} + {"name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","sink":{"httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpAuthorization":"AKIAXXXXXXXXXXXXXXXX"}} form: { } headers: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: PATCH response: proto: HTTP/2.0 @@ -498,7 +498,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -523,8 +523,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -534,7 +534,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -559,8 +559,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -570,7 +570,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -595,8 +595,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -606,7 +606,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs"}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -618,21 +618,21 @@ interactions: proto: HTTP/1.1 proto_major: 1 proto_minor: 1 - content_length: 332 + content_length: 314 transfer_encoding: [ ] trailer: { } host: terraform-provider-auth0-dev.eu.auth0.com remote_addr: "" request_uri: "" body: | - {"name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","status":"paused","sink":{"httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpCustomHeaders":[{"header":"foo","value":"bar"},{"header":"bar","value":"foo"}]}} + {"name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","sink":{"httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpCustomHeaders":[{"header":"foo","value":"bar"},{"header":"bar","value":"foo"}]}} form: { } headers: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: PATCH response: proto: HTTP/2.0 @@ -642,7 +642,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpCustomHeaders":[{"header":"foo","value":"bar"},{"header":"bar","value":"foo"}]}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpCustomHeaders":[{"header":"foo","value":"bar"},{"header":"bar","value":"foo"}]}}' headers: Content-Type: - application/json; charset=utf-8 @@ -667,8 +667,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -678,7 +678,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpCustomHeaders":[{"header":"foo","value":"bar"},{"header":"bar","value":"foo"}]}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpCustomHeaders":[{"header":"foo","value":"bar"},{"header":"bar","value":"foo"}]}}' headers: Content-Type: - application/json; charset=utf-8 @@ -703,8 +703,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: GET response: proto: HTTP/2.0 @@ -714,7 +714,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010031","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpCustomHeaders":[{"header":"foo","value":"bar"},{"header":"bar","value":"foo"}]}}' + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpCustomHeaders":[{"header":"foo","value":"bar"},{"header":"bar","value":"foo"}]}}' headers: Content-Type: - application/json; charset=utf-8 @@ -722,6 +722,150 @@ interactions: code: 200 duration: 1ms - id: 20 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpCustomHeaders":[{"header":"foo","value":"bar"},{"header":"bar","value":"foo"}]}}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 21 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 253 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","sink":{"httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpCustomHeaders":[]}} + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 + method: PATCH + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpCustomHeaders":[]}}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 22 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpCustomHeaders":[]}}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 23 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"lst_0000000000007100","name":"Acceptance-Test-LogStream-http-new-TestAccLogStreamHTTP","type":"http","status":"paused","sink":{"httpAuthorization":"AKIAXXXXXXXXXXXXXXXX","httpContentFormat":"JSONLINES","httpContentType":"application/json","httpEndpoint":"https://example.com/logs","httpCustomHeaders":[]}}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 24 request: proto: HTTP/1.1 proto_major: 1 @@ -738,8 +882,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010031 + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000007100 method: DELETE response: proto: HTTP/2.0 diff --git a/test/data/recordings/TestAccLogStreamSumo.yaml b/test/data/recordings/TestAccLogStreamSumo.yaml index f4127d46f..e3d134d0c 100644 --- a/test/data/recordings/TestAccLogStreamSumo.yaml +++ b/test/data/recordings/TestAccLogStreamSumo.yaml @@ -19,7 +19,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/0.11.0 url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams method: POST response: @@ -30,7 +30,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"demo.sumo.com"}}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"demo.sumo.com"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -55,8 +55,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: GET response: proto: HTTP/2.0 @@ -66,7 +66,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"demo.sumo.com"}}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"demo.sumo.com"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -91,8 +91,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: GET response: proto: HTTP/2.0 @@ -102,7 +102,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"demo.sumo.com"}}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"demo.sumo.com"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -127,8 +127,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: GET response: proto: HTTP/2.0 @@ -138,7 +138,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"demo.sumo.com"}}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"demo.sumo.com"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -150,21 +150,21 @@ interactions: proto: HTTP/1.1 proto_major: 1 proto_minor: 1 - content_length: 126 + content_length: 108 transfer_encoding: [ ] trailer: { } host: terraform-provider-auth0-dev.eu.auth0.com remote_addr: "" request_uri: "" body: | - {"name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}} + {"name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","sink":{"sumoSourceAddress":"prod.sumo.com"}} form: { } headers: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: PATCH response: proto: HTTP/2.0 @@ -174,7 +174,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -199,8 +199,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: GET response: proto: HTTP/2.0 @@ -210,7 +210,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -235,8 +235,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: GET response: proto: HTTP/2.0 @@ -246,7 +246,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -271,8 +271,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: GET response: proto: HTTP/2.0 @@ -282,7 +282,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' headers: Content-Type: - application/json; charset=utf-8 @@ -294,21 +294,21 @@ interactions: proto: HTTP/1.1 proto_major: 1 proto_minor: 1 - content_length: 229 + content_length: 211 transfer_encoding: [ ] trailer: { } host: terraform-provider-auth0-dev.eu.auth0.com remote_addr: "" request_uri: "" body: | - {"name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","status":"active","filters":[{"name":"auth.login.fail","type":"category"},{"name":"auth.signup.fail","type":"category"}],"sink":{"sumoSourceAddress":"prod.sumo.com"}} + {"name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","filters":[{"name":"auth.login.fail","type":"category"},{"name":"auth.signup.fail","type":"category"}],"sink":{"sumoSourceAddress":"prod.sumo.com"}} form: { } headers: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: PATCH response: proto: HTTP/2.0 @@ -318,7 +318,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"},"filters":[{"name":"auth.login.fail","type":"category"},{"name":"auth.signup.fail","type":"category"}]}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"},"filters":[{"name":"auth.login.fail","type":"category"},{"name":"auth.signup.fail","type":"category"}]}' headers: Content-Type: - application/json; charset=utf-8 @@ -343,8 +343,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: GET response: proto: HTTP/2.0 @@ -354,7 +354,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"},"filters":[{"name":"auth.login.fail","type":"category"},{"name":"auth.signup.fail","type":"category"}]}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"},"filters":[{"name":"auth.login.fail","type":"category"},{"name":"auth.signup.fail","type":"category"}]}' headers: Content-Type: - application/json; charset=utf-8 @@ -379,8 +379,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: GET response: proto: HTTP/2.0 @@ -390,7 +390,7 @@ interactions: trailer: { } content_length: -1 uncompressed: true - body: '{"id":"lst_0000000000010036","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"},"filters":[{"name":"auth.login.fail","type":"category"},{"name":"auth.signup.fail","type":"category"}]}' + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"},"filters":[{"name":"auth.login.fail","type":"category"},{"name":"auth.signup.fail","type":"category"}]}' headers: Content-Type: - application/json; charset=utf-8 @@ -398,6 +398,150 @@ interactions: code: 200 duration: 1ms - id: 11 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"},"filters":[{"name":"auth.login.fail","type":"category"},{"name":"auth.signup.fail","type":"category"}]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 12 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 121 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","filters":[],"sink":{"sumoSourceAddress":"prod.sumo.com"}} + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 + method: PATCH + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 13 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 14 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"id":"lst_0000000000010354","name":"Acceptance-Test-LogStream-sumo-TestAccLogStreamSumo","type":"sumo","status":"active","sink":{"sumoSourceAddress":"prod.sumo.com"}}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 15 request: proto: HTTP/1.1 proto_major: 1 @@ -414,8 +558,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 - url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010036 + - Go-Auth0-SDK/0.11.0 + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/log-streams/lst_0000000000010354 method: DELETE response: proto: HTTP/2.0 diff --git a/test/data/recordings/TestAccPrompt.yaml b/test/data/recordings/TestAccPrompt.yaml index a20264c13..25c448d13 100644 --- a/test/data/recordings/TestAccPrompt.yaml +++ b/test/data/recordings/TestAccPrompt.yaml @@ -2,6 +2,150 @@ version: 2 interactions: - id: 0 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 27 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"identifier_first":false} + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts + method: PATCH + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"universal_login_experience":"new","identifier_first":false,"webauthn_platform_first_factor":true}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 1 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"universal_login_experience":"new","identifier_first":false,"webauthn_platform_first_factor":true}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 2 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"universal_login_experience":"new","identifier_first":false,"webauthn_platform_first_factor":true}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 3 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"universal_login_experience":"new","identifier_first":false,"webauthn_platform_first_factor":true}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 4 request: proto: HTTP/1.1 proto_major: 1 @@ -19,7 +163,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: PATCH response: @@ -37,7 +181,7 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 1 + - id: 5 request: proto: HTTP/1.1 proto_major: 1 @@ -55,7 +199,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: GET response: @@ -73,7 +217,7 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 2 + - id: 6 request: proto: HTTP/1.1 proto_major: 1 @@ -91,7 +235,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: GET response: @@ -109,7 +253,7 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 3 + - id: 7 request: proto: HTTP/1.1 proto_major: 1 @@ -127,7 +271,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: GET response: @@ -145,7 +289,7 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 4 + - id: 8 request: proto: HTTP/1.1 proto_major: 1 @@ -163,7 +307,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: PATCH response: @@ -181,7 +325,7 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 5 + - id: 9 request: proto: HTTP/1.1 proto_major: 1 @@ -199,7 +343,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: GET response: @@ -217,7 +361,7 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 6 + - id: 10 request: proto: HTTP/1.1 proto_major: 1 @@ -235,7 +379,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: GET response: @@ -253,7 +397,7 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 7 + - id: 11 request: proto: HTTP/1.1 proto_major: 1 @@ -271,7 +415,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: GET response: @@ -289,7 +433,7 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 8 + - id: 12 request: proto: HTTP/1.1 proto_major: 1 @@ -307,7 +451,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: PATCH response: @@ -325,7 +469,7 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 9 + - id: 13 request: proto: HTTP/1.1 proto_major: 1 @@ -343,7 +487,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: GET response: @@ -361,7 +505,79 @@ interactions: status: 200 OK code: 200 duration: 1ms - - id: 10 + - id: 14 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"universal_login_experience":"new","identifier_first":false,"webauthn_platform_first_factor":true}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 15 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [ ] + trailer: { } + host: terraform-provider-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: { } + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [ ] + trailer: { } + content_length: -1 + uncompressed: true + body: '{"universal_login_experience":"new","identifier_first":false,"webauthn_platform_first_factor":true}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 1ms + - id: 16 request: proto: HTTP/1.1 proto_major: 1 @@ -379,7 +595,7 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0-SDK/0.10.0 + - Go-Auth0-SDK/latest url: https://terraform-provider-auth0-dev.eu.auth0.com/api/v2/prompts method: GET response: